#include<stdio.h>
void main()
{
int xingqi;
printf("请输入今天是星期几:");
scanf("%d",&xingqi);
if ((xingqi>7)||(xingqi<1))
printf("错误");
if ((xingqi==6)||(xingqi==7))
printf("休息日愉快!");
if ((xingqi>=1)&&(xingqi<=5))
printf("工作日愉快!");
}
[此贴子已经被作者于2007-9-22 9:32:23编辑过]