摘要: #include #include #include char* str_contact(const char*,const char*);/** ** C语言实现字符串拼接 **/int main(void){ char *ch1 = "hui_"; char *ch2 = "_h... 阅读全文
posted @ 2015-10-16 16:27 LittlePenguin 阅读(3463) 评论(0) 推荐(0) 编辑
摘要: #include #include int main(void){ if ( !access("C://Users/hui",0) ) puts("C://Users/hui EXISITS!"); else puts("C://Users/hui DOE... 阅读全文
posted @ 2015-10-16 15:16 LittlePenguin 阅读(1136) 评论(0) 推荐(0) 编辑
摘要: #include #include #include int main(void) { int status; system("cls"); status = mkdir("book"); /*这是在程序所在当前文件夹下创建book*/ (!status) ? (printf("Directo... 阅读全文
posted @ 2015-10-16 10:46 LittlePenguin 阅读(1860) 评论(0) 推荐(0) 编辑
摘要: #include #include int main() { FILE *fp;if((fp=fopen("g:\\a.txt","wb"))==NULL){ printf("\nopen file error"); getchar(); exit(1); }fputs("34234",fp);fc... 阅读全文
posted @ 2015-10-16 10:44 LittlePenguin 阅读(558) 评论(0) 推荐(0) 编辑
摘要: 1.问题:C语言程序实现读写一个txt文件,txt文件中存储一个十进制数、每读一次该数值加一。2.实现:新建一个文件夹,在该文件夹中建一个outputFileName.txt文件、内容是:1,再在该文件夹中新建一个t.c文件、内容是下面的代码。3.代码:#include #include char ... 阅读全文
posted @ 2015-10-16 09:19 LittlePenguin 阅读(2151) 评论(0) 推荐(0) 编辑