C/C++Í·ÎļþÒ»ÀÀ
C¡¢´«Í³ C++
#include <assert.h>¡¡¡¡¡¡¡¡
//É趨²åÈëµã
#include <ctype.h>¡¡¡¡¡¡¡¡
//×Ö·û´¦Àí
#include <errno.h>¡¡¡¡¡¡¡¡
//¶¨Òå´íÎóÂë
#include <float.h>¡¡¡¡¡¡¡¡
//¸¡µãÊý´¦Àí
#include <fstream.h>¡¡¡¡¡¡
//ÎļþÊäÈ룯Êä³ö
#include <iomanip.h>¡¡¡¡¡¡
//²ÎÊý»¯ÊäÈ룯Êä³ö
#include <iostream.h>¡¡¡¡¡¡
//Êý¾ÝÁ÷ÊäÈ룯Êä³ö
#include <limits.h>¡¡¡¡¡¡¡¡
//¶¨Òå¸÷ÖÖÊý¾ÝÀàÐÍ×îÖµ³£Á¿
#include <locale.h>¡¡¡¡¡¡¡¡
//¶¨Òå±¾µØ»¯º¯Êý
#include <math.h>¡¡¡¡¡¡¡¡¡¡
//¶¨ÒåÊýѧº¯Êý
#include <stdio.h>¡¡¡¡¡¡¡¡
//¶¨ÒåÊäÈ룯Êä³öº¯Êý
#include <stdlib.h>¡¡¡¡¡¡¡¡
//¶¨ÒåÔÓÏÊý¼°ÄÚ´æ·ÖÅ亯Êý
#include <string.h>¡¡¡¡¡¡¡¡
//×Ö·û´®´¦Àí
#include <strstrea.h>¡¡¡¡¡¡
//»ùÓÚÊý×éµÄÊäÈ룯Êä³ö
#include <time.h>¡¡¡¡¡¡¡¡¡¡
//¶¨Òå¹ØÓÚʱ¼äµÄº¯Êý
#include <wchar.h>¡¡¡¡¡¡¡¡
//¿í×Ö·û´¦Àí¼°ÊäÈ룯Êä³ö
#include <wctype.h>¡¡¡¡¡¡¡¡
//¿í×Ö·û·ÖÀà
//////////////////////////////////////////////////////////////////////////
±ê×¼ C++¡¡£¨Í¬ÉϵIJ»ÔÙ×¢ÊÍ£©
#include <algorithm>¡¡¡¡¡¡
//STL ͨÓÃËã·¨
#include <bitset>¡¡¡¡¡¡¡¡¡¡
//STL λ¼¯ÈÝÆ÷
#include <cctype>
#include <cerrno>
#include <clocale>
#include <cmath>
#include <complex>¡¡¡¡¡¡¡¡
//¸´ÊýÀà
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <deque>¡¡¡¡¡¡¡¡¡¡
//STL Ë«¶Ë¶ÓÁÐÈÝÆ÷
#include <exception>¡¡¡¡¡¡
//Òì³£´¦ÀíÀà
#include <fstream>
#include <functional>¡¡¡¡¡¡
//STL ¶¨ÒåÔËË㺯Êý£¨´úÌæÔËËã·û£©
#include <limits>
#include <list>¡¡¡¡¡¡¡¡¡¡¡¡
//STL ÏßÐÔÁбíÈÝÆ÷
#include <map>¡¡¡¡¡¡¡¡¡¡¡¡
//STL Ó³ÉäÈÝÆ÷
#include <iomanip>
#include <ios>¡¡¡¡¡¡¡¡¡¡¡¡
//»ù±¾ÊäÈ룯Êä³öÖ§³Ö
#include <iosfwd>¡¡¡¡¡¡¡¡¡¡
//ÊäÈ룯Êä³öϵͳʹÓõÄÇ°ÖÃÉùÃ÷
#include <iostream>
#include <istream>¡¡¡¡¡¡¡¡
//»ù±¾ÊäÈëÁ÷
Ïà¹ØÎĵµ£º
FILE* pFile = fopen("1.txt","w");
fwrite("http://www.886997.com",1,strlen(http://www.886997.com),pFile);
fseek(pFile,0,SEEK_SET); //´ÓÎļþµÄ¿ªÊ¼´¦¸²¸ÇдÈë
char cStr[100];
memset(cStr,0,sizeof(cStr));
fread(cStr,1,100,pFile);
char *pBuf;
fseek(pFile,0,SEEK_END);
int leng = ftell(pFile);
pBuf ......
ÕâƪÎÄÕºܳ¤£¬×ªÔØÏÂÀ´¹©×Ô¼ºÂýÂýѧϰ¡£
±à³ÌÐÞÑø £¨×÷Õߣº³Â𩣩
————
ʲôÊǺõijÌÐòÔ±£¿ÊDz»ÊǶ®µÃºÜ¶à¼¼Êõϸ½Ú£¿»¹ÊǶ®µ×²ã±à³Ì£¿»¹ÊDZà³ÌËٶȱȽϿ죿
ÎÒ¾õµÃ¶¼²»ÊÇ¡£¶ÔÓÚһЩ¼¼Êõϸ½ÚÀ´ËµºÍµ×²ãµÄ¼¼Êõ£¬Ö»Òª¿´°ïÖú£¬²é×ÊÁϾÍÄÜÕÒµ½£¬¶Ô
ÓÚËٶȿ죬ֻҪ±àµÃ¶àÒ²¾ÍÊìÄÜÉúÇÉÁË¡ ......
À´×Ô£ºhttp://blogger.org.cn/blog/more.asp?name=binaryluo&id=11408
CÎļþ²Ù×÷Óöµ½µÄ×´¿ö
1.½«Ò»¸öÎļþ¶Áµ½ÁíÒ»¸öÎļþ£¬ÓÓ(ch = getc(fp)) != EOF”À´ÅжÏÎļþÊÇ·ñ½áÊø£¬Èç¹ûÎļþÊÇÈ«Ó¢ÎÄÎı¾µÄ»°¾ø¶ÔûÎÊÌ⣬ÐÂÎļþµÄ´óСºÍÔÎļþ´óСһÑù£»µ«ÊÇÈç¹ûÊÇһЩÓÐÖÐÎÄ×Ö·û»òÕßÊǶþ½øÖÆ ......