title: Conjunction and multiple return values
body: <p>I have validation methods that return a two-element array of <code>true</code>/<code>false</code> and a string. An example is:</p>
  
  <pre><code>def check_length(name)
    if(name.length &gt; 50)
      return false, "Length more than 50"
    else
      return true, ""
    end
  end
  </code></pre>
  
  <p>I'm trying to check for multiple methods of this kind. I wrote a code like the following:</p>
  
  <pre><code>def validate
    value, message =
    check_length(name) &amp;&amp;
    is_valid(id) &amp;&amp;
    is_any_mismatch(name,id) &amp;&amp;
    is_valid(name) &amp;&amp;
    ...
  end
  </code></pre>
  
  <p>I expect <code>value</code> to take the <code>true</code>/<code>false</code> and <code>message</code> the string value. If <code>check_length</code> returns <code>false</code>, the second method <code>is_valid</code> should not be evaluated.</p>
  
  <p>But for the code above, even if <code>check_length</code> returns <code>false</code>, <code>is_valid</code> is evaluated, and <code>value</code> is overridden by the return value of <code>is_valid</code>.</p>
  
  <p>How can we break execution if the first condition is <code>false</code>, and return from <code>validate</code> function? i.e short circuit evaluation should work with two return values.</p>