1: Write a program that does the following: Reads from a file 10 integers (one per line) - file name Integers.dat Squares each of the integers. Adds the 10 integers together Adds the squares of the...

Answer fast and correct this time else will give downvote
1:<br>Write a program that does the following:<br>Reads from a file 10 integers (one per line) - file<br>name Integers.dat<br>Squares each of the integers.<br>Adds the 10 integers together<br>Adds the squares of the integers together<br>Writes each of the integers and its sum into a file called<br>'SumofSquares.dat'<br>The last line of the file should contain the total of all the integers<br>and the total of all of the squares of all of the integers.<br>Example of the input file (use any integers you prefer):<br>12<br>4<br>223<br>93 76<br>a, = 12<br>54<br>90<br>67<br>543<br>Example of the output file:<br>144<br>16<br>49729<br>5776<br>2916<br>8100<br>4489<br>294849<br>6.<br>Integer total =<br>Squares total =<br>1073<br>366029<br>

Extracted text: 1: Write a program that does the following: Reads from a file 10 integers (one per line) - file name Integers.dat Squares each of the integers. Adds the 10 integers together Adds the squares of the integers together Writes each of the integers and its sum into a file called 'SumofSquares.dat' The last line of the file should contain the total of all the integers and the total of all of the squares of all of the integers. Example of the input file (use any integers you prefer): 12 4 223 93 76 a, = 12 54 90 67 543 Example of the output file: 144 16 49729 5776 2916 8100 4489 294849 6. Integer total = Squares total = 1073 366029

Jun 09, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here