I have the following str
tmp=
'794 795 1005 1006 1017 1018 1048 1077 '
I want to convert it to a list or an array of integers.
I tried the followings:
[int(x) for x in tmp]
ValueError: invalid literal for int() with base 10: ''
and
map(int, tmp)
ValueError: invalid literal for int() with base 10: ''