File tree 1 file changed +27
-1
lines changed
1 file changed +27
-1
lines changed Original file line number Diff line number Diff line change @@ -180,11 +180,37 @@ final strictfp public static void main(String[] args)
180
180
181
181
-------------------------------------------------------------------------------------------------------------------------------------
182
182
183
+ Java variables
183
184
185
+ There are three types of variables
186
+ 1.local variables.
187
+ 2.instance variables
188
+ 3. Static variables.
189
+
190
+ 1.LOCAL Variables.
191
+ declare inside a method.
192
+
193
+
194
+ 2.INSTANCE Variables
195
+ menas that we can declare inside class but outside of the method.
196
+
197
+ 3.STATIC Variable.
198
+ variable that can be declared as static .it can not be local variavle
184
199
185
200
201
+ example for the variable declarations.
202
+ class A{
203
+ int data=50;//instance variable
204
+ static int m=100;//static variable
205
+ void method()
206
+ {
207
+ int n=90;//local variable
208
+
209
+ }
210
+ }//end of class
186
211
187
212
188
213
189
214
190
-
215
+ --------------------------------------------------------------------------------------------------------------------------
216
+
You can’t perform that action at this time.
0 commit comments