write C code to reverse a string such that if i/p is "abc
defg hij klmno pqrs tuv wxyz"
and the o/p should be "cba gfed jih onmlk srqp vut zyxw"
Answers were Sorted based on User's Feedback
Answer / naresh
man()
{
char ch[33];
printf("enter the string");
for(int i=0;i<33;i++)
scanf("%c",&ch[i]);
int k=0;
for(i=0;ch[i]!='/o';i++)
{
if(ch[i]==" ")
{ int n=i;
while(i>=k)
{
printf("%c",ch[i]);
i--;
}
k=n;
}
}
}
| Is This Answer Correct ? | 3 Yes | 1 No |
Answer / bipin chandra sai.s
hay just use concatenation of strings method
{
int temp=int a;
int a=int b;
int b=int temp;
}
| Is This Answer Correct ? | 2 Yes | 6 No |
# define x=1+4; main() { int x; printf("%d%d",x/2,x/4); }
Print all numbers which has a certain digit in a certain position eg: number=45687 1 number=4 2 number=5 etc
code for inverse a matrix
What happens if header file is included twice?
What is the maximum no. of arguments that can be given in a command line in C.?
What is Generic pointer? What is the purpose of Generic pointer? Where it is used?
What is the difference between struct and typedef struct in c?
There are 3 baskets of fruits with worng lables,one basket has apple,another basket has orange,another has combination of apple and orange,what is the least way of interchange the lables.
15 Answers Cisco, Google, MBT,
Which is better oop or procedural?
Does c have enums?
What is the most efficient way to store flag values?
How to add two numbers with using function?