Image for post
Image for post

Your Problem:

  • You have a survey with text entries whose values are used in a later portion of the same survey.
  • Your users don’t correctly spell simple things and you would rather have the computer auto correct it instead of doing it by hand to the data.

The Process:

In order to get accurately spelled versions of misspelled words, we will be using the difflib package. The main tool that we will be using in the package is the getClosestMatches() method, which allows us to find the closest spelling from a list of words by splitting the misspelled word into substrings.

  1. Download this txt…

Albert Su

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store