java第五次作业

public class Homework01 {

	public static void main(String[] args) {
		String str="耿丹学院计算机Java20170320";
		System.out.println(str.substring(11));

	}

}

  

public class Homework02 {

	public static void main(String[] args) {
           String str="耿丹计算机Java20170320";
           String newStr=str.replaceAll("Java","J2EE");
           System.out.println("替换后的结果:"+newStr);
	}

}

  

public class Homework03 {

	public static void main(String[] args) {
	      String str="耿丹    计算机     Java  20170320";
	      String newStr=str.replaceAll("  ","");
	      System.out.println("替换后的结果:"+newStr);
	}

}

  

public class Homework04 {

	public static void main(String[] args) {
	       String str="11011119970921****";
	       System.out.println(str.substring(6,14));
	}

}

  

posted @ 2017-03-29 19:57  栗子~lzy  阅读(88)  评论(2编辑  收藏  举报