最初のステートメントがコンストラクター呼び出しであっても、「this(10)」でこのエラーが発生するのはなぜですか。エクリプスを使用しています。
public class MaxIndependentSet {
private ArrayList<Integer> inputArr = new ArrayList<Integer>();
public void MaxIndependentSet(int size) {
inputArr.ensureCapacity(size);
}
public void MaxIndependentSet() {
this(10);
}
}