import re | |
CURRENCIES = { | |
"$": "USD", | |
"zł": "PLN", | |
"£": "GBP", | |
"¥": "JPY", | |
"฿": "THB", | |
"₡": "CRC", | |
"₦": "NGN", | |
"₩": "KRW", | |
"₪": "ILS", | |
"₫": "VND", | |
"€": "EUR", | |
"₱": "PHP", | |
"₲": "PYG", | |
"₴": "UAH", | |
"₹": "INR", | |
"﷼": "IRR", | |
} | |
CURRENCY_REGEX = re.compile( | |
"({})+".format("|".join(re.escape(c) for c in CURRENCIES.keys())) | |
) | |