Want to write articles/new answer to be published in javapedia.net? Send in your article with your name to javatutorials2016@gmail.com!

Prev Next

Java / Local Variables

Define local variable.

Posted on Apr 1, 2016 by Senthil Kumar.

Local variable also known as block level variable, are identifiers that are declared within a block of code or method.

This variable need to be initialized before using it.

In the below examples, "i" variable is an example of local variable and it is visible only to the enclosing block.

      int i;

void methodName() {
		int i;

❤Cash Back At Stores you Love !!!❤

Earn your $10 reward when you make your first purchase through Ebates by signing up with clicking below button.

Ebates Coupons and Cash Back

More Related questions...

Show more question and Answers...

Class Variables (Static Variables)

Comments & Discussions