Learning by doing: Reading books and trying to understand the (code) examples
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
262 B

  1. #include <stdio.h>
  2. int main (void) {
  3. unsigned int a;
  4. printf("Give an ASCII code value: ");
  5. scanf("%u", &a);
  6. if (a > 127) {
  7. printf("Outside of ASCII range\n");
  8. return 1;
  9. } else {
  10. printf("The character is: %c\n", a);
  11. }
  12. return 0;
  13. }