[Prolog] Very Simple orthographic script

Implement the argument orthografos(Sentence, Correct_Sentence) which will accept a "Sentence" sentence and return the correct spelling sentence "Correct_Sentence". The "Sentence" sentence is a list of words and every word is one

list of letters.

Example usage:

? - orthographos ([[t, h, e], [m, o, n], [a, n, d], [t, h], [r, e, d, a], [w, m, o, a, n]], CS).

CS = [[t, h, e], [m, a, n], [a, n, d], [t, h, e], [r, e, d] [w, o, m, a , n]]

The accusation will use a dictionary of spelling words in the form of facts

word / 1 (e.g.):

word ([h, e, l, l, o]).

word ([m, a, n]).

word ([w, o, m, a, n]).

word ([b, o, o, k]).

word ([t, h, e]).

word ([c, o, m, p, u, t, e, r]).

word ([c, a, r]).

word ([p, r, o, l, o, g]).

word ([p, e, n, c, i, l]).

word ([t, a, b, l, e]).

The program should correct at least the following types of spelling errors:

1. Wrong one letter. In this case the wrong word differs from a correct spelling word in a letter, e.g. womon -> woman

2. Two-letter position exchange that is not necessarily adjacent. In this case, the correct spelling word comes from the mutual exchange of two-letter positions of the wrong spelling word, e.g. wamon -> woman

3. The existence of an extra letter. In this case the correct spelling word comes from deleting a letter of the wrong spelling word, e.g. wolman ->


4. The lack of a letter. In this case, the correct spelling word comes from adding a letter to the wrong spelling word, e.g. womn -> woman


• For each type of spelling error, implement the appropriate appropriate spell in which giving the wrong spelling word returns the correct spelling word.

• Edit the sentence words one by one, checking which of the above will lead to the correct spelling word.

Beceriler: Prolog

Daha fazlasını gör: simple ajax script, download simple proxy script, html simple redirect script, simple download script, simple portfolio script, simple rsvp script, simple htaccess script, simple math script plus, simple email script, simple company script, simple perl script mysql delete, simple gallery script flash, simple freebie script, simple testing script, mediafire simple upload script, sign upsign login simple php script, simple raffle script, simple backup script

İşveren Hakkında:
( 34 değerlendirme ) Thessaloniki, Greece

Proje NO: #21264291

Bu iş için 2 freelancer ortalamada $28 teklif veriyor


Hi, I am a software engineer experienced in Prolog (I am using SWI Prolog). I can complete your project within 1 day from awarding, properly tested and commented. I do have two questions: 1. where do the word facts Daha Fazla

1 gün içinde %bids___i_sum_sub_32%%project_currencyDetails_sign_sub_33% AUD
(27 Değerlendirme)

hi , it's not a difficult task and i can do it , thanks in advance .....................................................

$30 AUD in 7 gün içinde
(1 Yorum)