Hey newb problem here need help

Joined
Feb 16, 2009
Messages
1
Reaction score
0
Hey alright heres what im trying to accomplish.

I want to be able to add strings to an arraylist and then give them a numerical value.
Like:

int coolness;
static ArrayList<String> people = new ArrayList<String>();
people.add(sam);


and then something like
people.sam.coolness = 999999;


How is this accomplished? thanks!
 
Joined
Dec 24, 2010
Messages
19
Reaction score
0
samyouel said:
Hey alright heres what im trying to accomplish.

I want to be able to add strings to an arraylist and then give them a numerical value.
Like:

int coolness;
static ArrayList<String> people = new ArrayList<String>();
people.add(sam);


and then something like
people.sam.coolness = 999999;


How is this accomplished? thanks!
not sure about your question but would not it work
people.sam.coolness = String.valueOf(999999);
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,814
Latest member
SpicetreeDigital

Latest Threads

Top