Initializacia
This commit is contained in:
parent
df6e7666dc
commit
ec266a099f
@ -28,9 +28,10 @@ int main() {
|
|||||||
fgets(ingredient, MAX_INPUT_LENGTH, stdin);
|
fgets(ingredient, MAX_INPUT_LENGTH, stdin);
|
||||||
ingredient[strcspn(ingredient, "\n")] = 0; // Remove newline character
|
ingredient[strcspn(ingredient, "\n")] = 0; // Remove newline character
|
||||||
|
|
||||||
|
printf("Zadaj jedalny listok:\n"); // Print the prompt
|
||||||
|
|
||||||
// Read the menu items
|
// Read the menu items
|
||||||
while (1) {
|
while (1) {
|
||||||
printf("Zadaj jedalny listok: ");
|
|
||||||
fgets(menu_item, MAX_INPUT_LENGTH, stdin);
|
fgets(menu_item, MAX_INPUT_LENGTH, stdin);
|
||||||
if (feof(stdin) || strlen(menu_item) == 1) {
|
if (feof(stdin) || strlen(menu_item) == 1) {
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user