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...


Sample code to retrieve objects from HashMap in sorted
ascending order?

Answers were Sorted based on User's Feedback



Sample code to retrieve objects from HashMap in sorted ascending order?..

Answer / murli

Map hm = new HashMap();
//add values to hashmap
Map tm = new TreeMap(hm);
//Iterate keySet in tm

Is This Answer Correct ?    9 Yes 2 No

Sample code to retrieve objects from HashMap in sorted ascending order?..

Answer / amit badgujar

Yes it is correct

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More Core Java Interview Questions

what is nested class in java?

0 Answers   IBS,


What is the purpose of a default constructor?

0 Answers  


What is the difference between call by reference and call by pointer?

0 Answers  


How to Sort list of Strings in ascending order without using java api.

1 Answers   HCL, NIIT,


Difference between method overloading and overriding.

0 Answers  


What advantage do java's layout managers provide over traditional windowing systems?

0 Answers  


Can we extend singleton class?

0 Answers  


What is increment in java?

0 Answers  


What is java abstraction with example?

0 Answers  


What are the limitations for static method?

3 Answers   Greenwood,


What is meant by controls and types?

1 Answers  


How to create packages in java?

0 Answers  


Categories