Ask your own question, for FREE!
Computer Science 8 Online
OpenStudy (anonymous):

i want to write phoneBook program in java and i have arraylist of contacts and want to sort by last name what should i do ?

OpenStudy (microbot):

is it a 2-dimentional array?

OpenStudy (anonymous):

array?

OpenStudy (microbot):

ye sry doesnt matter xD read wrong :P

OpenStudy (microbot):

do you have some code to share so i can help you ? (not sure i can but i can try :P)

OpenStudy (anonymous):

i mean arraylist have some methods like get, set, add, any exist for sorting an object by one of it' elements?

OpenStudy (microbot):

the sort method if i am not wrong...or you could override the existing sorting method and make your own.

OpenStudy (anonymous):

You need to implement a sorting algorithm on the arraylist... Like a bubble sort on the last name.

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Latest Questions
Arriyanalol: i need help
14 hours ago 7 Replies 1 Medal
Arriyanalol: CONGRATS to me
17 hours ago 8 Replies 2 Medals
Legomaster346: What colleges are good that are near Arab Alabama?
1 week ago 5 Replies 0 Medals
Arriyanalol: i need help
1 week ago 6 Replies 2 Medals
Arizona: does anyone know the percentage rate of 30,000 and 40,000
1 week ago 0 Replies 0 Medals
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!