fork download
  1. import re
  2. m = """
  3. 0 1 2 3 4 5
  4. 1 0 1 2 3 4
  5. 2 1 1 2 3 4
  6. """
  7. print(re.sub(r'^', '{} ', m.strip(), flags=re.M).format(*list('bip')))
Success #stdin #stdout 0.02s 9388KB
stdin
Standard input is empty
stdout
b 0 1 2 3 4 5
i 1 0 1 2 3 4
p 2 1 1 2 3 4