import re nums = re.findall(r"\d+", "A2B4C13")print(nums) # ['2', '4', '13']
Standard input is empty
['2', '4', '13']
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!