📄 stdio.html
字号:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html> <head> <meta name="generator" content="HTML Tidy for Linux/x86 (vers 1st October 2002), see www.w3.org"> <title>Standard C I/O</title> </head> <body bgcolor="#ffffff"> <table width="100%" bgcolor="#eeeeff"> <tr> <td><a href="index.html">cppreference.com</a> -> Standard C I/O</td> </tr> </table> <h3>Standard C I/O</h3> <table> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#clearerr">clearerr()</a></td> <td>clears errors</td> </tr> <tr> <td><a href="stdio_details.html#fclose">fclose()</a></td> <td>close a file</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#feof">feof()</a></td> <td>true if at the end-of-file</td> </tr> <tr> <td><a href="stdio_details.html#ferror">ferror()</a></td> <td>checks for a file error</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#fflush">fflush()</a></td> <td>writes the contents of the output buffer</td> </tr> <tr> <td><a href="stdio_details.html#fgetc">fgetc()</a></td> <td>get a character from a stream</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#fgetpos">fgetpos()</a></td> <td>get the file position indicator</td> </tr> <tr> <td><a href="stdio_details.html#fgets">fgets()</a></td> <td>get a string of characters from a stream</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#fopen">fopen()</a></td> <td>open a file</td> </tr> <tr> <td><a href="stdio_details.html#fprintf">fprintf()</a></td> <td>print formatted output to a file</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#fputc">fputc()</a></td> <td>write a character to a file</td> </tr> <tr> <td><a href="stdio_details.html#fputs">fputs()</a></td> <td>write a string to a file</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#fread">fread()</a></td> <td>read from a file</td> </tr> <tr> <td><a href="stdio_details.html#freopen">freopen()</a></td> <td>open an existing stream with a different name</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#fscanf">fscanf()</a></td> <td>read formatted input from a file</td> </tr> <tr> <td><a href="stdio_details.html#fseek">fseek()</a></td> <td>move to a specific location in a file</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#fsetpos">fsetpos()</a></td> <td>move to a specific location in a file</td> </tr> <tr> <td><a href="stdio_details.html#ftell">ftell()</a></td> <td>returns the current file position indicator</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#fwrite">fwrite()</a></td> <td>write to a file</td> </tr> <tr> <td><a href="stdio_details.html#getc">getc()</a></td> <td>read a character from a file</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#getchar">getchar()</a></td> <td>read a character from <strong>STDIN</strong></td> </tr> <tr> <td><a href="stdio_details.html#gets">gets()</a></td> <td>read a string from <strong>STDIN</strong></td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#perror">perror()</a></td> <td>displays a string version of the current error to <strong>STDERR</strong></td> </tr> <tr> <td><a href="stdio_details.html#printf">printf()</a></td> <td>write formatted output to <strong>STDOUT</strong></td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#putc">putc()</a></td> <td>write a character to a stream</td> </tr> <tr> <td><a href="stdio_details.html#putchar">putchar()</a></td> <td>write a character to <strong>STDOUT</strong></td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#puts">puts()</a></td> <td>write a string to <strong>STDOUT</strong></td> </tr> <tr> <td><a href="stdio_details.html#remove">remove()</a></td> <td>erase a file</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#rename">rename()</a></td> <td>rename a file</td> </tr> <tr> <td><a href="stdio_details.html#rewind">rewind()</a></td> <td>move the file position indicator to the beginning of a file</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#scanf">scanf()</a></td> <td>read formatted input from <strong>STDIN</strong></td> </tr> <tr> <td><a href="stdio_details.html#setbuf">setbuf()</a></td> <td>set the buffer for a specific stream</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#setvbuf">setvbuf()</a></td> <td>set the buffer and size for a specific stream</td> </tr> <tr> <td><a href="stdio_details.html#sprintf">sprintf()</a></td> <td>write formatted output to a buffer</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#sscanf">sscanf()</a></td> <td>read formatted input from a buffer</td> </tr> <tr> <td><a href="stdio_details.html#tmpfile">tmpfile()</a></td> <td>return a pointer to a temporary file</td> </tr> <tr bgcolor="#eeeeff"> <td><a href="stdio_details.html#tmpnam">tmpnam()</a></td> <td>return a unique filename</td> </tr> <tr> <td><a href="stdio_details.html#ungetc">ungetc()</a></td> <td>puts a character back into a stream</td> </tr> <tr> <td><a href="stdio_details.html#vprintf">vprintf, vfprintf, vsprintf</a></td> <td>write formatted output with variable argument lists</td> </tr> </table> </body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -