码迷,mamicode.com
首页 >  
搜索关键字:two pointer    ( 13796个结果
(转)zigbee >TI Z-stack协议栈各种地址的获取
第一种方法,利用NLME.h里面定义的专门API获取设备自身IEEE地址/** This function will return a pointer to the device's IEEE 64 bit address** This function resides in nwk_util.c....
分类:其他好文   时间:2014-08-03 20:21:55    阅读次数:351
leetcode Word Break II
Give two versions of WA code: Version 1: Runtime Error: Find the bug class Solution { public: void find(const string& s, const unordered_set& dict, vector& res) { int i, j, len = s.length(); ...
分类:其他好文   时间:2014-08-03 15:21:27    阅读次数:329
[LeetCode]Same Tree
Given two binary trees, write a function to check if they are equal or not. Two binary trees are considered equal if they are structurally identical and the nodes have the same value. /** ...
分类:其他好文   时间:2014-08-03 12:54:55    阅读次数:201
POJ - 3468 A Simple Problem with Integers (区间求和)
Description You have N integers, A1, A2, ... , AN. You need to deal with two kinds of operations. One type of operation is to add some given number to each number in a given interval. The other ...
分类:其他好文   时间:2014-08-03 12:53:25    阅读次数:311
Populating Next Right Pointers in Each Node
问题:将二叉树的所有结点指向他的右边的一个结点分析:对于每一个结点来说,其操作都是一样的,除了他的左儿子指向右儿子外,其左儿子的全部右后辈均指向其右儿子的全部左后辈/** * Definition for binary tree with next pointer. * struct TreeLin...
分类:其他好文   时间:2014-08-03 10:12:05    阅读次数:178
POJ 3895 Cycles of Lanes
Description Each of the M lanes of the Park of Polytechnic University of Bucharest connects two of the N crossroads of the park (labeled from 1 to N). There is no pair of crossroads connected by mo...
分类:其他好文   时间:2014-08-02 23:27:14    阅读次数:327
ZOJ 1633 Big String
Big String Time Limit: 2 Seconds      Memory Limit: 65536 KB We will construct an infinitely long string from two short strings: A = "^__^" (four characters), and B = "T.T" (three characters). R...
分类:其他好文   时间:2014-08-02 21:02:04    阅读次数:291
LeetCode 第二题,Median of Two Sorted Arrays
题目再现 There are two sorted arrays A and B of size m and n respectively. Find the median of the two sorted arrays. The overall run time complexity should be O(log (m+n)). 题意解析...
分类:其他好文   时间:2014-08-02 18:24:13    阅读次数:335
Merge Two Sorted Lists
问题:有序合并两个有序链表分析:归并排序的合并部分class Solution {public: ListNode *mergeTwoLists(ListNode *l1, ListNode *l2) { ListNode *helper=new ListNode(0); ...
分类:其他好文   时间:2014-08-02 18:17:03    阅读次数:170
POJ1837:Balance(01背包)
Description Gigel has a strange "balance" and he wants to poise it. Actually, the device is different from any other ordinary balance.  It orders two arms of negligible weight and each arm's lengt...
分类:其他好文   时间:2014-08-02 15:30:13    阅读次数:235
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!