Færdiggjort

A Phone Book

The format of the file is: int key;char lastName[20];char firstName[20]; char phone[20]; where key is a social security number (no dashes) of the person. Create an array of 100 entries as formatted above and initialize all integer elements to zero and string elements to spaces. Read each record on the [url removed, login to view] file and as each is read, use modulo-division hashing algorithm to determine the index in the array where the record will be stored. Before storing the record, check to see if it will have a collision with an existing array element. If there is a collision, print a message that indicates a collision has occurred and what the key values involved are. Then resolve the collision using the key-offset method described in the text. As you resolve the collision, keep in mind that another collision may occur and you will need to print the collision message each time that happens. Once you have processed the entire file, print the index and contents of the non-zero elements of the array. Place all of these displays into a file called directory Do not actually display them on the console. Next display a menu for the user to select from the following options: Enter one of the following options: 1. Search the directory by Name 2. Search the directory by SSN 3. Quit If the user selects option 1, prompt the user to enter a last name. Search the array using an unordered sequential search and display all information for all people that match that last name. If the user selects option 2, prompt the user to enter a social security number. Use the hashing method to find that person and display all information for that [url removed, login to view] the average number of comparisons executed to perform each of the searches and display the results.

## Deliverables

I would like the program to be done in Visual C++.

## Platform

Windows 98, ME, 2000, XP Visual C++

Evner: C programmering, Ingeniørarbejde, MySQL, PHP, Software Arkitektur, Software Testning

Se mere: what is a string in programming, what is a search string, what is a programming algorithm, what is an array in programming, what is an algorithm in programming, what is a method in programming, what is algorithm in programming, what is a algorithm in programming, what is a algorithm, text search algorithm, string search algorithm c, string search algorithm, string match algorithm, string match, string find c, string algorithm, sequential programming, search string in array, programming book , php find a person

Om arbejdsgiveren:
( 0 bedømmelser ) United States

Projekt ID: #2913108

Tildelt til:

emesevw

See private message.

$5 USD in 14 dage
(111 bedømmelser)
4.4

9 freelancere byder i gennemsnit $27 på dette job

ingeniadesign

See private message.

$11.05 USD in 14 dage
(53 bedømmelser)
5.1
herculesevw

See private message.

$28.05 USD in 14 dage
(79 bedømmelser)
4.7
patrica

See private message.

$23.8 USD in 14 dage
(19 bedømmelser)
3.2
stefanc

See private message.

$11.05 USD in 14 dage
(17 bedømmelser)
3.0
dannynoest

See private message.

$29.75 USD in 14 dage
(15 bedømmelser)
2.7
nickyro

See private message.

$21.25 USD in 14 dage
(8 bedømmelser)
2.3
aktvw

See private message.

$46.75 USD in 14 dage
(8 bedømmelser)
2.0
onurkvw

See private message.

$63.75 USD in 14 dage
(0 bedømmelser)
0.0