Advertisement
ivandrofly

convert c to lower case

Sep 29th, 2015
278
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.14 KB | None | 0 0
  1. /* lower: convert c to lower case; ASCII only */
  2. int lower(int c)
  3. {
  4. if (c >= 'A' && c <= 'Z')
  5. return c + 'a' - 'A';
  6. else
  7. return c;
  8. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement