C File Input/output

C File Input/output

The C programming language provides many standard library functions for file input and output. These functions make up the bulk of the C standard library header . The functionality descends from a "portable I/O package" written by Mike Lesk at Bell Labs in the early 1970s.

The I/O functionality of C is fairly low-level by modern standards; C abstracts all file operations into operations on streams of bytes, which may be "input streams" or "output streams". Unlike some earlier programming languages, C has no direct support for random-access data files; to read from a record in the middle of a file, the programmer must create a stream, seek to the middle of the file, and then read bytes in sequence from the stream.

The stream model of file I/O was popularized by the Unix operating system, which was developed concurrently with the C programming language itself. The vast majority of modern operating systems have inherited streams from Unix, and many languages in the C programming language family have inherited C's file I/O interface with few if any changes (for example, PHP). The C++ standard library reflects the "stream" concept in its syntax; see iostream.

Read more about C File Input/output:  Overview of Functions, Constants, Variables, Member Types, Example

Famous quotes containing the words file, input and/or output:

    Probably nothing in the experience of the rank and file of workers causes more bitterness and envy than the realization which comes sooner or later to many of them that they are “stuck” and can go no further.
    Mary Barnett Gilson (1877–?)

    Celebrity is a mask that eats into the face. As soon as one is aware of being “somebody,” to be watched and listened to with extra interest, input ceases, and the performer goes blind and deaf in his overanimation. One can either see or be seen.
    John Updike (b. 1932)

    Lizzie Borden took an axe
    And gave her mother forty whacks;
    When she saw what she had done,
    She gave her father forty-one.
    —Anonymous. Late 19th century ballad.

    The quatrain refers to the famous case of Lizzie Borden, tried for the murder of her father and stepmother on Aug. 4, 1892, in Fall River, Massachusetts. Though she was found innocent, there were many who contested the verdict, occasioning a prodigious output of articles and books, including, most recently, Frank Spiering’s Lizzie (1985)