ÈçºÎ²éÕÒC·ç¸ñ×Ö·û´®ÖжººÅµÄ¸öÊý
C/C++ code:
const char* p="ab12,32,123,9a"
ÎÒÏë×ö¸öÅжϣ¬²éÕÒÀïÃæÊÇ·ñÓÐÈý¸ö¶ººÅ£¬ÓÐÈý¸öµÄ»°Õý³£return.²»ÊÇÈý¸ö¶ººÅµÄºÃ£¬Ìáʾ´íÎóÐÅÏ¢¡£
лл¸÷λÀ²£¡£¡
±éÀú²éÕÒ¼ÆÊý¡£¡£¡£
strchr()
×îÊʺÏÁË
·½·¨Ì«¶àÁË£º
Öð¸ö×Ö·ûÅжÏ
»òÕßstrstr()
»òÕßstrchr()
µ÷Óÿ⺯Êý£¬»òÕß×Ô¼º°¤¸ö×Ö·û±éÀú
Â¥ÉϵÄ2λ¸ç£¬²»ÊÇÕÒλÖã¬ÊÇÕÒ¸öÊý
´ÓÍ·µ½Î²±éÀúÒ»±é
int count = 0;
while( *p != '\0')
{
if(*p++ = ''')
count++;
}
ǰ¶Ëʱ¼ä»Ø´ð±ðÈËÎÊÌâµÄʱºòÕýºÃд¹ý£¬Äã¸Ã¸Ã¾ÍÄÜÓÃÁËC/C++ code:
#include "string"
#include "iostream"
using std::string;
using std::cin;
using std::cout;
int main(int argc, char* argv[])
{
string strInput = "abc,def,ghi,jkl\
mnos,sadf,asgs\
f,sa,f,sa,fa,sdf";
int nCount = 0; //×ܸöÊý
int *nArray = new int[20];
for(int i = 0, j = 0; i < strInput.length() ; ++i)
{
if(strInput[i] == ',')
{
nCount++;
nArray[j++] = i;
}
}
cout<< "¹²ÓÐ','"<&l
Ïà¹ØÎÊ´ð£º
//C ½Ó¿Ú
extern "C"
{
TESSDLL_API int __cdecl GetTessText(const char *imagefile, char *text);
}
//ÎÒÔÚC#ÖÐÉùÃ÷
//µ÷ÓÃC DLL Öеĺ¯Êý
[DllImport("OCRapi.dll&quo ......
´ó¼ÒºÃ:
ÎÒÊǸãCµÄ, ÏÖÔÚÏëÓÃC Á¬½ÓMYSQL,µ«ÊÇÔõôҲÁ¬½Ó²»ÁË,ÎҵĴúÂëÈçÏÂ:
#include <stdio.h>
#include "C:\Program Files\MySQL\MySQL Server 5.0\include\mysql.h"
......
1. Èç϶¨Òå»áÓÐʲô´íÎó·¢Éú
//file1.c
int a[10];
//file2.c
extern int *a;
2. ´óÈÝÁ¿È«¾Ö±äÁ¿ÓÐʲôΣº¦£¬Èç
//file.c
......
<table width="100%" border="1" cellpadding="0" cellspacing="0">
<c:forEach items="${quaeres}" var="q">
......
ÒÔÏ·ÖÎö»ùÓÚ£º
Developer Platform :S60 3rd Edition, Feature Pack 2 SDK
Operating System :Symbian OS v9.3
Ò»£¬ÎªÊ²Ã´ÒªÊ¹ÓÃClient/Server¼Ü¹¹
ÔÚSymibian OSÖÐËùÓеÄÒì²½·þÎñ¶¼ÊÇServerͨ¹ýC/S¼Ü¹¹À´ÊµÏÖµ ......