码迷,mamicode.com
首页 >  
搜索关键字:str    ( 67828个结果
8.6 文件IO fflush fseek ftell rewind feof ferror
fprintf() 、sprintf、snprintf:int fprintf(FILE *stream, const char *format, ...);int sprintf(char *str, const char *format, ...);int snprintf(char *str,...
分类:Windows程序   时间:2014-09-02 22:43:15    阅读次数:288
POJ 2039 To and Fro(水题)
【题目简述】:字符串的简单处理,看懂题意,特别是他给的那个例子就好,很简单 见代码: #include #include #include #include using namespace std; char str[211][211]; int main() { int colum; char str1[211]; int tmp; while(cin>>colum,co...
分类:其他好文   时间:2014-09-02 21:25:55    阅读次数:248
8.2 二级指针 指针数组
二级指针找出最大的字符:#include char maxchar(char * str, char** max){ char da = *str; //先让最大的执行第一个字符 *max = str; while (*str) { if (*str > da) { ...
分类:其他好文   时间:2014-09-02 21:17:25    阅读次数:226
找出字符串中第一个不重复的字符(JavaScript实现)
如题~ 此算法仅供参考,小菜基本不懂高深的算法,只能用最朴实的思想去表达。 1 //找出字符串中第一个不重复的字符 2 // firstUniqueChar("vdctdvc"); --> t 3 function firstUniqueChar(str){ 4 var str = str...
分类:编程语言   时间:2014-09-02 19:46:25    阅读次数:189
日期包装函数
function producedate(){ var date=new Date(); var str=date.getFullYear()+"-"; if((date.getMonth()+1)<10){str+="0"+(date.getMonth()+1);}else{str+=(date....
分类:其他好文   时间:2014-09-02 19:43:15    阅读次数:201
js字符串常用方法枚举
js字符串常用方法枚举/* functionobj$(id)根据id得到对象 functionval$(id)根据id得到对象的值 functiontrim(str)删除左边和右边空格 functionltrim(str)删除左边空格 functionrtrim(str)删除右边空格 functionisEmpty(str)字串是否有值 functionequals(str1,str2)js判断比较两..
分类:Web程序   时间:2014-09-02 18:11:36    阅读次数:269
8.2 二级指针 指针数组
二级指针找出最大的字符:char maxchar(char * str, char** max){ char da = *str; //先让最大的执行第一个字符 *max = str; while (*str) { if (*str > da) { da = *str; *max = str; } ...
分类:其他好文   时间:2014-09-02 17:29:15    阅读次数:165
HtmlParser 2.0 中文乱码问题
对于HTMLParser 2.0工具包我们需要修改其中的Page.java文件使其适用中文的html文件分析。 主要是把protected static final String DEFAULT_CHARSET = "ISO-8859-1";修改成protected static final Str...
分类:Web程序   时间:2014-09-02 17:15:25    阅读次数:249
求一个字符串长度
function strLength(str){ var time1 = new Date; if(str.length == 0 || !str) return null; var l = str.length; for(var i = 0; i 255) l++; ...
分类:其他好文   时间:2014-09-02 17:06:24    阅读次数:239
随机生成字符串
1.相关的随机函数:mt_rand(),shuffle(),str_shuffle()2.总之就是字符串 数组 的灵活使用#打乱字符串str_shuffle, 截取字符串substr$str="abcdefghjklmnuvwxyz0123456789"; $str = str_shu...
分类:其他好文   时间:2014-09-02 13:50:14    阅读次数:185
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!