wow
This commit is contained in:
parent
d42448a9d0
commit
6fef06ae70
67 changed files with 436 additions and 1 deletions
31
04/ex08.c
Normal file
31
04/ex08.c
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
#include <stdio.h>
|
||||
|
||||
int main() {
|
||||
int month;
|
||||
printf("월(Month) 입력 : ");
|
||||
scanf("%d", &month);
|
||||
|
||||
switch (month) {
|
||||
case 1:
|
||||
case 3:
|
||||
case 5:
|
||||
case 7:
|
||||
case 8:
|
||||
case 10:
|
||||
case 12:
|
||||
printf("%d월은 31일까지 있습니다", month);
|
||||
break;
|
||||
case 4:
|
||||
case 6:
|
||||
case 9:
|
||||
case 11:
|
||||
printf("%d월은 30일까지 있습니다", month);
|
||||
break;
|
||||
case 2:
|
||||
printf("%d월은 28일까지 있습니다", month);
|
||||
break;
|
||||
default:
|
||||
printf("잘못된 월입니다.");
|
||||
break;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue