- import java.io.IOException;
- import java.util.Arrays;
-
- public class fuxi2_string_system_baozhuanglei
- {
- public static void main(String[] args)
- {
-
-
- String newstr;
- String str = " Iloveyou";
- newstr = str.trim();
- newstr = str.toUpperCase();
- newstr = str.toLowerCase();
- newstr = str.substring(1);
- newstr = str.substring(5,8);
- newstr = String.valueOf(87899);
- newstr = str.concat("fff");
- System.out.println(newstr);
-
- boolean bs = str.startsWith("i");
- bs = str.endsWith(".doc");
- bs = str.contains("h");
- bs = str.isEmpty();
- char c = str.charAt(6);
- int p = str.indexOf("co");
- p = str.lastIndexOf('o');
- p = str.indexOf('v', 3);
- p = str.length();
-
- System.out.println(p);
-
- String[] array = str.split("o");
- System.out.println(Arrays.toString(array));
-
-
-
- boolean f = false;
- Boolean ff = new Boolean(f);
- boolean fz = Boolean.parseBoolean("TRue");
- fz = ff.booleanValue();
-
- char ch = '5';
- Character cha = new Character(ch);
- boolean bc = cha.isDigit(ch);
- bc = Character.isUpperCase('D');
- char cz = cha.charValue();
-
- int in = Integer.MAX_VALUE;
- in = Integer.parseInt("568512");
-
-
- for (int i = 0; i < 10; i++)
- {
- System.out.println(i);
- }
- System.exit(1);
-
-
- Runtime run = Runtime.getRuntime();
- try
- {
- run.exec("C:/Program Files (x86)/Tencent/QQ/Bin/QQ.exe");
- }
- catch (IOException e)
- {
- e.printStackTrace();
- }
-
- System.arraycopy();
-
- Runtime.getRuntime().exec("D:\\Program Files\\SDK Setup.exe");
-
-
- }
- }