Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
    Bookmark Topic Watch Topic
  • New Topic

scamble --> help me to solve it

 
Manisekar Chinnasami
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Report post to moderator
hi friends,

here is the problem ...

i need to get all the combinations of a word ...

in detail ... if the input string is "man", then the output should be ...
(all itz combinations)
man
mna
amn
anm
nma
nam

three is little bit easy , but i need it for word with minimum five letters ....
 
Gavin Tranter
Ranch Hand
Posts: 333
  • Mark post as helpful
  • send pies
  • Report post to moderator
how did you calculate the combinations of MAN, cant you just use the same method/algorithmn for 5 plus?

[ August 07, 2007: Message edited by: Gavin Tranter ]
[ August 07, 2007: Message edited by: Gavin Tranter ]
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24211
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Report post to moderator
Duplicate, please continue here.
 
    Bookmark Topic Watch Topic
  • New Topic