O'Reilly logo

Just Enough C/C++ Programming by Guy W. Lecky-Thompson

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

File Processing with Complex Data Types

One of the most important operations that needs to be performed on data types in a real application is file input and output. You learned about file handling in previous chapters, and the choices remain similar, namely:

  • Member by member, formatted (text).

  • Member by member, binary.

  • Memory block.

The first choice usually yields a structured text file that can be edited with a text editor. The second yields a partially editable file—some of the items, such as integers, will remain in binary format. The final option yields a file that can usually be read only by the application that created it.

As you’ve seen, there are some advantages to all three options, but the most appropriate for user-defined complex data ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required