2014年5月13日

[LeetCode]Max Points on a Line

摘要: 题目:Givennpoints on a 2D plane, find the maximum number of points that lie on the same straight line.算法分析:定义最大直线为符合相同条件的直线中通过点最多的那条直线。对每个点p,计算其它的点与p形成的... 阅读全文

posted @ 2014-05-13 11:33 Jason1573 阅读(157) 评论(0) 推荐(0)

2014年5月12日

[LeetCode]Evaluate Reverse Polish Notation

摘要: 题目:Evaluate the value of an arithmetic expression inReverse Polish Notation.Valid operators are+,-,*,/. Each operand may be an integer or another expr... 阅读全文

posted @ 2014-05-12 19:08 Jason1573 阅读(152) 评论(0) 推荐(0)

[LeetCode]Reverse Words in a String

摘要: 题目:Given an input string, reverse the string word by word.For example,Given s = "the sky is blue",return "blue is sky the".Clarification:What constitu... 阅读全文

posted @ 2014-05-12 19:01 Jason1573 阅读(213) 评论(0) 推荐(0)

导航