Computer Science, asked by dmittal9928, 1 year ago

What is the output of the below code? class c{ public static void main(string a[]) { int i1=9; int i2; if(i1>3) { i2=8; } system.out.println(i2); } }

a. compile time error

b. runtim error

c. prints 8

d. prints 0?

Answers

Answered by ChadwickRoshan
0
a.compile time error

reason : "string" should be "String", and "system" should be "System".

if the above is corrected the answer will be

c. prints 8
Similar questions