I have this on my program and it shows an error saying : Unterminated string.
char Tok[63][63] = {"%%##","\""};
Is there other way to declare the double quotation mark as a string?
I have this on my program and it shows an error saying : Unterminated string.
char Tok[63][63] = {"%%##","\""};
Is there other way to declare the double quotation mark as a string?
This is a bug in Turbo C. I have tried:
char Tok[63][63] = { "%%##", "\"" };
int
main (int argc, char **argv)
{
return 0;
};
on gcc, in normal mode, C89 mode, and C99 mode with -Wall
and it compiles without errors (*). I have also manually reviewed the string and there is no way it is unterminated.
I suggest you use octal within your string literal, i.e.
char Tok[63][63] = { "%%##", "\042" };
and see if Turbo C likes that.
(*) = NB return 0
is not good practice from main()
- just there to ensure the code compiles without warnings in the simplest way possible