How to reverse a string using a recursive function, without
swapping or using an extra memory?
Answers were Sorted based on User's Feedback
Answer / mahendra aseri
Using recursive Function:
void rev_str(char *str)
{
if(*str!=NULL)
rev_str(str+1);
printf("%c",str);
}
| Is This Answer Correct ? | 20 Yes | 43 No |
c program to arrange digits in a no in ascending and descending order
Program to find larger of the two numbers without using if-else,while,for,switch
What is hashing in c language?
What is a ternary operator in c?
what is the output of the following program? main() { int i=-1,j=-1,k=0,l=2,m; m=i++&&j++&&k++||l++; printf("%d %d %d %d %d",i,j,k,l,m); }
write a programming in c to find the sum of all elements in an array through function.
Write a C++ program without using any loop (if, for, while etc) to print prime numbers from 1 to 100 and 100 to 1 (Do not use 200 print statements!!!)
What is the difference between exit() and _exit()?
How can you determine the size of an allocated portion of memory?
What compilation do?
7 Answers Geometric Software, Infosys,
why you will give me a job in TCS.
What are identifiers c?