I found a nice example of how to use strcmp, but it\'s only working with fgets(), and i need to make it work with scanf. So, here\'s the code:
int main(void) { c
"scanf" does take newline "\n" character as input. So you are not able to equal the both strings. if you want to equal both strings you need to remove newline"\n" form the first string ("apple" is fine).