views:

42

answers:

2

The following list contains 1 correct word called "disastrous" and other incorrect words which sound like the correct word?

A. disastrus
B. disasstrous
C. desastrous
D. desastrus
E. disastrous
F. disasstrous

Is it possible to automate generation of wrong choices given a correct word, through some kind of java dictionary API?

A: 

No, there is nothing related in java API. You can make a simple algorithm which will do the job.

Just make up some rules about letters permutations and doubling and add generated words to the Set until you get enough words.

Roman
A: 

There are a number of algorithms for matching words by sound - 'soundex' is the one that springs to mind, but I remember uncovering a few when I did some research on this a couple of years ago. I expect the problem you would find is that they take a word and return a value that represents how the word sounds so you can see if two spellings sound similar (so the words in the question should generate similar values); but I expect doing the reverse, i.e. taking the value and generating similar sounding spellings, would be quite hard.

Rik Garner