Physical distance between two places

后端 未结 6 632
悲哀的现实
悲哀的现实 2021-01-02 07:16

I need to measure the physical distance between two places whose names are provided as strings. Since sometimes the names are written slightly differently, I was looking for

6条回答
  •  余生分开走
    2021-01-02 08:12

    You might get some decent results using a phonetic algorithm to find slightly misspelld names.

    Also, if you use a more mechanical edit distance, you'll probably see better results using a weighted function that accounts for keyboard geometry (i.e. physically close keys are "cheaper" to replace than far off ones). That's a patented method btw, so be careful not to write something that becomes too popular ;)

提交回复
热议问题