O'Reilly logo

C Programming Absolute Beginner’s Guide, Third Edition by Dean Miller, Greg Perry

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

28. Saving Sequential Files to Your Computer

In This Chapter

Storing information in disk files

Opening a file

Using sequential files

None of the programs you’ve seen so far has been able to store data for very long. Think about this for a moment: If you defined an integer variable, put a 14 in it, and then turned off the computer (believe me now and try it later), that variable would no longer have 14 in it. If you turned your computer back on and tried to find the value in the variable, you couldn’t find it—no way.

This chapter explains how to save data to your disk. When the data is on your disk, it will be there until you change or erase it. Data on your disk is just like music on a tape. You can turn off the tape deck, and the tape ...

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