Hi, i was writing a program to make permutations of strings, but I ran into a snag and can't figure out what's wrong. It prints out the permutated strings, but some of them are duplicates.
I attached the source
Thanks for the help.
Dark_Omen 5 Posting Pro
Recommended Answers
Jump to PostSince you are using arraylist, use the contains() method to check if the entry already exists. If it doesn't, then add it.
All 3 Replies
Reply to this topic Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.