Highlights
Let’s calculate the average fuel consumption for a single filling. Using the notation above;
The average fuel consumption (afc1) = x/z (liters per km) The average cost (ac1) = (x/z)*y (cents per km)
Then for five fillings; The overall Average Fuel Consumption (afc) = {afc1+ afc2+...+ afc5}/5 The overall Average Cost (ac) = {ac1+ ac2+...+ ac5}/5
You’ll also need to check if ac exceeds client set threshold warning.
Part 1:
Write a simple Java program to calculate the average diesel consumption and the average cost for a single filling. Then extend this to include five fillings and calculate the overall average diesel consumption (afc) and average cost (ac) for the five fillings. You’ll also need to warn the user if the average cost is equal to higher than the threshold.
In Part 1, you will be developing a Java program without a GUI. Input and output are via the console.
When the program is executed, the user will be asked to input for five consecutive fillings:
This ICT104: IT Assignment has been solved by our IT experts at My Uni Paper. Our Assignment Writing Experts are efficient to provide a fresh solution to this question. We are serving more than 10000+ Students in Australia, UK & US by helping them to score HD in their academics. Our Experts are well trained to follow all marking rubrics & referencing style.
© Copyright 2026 My Uni Papers – Student Hustle Made Hassle Free. All rights reserved.