7
This commit is contained in:
parent
7bd6f0c84f
commit
e7574f64e9
@ -48,9 +48,10 @@ int count_products(Node *node) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void run_expert_system(Node *node) {
|
void run_expert_system(Node *node) {
|
||||||
|
printf("Expert z bufetu to vie.\n");
|
||||||
|
|
||||||
while (node) {
|
while (node) {
|
||||||
if (!node->yes && !node->no) {
|
if (!node->yes && !node->no) {
|
||||||
printf("Expert z bufetu to vie.\n");
|
|
||||||
printf("*%s\n", node->text);
|
printf("*%s\n", node->text);
|
||||||
printf("Koniec\n");
|
printf("Koniec\n");
|
||||||
return;
|
return;
|
||||||
@ -84,7 +85,7 @@ void create_default_knowledge_base() {
|
|||||||
perror("Failed to create the knowledge base file");
|
perror("Failed to create the knowledge base file");
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
fprintf(file, "Je to ovocie alebo zelenina?\n");
|
fprintf(file, "Je to ovocie alebo zelenina\n");
|
||||||
fprintf(file, "*Jablko\n");
|
fprintf(file, "*Jablko\n");
|
||||||
fprintf(file, "*Mrkva\n");
|
fprintf(file, "*Mrkva\n");
|
||||||
fclose(file);
|
fclose(file);
|
||||||
|
Loading…
Reference in New Issue
Block a user