This commit is contained in:
Bohdan Kapliuk 2024-11-11 14:24:03 +02:00
parent 6c44c29d69
commit 527f0cfb1d

View File

@ -52,11 +52,12 @@ void print_tree(struct tree* tree,int offset){
}
getchar();
char r = getchar();
getchar();
if (r == 'a') {
print_tree(tree->left, offset + 3);
} else if (r == 'n') {
print_tree(tree->right, offset + 3);
} else if (r == '\n'){
printf("Koniec vstupu\n");
}else {
printf("Nerozumiem\n");
exit(0);