title: Understanding python nested one line for loops
body: <p>I am trying to understand one line for-loops and putting it in to normal nomenclature for nested for-loops. The one-liner for-loops is as follows:</p>
  
  <pre><code>print ''.join((letter[i - 1]for i in (int(n) for n in key.split())))
  </code></pre>
  
  <p>I wrote the above nested for-loops in a conventional way as follows:</p>
  
  <pre><code>for n in key.split():
      n = int(n)
      for i in n:
          print ''.join(letter[i - 1])
  </code></pre>
  
  <p>I am not getting the desired result. Please can someone explain where my thinking is going wrong or how can the above one-line for-loops can be written conventionally. Thanks in advance.</p>