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 { {

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

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!