University of Texas at Dallas C Programming Lab Report hi, need help on this programming assignment. i attached the questions, and will be providing additional materials. Assignment Description (100 points)
The purpose of this project is to write a program to help record every students’ grades in a spreadsheet
roster. When TAs collect results from an online quiz platform, the platform can only provide the grades
of students who have submitted their quizzes. If a student skips them, the online platform will not keep
track of their grades. Therefore, when a TA downloads data from the platform, he/she will only have the
submitted results which is actually a spreadsheet that is given in the Fig. 1.
94
49
56
41
47
59
50
66
Echowels SCUITSEN. acnes.com
8000000
Candace shop adlasium.com
| നാറCrit
Conan Daugherty alquamaru Aliquam nequenone
B00060053
In Chan 2. Vestibulum vestrom mooo002
Beatrice Morgan auficienpuset
00000055
Ruth Woods upeitae.org
OOO0001
Unul Diccion con ehvaler.com
B00000051
Donna Dennis
consectetur turpis.net
Sydnee Holowy cubilia Curae. Phasellus dolor.net
8000X003
Tarie Son cubilia
Curas vehicula.edu
ROBOSCO
Kian Santana Cum sociis natoque tristique aliquetPhasellus.co.uk OSCOS
Travis House Donec Mr.
800000046
Bi Man Dane then
BOOOOOO
Barbara Water
Donec Polacerat el tuisque du
8000X0005
Echo Mars dubinsodales
BOOOM
Ceely Gram culturpis.co.uk
| നാരാ
Taylor Roberson Ovis minimeendvitae.edu
B0000002
Bertha Redige Dus volutpat.ru
BUDOUCOSE
Destor Richards
eget dictum
eget.com
FOX
Micayla Gran eget dictum@tincidunttempusrisus.edu
000000
Tukar Melon கரானபேயாபதியார்
1000SC
Ruth Me eget. Fusce org
B000000
Mano Everett it.pelentesque bibendum.edu
800000050
40
34
64
47
72
44
90
37
11
89
77
Figure 1: Students quiz score (input file)
However, we can have a thousand of students in a class but we have much less submissions. Then,
how can we fill these collected scores into a spreadsheet which has thousands of entries in the most
efficient way? A straightforward solution is to scan the whole list for each collected score but it is too
slow when the number of students is very large. Part of the roster is given by Fig. 2.
• Therefore, we consider using a hash table to record all collected scores since we will have the UINs and
we can use them as unique keys in the hash table. Thus, for the roeter, we read it row by row and we
can get UIN. We look up the UIN in the hash table and we will find the corresponding score Then,
we can record collected scores in the roster.
• A hash table is defined as a vector of linked lists. The size of the hash table m is equal to the number
of students in the roster. In case of a collision use the chaining method and place colliding elements in
the same linked list selected by the hash function
h(I) = 1 mod m
The chaining method on average is efficient if the number of elements from collisions in
each linked lists is constant, 0(1), compared to all elements stored in the hash table
The implementation steps:
1. (10 points) Read input.csv containing grades, see Fig. 1.
2
one.htm
C
1 Arawdoc C0000092
Fuicer
3 Armand Bowmetelus 30000048
+ Aubrey Ever tempor augu 300000027
5 Aurelia Donc metus.ewer 300000010
Bartara Walip 10000006
7 burch walung 100000001
Bad Moon
9 Beatrice Morten 3.000.000
10 Bertha Rodil Duis.wolve 800000032
Brandes Rasnica 80000007
12 Candace Bled place 007
13 Carson Thor Sumpende 300000019
14 Cachas lohnt 0000
15 Celsite NguySid. nutar 800000004
16 Chadwick Giet viverra. 800002073
17 Charles Merc vitae sapie 300000030
18 Chiquila besertaliqua BC0000056
19 Clayton Hemeuleus.Qul 100000006
20 Conan Dog aliquam ac RODOS
21 Daniele Besedari 100000012
22 Deacon Hideget
dictum 800002066
23 Deba Hal taminen 300000058
300000011
25 Deater Mascus pedei 100000000
26 Donna Dersicorette 0001
27 Cupin Delordu B00000016
28 Echo Huntes dutih sodele 300000074
29 Echo Wells acousan. 300000079
10 Eda Sykes volt primis 3.000000
31 Limo Landry and 100000007
22 Elmo Samec.com
33 Emmanuel credited
34 Eric Hendri tortor.
Ne 300000015
35 Fichastanet.com 00000096
16 Fulton Hicks Partes cours..000.000
37 Galvin Seatta malesuada 100000085
38 Ghet Son montre 000000
Figure 2: The roster file
2. (20 points) Use the Regex class to parse each row in input.csv.
The regular expression are part of the C++ STL. To find more information about regu-
lar expression please read the chapter Dr. Bjarne Stroustrup’s ” Programming. Principles
and Practice Using C++” the latest edition, Chapter 23, sections 23-6 through 23-9, “Tert
Processing” http://www.stroustrup.com/Programming/lecture-slides.html
include the header file (#include )
3. (20 points) Create a hash table using student’s UIN as a key and student’s score as a value
(key-value pair). Resolve collisions using the chaining method.
– Read the lecture notes and text book about Hashing, chap. 5.
– Display the statistics about the hash table: minimum, maximum, and average length of the
linked lists in the hash table.
4. Read the roster.csv containing students grades (= class grading book).
5. Use the Regex to parse each row in roster.csv.
6. Look up the hash table by using the parsed UIN and recover the corresponding quiz score.
7. (30 points) Create a new file output.csv with appended scores, see Fig 3, see more details below:
(a) read a line from roster.csv
(b) extract UIN field and create the corresponding key
(c) search the hush table using the key
i. if the search is successful, update the line by appending the corresponding score
ii. if the search is unsuccessful, copy the roster line without any changes
Comment: the CSV file format is very important. You should learn what a plain-text CSV file is.
Then, you can write the regex pattern string.
3
Alan Livihmutting doc 0000037
Aloe Care Fuscetis 300000031
Armand Bow nec tellus 800000043
Aubry verteter OOO00027
Aurelia Danc metus ewer 8000010
Barbara WiDonec iple 1000000
Rasa Burch in 2001
Basil Moon Donec nithe 800000091
Beatrice Moram 1000000SS
Bertha Rodri Duis volute 900000032
Braden Ras Nisou.ca 80000007
Candace Blendent WCS
Carson Thor Suspendisse 200.00049
Cathleen Bos habitat B30000020
Celeste Ny Sed.rulag 100000034
Chadwick Gietvlivema. 800.00073
Charles Merve sapte 3000030
Chiques 0000
Clayton Hem eu lacus.aut 899000036
Conan Daliquam. 8000000
Daniele Baitsed.ercidi 90000012
Deacon Ridget din 80000005
Dubra Hall amper 1000000SE
denunc quan 03
Dester Blank lectus.pede 800000036
Donna Dern cornect 100000023
Eagan Delan ordus B00000026
Echo Haynes dulin.scale 800000074
Ich Wells OC007
Edan Sykes velt.primis 8000004
Elmo Landry insodalest 80000000
tlmo Saro Nemo NOCCOSE
Emmanuel Carcu vestibu89000052
Erich Handbarter.ribes 80000001
Flavia Richan sit amet.com 89000009
Fulton Hicks farescu 820000030
Galvin Scato muletuada a 1000000
Gisela Sosa monies B000020
64
64
944
Figure 3: The updated by quiz score student file (output file)
What to submit to eCampus?
• Your C++ source code with the header block including: your name, user name, section number and
e-mail address
(20 points) A report which should consists of the following parts:
– The cover page
– Assignment number and its description.
– Description of data structures and algorithms used by your program.
Description of input and output data List all restrictions and assumptions that you have imposed
on your input data and program.
– How have you tested your program for corrections?
– Which C++ features or standard library classes have you used in your program?
Provide the statistics about the hash table. Are the computational results about the hashing
consistent with the expected running time for the hashing algorithm? Justify your answer.
Write your conclusion
Purchase answer to see full
attachment
Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.
You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.
Each paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.
Thanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.