<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">
































/** C and Matlab use 0 for false and
                 any other integer for true
                 
   ---------------------------------------
   
    Java uses instead a type boolean:
    values:   true   false
    
    
    operations !  (not)
               &amp;&amp; (and, conjuction)
               || (or, disjunction)
               == (equality, or equivalence)
               != (inequality, or inequivalence)
  
    
    Table that defines operations
    
    b      c    | ! b     b &amp;&amp; c   b || c   b == c   b != c      
    ------------|------------------------------------------
    false false | true    false    false    true     false
    false true  | true    false    true     false    true
    true  false | false   false    true     false    true
    true  true  | false   true     true     true     false
  
   ---------------------------------------
   
   
   
   
   
   Relations
       b == c    // true iff b and c have the same value
       b != c    // true iff b and c have different values
       b &lt;  c    // true iff b is less than c
       b &lt;= c    // true iff b is at most c
       b &gt;  c    // true iff b is greater than c
       b &gt;= c    // true iff b is at least c
       
   b and c must be of the same type.
   
   If they are both numeric types, the narrower one will
   be converted to the type of the wider one before the
   operation is carried out.
   
   ---------------------------------------
   
   
   
   
   
   
   
   
   Short-circuit evaluation
   
   5/0 == 3  &amp;&amp;  false     // gives error: division by 0
   false     &amp;&amp;  5/0 == 3  // no error. values is false
   
   
        b &amp;&amp; c                   
    
   is equivalent to non-Java expression
   
        if b then c else false   
   
   which is equivalent to java expression
   
        b ? c : false       // this IS a Java expression
   
   .....................
   
        b || c                   
    
   is equivalent to non-Java expression
   
        if b then true else c   
   
   which is equivalent to java expression
   
        b ? true : c       // this IS a Java expression
   
   
   
   
   
   
       
   
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  
  */</pre></body></html>