About 122,000 results
Open links in new tab
  1. fread - cppreference.com

    May 9, 2023 · If size or count is zero, fread returns zero and performs no other action. fread does not distinguish between end-of-file and error, and callers must use feof and ferror to determine which …

  2. C fread () Function - GeeksforGeeks

    Sep 17, 2024 · The C fread () is a standard library function used to read the given amount of data from a file stream. Defined inside <stdio.h>, the fread () function reads the given number of elements of …

  3. fread (3) - Linux manual page - man7.org

    RETURN VALUE top On success, fread () and fwrite () return the number of items read or written. This number equals the number of bytes transferred only when size is 1. If an error occurs, or the end of …

  4. fread () function - C Library

    The C library size_t fread (void *ptr, size_t size, size_t nmemb, FILE *stream) function reads data from the given stream into the array pointed to, by ptr.It is commonly used for reading binary files but can …

  5. An Essential Guide to C fread() Function by Practical Examples

    In this tutorial, you'll learn how to use the C fread () function to read data from a file into the memory.

  6. C fread Tutorial: Master File Reading with Practical Examples

    Apr 6, 2025 · This tutorial explores fread in depth, from basic usage to advanced techniques. You'll learn how to read different data types, handle errors, and optimize performance.

  7. How to Use fread () in C: Efficient Binary File Reading Explained

    Learn how to use the fread () function in C for efficient binary file reading. This comprehensive guide covers basic syntax, practical examples, key differences from similar functions, and best practices for …

  8. man page fread section 3

    The function fread () reads nitems objects, each size bytes long, from the. stream pointed to by stream, storing them at the location given by ptr. The function fwrite () writes nitems objects, each size bytes …

  9. C Language: fread function (Read Block from File) - TechOnTheNet

    In the C Programming Language, the fread function reads nmemb elements (each element is the number of bytes indicated by size) from the stream pointed to by stream and stores them in ptr.

  10. fread | Microsoft Learn

    Dec 2, 2022 · fread returns the number of full items the function read, which may be less than count if an error occurs, or if it encounters the end of the file before reaching count.