Starting from:

$30

CSCE 240 EXAM 3

CSCE 240 EXAM 3 
This is a 20 point exam.
You must submit a single zipped, and only zipped, archive of your Exam 3
project. Only zipped (.zip) archives will be accepted. Archive formats other than
.zip will not be accepted. Multiple individual file submissions will not be accepted
and will be deleted from Blackboard.
The archive must contain (at a minimum):
exam3/inc/char matrix.h
exam3/src/char matrix.cc
exam3/inc/employee.h
exam3/src/employee.cc
exam3/inc/smart appliance.h
exam3/src/smart appliance.cc
exam3/inc/tight vector.h
exam3/src/tight vector.cc
for full or partial credit.
Description
Each of the header files contains a description of the problem you are tasked to solve, along with point
allocation. The makefile contains rules to build each of the problems’ final test executable. The makefile
also contains rules to run cpplint on the files for style point assessment.
This is an exam. If you ask questions which can be answered by reading the test files or the project
files, I will refer you to those. Questions about strategy or syntax cannot be answered. Asking questions
about homework which happen to also answer questions about the exam cannot be answered. Given that
this is your final exam, late submissions are not accepted.
CSCE 240 Exam 3 Page 2 of 3
Points
CharMatrix: (5 Points)
1. Compilation: 0.5
(make test-char-matrix)
2. Style: 0.5
(make test-char-matrix-style)
3. TestFillConstructor: 1.0
(./test-char-matrix 0)
4. TestCopyConstructor: 1.0
(./test-char-matrix 1)
5. TestAssignOperator: 1.0
(./test-char-matrix 2)
6. test-char-matrix-memory: 1.0
(make test-char-matrix-memory)
Employee: (5 Points)
1. Compilation: 0.5
(make test-employee)
2. Style: 0.5
(make test-employee-style)
3. Demographic::first name() : 0.25 points
(./test-employee 0)
4. Demographic::last name() : 0.25 points
(./test-employee 1)
5. Demographic::date of birth() : 0.25 points
(./test-employee 2)
6. Employee::employee id() : 0.25 points
(requires child class)
(./test-employee 3)
7. HourlyEmpolyee::pay rate() : 0.75 points
(./test-employee 4)
8. HourlyEmployee::CalculatePay(double) :
0.75 points
(./test-employee 5)
9. SalaryEmployee::pay rate() : 0.75 points
(./test-employee 6)
10. SalaryEmployee::CalculatePay(double) :
0.75 points
(./test-employee 7)
Smart Appliance: (5 Points)
1. Compilation: 0.5
(make test-smart-appliance)
2. Style: 0.5
(make test-smart-appliance-style)
3. SmartLight::Activate: 0.5 points
(./test-smart-light 1 or 2)
4. SmartLight::Deactivate: 0.5 points
(./test-smart-light 3 or 4)
5. SmartLight::Set: 1.0 point
(./test-smart-light 5–10)
6. SmartThermostat::Activate: 0.5 points
(./test-smart-thermostat 1 or 2)
7. SmartThermostat::Deactivate: 0.5 points
(./test-smart-thermostat 3 or 4)
8. SmartThermostat::Set: 1.0 point
(./test-smart-thermostat 5–9)
TightVector: (5 Points)
1. Compilation: 0.5
(make test-tight-vector)
2. Style: 0.5
(make test-tight-vector-style)
3. TestAppendEmpty: 0.5
(./test-tight-vector 0)
4. TestAppendNotEmpty: 1.0
(./test-tight-vector 1)
5. TestAppendEmpty: 0.5
(./test-tight-vector 2)
6. TestAppendNotEmpty: 1.0
(./test-tight-vector 3)
7. test-tight-vector-memory: 1.0
(make test-tight-vector-memory)
Target Environment
Make sure that your code runs in the target environment. As always, you may develop and test your code
in your environment of choice. However, code which does not run in the test environment will not be considered. Ensure that you do not hardcode paths into your environment. This is unnecessary because the
makefile appends the root exam3 directory to the compiler’s include path.
Cont.
CSCE 240 Exam 3 Page 3 of 3
Academic Integrity
This is an exam. Requesting help from others is cheating. Working together is cheating. Discussing the
problems is cheating. This is a test of your skills and so you are to solve the questions on your own, using
only reference materials.
You will notice that there is more ambiguity in portions of this exam. More of the classes’ declaration
and definition is left to your discretion. That is intentional. For this exam, any submissions found to be
too similar will be turned into the Office of Academic Integrity. Those submissions’ grades will be held
until the investigation is complete. The penalty for submitting work found to be in violation of the Academic
Integrity code is a -100%.
The End.