Question: III. (10 points) Write a complete Java program to handle weather forecasts. The program should prompt the user for the number of days they would
III. (10 points) Write a complete Java program to handle weather forecasts. The program should prompt the user for the number of days they would like forecasted. It should read weather data from forecast.txt, which you may assume is in the following format:
Tuesday 75 windy
Wednesday 70 sunny
Thursday 68 breezy The program should print the weather forecast only for the number of days requested by the user.
VI. (10 points) Suppose a ?le named song.txt contains a carol, beginning with the following lines:
Chestnuts roasting on an open fire
Jack Frost nipping at your nose
Yuletide carols being sung by the fire
Write a main method to print the contents of the ?le backwards. You may assume all necessary imports, but be sure to handle any possible exceptions. Each letter should be reversed, as well as each line. That is, the last line should print as follows:
erif nepo na no gnitsaor stuntsehC
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
