작성
·
183
0
public class Main {
public static void main(String[] args) {
Static11 peo1 = new Static11("one") ;
Static11 peo2 = new Static11("two") ;
Static11 peo3 = new Static11("three") ;
}
}
public class Static11 {
private String name ;
public static int count ;
public Static11(String name){
this.name = name ;
count++ ;
}
}
이렇게 2개의 클래스가 있을때 , how many distinct instances of name, count 를 물으면
count 는 1개이고, name 은 3개인가요 ?