I had managed to get a variable to print out a #defined definition, but than I accidentally deleted the code and can not figure it out. I am hoping that someone may be able to point me in the right direction.
What I am getting is the 'aaa' and not 'one' to print. I know I am doing something wrong, but I can not see it.
yea sorry that was a bad explanation and sample code. What I am trying to do is find a way to automate that so I do not have to turn the 'aaa' into a for loop that can call it instead of me having to type out aaa, aab, aac . . . every time.
What it is suppose to be is a three digit alpha code that is assigned to the defined definition. when I start up the program it will assign 'aaa, aab, aac, ect' into an Array[x][x]. Than later in the program when it is printed to the screen instead of seeing 'aaa' you would instead see the #defined code, 'one' in the above code. I had this working before, but accidentally deleted the code and have been stuck for the last twoish days.
edit:
essentially I do not want to have to type aaa - zzz to add it to the array one line at a time. which i know how to do, but I can not get it to print out the defined value
you "could" make function pointer array out of Array[] to do it, I *think*. This isn't anything I would attempt to do, but I am fairly sure it would be possible with some effort.
But this feels like you should just use a <map> or an array of structs with both values or something to avoid the uglies.