摘要:Week9 W9L1 Static Variable the particular member belongs to a type itself, rather than to an instance of that type. Array of Objects Just like int or 
        
阅读全文
 
    
        
        
摘要:Week7 W7L1 Java Virtual Machine (JVM) JDK (Development Kit) JRE (Runtime Environment) JDB (Debugger) .java -> [javac compiler] -> .class -> [JVM] -> U
        
阅读全文
 
    
        
        
摘要:Week6 W6L1 Array // create an Array int [] myArray; myArray = neew int[5]; // 2D Array int[][] a = new int[3][5]; // 3 rows, 5 columns Arrays + For Lo
        
阅读全文
 
    
        
        
摘要:Week5 W5L1 Review Control Flow Condition Loops counter Loops For loops Does the exact same thing with less code for (int i = 0; i < 10; i++) // initia
        
阅读全文
 
    
        
        
摘要:Java数组 数组的定义 相同类型数据的有序集合 相同类型的若干个数据 通过下标访问 变量的类型	变量的名字	=	变量的值; public class Array { public static void main(String[] args) { int[] nums; //声明 int nums
        
阅读全文
 
    
        
        
摘要:Week4 W4L1 三元运算符 (ternary operator) public static void main(String[] args) { boolean isCar = true; boolean wasCar = isCar ? true : false; System.out.p
        
阅读全文
 
    
        
        
摘要:Java方法 一个方法只完成一个功能,利于后期拓展 例如: public class Methods { public static void main(String[] args) { } public static int add(int a, int b) { int result = 0; 
        
阅读全文
 
    
        
        
摘要:Java流程控制 IO流:输入输出流 Scanner 创建对象:Scanner scanner = new Scanner(System.in); 用hasNext()与hasNextLine()判断是否有输入数据 使用next()与nextLine()方法接收数据:... = scanner.ne
        
阅读全文
 
    
        
        
摘要:Week3 W3L1 public static void main(string[] args) { System.out.println("hello world"); // ";"很重要 System.out.println(10+5); } Variables Stored in RAM p
        
阅读全文
 
    
        
        
摘要:Java基础语法 注释 //单行注释 /* 多行注释 */ JavaDoc(以后学习) 标识符 所有标识符都应以字母,$ 或 _ 开始 首字符之后可以是字母,$ ,_ 或数字 数据类型 Java是强类型语言,变量先定义后使用 整数: byte short int long(在数字后加L,e.g. 1
        
阅读全文