java - HashMap and sorting -
i building trie, each node has hashmap sons' value stored, , keys name.
i'm using hashmap because, mainly, need performances instead of sorting, instead have used treemap, of course.
now, need, in function, sort hash map values key values (that strings). i'm using iterator iterate values.
any suggest?
thank you
you should put map.keyset in list sort , iterate on list of sorted keys.
Comments
Post a Comment