I have two lists of strings:
letters = [\'abc\', \'def\', \'ghi\']
numbers = [\'123\', \'456\']
I want to for loop through them to create a lis
You can try list comprehension with two nested for loop over numbers and then letters :
print([l+n for n in numbers for l in letters])
# ['abc123', 'def123', 'ghi123', 'abc456', 'def456', 'ghi456']
You can also use nested for loop:
out = []
for n in numbers:
for l in letters:
out.append(l+n)
print(out)
# ['abc123', 'def123', 'ghi123', 'abc456', 'def456', 'ghi456']
For more details on list comprehension, see either the doc or this related topic.