18 lines
304 B
C
18 lines
304 B
C
#include <stdio.h>
|
|
#include <stdlib.h>
|
|
#include <string.h>
|
|
#include <ctype.h>
|
|
|
|
typedef struct tree{
|
|
char value[256];
|
|
struct tree* left; //ano
|
|
struct tree* right; // nie
|
|
}Tree;
|
|
|
|
void trim_newline(char *str){
|
|
size_t len = strlen(str);
|
|
if(len > 0 && (str[len -1] == '\n')){
|
|
str[len - 1] = '\0';
|
|
}
|
|
}
|