telegrafista

This commit is contained in:
Maryna Kravtsova 2020-12-03 15:25:17 +01:00
parent fd4a72cda6
commit 6f2d67a8e1

View File

@ -65,7 +65,10 @@ void search(struct morsetree* root, char* decode){
printf("\n"); printf("\n");
return; return;
}*/ }*/
if(decode[i+1] == ' ' || decode[i+1] == '\n' || decode[i+1] == '\0'){ if(decode[i] == ' ' || decode[i] == '\n' || decode[i] == '\0'){
if(i == strlen(decode)){
return;
}
printf("%c", this->letter); printf("%c", this->letter);
this = root; this = root;
} }