Question: What is wrong with this code: public class A { { System.out.println(i); } int i = 10 O A) Invalid use of a static initialization

What is wrong with this code: public class A { { System.out.println(i); } int i = 10 O A) Invalid use of a static initialization block. B) Nothing, the code will run properly O-C) Use of a method before it is defined OD) Use of a field before it is defined
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
