Hi friends...

I need to write a program in C which will print all the combinations of a string with non-repeating characters. Example: “Say” will have the following: s, a,y, sa, sy, as,sy, ys, ya, asy,sya,ysa and so on. The string length is not known. The string will be a command line argument to the program.

For example if i
Enter the string : say

output i want to get is like this(below)

s
a
y
sa
sy
as
ys
ay
ya
sya
ysa
yas
ays
asy
say

please guys its urgent if any one have post it here

Member Avatar

Can you show us what you have so far?