+ 3
What is the problem on this code i want print reverse string
/* C program to Reverse a String without using strrev() */ #include <stdio.h> #include <string.h> int main() { char Str[100]; int i, len; printf("\n Please Enter any String : "); gets(Str); len = strlen(Str); printf("\n String after Reversing : "); for (i = len - 1; i >= 0; i--) { printf("%c", Str[i]); } return 0; }
5 Respuestas
+ 1
Your code is working perfectly in my machine. Avoid the warning of the compiler and go ahead run your program ,, u will get the desired output.
+ 1
your code is working perfectly in sololearn code playground. Don't write your code in a clumsy way. Write both header files in different lines and run the program ,,it will work.
+ 1
k thanks
0
k thanks bro but this code not working in sololearn code playground
0
Thanks