title: Check every matrix element in matrix and put the result in a variable
body: <p>I have a matrix <code>v</code>:</p>
  
  <pre><code>0     1     0     0     1     1
  1     0     1     1     0     0
  0     1     0     1     0     0
  0     1     1     0     0     1
  1     0     0     0     0     0
  1     0     0     1     0     0
  </code></pre>
  
  <p>I need to check every element in this matrix using a loop (if the element is 0 the result will 
  be -1 and if the element is 1 the result will be 0). The result of every element will be in a variable to use it in another operation.</p>