Advertisement
sanpai

Replace a charecter by next charecter

Aug 21st, 2012
58
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. #include<stdio.h>
  2. int main()
  3. {
  4. char ch;
  5. printf("\n Enter the charecter from the keyboard ");
  6. scanf("%c",&ch);
  7. if(ch>=97 && ch<=121)
  8. {
  9. ch++;
  10. }
  11. else if(ch=122)
  12. {
  13. ch='a';
  14. }
  15. printf("\n The output charecter is = %c \n",ch);
  16. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement