Fields are declared outside of a class’s methods and are usually found right below the class declaration. Fields can be accessed by all methods of a class. They can also be accessed from other classes (unless they are private) using the dot operator. If a…