摘要: ​ Vector基本介绍 ​ Vector VS ArrayList ​ Vector底层原码断点分析 package chapter17.List; ​ import java.util.Vector; ​ public class Vector01 { public static void ma 阅读全文
posted @ 2022-04-26 09:38 征途** 阅读(29) 评论(0) 推荐(0)
摘要: ​ 集合体系 集合主要是两组(单列集合,双列集合) Collection接口有两个重要子接口 List 和 Set 实现子类都是单列集合 Map接口实现子类 双列集合 存放Key-Value ​ ​ ​ package chapter17.Collection; ​ import java.util 阅读全文
posted @ 2022-04-20 10:18 征途** 阅读(21) 评论(0) 推荐(0)
摘要: Math类 package chapter16.Math类; ​ public class MathMethod { public static void main(String[] args) { //全是静态方法 System.out.println(Math.abs(-9));//绝对值 Sy 阅读全文
posted @ 2022-04-19 10:28 征途** 阅读(41) 评论(0) 推荐(0)
摘要: ​ 包装类 package chapter16.包装类; ​ public class WrapperType { public static void main(String[] args) { //父类object ​ //boolean>Boolean //char>Character // 阅读全文
posted @ 2022-04-15 10:26 征途** 阅读(26) 评论(0) 推荐(0)
摘要: ​ 面向对象习题 package chapter14; ​ public class Homework01 { public static void main(String[] args) { Car c = new Car(); Car c1 = new Car(100); System.out. 阅读全文
posted @ 2022-04-05 21:53 征途** 阅读(33) 评论(0) 推荐(0)
摘要: ​ 枚举类 package chapter12; ​ public class Enumeration01 { public static void main(String[] args) { Season season = new Season("春天", "温暖"); Season winter 阅读全文
posted @ 2022-03-30 17:03 征途** 阅读(45) 评论(0) 推荐(0)
摘要: 内部类简介 package chapter11;​public class InnerClass01 {//外部其他类 public static void main(String[] args) {​ }}class Outer{//类的构成:属性,方法,构造器,代码块,内部类 private i 阅读全文
posted @ 2022-03-29 22:55 征途** 阅读(35) 评论(0) 推荐(0)
摘要: ​ Final package chapter10.D4关键字Final; //final最后的,用在类则不能被继承(但可实例化),用在方法则不能被重写(可在子类继承),用在属性上则不能修改 //用作常量,必须赋值(定义时,构造器赋值,代码块赋值) 若是静态常量,不能用构造器赋值,因为加载顺序有先后 阅读全文
posted @ 2022-03-26 18:55 征途** 阅读(54) 评论(0) 推荐(0)
摘要: ​ main语法 ​ package chapter10.D1类变量和类方法; ​ public class Main01 { private static String name="征途"; private int n1=1000; private void cry(){ System.out.p 阅读全文
posted @ 2022-03-25 20:38 征途** 阅读(54) 评论(0) 推荐(0)
摘要: 房屋出租项目 工具包 package chapter09.D10房屋出租项目.工具包;​​​/** 工具类的作用: 处理各种情况的用户输入,并且能够按照程序员的需求,得到用户的控制台输入。 */​import java.util.*;/**​​ */public class Utility { // 阅读全文
posted @ 2022-03-24 22:58 征途** 阅读(130) 评论(0) 推荐(0)