Professional Documents
Culture Documents
PK 2
PK 2
Sponsored: Segment Send data to any tool without having to implement a new API every time. Get started
1 #include<stdio.h>
2 #include<string.h> Execute Mode, Version, Inputs & Arguments
Online C CompilerCommandLine
IDE Arguments
3
4 int main() {
5 char s[100];
6 scanf("%s",s); Thanks for using our
Online C CompilerStdin
IDE
7 int h = strlen(s);
8 int i=0;
9 int z=h-1; Inputs
10 int temp=s[0]; to execute your program
11 s[0]=s[z]; 12345
12 s[z]=temp;
13 printf("%s",s);
14
15 } Result
CPU Time: 0.00 sec(s), Memory: 1468 kilobyte(s)compiled and executed
52341
https://www.jdoodle.com/c-online-compiler/ 1/1