| ▲ | DevX101 6 days ago |
| It still is? Few engineers could build a good spell checker without external libraries, giving a database of valid words. |
|
| ▲ | Aurornis 6 days ago | parent | next [-] |
| > Few engineers could build a good spell checker without external libraries, giving a database of valid words. Writing a spell checker that quickly identifies if a word is in a list of valid words (the problem described in the article) is a trivial problem for anyone who has basic algorithms and data structure knowledge. It's the classic example for using a trie: https://en.wikipedia.org/wiki/Trie The problem described in the article is doing it within very limited storage space. How do you store your list of 200K words on a system with only 256K of memory? This is the challenging part. |
| |
| ▲ | mandeepj 6 days ago | parent [-] | | > How do you store your list of 200K words on a system with only 256K of memory? Your hard disk is almost always larger than your RAM. You only load into memory what's needed at the moment. I hope that gives a hint on how to proceed with the above problem. | | |
| ▲ | dhosek 6 days ago | parent | next [-] | | But you don’t necessarily even have a hard disk. You might only have a 320K floppy. Floppy-only computers were pretty common in the late 80s when I was in undergrad. | | |
| ▲ | unregistereddev 6 days ago | parent | next [-] | | Indeed, I remember having to insert a dedicated 5 1/4" floppy in order to run spell check in Apple Writer on an Apple ][e. | |
| ▲ | mandeepj 5 days ago | parent | prev [-] | | Let's replace "hard disk" with "external storage". Shall we? |
| |
| ▲ | sib 6 days ago | parent | prev | next [-] | | The article refers to the need to support machines that did not even have hard disk drives. | |
| ▲ | Hackbraten 6 days ago | parent | prev | next [-] | | What's a hard disk? | |
| ▲ | aidenn0 5 days ago | parent | prev [-] | | OK. You have no hard disk, just a 360K floppy. |
|
|
|
| ▲ | kccqzy 6 days ago | parent | prev | next [-] |
| I was actually asked to build a spell checker in an interview. I immediately thought of Peter Norvig's article on spell corrector (https://norvig.com/spell-correct.html) and proceeded to explain. It turned out that the interviewer really wanted a spell checker not spell corrector: the program will only point out words not in the set of known words. I failed that interview by overengineering. |
| |
| ▲ | dehrmann 6 days ago | parent | next [-] | | > I failed that interview by overengineering. Almost. You needed to clarify what the interviewer was asking and discover requirements. As much as HN likes to hate on coding interviews requiring specific algorithm knowledge, determining requirements is very much part of the job, and engineers have a tendency to build what they want to build, not what the customer wants. | | |
| ▲ | elzbardico 5 days ago | parent [-] | | I don't care about people who like to overengineer things, as long as they are humble and have awareness of this tendency. Sometimes you need the extra power and creativity. If they are affable and don't take critics personally, they usually get in with the program easily. |
| |
| ▲ | Gibbon1 5 days ago | parent | prev [-] | | Marvin the Paranoid Android voice. 'Oh... that. Just do a linear search on a dictionary. Put the small words first. I know it's woefully inefficient but you won't fuck that up' |
|
|
| ▲ | aidenn0 5 days ago | parent | prev | next [-] |
| TFA is just about flagging misspelled words, not making suggestions. That's something I would expect any undergraduate to be able to write. |
|
| ▲ | adrianN 6 days ago | parent | prev | next [-] |
| The existence of external libraries is part of the point. |
|
| ▲ | justin66 6 days ago | parent | prev [-] |
| It takes a PhD to develop that. (ahem) |