垂直居中: 先height再ling-height,都设成一样高设置外边距:
margin-top,margin-left,margin-right,margin-bottomdiv背景单张铺满设置: width: 30px;
height: 30px; line-height: 30px;...
分类:
Web程序 时间:
2014-05-08 14:38:55
阅读次数:
474
Found the solution myself in the end. The problem
was not with theLinearLayout,but with theScrollView(seems weird, considering the
fact that theScroll...
分类:
移动开发 时间:
2014-05-08 13:42:02
阅读次数:
321
Network Working Group S. BradnerRequest for
Comments: 2119 Harvard UniversityBCP: 1...
分类:
其他好文 时间:
2014-05-07 21:26:24
阅读次数:
379
Given n points on a 2D plane, find the maximum
number of points that lie on the same straight line. 解题想法:
其实判断一个直线上最好的方法是判断斜率。如果在同一直线上,那么直线上一点与其他点的斜率相...
分类:
其他好文 时间:
2014-05-07 21:13:02
阅读次数:
323
if(navigator.userAgent.indexOf("MSIE")>0){return"MSIE";}if(isFirefox=navigator.userAgent.indexOf("Firefox")>0){return"Firefox";}if(isSafari=navigator....
分类:
Web程序 时间:
2014-05-07 17:03:46
阅读次数:
288
DescriptionYou are to write a program that has
to decide whether a given line segment intersects a given rectangle.An
example:line: start point: (4,9)...
分类:
其他好文 时间:
2014-05-07 13:55:45
阅读次数:
387
21天战拖记——Day3:今天起得早,全天要过好(2014-05-06)
分类:
其他好文 时间:
2014-05-07 13:27:30
阅读次数:
215
变形了的最近点对,关键在于计算距离的时候,如果同类点的话,直接判定为无穷大即可。
其他闲话:
(1)因为一些原因,被迫暂时用回C++.
(2)好久没刷题,忘记了数组一开始要开最大,多次new和delete,导致超时。
(3) 感觉算法导论的最近点对没有考虑到有多个点都在一条vertical line上的情形。
#include
#include
#include
#include...
分类:
其他好文 时间:
2014-05-07 11:29:11
阅读次数:
334
procedure TForm1.N11DrawItem(Sender: TObject;
ACanvas: TCanvas; ARect: TRect; Selected: Boolean);beginIf (Selected)
ThenbeginACanvas.Font.Color := clW...
分类:
其他好文 时间:
2014-05-07 10:52:51
阅读次数:
283