Skip to content

Commit

Permalink
Merge pull request tarunsinghofficial#1112 from lidhishc/patch-4
Browse files Browse the repository at this point in the history
Reverse a String using C
  • Loading branch information
tarunsinghofficial committed Oct 31, 2020
2 parents 4968577 + db29eb8 commit 6ee1695
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions C Program/ReverseString.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#include <stdio.h>
#include <string.h>
int main()
{
char s[100];

printf("Enter a string to reverse\n");
gets(s);

strrev(s);

printf("Reverse of the string: %s\n", s);

return 0;
}

0 comments on commit 6ee1695

Please sign in to comment.