Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <string.h>
- #include <ctype.h>
- char *str_cpy(char *firts, const char *second)
- {
- while(*second) *firts++ = *second++;
- ++*firts = '\0';
- return firts;
- }
- char *str_cat(char *dest, const char *src)
- {
- char *tmp = dest;
- while (*dest)
- dest++;
- while ((*dest++ = *src++) != '\0')
- ;
- return tmp;
- }
- int main()
- {
- int i;
- char str[100];
- char temp[100];
- printf("Input symbol:\n");
- gets(str);
- str_cpy(temp, str);
- i=0;
- while(temp[i])
- {
- if(isalpha(temp[i]))
- {
- temp[i]=temp[i]+1;
- }
- i++;
- }
- i=0;
- while(temp[i])
- {
- printf("%c",temp[i]);
- i++;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement