get digit from string python code example Example: python digit string import string print(string.digits) >> "0123456789"