View Single Post
Old Jul 10th, 2005, 2:29 PM   #2
DaWei
Resident Grouch
 
DaWei's Avatar
 
Join Date: Jun 2005
Posts: 6,453
Rep Power: 10 DaWei is on a distinguished road
I would suggest that you take a different tack. Either use a map (key => value, which is the building number => building name), or simply an array whose elements contain the building names. Element 0 would represent building 0, "Sears Hardware", and so forth.

One can't see all your code, but you have a fundamental problem when you say you can't properly return the string. I don't give a crap if the Pope anointed it, you can't return it from a function defined as returning a void. Your description is somewhat ambiguous regarding what you are actually trying to do, somewhat as if you're frustrated and have turned to trying Voodoo without first killing a good chicken. Consequently, perhaps I have misunderstood, somewhat.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code.
Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers
DaWei is offline   Reply With Quote