/**
* 〈一句话功能简述〉<br>
* 〈no descrition〉
*
* @author abu
* @create 2019/7/9
* @since 1.0.0
*/
public class TestPritimive {
public static void main(String[] args){
Pritimive d = new Pritimive();
for(int i = 0;i < d.t.length; i++){
System.out.println(d.t[i]);
}
d.t[0] = true;
d.t[1] = true;
d.t[2] = true;
d.t[3] = true;
for(int i = 0;i < d.t.length; i++){
System.out.println(d.t[i]);
}
}
}
class Pritimive{
boolean[] t = new boolean[4];
}
/**
* 〈一句话功能简述〉<br>
* 〈数组的练习〉
*
* @author abu
* @create 2019/7/8
* @since 1.0.0
*/
//test1 创建数组,String类型空值为null,int类型空值为0,
public class TestArray {
public static void main(String[] args) {
String[] str = new String[4];
str[0] = "你";
str[1] = "真";
str[2] = "好";
str[3] = "看";
for(int i = 0; i < str.length; i ++){
System.out.println(str[i]);
}
byte[] score = new byte[4];
for(int i = 0; i < score.length; i ++){
System.out.println(score[i]);
}
float[] f = new float[4];
for(int i = 0; i < f.length; i ++){
System.out.println(f[i]);
}
char[] c = new char[4];
for(int i = 0; i < c.length; i ++){
System.out.println(c[i] + i + c[i] + "v");
}
boolean[] b = new boolean[2];
for(int i = 0; i < b.length; i ++){
System.out.println(b[i]);
}
}
}