title: How to know if a vector is composed by the same elements?
body: <p>How can I check if a vector has all the same elements?</p>
  
  <p>For example let's say I have:</p>
  
  <pre><code>vec1 = rep(10,20)
  vec2 = seq(1:20)
  </code></pre>
  
  <p>How can I show that <code>vec1</code> has all the same elements?</p>