码迷,mamicode.com
首页 >  
搜索关键字:median of two sorted    ( 17004个结果
Quick-sort
brief : the quick sort can divide into two steps, the first step is partition, the second step is conquer the subset.i) as the first step, array A[lef...
分类:其他好文   时间:2014-10-01 01:21:50    阅读次数:209
[leetcode]Merge k Sorted Lists @ Python [基础知识: heap]
原题地址:https://oj.leetcode.com/problems/merge-k-sorted-lists/题意:Mergeksorted linked lists and return it as one sorted list. Analyze and describe its com...
分类:编程语言   时间:2014-10-01 00:32:30    阅读次数:270
leetcode--two sum
Problem: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 th...
分类:其他好文   时间:2014-09-30 23:33:10    阅读次数:319
【python】An Introduction to Interactive Programming in Python(week two)
This is a note forhttps://class.coursera.org/interactivepython-005In week two, I have learned:1.event-drvien programing4 event types:Input: button, te...
分类:编程语言   时间:2014-09-30 23:13:50    阅读次数:210
Remove Duplicates from Sorted Array
Follow up the "remove duplicates",what if duplicates are allowed at most twice?思路一:使用变量numlength记录数组中相同数字出现不超过两次所得到的数组长度;code:class Solution {public: ...
分类:其他好文   时间:2014-09-30 23:01:00    阅读次数:171
Merge Sorted Array
[leetcode]Given two sorted integer arrays A and B, merge B into A as one sorted array....
分类:其他好文   时间:2014-09-30 11:36:39    阅读次数:154
Add Binary <leetcode>
Given two binary strings, return their sum (also a binary string).For example,a ="11"b ="1"Return"100".算法:模拟加法过程 1 class Solution { 2 public: 3 st...
分类:其他好文   时间:2014-09-30 11:05:31    阅读次数:155
[LeetCode] Multiply Strings 字符串相乘
Given two numbers represented as strings, return multiplication of the numbers as a string. Note: The numbers can be arbitrarily large and are non-negative. 这个题说数可能是任意的大的非负数,肯定不是让你直接乘起来返回(我干了。。)而是...
分类:其他好文   时间:2014-09-30 06:45:32    阅读次数:167
[LeetCode] Add Two Numbers
You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a single digit. Add the two numbers and return it as a link...
分类:其他好文   时间:2014-09-30 04:40:32    阅读次数:182
[leetcode] Scramble String @python
Given a strings1, we may represent it as a binary tree by partitioning it to two non-empty substrings recursively.Below is one possible representation...
分类:编程语言   时间:2014-09-30 02:51:41    阅读次数:394
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!