Question: 2. Program 1: Word Pattern - Write a program or script in the programming language of your choice to Part 1: Word to Pattern a.

 2. Program 1: Word Pattern - Write a program or script

2. Program 1: Word Pattern - Write a program or script in the programming language of your choice to Part 1: Word to Pattern a. for any given string of characters, return the pattern (we'll discuss in class). For example, the word "apple" may be represented as the patterns "abbcd" or "01123" or "12234" The word "zoozoo" may be "abbabb", "011011", "122122" b. The program should be able to take a string from console (typed word) or read words from a file Part 2: Pattern to Word a. for a given string of characters representing a word pattern, return possible candidate words (take advantage of words_aplha.txt and you may want to create a new file) For example, the pattern "abbcd" will return a list of candidates as: apple essay reefs hooky leets wooly Likewise if a word is entered "apple" then the candidate list is also returned b. The program should be able to take a string from console (typed word) or read words from a file

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!