Reverse a string word by word??

Answer Posted / dally

#include<stdio.h>
#include<conio.h>

int main()
{
char array1[] = "STRING FOR TESTNG";
char array2[20],i=0;
int count;
count = strlen(array);
for(count;count>1;count--)
{
array2[i]= array1[count];
i++;
}
printf("%s\n",array2);

}

Is This Answer Correct ?    0 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How is a macro different from a function?

648


Write a program to implement a round robin scheduler and calculate the average waiting time.Arrival time, burst time, time quantum, and no. of processes should be the inputs.

615


What is a static variable in c?

659


Is null always equal to 0(zero)?

574


i have to apply for rbi before that i need to know the the syllabus for the entrance questions. whethet it may be aps or techinical

1832






Where is volatile variable stored?

637


Using which language Test cases are added in .ptu file of RTRT unit testing???

3575


In C language, a variable name cannot contain?

730


Explain what math functions are available for integers? For floating point?

603


all c language question

1860


What is meant by gets in c?

598


What is typedef struct in c?

575


If you know then define #pragma?

668


Who is the main contributor in designing the c language after dennis ritchie?

541


2) Write a program that will help Air Traffic Control for an airport to view the sequence of flights ready for take-off. The airport can accommodate 10 flights waiting for take-off at any point in time. Each flight has a unique 3 digit numeric identifier.  Each time a flight takes-off, Air Traffic Control adds a flight to the waitlist. Each time a flight is added to the waitlist, the list of flights waiting to take-off must be displayed.  When a flight is cleared for take-off, Air Traffic Control removes the flight from the waitlist. Each time a flight takes-off, the list of flights waiting to take-off must be displayed.  Sequence of take-off is the sequence of addition to the waitlist

2511