class calendar
{
public static void main(String[]args)
{
int yearIn ;
yearIn = Integer.parseInt(args[0]);
showDays(yearIn);
}
static void showDays(int year)
{ int month = 1;
out:
for(;month<13;month++)
{ switch(month)
{
case 1:
for(int day = 1;day<32;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
case 2:
int count =0;
if((year % 4)!=0)
{count = 28;}
else if((year % 100==0)&(year % 400 != 0))
{count = 28;}
else
{count = 29;}
for(int day=1;day<=count;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
case 3:
for(int day = 1;day<32;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
case 4:
for(int day = 1;day<31;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
case 5:
for(int day = 1;day<32;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
case 6:
for(int day = 1;day<31;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
case 7:
for(int day = 1;day<32;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
case 8:
for(int day = 1;day<32;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
case 9:
for(int day = 1;day<31;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
case 10:
for(int day = 1;day<32;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
case 11:
for(int day = 1;day<31;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
case 12:
for(int day = 1;day<32;day++)
{System.out.println(month+"月"+day+"日");
}
continue;
}
} } }

  

最新文章

  1. (四)SQL入门 数据库的操作与事务管理
  2. 【C语言】C语言常量和变量
  3. 滚动到底部加载更多及下拉刷新listview的使用
  4. table的css样式
  5. iOS ASIHTTPRequest 请求https
  6. JSP中RequestDispatcher的用法
  7. python矩阵运算 不断收集整理
  8. Android用自己的app替换Launcher
  9. 如果浏览器自动调用quirks模式打开的话
  10. android基本的数据库创建和使用
  11. 腾讯文学动作密集 疑为手Q发力移动阅读铺路
  12. python 打印类的属性、方法
  13. JAVA简便解析json文件
  14. ecstore中怎样使用ajax提交数据
  15. SEO网页优化
  16. 使用@property
  17. django学习,session与cookie
  18. null值经过强转会怎样?
  19. MySQL入门很简单-触发器
  20. 微信小程序基础

热门文章

  1. eclipsec常用快捷键
  2. Java多线程编程实战指南(核心篇)读书笔记(四)
  3. ORA-06512: at "SYS.XMLTYPE" 问题记录
  4. HDU 1452
  5. IAuthenticationManager.SignOut 退不了
  6. 写一个Python的windows服务
  7. Codeforces 1012C Hills【DP】*
  8. 《DSP using MATLAB》示例Example 6.20
  9. 基于jquery的可查询多级select控件(可记录历史选择)
  10. MTK-shot mode