September 17th, 2011, 06:48 AM
Strings in variable names?
So say I have a string called name which maybe be equal to "Sam" or "Max" or maybe "Betty". I'm trying to make a variable that has a different name for each value of name.
For example it might be Samitems or Maxitems or Bettyitems.
Is there anyway way to insert a string into a variable name?
September 17th, 2011, 07:38 AM
Re: Strings in variable names?
You create variable names when you type them into the source code.
anyway way to insert a string into a variable name?
If you want to use a String to access a value when the a program is executing, look at the Map class.
Tags for this Thread
Click Here to Expand Forum to Full Width
This a Codeguru.com survey!