diff --git a/cv7/program.c b/cv7/program.c index 006e273..eb7ba1e 100644 --- a/cv7/program.c +++ b/cv7/program.c @@ -48,9 +48,10 @@ int count_products(Node *node) { } void run_expert_system(Node *node) { + printf("Expert z bufetu to vie.\n"); + while (node) { if (!node->yes && !node->no) { - printf("Expert z bufetu to vie.\n"); printf("*%s\n", node->text); printf("Koniec\n"); return; @@ -84,7 +85,7 @@ void create_default_knowledge_base() { perror("Failed to create the knowledge base file"); exit(1); } - fprintf(file, "Je to ovocie alebo zelenina?\n"); + fprintf(file, "Je to ovocie alebo zelenina\n"); fprintf(file, "*Jablko\n"); fprintf(file, "*Mrkva\n"); fclose(file);