title: Get lengths of multiple vector subsets defined by a vector of subset parameters
body: <p>I have a vector <code>x</code> of <code>n</code> elements.</p>
  
  <p>Now I want to get multiple subsets of this vector of the scheme <code>s = subset(x, x&lt;=p)</code> where <code>p</code> will hold several values, given through a vector.  </p>
  
  <p>In the end I would like to have the lengths of these subsets stored in a vector according to the vector containing the values for <code>p</code>.  </p>
  
  <p>Can you help me doing this without loops etc?</p>