资源介绍
import java.io.*;
public class Calendar{
static int year;
static int weekDay;
public static void main(String args[])throws IOException{
System.out.println("请输入年份:");
InputStreamReader ir;
BufferedReader in;
ir=new InputStreamReader(System.in);
in=new BufferedReader(ir);
String s=in.readLine();
year=Integer.parseInt(s);
if(year<1){
System.out.println("输入的年份不能小于1!");
return;
}
weekDay=(int)firstDayOfYear(year);
System.out.println(" "+year+"年");
System.out.println(" ==================================================");
- 上一篇: JavaSE6_API
- 下一篇: Java开源项目Hibernate包作用详解