TOPUPchat logo...
Forgot password?

Select : C language | Java

Q.6] what do we need to do with the following program to make it better? select any 1 option

1. public class loop{
2. public int a=100;
3.
4. public static void main(){
5.    loop l=new loop();
6.    System.out.println(l.a);
7.    }
8. }
    

Options]

A) replace line 5 with “Object l=new loop();”
B) replace line 4 with “public static void main(String...a){ “
C) replace line 6 with “System.err.println(l.a);”
D) none of above        

Click to See Answer
B) replace line 4 with “public static void main(String...a){ “    

Next | comparision between float and double

Previous | assigning all small variables

Hemen Ashodia [paper setter]
Register & recharge
Male Female
I agree Terms and Conditions