Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

how do you store phone numbers using java collections

Answer Posted / shahnawaz sheikh

Using HashMap.. can be one of the way.

HashMap hs = new HashMap();

hs.put("amit","989213232");
hs.put("john","989211422");
hs.put("Alex","989214578");

Is This Answer Correct ?    6 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Define an enumeration?

1002


What is threaded programming and when is it used? : Java thread

1036


What is a memory leak in java?

1035


What is a map in java?

947


What is classpath?

979


What is the method in java?

1045


Can each java object keep track of all the threads that want to exclusively access it?

924


What is the purpose of encapsulation?

972


What is the difference between a window and a frame in java programming?

1098


What are three types of loops in java?

1082


Can a static member function access member variable of an object?

974


What is thread synchronization in java?

869


What is a java object and java application?

1009


What is the difference between char and char *?

1035


What are the pillars of java?

885