Advertisement
aiNayan

Task2

Aug 17th, 2020
93
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.33 KB | None | 0 0
  1. #include<stdio.h>
  2. int main()
  3. {
  4.     int n;
  5.     printf("Enter your marks: ");
  6.     scanf("%d", &n);
  7.     switch(n/10) {
  8.        case 10:
  9.        case 9:
  10.        case 8: printf("A+");
  11.        break;
  12.        case 7: printf("A");
  13.        break;
  14.        case 6: printf("A-");
  15.        break;
  16.        default: printf("F");
  17.     }
  18.     return 0;
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement