summaryrefslogtreecommitdiff
path: root/progs/unparsable_programs/a158.py
blob: 6e5fda02b3fe38a09f71be6d59514d528655e4d5 (plain)
1
2
3
4
5
def is_decimal(num):
    import re
    dnumre = re.compile(r"""^[0-9]+(\.[0-9]{1,2})?$""")
    result = dnumre.search(num)
    return bool(result)