public class demo5 { public void main(String[] args) { // TODO Auto-generated method stubDemo3 t1=new Demo3();Demo3 t2=new Demo3();t1.color=1;t1.cpu=20;t1.size=1;t1.var=5;t2.color=1;t2.cpu=20;t2.size=1;t2.var=5;if(t1.equals(t2)){ System.out.println("1111"+t1+"==="+t2);}else System.out.println("2222"+t1+"==="+t2); }}
添加回答
举报
0/150
提交
取消