编程介的小学生 2019-05-18 18:48 采纳率: 20.5%
浏览 419

输入一个日期的数字,计算是星期几的一个算法问题,怎么采用的C程序的语言的代码的编写的方式加以实现的?

Problem Description
Today is Saturday, 17th Nov,2007. Now, if i tell you a date, can you tell me what day it is ?

Input
There are multiply cases.
One line is one case.
There are three integers, year(0<year<10000), month(0<=month<13), day(0<=day<32).

Output
Output one line.
if the date is illegal, you should output "illegal". Or, you should output what day it is.

Sample Input
2007 11 17

Sample Output
Saturday

  • 写回答

1条回答 默认 最新

  • 诸和 2019-05-18 21:44
    关注

    设置枚举变量,今天是第一个,没加一天枚举加一,攒够7个了从头数

    评论

报告相同问题?

悬赏问题

  • ¥15 drone 推送镜像时候 purge: true 推送完毕后没有删除对应的镜像,手动拷贝到服务器执行结果正确在样才能让指令自动执行成功删除对应镜像,如何解决?
  • ¥15 求daily translation(DT)偏差订正方法的代码
  • ¥15 js调用html页面需要隐藏某个按钮
  • ¥15 ads仿真结果在圆图上是怎么读数的
  • ¥20 Cotex M3的调试和程序执行方式是什么样的?
  • ¥20 java项目连接sqlserver时报ssl相关错误
  • ¥15 一道python难题3
  • ¥15 牛顿斯科特系数表表示
  • ¥15 arduino 步进电机
  • ¥20 程序进入HardFault_Handler