simple c++ program for "abcde123ba" convert "ab321edcba"
with out using string
Answer Posted / pramod
void mystrrev(char* str)
{
char ch;
int last=strlen(str)-1;
for(int i=0;i<last;i++,last--)
{
ch=str[i];
str[i]=str[last];
str[last]=ch;
}
}
| Is This Answer Correct ? | 5 Yes | 1 No |
Post New Answer View All Answers
What is buffering in c++?
What is prototype for that c string function?
What do the header files usually contains?
Can we overload operator in c++?
Is c++ a pure oop language?
Write about the use of the virtual destructor?
What are the operators in c++?
Are php strings immutable?
Mention the storage classes in c++.
What are friend classes? What are advantages of using friend classes?
Can I learn c++ without learning c?
int age=35; if(age>80) {Console.WriteLine("Boy you are old");} else {Console.WrieLine("That is a good age");}
Write a note about the virtual member function?
Can we specify variable field width in a scanf() format string? If possible how?
Is oops and c++ same?