Beginner Java - can not find the symbol - variable


let's say I have : public static int MIN = 0; in a class.

and I am trying to use this constant in another class with main : myVar = MIN;

why am I getting cannot find symbol - variable MIN error? both classes are public and so is the constant MIN.

any help would be appreciated. thank you fellow coders

e; thank you guys, it worked!

In order to use a class constant like MIN from a class A, you would need to

import static A.MIN;

or you could use

int myVar = A.MIN;