Problem:
Copy a piece of code from the net, paste into the program strcat_compare.c of oneself write, then compile Gcc-o strcat_compare strcat_compare.c;
The error occurs as follows:
Copy Code code as follows:
avid@ubuntu:~/wrk/tmp$ Gcc-o Strcat_compare strcat_compare.c
strcat_compare.c:in function ' main ':
Strcat_compare.c:28:1: Error:stray ' \343 ' in the program
Strcat_compare.c:28:1: Error:stray ' \200 ' in the program
Strcat_compare.c:28:1: Error:stray ' \200 ' in the program
Strcat_compare.c:28:1: Error:stray ' \343 ' in the program
Strcat_compare.c:28:1: Error:stray ' \200 ' in the program
Strcat_compare.c:28:1: Error:stray ' \200 ' in the program
Strcat_compare.c:30:1: Error:stray ' \343 ' in the program
Strcat_compare.c:30:1: Error:stray ' \200 ' in the program
Strcat_compare.c:30:1: Error:stray ' \200 ' in the program
Strcat_compare.c:30:1: Error:stray ' \343 ' in the program
Strcat_compare.c:30:1: Error:stray ' \200 ' in the program
Strcat_compare.c:30:1: Error:stray ' \200 ' in the program
Strcat_compare.c:32:1: Error:stray ' \343 ' in the program
Strcat_compare.c:32:1: Error:stray ' \200 ' in the program
Strcat_compare.c:32:1: Error:stray ' \200 ' in the program
Strcat_compare.c:32:1: Error:stray ' \343 ' in the program
Strcat_compare.c:32:1: Error:stray ' \200 ' in the program
Strcat_compare.c:32:1: Error:stray ' \200 ' in the program
david@ubuntu:~/wrk/tmp$
Operating environment: Ubuntu 11.10;
Solution:
1. Put the dog search, said that the program itself may have no problem with the grammar, but the error line contains unrecognized characters, such as the format of the space is not correct;
2. Delete the space in front of the error line in the program, reinsert the space or the TAB key, recompile, and the error disappears.
OK, problem solved.