import re print(re.findall(r'\d', '1٤٥٦4'))
Standard input is empty
['1', '٤', '٥', '٦', '4']
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!