title: What is the difference between public int and int in Java?
body: <p>I've only started to learn Java (I'm a student, and C++ is the base langauge I know best) and I've come across access and modifiers.</p>
  
  <p>In code I've seen the use of </p>
  
  <pre><code> public int NAME;
   // and
   int NAME;
  </code></pre>
  
  <p>Does it make a difference? If so, what is the difference. What does it do exactly?</p>