title: What does "?" mean in Java?
body: <p>I dont know what the question mark (<code>?</code>) stand for in java, I was doing a small program, a Nim-game. were looking in a book, for help and saw this statement:</p>
  
  <pre><code>int pinsToTake = (min &gt;= 2) ? 2 : 1;
  </code></pre>
  
  <p>I don't understand it, what will <code>?</code> represent, can it be something to do with if-statement but you put it in a variable? and the <code>:</code> can be something "else"? (this things that I just said can be very misleading)</p>