title: How to make a for loop for each vector in list
body: <p>I have a list l, contains four vectors, each vector contains a number of elements, the vectors are not the same length. </p>
  
  <pre><code>l&lt;- list(2:4,3:5,4:7,5:7)
  
    for ( i in length(l)){
  
       print(l)
     }
  
  [[1]]
  [1] 2 3 4
  
  [[2]]
  [1] 3 4 5
  
  [[3]]
  [1] 4 5 6 7
  
  [[4]]
  [1] 5 6 7
  </code></pre>
  
  <p>I would like to add value 2 to all the elements of each vector in the list using for loop.<br>
  Maybe we need (<strong>two for loops</strong>) The external  will be for the list and the internal will be for each vector of the list, I would like to obtain  the following result :</p>
  
  <pre><code>    [[1]]
      [1] 4 5 6
  
      [[2]]
      [1] 5 6 7
  
      [[3]]
      [1] 6 7 8 9
  
      [[4]]
      [1] 7 8 9
  </code></pre>
  
  <p><strong>Please note that:</strong> the original list contains 389 vectors, each vector contains not less than  45 elements. </p>