title: PySpark - Convert an RDD into a key value pair RDD, with the values being in a List
body: <p>I have an RDD with tuples being in the form:</p>
  
  <pre><code>[("a1","b1","c1","d1","e1"), ("a2","b2","c2","d2","e2"), ...
  </code></pre>
  
  <p>What I want is to transform that into a key-value pair RDD, where the first field will be the first string (key) and the second field a list of strings (value), i.e. I want to turn it to the form:</p>
  
  <pre><code>[("a1",["b1","c1","d1","e1"]), ("a2",["b2","c2","d2","e2"]), ...
  </code></pre>