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


Can we declare variables inside a method as Final Variables?

Answers were Sorted based on User's Feedback



Can we declare variables inside a method as Final Variables?..

Answer / therathna

write a small program and check ur system

we can use final variable method

Is This Answer Correct ?    15 Yes 2 No

Can we declare variables inside a method as Final Variables?..

Answer / srinu

yes we can declare a varible as final variable inside method
public class Finalv
{
public void m1()
{
final int a=10;
System.out.println(a);
}
public static void main(String k[])
{
Finalv f=new Finalv();
f.m1();
}
}

Is This Answer Correct ?    13 Yes 0 No

Can we declare variables inside a method as Final Variables?..

Answer / ravikiran(aptech mumbai)

yes we can declare.

Is This Answer Correct ?    12 Yes 1 No

Post New Answer

More Core Java Interview Questions

What are the steps involved to write rmi based programs?

0 Answers  


Explain about Superclass and Subclass?

6 Answers  


We can write any Java Logics in our JSP. Then why we are using servlets(Controller Layer) to interact with the DAO ?

6 Answers   TCS,


Can variables be used in java without initialization?

0 Answers  


Is array a class?

0 Answers  


What are examples of modifiers?

0 Answers  


There are 100 keys and values in HashMap.how to get the keys and values?

1 Answers   IBS,


what is the difference between yielding and sleeping? : Java thread

0 Answers  


What is an example of character?

0 Answers  


When should I use abstract classes and when should I use interfaces?

2 Answers  


what is the main difference between string and stringbuffer? can you explain it with program?

2 Answers  


whats is the use of final,in which situation final can be used in the application?

2 Answers   DNS,


Categories