I use a AT89S52 and programming with KEIL C51.How can I implement a look-up table for string ? My array example : array[0] = "ABC" array[1] = "Hello" array[2] = "Good morning" array[3] = "Good night"
Just to pick a nit what do you mean by array[0] = {"ABC"}; Do you mean to write array0[] = {"ABC"}; Bradford
"Just to pick a nit what do you mean by array[0] = {"ABC"};" He didn't write the curly braces; he actually wrote:
array[0] = "ABC"
"That would be a definition (with initialisation) of an array of chatacters..." Actually, it wouldn't quite be that - because the type specification is missing!
"You need to study a 'C' textbook." If you are already a Pascal programmer, 'C' isn't really all that different. The C Programming Language (2nd Edition) by Brian W. Kernighan & Dennis M. Ritchie (Prentice Hall) should be sufficient for you. http://www.amazon.co.uk/exec/obidos/ASIN/0131103628/qid=1123320611/sr=1-1/ref=sr_1_10_1/202-7712637-9820637