c语言 13-1
1、
#include <stdio.h> int main(void) { FILE *fp; char filename[128]; printf("filename: "); scanf("%s", filename); fp = fopen(filename, "r"); if(fp != NULL) { printf("%s exists.\n", filename); fclose(fp); } else { printf("\a%s does not exist.", filename); } return 0; }