public class X {
2. private static int a;
3.
5. public static void main (String[] args) {
6. modify (a);
7. }
8.
9. public static void modify (int a) {
10. a++;
11. }
why it is printing '0" ..as per the question int a should get increased and print 1
I am not understanding this
2. private static int a;
3.
5. public static void main (String[] args) {
6. modify (a);
7. }
8.
9. public static void modify (int a) {
10. a++;
11. }
why it is printing '0" ..as per the question int a should get increased and print 1
I am not understanding this
Comment