函数使用部分
package exercise; import java.util.*; public class exercise { int year=0; int month=0; int day=0; public static void main(String[]args){ exercise zhangjie = new exercise(); Calendar c=Calendar.getInstance();//获得系统当前日期 zhangjie.year=c.get(Calendar.YEAR); zhangjie.month=c.get(Calendar.MONTH)+1;//系统日期从0开始算起 zhangjie.day=c.get(Calendar.DAY_OF_MONTH); //Text tianxia = new Text(); //zhangjie.Text; System.out.println("year is"+zhangjie.year+"mouth is"+zhangjie.month+"day is "+zhangjie.day); } }
我要坚持一年,一年后的成功才是我想要的。