diff --git a/cv1/program.c b/cv1/program.c index b71697d..7bd13c7 100644 --- a/cv1/program.c +++ b/cv1/program.c @@ -48,10 +48,11 @@ int main() { price[strcspn(price, "\n")] = 0; decode_hacker_script(menu_item, decoded_item); - count++; // Zvyšujeme count pre každú načítanú položku + count++; + double price_value = atof(price); if (strstr(decoded_item, decoded_search) != NULL) { - printf("%s\n%.2f\n", menu_item, price); + printf("%s\n%.2f\n", menu_item, price_value); } } @@ -59,4 +60,3 @@ int main() { return 0; } -