Question: Exercise#3 (1 point): Repeat exercise 2 here, but read the input from a file instead from a user and print the output to a file

 Exercise#3 (1 point): Repeat exercise 2 here, but read the input

Exercise#3 (1 point): Repeat exercise 2 here, but read the input from a file instead from a user and print the output to a file instead of console as shown below: Output File Sample: Car's original price: 20000AED Car's selling price: 25000AED No. of cars to be sold: 23 Input File Sample: 20000 25000 23 I ************** Profit = 575000 - 460000 = 115000 AED Exercise#4 (2 Points). Write a program to do the following: 1. Read the content from the file with students' names with class scores 2. Create a new file (student_average.txt) and write names (first and last) and max (use Math.maxo iteratively) score of classes for each student. 3. Create a new file (class_average.txt) and write class name and average score of each class. Text file: Name MT181 CS101 PH6.01 EE101 CH101 Zayn 100 92 85 96 85 Jason 98 82 80 88 79 Russel 84 80 95 99 100 Linus 88 92 93 95 99 Michelle 86 88 81 90 91 Leving 98 93 82 94 81 Exercise#3 (1 point): Repeat exercise 2 here, but read the input from a file instead from a user and print the output to a file instead of console as shown below: Output File Sample: Car's original price: 20000AED Car's selling price: 25000AED No. of cars to be sold: 23 Input File Sample: 20000 25000 23 I ************** Profit = 575000 - 460000 = 115000 AED Exercise#4 (2 Points). Write a program to do the following: 1. Read the content from the file with students' names with class scores 2. Create a new file (student_average.txt) and write names (first and last) and max (use Math.maxo iteratively) score of classes for each student. 3. Create a new file (class_average.txt) and write class name and average score of each class. Text file: Name MT181 CS101 PH6.01 EE101 CH101 Zayn 100 92 85 96 85 Jason 98 82 80 88 79 Russel 84 80 95 99 100 Linus 88 92 93 95 99 Michelle 86 88 81 90 91 Leving 98 93 82 94 81

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!