摘要:
在开发中常常遇到须要查看一个字符串t是否在字符串s中存在,并找到其第一次出现的位置,也就是在字符串s中查找子串t,我们寻常都是怎么实现那?我们最起码有三个方法能够用。CString和string中的find函数。以及string.h中的strstr函数,用起来既简单又快捷,CString是MFC中的 阅读全文
posted @ 2017-08-10 16:50
cxchanpin
阅读(209)
评论(0)
推荐(0)
摘要:
面试题:一个汉字占多大空间。事实上这个问题我了解不深的,知道结论不知道为什么。借此梳理下认识。先回想下java基本类型一基本类型 :简称四类八种,声明变量的同一时候分配了空间。举比例如以下: Int a =1;一、4种整型 byte 1字节 -128——127 short 2 字节 -32,768 阅读全文
posted @ 2017-08-10 15:47
cxchanpin
阅读(735)
评论(0)
推荐(0)
摘要:
Given a linked list and a value x, partition it such that all nodes less than x come before nodes greater than or equal to x. You should preserve the 阅读全文
posted @ 2017-08-10 14:12
cxchanpin
阅读(179)
评论(0)
推荐(0)
摘要:
很具体的介绍linux中vim的操作命令。 高级一些的编辑器,都会包括宏功能,vim当然不能缺少了。在vim中使用宏是很方便的: :qx 開始记录宏。并将结果存入寄存器x q 退出记录模式 @x 播放记录在x寄存器中的宏命令 略微解释一下,当在normal模式下输入:qx后,你对文本的全部编辑动作将 阅读全文
posted @ 2017-08-10 12:47
cxchanpin
阅读(646)
评论(0)
推荐(0)
摘要:
1.去CC 之前2.0的CC**,把CC都去掉,主要的元素都是保留的 2.0 CCSprite CCCallFunc CCNode .. 3.0 Sprite CallFunc Node .. 2.cc***结构体改变 2.0 ccp(x,y) ccpAdd(p1,p2) ccpSub ccpMul 阅读全文
posted @ 2017-08-10 11:48
cxchanpin
阅读(673)
评论(0)
推荐(0)
摘要:
这一章节我们继续类型擦除的话题,我们将通过对照数组与泛型容器,观察类型擦除给泛型容器带来什么问题?1.数组package com.ray.ch13; public class Test { public static void main(String[] args) { Fruit[] fruits 阅读全文
posted @ 2017-08-10 10:49
cxchanpin
阅读(146)
评论(0)
推荐(0)
摘要:
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=5247 找连续数 Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submis 阅读全文
posted @ 2017-08-10 08:58
cxchanpin
阅读(227)
评论(0)
推荐(0)