Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- int main()
- {
- int a;
- printf("Enter the order of a Month: ");
- scanf("%d", &a);
- if (a == 1)
- printf("31 days in january");
- else if (a == 2)
- printf("28 days in february");
- else if (a == 3)
- printf("31 days in march");
- else if (a == 4)
- printf("30 days in april");
- else if (a == 5)
- printf("31 days in may");
- else if (a == 6)
- printf("30 days in june");
- else if (a == 7)
- printf("31 days in july");
- else if (a == 8)
- printf("31 days in august");
- else if (a == 9)
- printf("30 days in september");
- else if (a == 10)
- printf("31 days in october");
- else if (a == 11)
- printf("30 days in november");
- else if (a == 12)
- printf("31 days in december");
- else
- printf("Invaild value");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement