Implement the spell checker and the hash table

Assignment Help Basic Computer Science
Reference no: EM132329159

A spell checker that stores a set of words, W, in a hash table and implements a function, spellCheck(s), which performs a spell check on the string s with respect to the set of words, W.

If s is in W, then the call to spellCheck(s) returns an iterable collection that contains only s, because it is assumed to be spelled correctly in this case. Otherwise, if s is not in W, then the call to spellCheck(s) returns a list of every word in W that could be a correct spelling of s.

Your program should be able to handle all the common ways that s might be a misspelling of a word in W, including

  • swapping adjacent characters in a word;
  • inserting a single character in between two adjacent characters in a word;
  • deleting a single character from a word; and 
  • replacing a character in a word with another character. 

The input to your program will consist of the name of a text file, and strings of characters manually entered by the user. The text file will contain the set of words, W, one word per line, and should be read in the program when the program starts. The strings of characters input by the user will be used to test the hash table and the spellCheck function. The program will keep running the tests until the user enters the string "quit".

Using classes SpellChecker and HashTable to implement the spell checker and the hash table, respectively

Using UML class diagram that describes your class design.

Reference no: EM132329159

Questions Cloud

By how much would termes annual gross profit increase : Currently, sales are $680,000 per year and cost of sales are 65% of sales. The equipment is expected to last for 4 years with no residual value.
Identify the name of the wizard : Choose a design wizard; write observations below as you work through the process of using it to prepare for the initial post.
What is the budgeted balance of rosss accounts receivable : Ross Corporation makes all sales on account. The June 30th balance sheet balance in its accounts receivable is $310,000, of which $250,000 pertain to sales.
Discuss the two key requirements for writing sql server : Discuss the two key requirements for writing SQL Server audits to the Windows Security log.
Implement the spell checker and the hash table : Using classes SpellChecker and HashTable to implement the spell checker and the hash table, respectively
Explain how you would use the three new firewall approaches : Please list and explain how you would use the three new firewall approaches to achieve optimal separation in the protection of large-scale national assets?
Mention the seven layers of the osi stack : a. Mention the seven layers of the OSI stack, and describe the basic function of each layer.
Element of hardware architecture in terms : Given a computer system, describe each element of its hardware architecture in terms of its various sub-systems
What are some of the higher level positions : Consider your company's supply chain management team. What are some of the higher level positions and what are their responsibilities?

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Identifies the cost of computer

identifies the cost of computer components to configure a computer system (including all peripheral devices where needed) for use in one of the following four situations:

  Input devices

Compare how the gestures data is generated and represented for interpretation in each of the following input devices. In your comparison, consider the data formats (radio waves, electrical signal, sound, etc.), device drivers, operating systems suppo..

  Cores on computer systems

Assignment : Cores on Computer Systems:  Differentiate between multiprocessor systems and many-core systems in terms of power efficiency, cost benefit analysis, instructions processing efficiency, and packaging form factors.

  Prepare an annual budget in an excel spreadsheet

Prepare working solutions in Excel that will manage the annual budget

  Write a research paper in relation to a software design

Research paper in relation to a Software Design related topic

  Describe the forest, domain, ou, and trust configuration

Describe the forest, domain, OU, and trust configuration for Bluesky. Include a chart or diagram of the current configuration. Currently Bluesky has a single domain and default OU structure.

  Construct a truth table for the boolean expression

Construct a truth table for the Boolean expressions ABC + A'B'C' ABC + AB'C' + A'B'C' A(BC' + B'C)

  Evaluate the cost of materials

Evaluate the cost of materials

  The marie simulator

Depending on how comfortable you are with using the MARIE simulator after reading

  What is the main advantage of using master pages

What is the main advantage of using master pages. Explain the purpose and advantage of using styles.

  Describe the three fundamental models of distributed systems

Explain the two approaches to packet delivery by the network layer in Distributed Systems. Describe the three fundamental models of Distributed Systems

  Distinguish between caching and buffering

Distinguish between caching and buffering The failure model defines the ways in which failure may occur in order to provide an understanding of the effects of failure. Give one type of failure with a brief description of the failure

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd