Advertisement
kiwser

Untitled

Feb 13th, 2020
207
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.40 KB | None | 0 0
  1. #include<stdio.h>
  2.  
  3. int main()
  4. {
  5.     int num;
  6.     printf("Enter a number: ");
  7.     scanf("%d",&num);
  8.     if(num==1)
  9.     {
  10.         printf("The number is 1\n");
  11.     }
  12.     else if (num==2)
  13.     {
  14.         printf("The number is 2\n");
  15.     }
  16.     else if(num==1)
  17.     {
  18.         printf("The number is not 1\n");
  19.     }
  20.     else
  21.     {
  22.         printf("The number is not 1\n");
  23.     }
  24.     return 0;
  25. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement