TECH1200 Fundamentals of Programming – Control Flow Prototype: Study Guide + Solved Answer

TECH1200 Fundamentals of Programming - Control Flow Prototype | Taxation Program Design & Implementation | Study Guide + Solved Answer

This guide walks you through TECH1200 Fundamentals of Programming - Control Flow Prototype assessment - one of the most hands-on tasks you'll face early in your programming journey. It covers the complete design and development cycle: writing clean pseudocode, building a logical flow chart, and implementing a functional Python 3 program that calculates employee income, tax deductions, and superannuation.

You'll get a breakdown of exactly what the assessors are looking for across all four marking criteria, plus a solved example you can study alongside your own work. Whether you're stuck on input validation or unsure how to structure your functions, this guide gives you a clear, practical path forward. Don't skip the scoring tips - they're pulled directly from the rubric.

ASSESSMENT OVERVIEW

This assessment evaluates your ability to design and implement a basic program using structured logic and Python.

  • Interpret a simple taxation-based case study
  • Design solution using pseudocode (~300-400 words)
  • Create a flowchart (~1 page equivalent)
  • Develop a Python 3 program with input validation (~400-600 words equivalent code)
  • No referencing required
  • Submit 2 files only: .py file + Word/PDF document
  • Program must include looping for repeated use and clear user interaction

Task 1: Pseudocode

Goal Description

The pseudocode is the blueprint of your program. It earns the most marks (10 out of 20), so treat it seriously. A well-structured pseudocode demonstrates that you understood the problem before you touched a line of Python. It needs to show the complete logical flow - from accepting inputs to calculating outputs to looping for multiple employees.

The Solved Pseudocode

Step 1: Start the program.

Step 2: Define the function called compute_earnings with the attributes work_hours and pay_rate.

Step 2.1: By multiplying work_hours with pay_rate, find the gross_pay.

Step 2.2: By multiplying 0.20 with gross_pay, find the tax_amount.

Step 2.3: By multiplying 0.10 with gross_pay, find the pension_contribution.

Step 2.4: By subtracting like below, find the final_pay: gross_pay - tax_amount - pension_contribution.

Step 2.5: Return gross_pay, tax_amount, pension_contribution, and final_pay.

Step 3: Define the function called main().

Step 3.1: Perform the loops for performing more calculations.

Step 3.1.1: Ask the user for inputs - the employee's name, working hours, and the rate of payment.

Step 3.1.2: Check whether the work_hours and pay_rate variables are greater than zero for validation purposes.

Step 3.1.2.1: If work_hours or pay_rate is zero or less, display the error message and continue to the next iteration.

Step 3.1.3: Call the function compute_earnings with the parameters work_hours and pay_rate (Joyner, 2014, p. 14).

Step 3.1.4: Display the following output - employee name, income (gross pay), income tax deduction, superannuation, and final payment.

Step 3.1.5: Ask the user whether they want to calculate for another employee. If the user does not type 'yes' or 'y', break the loop.

Step 3.1.6: Display relevant error messages if the entered input is not a number.

Step 4: Call the main() function to start the program.

Step 5: End the program.

"The compute_earnings function is fundamental - it performs all financial calculations including gross pay, tax, and superannuation, keeping the logic cleanly separated from user interaction in main()."

Tip: Markers want to see a clear separation between the compute_earnings function and main() - don't merge them. The rubric rewards 'comprehensive understanding of the program design process' at Distinction level, which means your pseudocode should mirror exactly how your Python code is structured.

Task 2: Flow Chart

Goal Description

The flow chart is the visual companion to your pseudocode. It maps the same logic using standard symbols - ovals for start/end, rectangles for processes, diamonds for decisions. If your pseudocode is accurate, the flow chart should almost draw itself. Markers check whether the chart reflects the actual program design process.

Flow Chart Steps Explained

Step 1: Start the Python program (Hetland, 2017, p. 23).

Step 2: Collect the employee's name from the user.

Step 3: Collect work hours and pay rate from the user.

Step 4: Check whether the payment rate and working hours contain any negative or zero values.

Step 4.1: If working hours or payment rate is zero or negative, return to Step 2 and prompt the user again.

Step 4.2: If both inputs are positive, proceed to calculate the output.

Step 5: Display the output - income, income tax deduction, and superannuation deduction.

Step 6: Ask the user whether they wish to calculate for another employee.

Step 7: If yes, loop back to Step 2. If no, exit the program.

"The decision diamond at Step 4 is the most critical part of the flow chart - it's where input validation happens, and its absence or inaccuracy is one of the most common reasons students lose marks."

Tip: Your flow chart needs a visible loop-back arrow. Markers need to see that your design accounts for the 'calculate again?' decision. Use standard flow chart notation - don't invent your own symbols.

Task 3: Python 3 Program Implementation

Program Architecture

The Python program uses two functions - compute_earnings and main - to keep the logic clean and modular. The compute_earnings function handles all the mathematics, and main handles user interaction, validation, and the loop (Hall & Stacey, 2010, p. 35).

compute_earnings Function

This function takes work_hours and pay_rate as parameters. It calculates the gross pay by multiplying the two values. The income tax is 20% of gross pay (multiply by 0.20). The superannuation (pension contribution) is 10% of gross pay (multiply by 0.10). The final pay is derived by subtracting both deductions from gross pay. The function returns all four values for display.

main Function and Input Validation

The main function runs inside an infinite while loop, allowing the program to process multiple employees without restarting. It collects three inputs from the user: employee name, hours worked, and hourly pay rate. A critical validation step checks that both work_hours and pay_rate are greater than zero - if either value is zero or negative, the program displays an error message and continues to the next iteration (Lutz, 2001, p. 42).

