I need to generate a string with n characters in Python. Is there a one line answer to achieve this with the existing Python library? For instance, I need a string of 10 l
If you can use repeated letters, you can use the * operator:
*
>>> 'a'*5 'aaaaa'