java how to make variable public code example
Example 1: how to declare a public variable in java
public class Example {
public static int a;
public static int b;
}
Example 2: java how to make a variable global
public class Example {
public static int a;
public static int b;
}