Java Assignment 1
Topics: Documentation, Variables, Math, Scanner
Directions:
Complete the following programming questions in Java. Programs must follow programming standards for variable names and comments. The user should be prompted for the appropriate data and output should have context for the user. Round decimals to 2 decimal places. Flowchart must be submitted with each program and must be NEAT. Complete flowcharts using a flowcharting template, ruler or software. (i.e. Visio) Submit .java file and flowchart image to MS Teams.
Flowcharts: 5 marks
Program: up to 10 marks
Complete the following programming questions in Java. Programs must follow programming standards for variable names and comments. The user should be prompted for the appropriate data and output should have context for the user. Round decimals to 2 decimal places. Flowchart must be submitted with each program and must be NEAT. Complete flowcharts using a flowcharting template, ruler or software. (i.e. Visio) Submit .java file and flowchart image to MS Teams.
Flowcharts: 5 marks
Program: up to 10 marks
Bronze: Max 7 marks
Demonstrates Basic Understanding
Ms. Latimer is preparing to teach the unit “circle” in grade 10 mathematics. You need to help her out and write a program to calculate the circumference of a circle, the area of a circle and the volume of a sphere based on the radius that is inputted from the user. All the results should be outputted in a table and rounded to 2 decimal places.
Demonstrates Basic Understanding
Ms. Latimer is preparing to teach the unit “circle” in grade 10 mathematics. You need to help her out and write a program to calculate the circumference of a circle, the area of a circle and the volume of a sphere based on the radius that is inputted from the user. All the results should be outputted in a table and rounded to 2 decimal places.
Sample Output:
Silver: Max 8 Marks
Demonstrates Good Understanding
A driver’s education class does time trials out in the parking lot. However, they use an old stopwatch that holds the time in seconds. Write a program that inputs number of seconds as a whole number, and then converts that value to hours, minutes, and seconds.
Demonstrates Good Understanding
A driver’s education class does time trials out in the parking lot. However, they use an old stopwatch that holds the time in seconds. Write a program that inputs number of seconds as a whole number, and then converts that value to hours, minutes, and seconds.
Sample Output:.
Gold Max 10 Marks:
Demonstrates Excellent Understanding
A fast-food restaurant charges $1.49 for burgers, $0.89 for fries, and $0.99 for sodas. You have been commissioned to write a cash program that allows an employee to enter an order (the number of burgers, fries, and sodas), the amount of cash the customer spent, and then display an itemized receipt that includes the customer order with subtotal, calculated tax, amount tendered and change owed.
Demonstrates Excellent Understanding
A fast-food restaurant charges $1.49 for burgers, $0.89 for fries, and $0.99 for sodas. You have been commissioned to write a cash program that allows an employee to enter an order (the number of burgers, fries, and sodas), the amount of cash the customer spent, and then display an itemized receipt that includes the customer order with subtotal, calculated tax, amount tendered and change owed.
AMDG
Learning Outcomes:
2.1.1: Explain the need and purpose for documentation.
2.1.2: Document the program code for all assignments
2.1.3: Assign meaningful names to variables using accepted conventions
3.2.1: Use a structured model for solving problems
4.2.1: Recognize that a particular data type permits certain operations to be carried out efficiently
4.2.2: Identify and use appropriate data types
4.2.3: Obtain input from the program user.
4.2.5: Format numerical data
2.1.1: Explain the need and purpose for documentation.
2.1.2: Document the program code for all assignments
2.1.3: Assign meaningful names to variables using accepted conventions
3.2.1: Use a structured model for solving problems
4.2.1: Recognize that a particular data type permits certain operations to be carried out efficiently
4.2.2: Identify and use appropriate data types
4.2.3: Obtain input from the program user.
4.2.5: Format numerical data