title: true/false Boolean value inside println method
body: <pre><code>public void run(){
      int x = 9; 
      int y = 9;
  
      println( "true or false = " + (x == y) );
      println("true or false = " + ( x &lt; y) );
      prinltn("true or false = " + (x &gt; y) );
  </code></pre>
  
  <p>}</p>
  
  <p>In an example my book uses parentheses <code>()</code> inside the println method to test whether something is true or false. It was my first time seeing <code>()</code> used as a boolean test inside the println method. Previously I thought to solve the problem by something like  </p>
  
  <pre><code>  if (x == y) {
       println("true or false = true");
    } else {
       println("true or false = false");
    }
  </code></pre>
  
  <ol>
  <li>where can i find more information about boolean  inside the println method? </li>
  <li>Is one more right than the other? Should i avoid using one of the examples above?  </li>
  </ol>