码迷,mamicode.com
首页 >  
搜索关键字:two pointer    ( 13796个结果
Container With Most Water leetcode java
题目:Given n non-negative integers a1, a2, ..., an, where each represents a point at coordinate (i, ai). n vertical lines are drawn such that the two e....
分类:编程语言   时间:2014-07-27 11:04:52    阅读次数:278
N-Queens leetcode java
题目:The n-queens puzzle is the problem of placing n queens on an n×n chessboard such that no two queens attack each other.Given an integer n, return a....
分类:编程语言   时间:2014-07-27 11:00:22    阅读次数:262
【stl学习笔记】list
list使用双向链表来管理元素。与vector、deque的区别:1.list不支持随机存取,在list中随机遍历任意元素,是很缓慢的行为2.任何位置上执行元素的安插和移除都非常快,始终是常数时间内完成,因为无须移动任何其他元素3.安插和删除动作不会造成指向其他元素的各个pointer、refere...
分类:其他好文   时间:2014-07-27 10:07:52    阅读次数:241
【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 ...
分类:其他好文   时间:2014-07-27 09:53:12    阅读次数:350
Eclipse 手动增加linker library
多个cu文件nvcc -cubin -m64 -lcudadevrt -lcublas_device -gencode arch=compute_35,code=sm_35 -o test.cubin -c test.cu -dlinkYou can also do that in two step...
分类:系统相关   时间:2014-07-26 16:51:12    阅读次数:350
POJ 3414 Pots
Pots Description You are given two pots, having the volume of A and B liters respectively. The following operations can be performed: FILL(i)        fill the pot i (1 ≤ i ≤ 2) from the tap;DR...
分类:其他好文   时间:2014-07-26 15:04:00    阅读次数:263
hdu1247Hat’s Words (组合单词,字典树+DFS)
Problem Description A hat’s word is a word in the dictionary that is the concatenation of exactly two other words in the dictionary. You are to find all the hat’s words in a dictionary. Input ...
分类:其他好文   时间:2014-07-26 15:02:10    阅读次数:220
E - Power Strings,求最小周期串
E -Power StringsTime Limit:3000MSMemory Limit:65536KB64bit IO Format:%I64d & %I64uSubmitStatusPracticePOJ 2406DescriptionGiven two strings a and b we ...
分类:其他好文   时间:2014-07-26 14:10:16    阅读次数:201
kmp
Given two sequences of numbers : a[1], a[2], ...... , a[N], and b[1], b[2], ...... , b[M] (1 #includeintnext[10005];ints[1000005],p[10005];intn,m;void...
分类:其他好文   时间:2014-07-26 13:46:34    阅读次数:297
[ACM] ZOJ 3725 Painting Storages (DP计数+组合)
Painting Storages Time Limit: 2 Seconds      Memory Limit: 65536 KB There is a straight highway with N storages alongside it labeled by 1,2,3,...,N. Bob asks you to paint all storages with two...
分类:其他好文   时间:2014-07-26 02:48:17    阅读次数:178
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!