public Keyword

Using a public keyword declares public visibility for a class, variable, or method. Any other class in the program can access items with public visibility.

Here’s an example that declares a public class variable (also called a field):

public int Diameter;

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset