Обновить cv7/program.c
This commit is contained in:
parent
382ffe54c1
commit
9b22d42909
@ -31,7 +31,6 @@ Node* load_knowledge_base() {
|
||||
|
||||
if (line[0] == '\n') return NULL;
|
||||
|
||||
// Создание узла
|
||||
Node *node = create_node(line);
|
||||
|
||||
if (line[0] != '*') {
|
||||
@ -50,13 +49,14 @@ int count_items(Node *node) {
|
||||
void ask_question(Node *node) {
|
||||
if (node == NULL) return;
|
||||
|
||||
printf("%s", node->text);
|
||||
|
||||
if (node->text[0] == '*') {
|
||||
printf("Expert z bufetu to vie.\n");
|
||||
return;
|
||||
}
|
||||
|
||||
printf("Odpovedajte 'a' pre prvu moznost alebo 'n' pre druhu moznost.\n");
|
||||
printf("%s", node->text);
|
||||
|
||||
char answer;
|
||||
if (scanf(" %c", &answer) != 1) {
|
||||
|
Loading…
Reference in New Issue
Block a user