declare variable in java
Variables are basic unit of storage. All variables have scope the scope of variable is define its visibility.Variables are define by data types and variable name.
Declaring a Variable :
In java variable can be declared before its used.
Example of Declaring a Variable:
if Declare one Variable
syntax int a;
if Declare more then one Variable then syntax is
int a,b,c,d;
Declare Variable with value :
int a=12;
if Declare more then one Variable then syntax is
int a=12,b=13,c=14,d=15;
Love this post ... This was a great help for a beginner like me
ReplyDelete