题目:Givennpoints on a 2D plane, find the maximum
number of points that lie on the same straight
line.算法分析:定义最大直线为符合相同条件的直线中通过点最多的那条直线。对每个点p,计算其它的点与p形成的...
分类:
其他好文 时间:
2014-05-16 23:26:31
阅读次数:
389
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 ...
分类:
其他好文 时间:
2014-05-16 23:18:16
阅读次数:
360
复习一下单链表的常用操作,包括单链表的创建、插入、删除、排序、逆置以及打印输出等。#includeusing namespace std;typedef
struct Single_link{ int data; struct Single_link *next;}node;//单链表的...
分类:
其他好文 时间:
2014-05-16 22:14:34
阅读次数:
397
一、JS中的数据类型 1.数值型(Number):包括整数、浮点数。 2.布尔型(Boolean)
3.字符串型(String) 4.对象(Object) 5.数组(Array) 6.空值(Null)
7.未定义(Undefined)二、判断一个变量的数据类型1.数值型(...
分类:
编程语言 时间:
2014-05-13 17:24:30
阅读次数:
360
1目的:设计原则是基本的工具,应用这些规则可使代码更加灵活、更容易维护,更容易扩展2分类2.1SRP(单一职责)The
single responsibility principle系统中的每一个对象都应该只有一个单独的职责,而所有对象所关注的就是自身职责的完成。Every
object in yo...
分类:
其他好文 时间:
2014-05-13 16:47:34
阅读次数:
270
1729 is the natural number following 1728 and preceding 1730. It is also known as the Hardy-Ramanujan number after a famous anecdote of the British mathematician G. H. Hardy regarding
a hospital vis...
分类:
其他好文 时间:
2014-05-13 14:52:34
阅读次数:
314
本文为senlie原创,转载请保留此地址:http://blog.csdn.net/zhengsenlie
Best Time to Buy and Sell Stock II
Total Accepted: 13030 Total
Submissions: 36467
Say you have an array for which the ith ...
分类:
其他好文 时间:
2014-05-13 14:08:39
阅读次数:
414
K-th Number
Time Limit: 20000MS
Memory Limit: 65536K
Total Submissions: 35704
Accepted: 11396
Case Time Limit: 2000MS
Description
You are working for Macrohard com...
分类:
其他好文 时间:
2014-05-13 14:07:41
阅读次数:
203
CiscoCUCMallowsyoutoconfiguresinglenumberreach(alsoknownasmobility)sothatacalldestinedforyourdeskphone‘sextensioncanringonanumberofotherdevicessuchasyourcellphone,blackberry,homephone,etc.Thisfeaturealsoallowsyoutoseamlesslytransferanactivecallfromyourcellp..
分类:
其他好文 时间:
2014-05-13 12:56:54
阅读次数:
618
Prime Ring Problem
Problem Description
A ring is compose of n circles as shown in diagram. Put natural number 1, 2, ..., n into each circle separately, and the sum of numbers in two adjacent...
分类:
其他好文 时间:
2014-05-13 11:54:17
阅读次数:
444