fork download
  1. words=['qwe', 'asdf', 'rftgyhu', 'vbngfr', 'yuo']
  2.  
  3. spaces = 0
  4. for word in words:
  5. print(' ' * spaces + word)
  6. spaces += len(word)
Success #stdin #stdout 0.02s 9260KB
stdin
Standard input is empty
stdout
qwe
   asdf
       rftgyhu
              vbngfr
                    yuo