Question: 1. (String permutation) Write a recursive method public static void displayPermutation(String s) in a class named Question1.java, to print all the permutations of a string.

1. (String permutation) Write a recursive method public static void displayPermutation(String s) in a class named Question1.java, to print all the permutations of a string. For example, Input: abc Output: All possible permutations of abc are: abc acb bac bca cab cba

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!