Каков результат выполнения кода?
class SomeClass { public static void main(String[] args) { boolean flag = true; int value; if (flag) { value = flag ? 1 : 2; } else { value = flag ? 3 : 4; } System.out.println(value); } }
1
2
3
0
Please log in or register to have a possibility to add comment.
Please log in or register to have a possibility to add comment.