0% found this document useful (0 votes)
6 views

Homework Assignment Sheet Week 3

Uploaded by

Kutsu
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

Homework Assignment Sheet Week 3

Uploaded by

Kutsu
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Homework, week 3. All uploads should be to Canvas.

The first 3 items are worth 5 points


each, the pseudocode item is worth 15 points.

1. Watch the two YouTube videos linked below and answer the following questions on the
PEP/8 Simulator. Upload the answers in a word doc titled Simulator

Link 1 and Link 2

What was the name of the presenter?

What should you clear each time you run this program?

What is ZZ for?

Why are the instructions communicated in hex?

What did the first simulation accomplish?

What page in the book is the example #2 from?

What command is used to change form source code to machine code?

Where are the results of an instruction stored?

What input did not get used?

What did the second simulation accomplish?

2. Go to this website and build your machine. Money is no object!!!!

http://www.computerlx.com/

This website will let you start with a computer and then customize to whatever you want. Pick
one of the machines and you will be taken to a screen with a series of dropdowns. These will
allow you to customize every part of the computer. After the last class, you are all hardware
experts now so you can build yourself a dream machine. Take a screen print of your final
product and upload to Canvas with the title Dream Machine.

Note: You don’t have to use this website if you have another. Make sure I can read the picture /
document you upload.
Watch the Pseudocode video and see the Pseudo Code powerpoint for the programming
constructs.

3. What programming construct would you use for the following situations? Upload the
answers in a word doc titled Constructs. Don’t worry about the exact syntax, just
express the construct using English.
Example: When the value of A is greater than 10, print A, otherwise, print B

IF A > 10 then
Print A
ELSE
Print B

Test a value named Total, if it’s less than or equal to 10, add 1 to Total, otherwise reset the value
to 0.

Test a value named Color. If Value is Red, print STOP, if value is Yellow, print SLOW, if value
is Green, print GO!

Read in 20 number values. If the value is even, print the value otherwise skip it.

Read in a list of number values (the list can be different sizes at different times). Add the sum of
the values in a variable called Total.

Print each character of a line until you reach a semi-colon.

4. Develop the algorithm and write a detailed pseudocode solution for the following
system. Upload the pseudocode to Canvas in a word doc titled Payroll System

You need to account for each step that the program will do, what variables will be needed, how
the logic of the program will execute (constructs and branching or looping) and what the output
will be.

I have a small company with 20 employees. I need a payroll system that calculates the pay and
taxes for each employee. I have the following input files:

 EmployeeData – Contains the employee information with their hourly pay rate.
 TaxTable – A lookup table that specifies the taxes to be withheld for ranges of values,
starting at zero and ending at 2,500.00.
 TimeCardData – Each line is a sum of the hours that the employee worked each day.

Employees can also earn overtime


 If the total hours in a week is more than 40, the OT rate is 1.5 times their hourly rate.
After processing, I need an output file called WeeklyPayroll. There should be one line in the file
for each employee that contains these fields

Employee Name
Gross Pay (total pay due)
Taxes Due (value from lookup)
Net Pay (Gross – Taxes)
Regular Pay (earnings without overtime)
OT Pay (overtime earnings)

You might also like