Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Advanced level school computer science. need helps. 3 The file, HASHEDDATA.TXT, holds details of the names and telephone numbers of 250 people. There are a

image text in transcribed

image text in transcribed

Advanced level school computer science. need helps.

3 The file, HASHEDDATA.TXT, holds details of the names and telephone numbers of 250 people. There are a total of 500 lines in the file, and a number of these lines are empty of name and telephone number. An index is stored for each line of the file. The format of the data in the file is: ,, The first 10 lines from the file are shown as follows: The values in the file are separated by the comma character. A record structure is used to store a name and telephone number. A data structure of 500 records is needed to store all the names and telephone numbers. Each line in the file is written to a corresponding position in the data structure. The records with index six to eight from the data structure are: Task 3.1 Use program code to create a: - record structure to hold the name and telephone number for one person - data structure, using this record structure to store 500 records. The hash calculated from the searchName can be used to find a corresponding record in the data structure. If the SearchName is not found in the record given by the hash and the record is not empty: - compare searchName with the next record - until the SearchName is found or an empty record is found. If an empty record is found then the program will report that the name is "NOT FOUND". If the record is found, the program will output the index, name and telephone number

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Modern Database Management

Authors: Jeffrey A. Hoffer Fred R. McFadden

9th Edition

B01JXPZ7AK, 9780805360479

More Books

Students also viewed these Databases questions