title: Exporting all images in a Google Earth Engine image collection (Google Earth Engine API)
body: <p>I need to download a bunch of Landsat images for my thesis. My problem seems simple but I don't have a clue about JavaScript and the documentation didn't help enough.
  I have filtered the collection to my region and time period and i want to export all images to Drive, seperately. 
  Collection example:</p>
  
  <pre><code>var surfaceReflectanceL5 = ee.ImageCollection('LANDSAT/LT5_SR');
  var dateSR5=surfaceReflectanceL5.filterDate('1984-01-01', '1985-01-01');
  var prSR5=dateSR5.filter(ee.Filter.eq('wrs_path', 182))
                       .filter(ee.Filter.eq('wrs_row', 35)); 
  </code></pre>
  
  <p>The code for exporting a single image is:</p>
  
  <pre><code>Export.image.toDrive({
    image: image1 //example, var image1='Landsat/....'
    description: 'L51984_1',
    scale: 30,
  });
  </code></pre>
  
  <p>How can I iterate through the collection to export all images? The use of map() function seems to be the answer.</p>
  
  <pre><code>prSR5.map(Export.image.toDrive({
    image: image,
    description: 'L51984',
    scale: 30,
  }));
  </code></pre>
  
  <p>The question is how to set the image parameter to the correct image (i.e first the 1st image, then the 2nd etc, something like '<code>thisImage()</code>' ) and the description to match image (i.e. <code>'L51984_1'</code>,<code>'L51984_2'</code>...).</p>
  
  <p>Many thanks in advance!!!</p>