文档介绍:Java 我这人从不记仇,一般有仇当场我就报了。没什么事不要找我,有事更不用找我! 就算是 believe 中间也藏了一个 lie! 我那么喜欢你, 你喜欢我一下会死啊? 我又不是人民币,怎么能让人人都喜欢我? /** 第一个程序*/ public class e { public static void main(String[] args) { (" 这是你的第一个程序,欢迎你走入 Java 的大门"); }} /** 学生信息导入*/ class StudentTest { public static void main(String[] args) { Student aStudent = new Student(); (" 张楠"); ("20030408"); (" 学生的姓名是: "+ () +" ,学号是: "+ ()); }} class People { private String name; public String getName(){ return name; } public void setName(String strName) { name = strName; }} class Student extends People { private String studentNum; public String getStudentNum() { return studentNum; } public void setStudentNum(String strStudentNum) { studentNum = strStudentNum; }} /** 移位运算符测试*/ public class BitMotion { public static void main(String[] args) { int a= 15; int b= 2; int x=a << b; int y=a >> b; int z=a >> b; (a + "<<" +b+ "=" + x); (a + ">>" +b+ "=" + y); (a + ">>>" +b+ "=" + z); }} /* * 测试位的四种运算*/ public class BitOperation { public static void main(String[] args) { int a= 15; int b= 2; int x=a& b; int y=a| b; int z=a^ b; int r= ~x; (a + "&" +b+ "=" + x); (a + "|" +b+ "=" + y); (a + "^" +b+ "=" + z); ("~" +x+ "=" + r); }} /* * 测试 boolean 型数据*/ public class BooleanTest { public static void main(String[] args) { int a= 20; int b= 30; boolean x, y,z; x= (a> b); y= (a< b); z= ((a + b) == 50); ("x=" + x); ("y=" + y); ("z=" + z); }} /** 测试不同数制表现形式及系统的自动转化功能*/ public class ByteTest { public static void main(String[] args) { byte x= 22;// 十进制 byte y= 022;// 八进制 byte z= 0X22;// 十六进制 (" 转换成十进制, x=" + x); (" 转换成十进制, y=" + y); (" 转换成十进制, z=" + z); } } /* * 测试 char 型与整数的转换*/ public class CharTest { publi