159100留学生讲解、辅导Programming、C++编程语言调试、C++讲解 辅导Python程序|辅导留学生 Statistics统计、

- 首页 >> C/C++编程
Course: 159100 Introduction to Programming
Assessment: 04 Computer Programmes & 05 Computer Programmes
Course Learning Outcomes Assessed:
• Define variables and perform input/output operations.
• Control program flow with conditional and iteration statements.
• Write, compile and debug C++ programs.
• Construct suitable Graphical User Interfaces and generate beginner-level graphics.
• Write, compile and debug C++ programs
Weighting: 30 %
Due Date: 18/10/2020, 5:00 PM
This is an individual assessment.
Introduction
It’s common for engineering projects to require parts and items to be purchased, especially by a third
party. One way to make it easy for them to get what you want, and from where you want them to get
it from, is to collate all the parts’ details into a single document - a Bill of Materials (BOM). A BOM is a
shopping list for parts that are required to create a product.
You are required to write a C++ program that allows a user to interactively create a BOM and export
it to a file.
Aims
The assessment’s aims are to demonstrate proficiency in:
• Writing, building, and running a C++ program.
• Defining a class and using its member variables and member functions.
• Creating Graphical User Interfaces.
• Using the Qt framework.
Objectives
The assessment’s objective is to:
• Write a C++ program that allows a user to interactively create a BOM and export it to a file.
The program should be able to:
• Let the user enter an item’s description, how many units are needed, the supplier’s part
number, where to get it from, and how much it costs.
• Let the user add multiple items to the BOM.
• Display the current BOM, the number of items, and the current total cost to the user.
• Let the user export the BOM to a text file.
Your program must use an Item class. The class should have private member variables that store
the item’s description, the supplier’s part number, where it can be purchased from, and how much it
costs. The class should have public accessor and mutator functions that get and set the private
member variables’ values. Choose appropriate names and data types for the class’s member
variables. Choose appropriate names for the class’s member functions; choose appropriate names
and data types for their returned data and parameters.
Requirements
You are required to:
• Write a C++ program that addresses the assessment’s objectives.
• Write a report detailing what you did, how, and why.
Resources
Use the following data to test your program:
Submission Instructions
Add all your source code files and report to a .zip archive and name it in the following format:
FIRSTNAME_LASTNAME_ID.zip. Do not include your build directory.
Upload your submission to Stream before the due date.
Hints
The following figures should give you an idea of how data could be captured, how it could be
presented, how it could be exported, and how it could be saved:
1. An example interface 2. An item being entered.
3. An item being added to the Bill of
Materials.
4. The Bill of Materials being exported.
5. The exported file’s contents.
Name Part Number Units Source Cost
10k Ohm 1 Watt Carbon Film Resistors - Pack of 2 RR2798 100 https://www.jaycar.co.nz/10k-ohm-1-watt-carbon-film-resistors-pack-of-2/p/RR2798 0.08
0.71mm Duratech Solder - 200gm NS3005 1 https://www.jaycar.co.nz/0-71mm-duratech-solder-200gm/p/NS3005 19.9
40W Soldering Iron with LEDs TS1470 1 https://www.jaycar.co.nz/40w-soldering-iron-with-leds/p/TS1470 28.9
Deluxe Soldering Iron Stand TS1507 1 https://www.jaycar.co.nz/deluxe-soldering-iron-stand/p/TS1507 21.9
Total
$78.70
You may find the following headers helpful:
• QFile
• QFileDialog
• QTextStream
• QVector
The following code shows how to create an instance of the QVector class and push a value to its end:
QVector myVector {};
myVector.push_back(1);
The following code shows how to create an instance of the QTextStream class and use it to write
data to a string:
QString string {};
QTextStream stream {string};
stream << “Hello World”;
The following code shows how to get a file name using the QFileDialog:
QString filename = QFileDialog::getSaveFileName(this, “Save”,
“C:/”, “Text (*.txt)”);
Frequently Asked Questions
Q. How long should the report be?
A. It should be between 1000 – 1500 words.
Q. How should I structure my report?
A. You should include the following sections: Introduction, Algorithm, Methodology, Results, and
Conclusion. You should discuss your program’s high-level operation in the Algorithm section; you
should discuss your program’s implementation in the Methodology section; and you should discuss
your program’s results in the Results section. Be sure to include your program’s results in your
Results section.
Q. What Integrated Development Environment (IDE) should I use?
A. You should use Qt Creator.
Q. What compiler should I use?
A. You should use Qt’s MinGW kit’s compiler.
Q. Can I get an extension?
A. Yes, but only for exceptional circumstances, e.g. cases of illness, injury, bereavement or other
critical personal circumstances beyond your immediate control. Extensions will be granted at course
or offering coordinator’s discretion. Last minute computer failure and loss of data/files is a very
common excuse and generally not acceptable. Plan to complete the assessment a few days before
the deadline. Start early! Do not underestimate the time it will take to get a working application and
write a good report.
Program Marking Rubric
The program is worth 2/3 of the assessment’s final grade.
D Range (40 – 49.99) C Range (50 – 64.99) B Range (65 – 79.99) A Range (80 – 100) Weighting
Poor Adequate Good Excellent.
Program
The program’s source code doesn’t
compile.
Each variable is named poorly. Each
variable’s data type matches the data it
is supposed to store poorly.
Classes and functions are partially used.
Each class and function is named poorly.
Each function’s return type and input
and output parameters matches the data
it is supposed to work with poorly.
The GUI’s presentation is poor.
A common naming convention is
partially used. The source code’s
formatting is poor.
The program’s source code compiles. It
has a lot of warning messages.
Each variable is named adequately. Its
purpose can be partially deduced from
its name. Each variable’s data type
matches the data it is supposed to store
adequately.
A modular style of programming is
partially used throughout the program’s
source code. Classes and functions are
partially used.
Each class and function is named
adequately. Its purpose can be partially
deduced from its name. Each function’s
return type and input and output
parameters matches the data it is
supposed to work with adequately.
Comments are used adequately to
document the source code. A common
naming convention is partially used. The
source code’s formatting is adequate.
The GUI’s presentation is adequate.
The program run, but has major issues. It
partially displays output in the format
specified.
The program’s source code compiles. It
has some warning messages.
Each variable is named well. Its purpose
can be deduced from its name. Each
variable’s data type matches the data it
is supposed to store well.
A modular style of programming is
largely used throughout the program’s
source code. Classes and functions are
largely used.
Each class and function is named well. Its
purpose can be deduced from its name.
Each function’s return type and input
and output parameters matches the data
it is supposed to work with well.
Comments are used well to document
the source code. A common naming
convention is largely used. The source
code’s formatting is good.
The GUI’s presentation is good.
The program runs, but has minor issues.
It largely displays output in the format
specified.
The program’s source code compiles. It
has no warnings or errors.
Each variable is named extremely well.
Its purpose can easily be deduced from
its name. Each variable’s data type
matches the data it is supposed to store
extremely well. Each variable is initialised
when defined.
A modular style of programming is used
throughout the program’s source code.
Classes and functions are used extremely
well. Each function does one task very
well.
Each class and function is named
extremely well. Its purpose can easily be
deduced from its name. Each function’s
return type and input and output
parameters matches the data it is
supposed to work with extremely well.
Arguments are passed by value or passed
by reference, where appropriate.
Comments are used extremely well to
document the source code. A common
naming convention is used consistently.
The source code’s formatting is
excellent.
The GUI’s presentation is excellent.
The program runs without any issues.
It displays output in the format specified.
100 %
Report Marking Rubric
The report is worth 1/3 of the assessment’s final grade.
D Range (40 – 49.99) C Range (50 – 64.99) B Range (65 – 79.99) A Range (80 – 100) Weighting
Poor Adequate Good Excellent.
Introduction
The report’s introduction is poor. It
summarises the assessment’s
motivation, aim, and objectives. It
summarises the work contained in the
report.
The report’s introduction is adequate. It
presents the assessment’s motivation,
aim, and objectives. It presents the work
contained in the report. It summarises
the report’s structure.
The report’s introduction is good. It
describes the assessment’s motivation,
aim, and objectives. It describes the
work contained in the report. It presents
the report’s structure.
The report’s introduction is excellent. It
discusses the assessment’s motivation,
aim, and objectives. It discusses the work
contained in the report. It presents the
report’s structure.
5 %
Algorithm
The report’s algorithm section is poor. It
summarises the developed algorithm.
The report’s algorithm section is
adequate. It presents the developed
algorithm. A figure is used to illustrate
the algorithm.
The report’s algorithm section is good. It
describes the developed algorithm and
its key stages. A figure is used to
illustrate the algorithm.
The report’s algorithm section is
excellent. It discusses the developed
algorithm; justifying its key stages, and
highlighting its advantages and
disadvantages. Appropriate figures are
used to illustrate the algorithm.
30 %
Methodology
The report’s methodology is poor. It
summarises what was done. Some code
snippets are presented. A few tables,
figures, and listings are used to help
explain the work done.
The report’s methodology is adequate. It
describes what was done. The tools,
libraries, and language used are
presented. Code snippets are presented.
A few tables, figures, and listings are
used to help explain the work done.
The report’s methodology is good. It
describes what was done and how. The
tools, libraries, and language used are
described. Relevant code snippets are
explained. Some relevant tables, figures,
and listings are used to help explain the
work done.
The report’s methodology is excellent. It
discusses what was done, how, and why.
The tools, libraries, and language used
are discussed. Relevant code snippets
are explained in detail. A lot of relevant
tables, figures, and listings are used to
help explain the work done.
30 %
Results
The report’s results section is poor. It
summarises the implemented
algorithm’s output.
The report’s results section is adequate.
It presents a limited analysis of the
implemented algorithm’s output;
critiquing it in terms of a few relevant
metrics.
The report’s results section is good. It
presents an analysis of the implemented
algorithm’s output; critiquing it in terms
of some relevant metrics.
The report’s results section is excellent.
It presents a detailed analysis of the
implemented algorithm’s output;
critiquing it in terms of relevant metrics.
20 %
Conclusion
The report’s conclusion is poor. It
summarises the assessment’s outcome.
The report’s conclusion is adequate. It
presents the assessment’s outcome.
The report’s conclusion is good. It
describes the assessment’s outcome.
The report’s conclusion is excellent. It
discusses the assessment’s outcome. 5 %
Overall
The report is poor. It includes a few
tables, figures, or listings. It summarises
what was done. It has a lot of spelling,
grammar, and punctuation issues. Its
fluency is poor.
The report is adequate. It includes a few
relevant tables, figures, and listings. It
describes what was done. It has a lot of
spelling, grammar, or punctuation issues.
Its fluency is good.
The report is good. It includes some
relevant tables, figures, and listings. It is
easy to read. It describes what was done
and how. It has some spelling, grammar,
or punctuation issues. Its fluency is good.
The report is excellent. It includes a lot of
relevant tables, figures, and listings. It is
very easy to read. It discusses what was
done, how, and why. It has a few
spelling, grammar, or punctuation issues.
Its fluency is excellent.
10 %

站长地图