![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Java
mm114820
资料不重要 重要的是当我看到我的资料被改后不发脾气,默默地改回去就好
展开
-
Super关键字
子类不继承父类的构造函数。 ①子类若想使用父类的构造函数,必须满足: 1.在子类的构造函数中使用 2.使用super关键字 3.super关键字是子类构造方法的第一条语句 ②子类若想使用被子类隐藏了的父类的成员变量或方法,也要使用super关键字 eg:super.x; super.play();...原创 2018-12-07 20:14:07 · 73 阅读 · 0 评论 -
Java各种数据类型转换
String和int Int转String: 1.通过前面或后面加字符串 : int a=11; String s=a+""; 2.调用String提供的API: int a=11; String s=String.valueOf(a); 3.使用int的包装类: int a=11; String s=Integer.toString(a); String转int: 1.调...原创 2019-01-01 21:16:56 · 255 阅读 · 0 评论