Write a program to write a given string in maximum
possibilities?
i.e str[5]="reddy";
i.e we can write this string in 120 ways
for that write a program
Answer Posted / sunil singh
Here is an example program...
#include "stdafx.h"
#include "string.h"
int recursive(int length)
{
if ( length <= 1 )
return 1;
else
return length*recursive(length-1);
}
int main(int argc, char* argv[])
{
char data[] = "ready";
printf("maximum possibilities - %d \n", recursive
(strlen(data)));
return 0;
}
| Is This Answer Correct ? | 1 Yes | 4 No |
Post New Answer View All Answers
By using C language input a date into it and if it is right?
What is the difference between constant pointer and constant variable?
What is typedef example?
Why doesnt that code work?
What are the disadvantages of a shell structure?
Do you know null pointer?
write a program using linked list in which each node consists of following information. Name[30] Branch Rollno Telephone no i) Write the program to add information of students in linked list
What is the difference between text and binary i/o?
Explain is it better to bitshift a value than to multiply by 2?
What is a sequential access file?
What is extern keyword in c?
Combinations of fibanocci prime series
Is it cc or c in a letter?
How can I call a function with an argument list built up at run time?
How can I find out if there are characters available for reading?