Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- int main()
- {
- int l, j,i;
- char str[20];
- gets(str);
- l=strlen(str);
- for(j=l-1;j>=0;j--)
- {
- if(str[j]=='1')
- str[j]='0';
- else
- str[j]='1';}
- printf("%s",str);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement