Exercises
11. | Compile, build, and execute the three file copy programs. Other possibilities include using UNIX compatibility libraries, including the Microsoft Visual C++ library (a program using this library is included on the book's Web site). Note: All source code is included on the Web site. Appendix A gives some brief notes on getting started with the Web site code using Microsoft Visual Studio .NET or Visual C++ 6.0.Appendix A will get you started, and you will find extensive information on the Microsoft Web site and with the development environment's documentation. |
13. | Windows uses the carriage returnline feed (CRLF) sequence to denote an end of line. Determine the effect on Program 1-1 if the input file is opened in binary mode and the output file in text mode, and conversely. What is the effect under UNIX or some other system? |
14. | Time the file copy programs on any large file. Obtain data for as many of the combinations as possible and compare the results. Needless to say, performance depends on many factors, but, by keeping other system parameters the same, it is possible to get helpful comparisons between the implementations. Suggestion: Tabulate the results in a spreadsheet to facilitate analysis. Chapter 6 contains a program for timing programs, and Appendix C gives some experimental results. |