Hi everyone. I'm trying to get my code to automatically print out string literals called MESSAGE1, MESSAGE2, etc. However, the compiler tells me that it cannot find MESSAGEi. This isn't what I want, obviously. How do I do it properly?
Richard
]Code:#define MESSAGE(i) MESSAGE##i #define MESSAGELINES 2 #define MESSAGE1 "First string" #define MESSAGE2 "Second string" int i ; for ( i = 0 ; i < MESSAGELINES ; i++ ) printf ( "%s" , MESSAGE(i) ); return 0;