What is the equivalent keyword for extern in java?
java
Solution
`File1.buf`. More generally: `ClassName.FIELD_NAME`. A few notes
- use `CAPITAL_LETTERS` to name your static final fields (`BUF`)
- use `static final` rather than `final static` (not crucial, but it is a widely accepted style)
Problem
I have one public static variable in one file and how can I export the same variable to other files? For ex:- file1.java ``` public final static int buf = 256; ``` file2.java How can I access the variable "buf" in this file?