Join Nostr
2024-12-19 19:21:01 UTC

Trey Hunner 🐍 on Nostr: I think I just found my least favorite way to accurately check whether a string ...

I think I just found my least favorite way to accurately check whether a string (value) represents a number in #Python. 😬

value.removeprefix("-").replace(".", "", 1).isnumeric()