The following questions are based on the exercises from the last tutorial.
Type the program for Question 1 (GST problem) from the last tutorial. Type the program exactly as shown. The problem is described again below.
A shop owner requires a program to calculate the GST payable on items purchased. The GST is one-tenth of the pre GST price. For example, if the pre-GST price was $100 then the GST is $10 and the price including GST is $110. The user is to input the pre-GST price and the program is to display the GST and the final price including GST.
Run Pre GST Price ($) ? 100 GST = $10.00 Price Including GST = $110.00
Run Pre GST Price ($) ? 5.50 GST = $0.55 Price Including GST = $6.05
Type this program exactly as shown below (except for the author - use your name instead)

Write a Visual Basic program for the following problem.
An athlete is interested in their average speed over a distance. The user is to input the distance (in km) and time taken (in seconds) and the average speed in kilometres per hour is to be displayed. Firstly, as the speed is in kilometres per hour, the time taken in seconds needs to be converted to hours; there are 3600 seconds in an hour, so dividing the time in seconds by 3600 gives the time taken in hours, so 1800 seconds = 1800 ÷ 3600 = 0.5 hours. For example if the athlete travelled 5km in 1800 seconds, then their average speed is calculated as follows: 1800 seconds is 1800 ÷ 3600 hours = 0.5 hours. The average speed is the distance travelled (in km) divided by the time taken (in hours) = 5 km ÷ 0.5 hours = 10kph.
Run Distance (km) ? 15 Time taken (sec) ? 3600 Average speed = 15kph
Run Distance (km) ? 5 Time taken (sec) ? 1800 Average speed = 10kph
calcAverageSpeed()
Input distance, timeInSeconds
timeInHours = timeInSeconds / 3600
averageSpeed = distance / timeInHours
Display averageSpeed
STOP
| Name | Data Type | Description |
| averageSpeed | Double | The average speed over the distance in kph (Kilometres per hour) |
| distance | Double | Distance travelled in kilometres |
| timeInHours | Double | The time taken to travel the distance in hours and fractions of hours |
| timeInSeconds | Integer | The time taken to travel the distance (in seconds) to the nearest whole second |
Due Date: Tutorial 8
Marks: 2%
Question 1 above is Assessable Tutorial B. Hand in a title page as specified in Assessable Tutorial A, and a printout of the code for question 1. The printout of the code should be done from within Access (e.g. File->Print when the code is displayed).