(Latest Revision: Wed Nov 23 20:33:03 PST 2016 ) adderScp.txt

adderScp.txt


Script started on Wed Nov 23 20:31:01 2016
lucifer.local>> cat inDat02
240.8563
501.535
524.9
449.20
598.478
293.253
6.7822
249.641
807.91
39.6141
668.72268
742.1010
539.438
910.734
525.856
933.35
291.7477
lucifer.local>> a.out

This is a program that reads a file containing 17
real numbers.  It writes the sum of the numbers
to the screen, and also to an output file.  After writing
the sum, the program writes the numbers themselves,
in reverse order, both to the screen, and
to the output file.

Enter the filename for the input: inDat02

Enter the filename for the output: outDat

The sum is: 8324.12

In reverse order, the data is:

291.75
933.35
525.86
910.73
539.44
742.10
668.72
 39.61
807.91
249.64
  6.78
293.25
598.48
449.20
524.90
501.54
240.86

lucifer.local>> cat outDat

The sum is: 8324.12

In reverse order, the data is:

291.75
933.35
525.86
910.73
539.44
742.10
668.72
 39.61
807.91
249.64
  6.78
293.25
598.48
449.20
524.90
501.54
240.86

lucifer.local>> a.out

This is a program that reads a file containing 17
real numbers.  It writes the sum of the numbers
to the screen, and also to an output file.  After writing
the sum, the program writes the numbers themselves,
in reverse order, both to the screen, and
to the output file.

Enter the filename for the input: foobar.txt

Enter the filename for the output: outDat

FAILED TO OPEN FILE: foobar.txt

lucifer.local>> exit
exit

Script done on Wed Nov 23 20:31:32 2016