What will be indicated in the console?

public class D {
    public static void main(String[] args) {
        E e = new E();
        e.someVariable = 100;
        e.doIt(e);
        System.out.println(e.someVariable);
    }
}

class E {
    public int someVariable = 10;

    public void doIt(E aE) {
        aE.someVariable++;
    }

    E() {
    }
}

Следи за CodeGalaxy

Мобильное приложение Beta

Get it on Google Play
Обратная Связь
Продолжайте изучать
тесты по Java
Cosmo
Зарегистрируйся сейчас
или Подпишись на будущие тесты