码迷,mamicode.com
首页 >  
搜索关键字:return    ( 60766个结果
[leetcode]Anagrams @ Python
原题地址:https://oj.leetcode.com/problems/anagrams/题意:Given an array of strings, return all groups of strings that are anagrams.Note: All inputs will be i...
分类:编程语言   时间:2014-06-29 13:25:28    阅读次数:355
LeetCode:First Missing Positive
题目链接 Given an unsorted integer array, find the first missing positive integer. For example, Given [1,2,0] return 3, and [3,4,-1,1] return 2. Your algo...
分类:其他好文   时间:2014-06-29 07:44:48    阅读次数:321
cocos2d-x添加触摸
//CCLayer//CCTouchDelegateboolCBattleLayer::init(){ if( ! CCLayer::init() ) { return false; } this->setTouchEnabled( true ); return true;}void...
分类:其他好文   时间:2014-06-07 11:14:29    阅读次数:223
LeetCode:Remove Duplicates from Sorted Array && Remove Element
Given a sorted array, remove the duplicates in place such that each element appear only once and return the new length.Do not allocate extra space for...
分类:其他好文   时间:2014-06-06 06:53:19    阅读次数:347
LeetCode:Reverse Nodes in k-Group
Given a linked list, reverse the nodes of a linked list k at a time and return its modified list. If the number of nodes is not a multiple of k then l...
分类:其他好文   时间:2014-06-05 22:13:19    阅读次数:391
随记-------不定期添加遗忘知识点
1. 复合字面值char *get_status_str(int status){ return (char *[]){"linkdown","partial-linkup","full-linkup","N/A"}[status];} 2. 常量折叠#include int main() { .....
分类:其他好文   时间:2014-06-05 20:35:26    阅读次数:199
js字符串长度计算(一个汉字==两个字符)和字符串截取
js字符串长度计算(一个汉字==两个字符)和字符串截取String.prototype.realLength = function() { return this.replace(/[^\x00-\xff]/g, "**").length; // [^\x00-\xff] - 匹配非双字节的字...
分类:Web程序   时间:2014-06-05 18:57:13    阅读次数:287
leetcode--Two Sum
Given an array of integers, find two numbers such that they add up to a specific target number.The function twoSum should return indices of the two nu...
分类:其他好文   时间:2014-06-05 14:15:07    阅读次数:221
leetcode--Add Binary
Given two binary strings, return their sum (also a binary string).For example,a ="11"b ="1"Return"100".public class Solution { /**The program is us...
分类:其他好文   时间:2014-06-05 14:08:35    阅读次数:188
leetcode--Swap Nodes in Pairs
Given a linked list, swap every two adjacent nodes and return its head.For example,Given1->2->3->4, you should return the list as2->1->4->3.Your algor...
分类:其他好文   时间:2014-06-05 13:41:44    阅读次数:231
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!