Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def convertToInteger(stringID):
- id = [0, 1, 2, 3, 4, 5, 6]
- stringId = '0123456'
- [int(x) for x in stringId]
- => [0, 1, 2, 3, 4, 5, 6]
- map(int, stringId)
- => [1, 2, 3, 4, 5, 6]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement