You are on page 1of 4

HIGHER EDUCATION PROGRAMMES

Academic Year 2023: January - June

Formative Assessment 2: Systems Development 1 (HSYD100-1)

NQF Level, Credits: 5, 12

Weighting: 25%

Assessment Type: Practical Exercise

Educator: P. Jideani

Examiner: P. Jideani

Due Date: 12 May 2023

Total: 50 marks

Instructions:

• This paper consists of 2 questions.


• It is based upon units 5 - 8 of your study guide.
• All questions are compulsory.

• You must submit your code and your screenshots of your application in one pdf
file

1 HSYD100-1–Jan-Jun2023-FA2-PC-V2-13022023
Question 1 [20 marks]
You and four other members of your programming study group decide to tackle
programming by making it fun and interesting. The five of you decide to create a game.
Each member of the team picks a number, the program should accept this number.
Using a bar chart style illustrate the numbers chosen by displaying an asterisk for each
number. The output of your program should display similar to the image below

2 HSYD100-1–Jan-Jun2023-FA2-PC-V2-13022023
RUBRIC

Functionality Marks

Request various user inputs 4

Receive user inputs 4

Use of a function to perform asterisks 7

Correct output statements 5

Question 2 [30 marks]

Question 2.1 [13 marks]

You are gradually making progress in your programming journey and your love for
programming continues to grow. You are developing an application for invoicing.
Create a class called Purchase. Each Purchase must have an invoice number, amount
of sale and an amount for sales tax. You have been reminded that you need to include
set methods for the invoice number and sale amount. For the set method of the sale
amount, calculate the sales tax as 5 percent of the sale amount. You have been again
reminded that you need to include a display method that displays all the purchase’s
details.

RUBRIC

Functionality Marks

Correct class name 2

Instance variables 3

Mutator methods 6

Display or toString method 4

3 HSYD100-1–Jan-Jun2023-FA2-PC-V2-13022023
Question 2.2 [17 marks]

You are about to complete this exciting invoicing system. Now code an application that
declares a purchase object and prompts the user for purchase details. When this
prompt is made, do not allow the user to proceed until a number between 1000 and
6000 inclusive has been entered. When the system prompts for a sale amount, it must
not proceed until the user has entered a non-negative value. In the event a valid
purchase object has been created, display the object’s invoice number, sale amount
and sales tax.

RUBRIC

Functionality Marks

Code in the correct method 2

Object creation 3

Receive user input and evaluate based 9


on the conditions

Correct Output statements 3

4 HSYD100-1–Jan-Jun2023-FA2-PC-V2-13022023

You might also like