Use an ifstream object named indata to read the first three integers from a file called lottowins and write each number to standard output, on a line by itself. Assume that this is the extent of the input that this program will do.
.
.
Click on the title for the solution
.
.
indata.open("lottowins");
int a,b,c;
indata>>a>>b>>c;
cout<<a<<endl<<b<<endl<<c<<endl;
indata.close();
.
Click on the title for the solution
.
.
This is the answer:
:
indata.open("lottowins");
int a,b,c;
indata>>a>>b>>c;
cout<<a<<endl<<b<<endl<<c<<endl;
indata.close();
Comments
Post a Comment