The program wraps numeric input collection in a try-except block to catch ValueError exceptions, ensuring users cannot break the program by entering text where a number is expected. After displaying results, the user is asked whether to calculate for another employee. Entering anything other than 'yes' or 'y' terminates the loop.

Output Format

All calculated values are displayed with two decimal places using Python's string formatting. The output shows the employee name, gross income, income tax deduction, superannuation deduction, and final take-home pay.

"The program uses an infinite loop and exception handling to ensure continuous operation and reliable user input - both of which directly address the assessment's requirement for user interactivity and input validation."

Tip: HD-level implementation means 'exemplary comments and organisation.' Write a comment above every logical block - function definitions, the validation check, the try-except, and the loop condition. Markers read your comments as evidence of programming understanding.

Want the Full Solved Solution for TECH1200?

Get the complete submission-ready file with formatted pseudocode, flowchart diagrams, and fully commented Python code.

Order Custom Solution

How to Score High on This Assessment

  • Match your pseudocode structure to your Python code exactly - each Step in your pseudocode should correspond to a visible block of code; markers will cross-check them.
  • Name your functions compute_earnings and main - these names appear in the marking context and signal you followed the specification closely.
  • Always validate that work_hours and pay_rate are greater than zero - this satisfies both the Problem Solving and Program Implementation criteria and is explicitly required in the case study.
  • Use try-except blocks around numeric input conversions - catching ValueError shows you understand defensive programming, which maps directly to the 'exceptional problem-solving ability' descriptor at HD.
  • Add a comment above every logical section of your Python code - the rubric specifically distinguishes between 'appropriate comments' (Distinction) and 'exemplary comments' (HD).
  • Your flow chart must include a visible loop-back arrow for the 'continue calculation?' decision - missing this loses marks on both the flow chart and problem-solving criteria.
  • Output must display values to two decimal places - sloppy formatting reads as incomplete work even when the maths is correct.
  • Keep variable names descriptive - work_hours, pay_rate, tax_amount, pension_contribution. Single-letter variable names will cost you Coding Standards marks.
  • Test your program with the exact values from the case study (John Smith: 40 hrs, $25/hr → Income $1000, Tax $200, Super $100) before submitting.

Why Students Struggle With This Assessment

Unclear logic flow
Most students skip planning → Fix: Write pseudocode first

Weak input validation
They only check negatives → Fix: Handle text input with try-except

Mismatch between flowchart and code
Design doesn't reflect implementation → Fix: Build both from same logic

No looping structure
Program runs once only → Fix: Always include a user-controlled loop

Messy code formatting
Hard to read → Fix: Use spacing, comments, and clear naming

Quick Revision Checklist

  • Pseudocode uses Step numbering and clearly shows compute_earnings and main functions separately
  • Pseudocode includes input steps for employee name, hours worked, and hourly rate
  • Pseudocode shows validation logic (check work_hours > 0 AND pay_rate > 0)
  • Pseudocode shows loop - 'ask user to continue or exit' logic
  • Flow chart uses correct symbols (oval=start/end, rectangle=process, diamond=decision)
  • Flow chart includes decision diamond for negative/zero input with loop-back arrow
  • Flow chart includes 'calculate again?' decision with both Yes (loop) and No (exit) arrows
  • Python program calculates gross_pay = work_hours * pay_rate correctly
  • Tax deduction = 20% of gross_pay and superannuation = 10% of gross_pay
  • Program tested with John Smith (40 hrs, $25/hr) and Jane Doe (35 hrs, $30/hr) values
  • try-except block catches ValueError for non-numeric inputs
  • All output values formatted to two decimal places
  • Code includes comments above every logical block (function definition, validation, loop, try-except)
  • Variable names are descriptive (work_hours, pay_rate, tax_amount, pension_contribution)
  • Exactly 2 files submitted - one .PY and one Word/PDF with pseudocode, flow chart, and references

Related Units You Might Be Studying

Frequently Asked Questions

Q: What exactly does this assessment ask me to produce?

A: You need to submit two files: a Python (.py) file containing your working program, and a Word or PDF document containing your pseudocode, flow chart, and any references. The program must calculate employee income from hours worked and hourly rate, then apply a 20% tax deduction and 10% superannuation deduction. It must handle multiple employees using a loop and validate all user inputs.

Q: Do I have to use two separate functions, or can I write everything in one?

A: The case study and the marking rubric both reward modular design. While you won't fail for using one function, you'll lose marks in Problem Solving. The expected design has a compute_earnings function handling all calculations and a main function handling user interaction - keep them separate.

Q: Can I use ChatGPT or other AI tools to help write my code?

A: This assessment is GenAI Level 2 - you may use AI tools for research and content generation, but you must reference any AI output in APA 7 format and include a full appendix of all prompts and responses. Unreferenced AI use is treated as academic misconduct and can result in a zero mark.

Q: What's the most common reason students lose marks on this assessment?

A: Pseudocode that doesn't align with the actual Python code. Markers compare them side by side. The second most common issue is missing input validation - many students forget to handle negative values or non-numeric entries. Both are explicitly tested in the marking guide.


Ask Tutor for Help

We help students with course-specific content, tools and services in order to learn more effectively and succeed. Get one-on-one Assignment help - Homework Help from subject’s tutors—available 24/7. Ask your question anytime from anywhere.    Click here....

Comments

Leave a Reply

Captcha

Millions of Study Resources/Solved Problems and Course Assignments !! Start Discovering