码迷,mamicode.com
首页 >  
搜索关键字:median of two sor    ( 12209个结果
leetcode第28题--Divide Two Integers
Divide two integers without using multiplication, division and mod operator.分析:题目意思很容易理解,就是不用乘除法和模运算求来做除法,很容易想到的一个方法是一直做减法,然后计数,超时。在网上找到一种解法,利用位运算,意思是...
分类:其他好文   时间:2014-10-21 02:10:36    阅读次数:185
SetInterval
var timer=null;var aNow=null;var g_aImg=[];var g_oImgWeek=null;var g_aWeekName=[ "one", "two", "three", "four", "five", "six", "seven"];window.onload=...
分类:其他好文   时间:2014-10-21 00:47:58    阅读次数:222
[LeetCode]Merge Two Sorted Lists
Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the first two lists. /** * Definition for singly-linked list. * publ...
分类:其他好文   时间:2014-10-20 21:28:05    阅读次数:233
Divide Two Integers
Divide two integers without using multiplication, division and mod operator.分析:不能用乘、除、取模运算,我们可以用的运算还有加、减、位运算。一个比较简单的想法是在dividend上不断减去divisor,知道余数小于div...
分类:其他好文   时间:2014-10-20 21:18:28    阅读次数:183
LeetCode: Add Two Numbers 解题报告
Add Two NumbersYou are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes co...
分类:其他好文   时间:2014-10-20 18:50:54    阅读次数:111
HDU - 4803 Poor Warehouse Keeper(贪心)
Description Jenny is a warehouse keeper. He writes down the entry records everyday. The record is shown on a screen, as follow:  There are only two buttons on the screen. Pressing the button i...
分类:其他好文   时间:2014-10-20 15:06:03    阅读次数:259
如何让vnc控制由默认的twm界面改为gnome?(转)
其实只要修改用户 .vnc目录下的xstartup配置文件即可[root@localhost ~]# more /root/.vnc/xstartup#!/bin/sh# Uncomment the following two lines for normal desktop:# unset SES...
分类:其他好文   时间:2014-10-20 14:55:43    阅读次数:246
leetcode第23题--Swap Nodes in Pairs
Problem: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.Yo...
分类:其他好文   时间:2014-10-20 13:15:42    阅读次数:195
Leetcode | Swap Nodes in Pairs
Given a linked list, swap every two adjacent nodes and return its head.For example,Given 1->2->3->4, you should return the list as 2->1->4->3.Your alg...
分类:其他好文   时间:2014-10-20 09:49:08    阅读次数:181
poj2406--Power Strings(KMP求最小循环节)
Power Strings Time Limit: 3000MS   Memory Limit: 65536K Total Submissions: 33178   Accepted: 13792 Description Given two strings a and b we define a*b to be their concatena...
分类:其他好文   时间:2014-10-19 21:29:13    阅读次数:204
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!