码迷,mamicode.com
首页 >  
搜索关键字:implement strstr    ( 2381个结果
LeetCode: Pow(x, n) 解题报告
Pow(x, n) Implement pow(x, n).SOLUTION 1:使用二分法。1. 负数的情况,使用以下的公式转化为求正数power,另外,考虑到MIN_VALUE可能会造成越界的情况,我们先将负数+1:X^(-n) = X^(n + 1) * XX^n = 1/(x^(-n))2....
分类:其他好文   时间:2014-12-19 21:53:05    阅读次数:217
Single Number
Given an array of integers, every element appears twice except for one. Find that single one. Note: Your algorithm should have a linear runtime complexity. Could you implement it without using ext...
分类:其他好文   时间:2014-12-19 19:14:19    阅读次数:141
【leetcode】Wildcard Matching(hard) ★ 大神太牛了
Implement wildcard pattern matching with support for'?'and'*'.'?' Matches any single character.'*' Matches any sequence of characters (including the e...
分类:其他好文   时间:2014-12-19 00:22:53    阅读次数:185
[LeetCode]Single Number II
Given an array of integers, every element appears three times except for one. Find that single one. Note: Your algorithm should have a linear runtime complexity. Could you implement it without usi...
分类:其他好文   时间:2014-12-17 22:45:19    阅读次数:215
【LeetCode】Next Permutation 解题报告
【题目】 Implement next permutation, which rearranges numbers into the lexicographically next greater permutation of numbers. If such arrangement is not possible, it must rearrange it as the lowes...
分类:其他好文   时间:2014-12-16 11:50:47    阅读次数:146
String to Integer (atoi)
Implement atoi to convert a string to an integer. Hint: Carefully consider all possible input cases. If you want a challenge, please do not see below and ask yourself what are the possible input ca...
分类:其他好文   时间:2014-12-15 19:07:22    阅读次数:181
MD5加密
#import @interface MyMD5 : NSObject { }+(NSString *) md5: (NSString *) inPutText ;@end#import "MyMD5.h"#import "CommonCrypto/CommonDigest.h"@implement...
分类:其他好文   时间:2014-12-15 19:03:53    阅读次数:117
cxf 学习
最近在学习java,想搞j2ee的开发,以及手机网站的开发。 IDE:Intellij IDEA 13 JDK: 1.7 server:Tomcat 8.0.15 System:windows 7 X64 总结: 1:搞清楚,IDEA中,什么是插件? 2:CXF中,在开发WebService的过程中,不要单独的针对helloWord.java(implement interface...
分类:其他好文   时间:2014-12-15 17:25:37    阅读次数:244
C语言字符串处理函数源码
strstr()函数源码/* 得到s1中第一次包含s2字符串的位置指针。*/#include char * my_strstr(const char *s1,const char *s2){ if (*s1 == 0) { if (*s2) return (char *) NULL; return ...
分类:编程语言   时间:2014-12-15 13:39:42    阅读次数:178
Programming Question - 6
Question 1Download the text filehere. (Right click and save link as).The goal of this problem is to implement a variant of the 2-SUM algorithm (covere...
分类:其他好文   时间:2014-12-13 21:41:15    阅读次数:1587
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!