I have a list
f=['20.0', '21.0', '22.0', '23.0', '24.0', '25.0', '26.0', '27.0',
'28.0', '29.0', '30.0', '31.0', '32.0', '33.0']
I want to change the list to string such that each element is recognized as an integer 20 21... That is f[0]=20
, f[1]=21
. If I just use f=str(f)
, then it will count ['
as an element too.
source https://stackoverflow.com/questions/73129143/convert-list-to-string-in-python-such-that-it-separates-the-each-integer-as-an-e
Comments
Post a Comment