输入与输出
标准库中的输入与输出函数包括:
- int scanf(const char *format, ...)
- int printf(const char *format, ...)
- int getchar(void)
- int putchar(int c)
- char gets(char s)
- int puts(const char *s)
- int sprintf(char s, const char format, ...)
- int snprintf(char s, size_t n, const char format, ...)
文件操作
- FILE fopen(const char filename, const char *mode)
- int fclose(FILE *stream)
- size_t fread(void ptr, size_t size, size_t nmemb, FILE stream)
- size_t fwrite(const void ptr, size_t size, size_t nmemb, FILE stream)
- int fprintf(FILE stream, const char format, ...)
- int fscanf(FILE stream, const char format, ...)
- int fgetc(FILE *stream)
- int fputc(int c, FILE *stream)
- char fgets(char s, int n, FILE *stream)
- int fputs(const char s, FILE stream)
- int getc(FILE *stream)
- int putc(int c, FILE *stream)
- int fseek(FILE *stream, long int offset, int whence)
- long int ftell(FILE *stream)
- void rewind(FILE *stream)