#include "stdio.h"
void main()
{
void fun();
char m;
int i;
char date[7][10]={"monday","tuesday","wednesday","thursday","friday","saturday","sunday"};
for(i=0;i<7;i++)
printf("%s ",date[i]);
scanf("%c",&m);
switch(m)
{
case 'm': printf("星期一");break;
case 'w': printf("星期三");break;
case 'f': printf("星期五");break;
case 't': fun();break;
}
}
void fun()
{
printf("請輸入第二個字母:\n");
char v;
scanf("%c",&v);
switch(v)
{
case'u':printf("星期二\n");break;
case'h':printf("星期四\n");break;
default:printf("error\n");
}
}