package helloWorld;
public class Test{
public static final QQ qq[]=new QQ[5];
static{
qq[0]=new QQ("李允智","54");
qq[1]=new QQ("孙中山","88");
qq[2]=new QQ("毛泽泽","77");
qq[3]=new QQ("邓晓晓","66");
qq[1]=new QQ("孙花花","81");
qq[4]=new QQ("木子美","41");
}
public static void main(String [] args){
System.out.println(qq[0]);
System.out.println(qq[1]);
System.out.println(qq[2]);
System.out.println(qq[3]);
System.out.println(qq[4]);
}
}
package helloWorld;
public class QQ {
String name;
String age;
public QQ(String name,String age){
this.name=name;
this.age=age;
}
}
输出为
helloWorld.QQ@757aef
helloWorld.QQ@d9f9c3
helloWorld.QQ@9cab16
helloWorld.QQ@1a46e30
helloWorld.QQ@3e25a5
求解啊。