1: Add new word 2: Delete word 3: Get meaning 4: Dictionary list 5: Spell check a text file. 6: Exit Notes: Add new word - This option should request a word and its meaning. Insert the word into the dictionary if it is new. No duplicates are allowed. All words are to be stored in lowercase letters. Delete word - This option should request a word and delete it from the dictionary. Get meaning - This option should request a word and print its meaning if found in the dictionary. If it is not found an appropriate message must be shown. Dictionary List- This option must simply list all the words contained in the dictionary. Note that the meanings should not be listed. Spell check a text file- This option should prompt the user for a text file. You may assume the text file contains only sentences with words and the only punctuation allowed are periods (.), commas (,). You must print all the word that are not in the dictionary. Please note this must still work regardless of the case of the letters. Exit - This option should exit the program.

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

using java programming code the following

Your program must first load all known words from the text file "wordlist.txt" into the
dictionary class you created (which stores all the word in the array as sorted).
NOTE that this list does not contain any definitions and none need to be created. Only new
words need definitions. The words loaded from the file should have "Undefined word" as the
definition.
Create a main program with the following menu options:
1: Add new word
2: Delete word
3: Get meaning
4: Dictionary list
5: Spell check a text file.
6: Exit
Notes:
Add new word - This option should request a word and its meaning. Insert the word into the
dictionary if it is new. No duplicates are allowed. All words are to be stored in lowercase
letters.
Delete word - This option should request a word and delete it from the dictionary.
Get meaning - This option should request a word and print its meaning if found in the
dictionary. If it is not found an appropriate message must be shown.
Dictionary List- This option must simply list all the words contained in the dictionary. Note
that the meanings should not be listed.
Spell check a text file- This option should prompt the user for a text file. You may assume the
text file contains only sentences with words and the only punctuation allowed are periods (.),
commas (,). You must print all the word that are not in the dictionary. Please note this must
still work regardless of the case of the letters.
Exit - This option should exit the program.
Transcribed Image Text:Your program must first load all known words from the text file "wordlist.txt" into the dictionary class you created (which stores all the word in the array as sorted). NOTE that this list does not contain any definitions and none need to be created. Only new words need definitions. The words loaded from the file should have "Undefined word" as the definition. Create a main program with the following menu options: 1: Add new word 2: Delete word 3: Get meaning 4: Dictionary list 5: Spell check a text file. 6: Exit Notes: Add new word - This option should request a word and its meaning. Insert the word into the dictionary if it is new. No duplicates are allowed. All words are to be stored in lowercase letters. Delete word - This option should request a word and delete it from the dictionary. Get meaning - This option should request a word and print its meaning if found in the dictionary. If it is not found an appropriate message must be shown. Dictionary List- This option must simply list all the words contained in the dictionary. Note that the meanings should not be listed. Spell check a text file- This option should prompt the user for a text file. You may assume the text file contains only sentences with words and the only punctuation allowed are periods (.), commas (,). You must print all the word that are not in the dictionary. Please note this must still work regardless of the case of the letters. Exit - This option should exit the program.
You are required to create a personal dictionary and spellcheck program. There must only be
two core classes. A class "WordInfo" and a class "Dictionary".
The information stored on a wordInfo object consists of:
A word: a string
A meaning: a string
The dictionary class is responsible for holding all the words and supports the following
operations:
public bool add (string word, string meaning) – adds a new word to the dictionary. No
duplicate words are allowed. You must store all the words in all array of size 1500. All words
should be stored in lowercase.
public bool delete (string word) - deletes the wordInfo object with the matching word.
public bool exists(string word) – returns true if the word is in the dictionary and false
otherwise.
public String getMeaning(string word)- returns the meaning of the word.
public int getCount() – returns the number of words in the dictionary. Note that is must be
-
implemented even if not used.
public string printWordList () – returns a list of all the words stored in the dictionary in
alphabetical order (only the words, not the meanings).
public void printDictionary()- prints the full word and meaning for each wordInfo object in the
dictionary (in ascending order).
Transcribed Image Text:You are required to create a personal dictionary and spellcheck program. There must only be two core classes. A class "WordInfo" and a class "Dictionary". The information stored on a wordInfo object consists of: A word: a string A meaning: a string The dictionary class is responsible for holding all the words and supports the following operations: public bool add (string word, string meaning) – adds a new word to the dictionary. No duplicate words are allowed. You must store all the words in all array of size 1500. All words should be stored in lowercase. public bool delete (string word) - deletes the wordInfo object with the matching word. public bool exists(string word) – returns true if the word is in the dictionary and false otherwise. public String getMeaning(string word)- returns the meaning of the word. public int getCount() – returns the number of words in the dictionary. Note that is must be - implemented even if not used. public string printWordList () – returns a list of all the words stored in the dictionary in alphabetical order (only the words, not the meanings). public void printDictionary()- prints the full word and meaning for each wordInfo object in the dictionary (in ascending order).
Expert Solution
steps

Step by step

Solved in 5 steps with 14 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY