Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


What is the output of the following Java program?
class Main {
public static void main(String args[]){
final int i;
i = 10;
System.out.println(i);
}
}

10. What is the output of the following Java program?
class Main {
public static void main(String args[]){
final int i;
i = 10;
System.out.println(i);
}
}



What is the output of the following Java program? class Main { public static void main(String a..

Answer / hrindows@gmail.com

Output
10
Since i is the blank final variable. It can be initialized only once. We have initialized it to Therefore, 10 will be printed.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

When does a class need a virtual destructor?

0 Answers   Flextronics,


Is it compulsory to have atleast one abstract method in abstract class?

10 Answers  


What are command line arguments?

5 Answers  


Explain restrictions on using enum?

0 Answers  


heavy components means what?

4 Answers  


Why runnable interface is used in java?

0 Answers  


How does the java compiler work?

0 Answers  


What is the use of arraylist in java?

0 Answers  


Sample code to retrieve objects from HashMap in sorted ascending order?

2 Answers  


What is difference between static class and normal class?

0 Answers  


Is array a class?

0 Answers  


What is hash code collision?

0 Answers  


Categories