What is best way to achieve the following? Each of the elements in the list needs to be appended with a common string.
path = os.path.join(os.path.dirname(__file__), 'configs'))
files = ['%s/file1', '%s/file2'] % path
But I am getting the following error:
TypeError: unsupported operand type(s) for %: 'list' and 'str'