Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Sorting Strings having digits and dots(.)

807589Nov 18 2008 — edited Dec 2 2008
I would like to sort an array of strings having values like 1, 1.1, 2, 2.1, 1.1.1, 2.1.1, 1.1.2 and so on.
this should be sorted as 1, 1.1, 1.1.1, 1.1.2, 2, 2.1, 2.1.1
if u can think of an effective algo, plz help me.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 30 2008
Added on Nov 18 2008
17 comments
2,094 views