#include<stdio.h>
#include<stdlib.h>
#include<assert.h>
char*my_strcat(char*dest,constchar*src)
{
assert(dest);
assert(src);
char*ret=dest;
while(*dest)
{
dest++;
}
while(*dest++=*src++)
{
;
}
returnret;
}
intmain()
{
chararr3[20]="welco..
分类:
数据库 时间:
2015-11-19 07:13:28
阅读次数:
196
1.intmy_strcmp(constchar*str1,char*str2)//my_strcmp库函数的实现{intret=0;while((*str1==*str2)&&*str1&&*str2){str1++;str2++;while(!(*str1&&*str2))return1;}return-1;}2.char*strcat(char*str1,constchar*str2)//strcat库函数的实现方法{char*..
分类:
其他好文 时间:
2015-11-13 10:35:22
阅读次数:
392
Strcat函数原型如下:
char*strcat(char*strDest,constchar*strScr)//将源字符串加const,表明其为输入参数
{
char*address=strDest;//该语句若放在assert之后,编译出错
assert((strDest!=NULL)&&(strScr!=NULL));//对源地址和目的地址加非0断言
while(*strDest)//是..
分类:
编程语言 时间:
2015-11-10 14:18:46
阅读次数:
240
去空格及特殊符号s.strip().lstrip().rstrip(',')复制字符串#strcpy(sStr1,sStr2)sStr1 = 'strcpy'sStr2 = sStr1sStr1 = 'strcpy2'print sStr2连接字符串#strcat(sStr1,sStr2)sStr1...
分类:
编程语言 时间:
2015-11-06 14:25:56
阅读次数:
190
#include<stdio.h>#include<assert.h>char*my_strcat(char*dst,constchar*src){ char*cp=dst; assert(dst); assert(src); while(*cp) { cp++; } while(*cp++=*src++) { ; } returndst;}charstrncat(char*front,constchar*back,intcount){ char*start=front; asse..
分类:
其他好文 时间:
2015-11-03 00:52:16
阅读次数:
133
clc;clear all;for i=1:40for j=1:10image=imread(strcat('N:\FACE\orl_faces\s',...int2str(i),'\',int2str(j),'.pgm'));imwrite(image,strcat('N:\FACE\orl_fa...
分类:
其他好文 时间:
2015-10-29 19:44:23
阅读次数:
182
save_file_name='C:\Users\cong\Desktop\研一实战\项目\图像中时间数字识别\OCR\result6\';for j=0:1:9 image_path=strcat('C:\Users\cong\Desktop\研一实战\项目\图像中时间数字识别\traini...
分类:
其他好文 时间:
2015-10-24 21:49:34
阅读次数:
138
有点坑:在windows下,这么写,打印时也会把\n当成字符串打印出来path= strcat('/home/wang/Desktop/trainset/num0/',file(i).name,'\n');好吧,这是windows下成功的,注意fid=fopen([save_file_name,'r...
loadrunner比较有用的字符串函数******************************************************************************** strcat的串连两个字串。1)strcat char *strcat ( char *t...
分类:
其他好文 时间:
2015-10-23 11:58:31
阅读次数:
247
使用说明:测试使用libphenom库的字符串追加函数,效率是strcat的60多倍。所以在进行大量的字符串累加的时候可以考虑使用libphenom库依赖库:ck-0.4.5.tar.gz cmake-3.1.2.tar.gzlibtap-1.12.0.tar.bz2libphenom.tar.g....
分类:
系统相关 时间:
2015-10-17 20:28:32
阅读次数:
747