Question: (File Input/ Output) Q2. Write statements to define an input stream and an output stream and associate them to the following files, respectively: in.dat, out.dat.

(File Input/ Output) Q2. Write statements to define an input stream and an output stream and associate them to the following files, respectively: in.dat, out.dat. Assume that in.dat has eight integers. Write statements to calculate the sum, product, and average of the integers and to write these values to out.dat
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
