Showing posts with label Variables in Java. Show all posts
Showing posts with label Variables in Java. Show all posts

Java-Types of Variables / Chapter - 5 /Language Fundamental



Java Types Of Variables


Based on the position of declaration & behavior all variables are divided into three parts.


1.instance variable


2.static variable


3.local variable




 


1.instance variable:-



  • If the value of a variable varied from object to object is called Instance variable.

  • For every object, a separate copy of instance variable will be created.

  • Instance variable should be declared within the class directly, but outside of any method/block/constructor.

Flipkart End Of Season Sale






© Copyright 2017 Javabychetan.blogspot.com