Hacker News new | past | comments | ask | show | jobs | submit login

How is that better than just checking against a list of suburb names?



It's also handling what state the suburb is in, and can deal with various kinds of bad data (e.g. lack of uniformity of spacing and capitalisation).


The regex is a compressed representation which saves memory, and it's also likely to be quite a bit faster which saves cycles. I consider it a clever bit of optimisation.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: