由买买提看人间百态

topics

全部话题 - 话题: bounded
首页 上页 1 2 3 4 5 6 7 8 9 10 下页 末页 (共10页)
t*******d
发帖数: 12895
1
来自主题: USANews版 - 加州是winner take all
Tuesday 7 June 2016: All 172 of California's delegates to the Republican
National Convention are pledged to presidential contenders in today's
California Presidential Primary.
159 district delegates are to be bound to presidential contenders based on
the primary results in each of the 53 congressional districts: each
congressional district is assigned 3 National Convention delegates and the
presidential contender receiving the greatest number of votes in that
district will receive all 3 of that ... 阅读全帖
w********0
发帖数: 1211
2
我一直有这么一个疑惑,首先,这delegate不是一张张抽象的票,而是一个个具体的人
,每人在convention上可以投一票,但bound的delegate在bound的轮次里得按初选的结
果投,这个理解对吧。
如果对,那么问题来了,那些被赢者通吃的州和区里的delegate很清楚该投谁,但那些
被按比例分配的州和区怎么办?比如昨天纽约州的某个区的结果是Trump拿到两票,
Kasich拿到一票。那到了Convention上,这三个delegate谁投Trump,谁投Kasich? 是
Trump和Kasich事先指定好,还是说到时候把这三人抽象地打成“一包选票”,就说你
甭管我们具体谁选谁,反正我们仨这轮两票归Trump,一票归Kasich? 当然数字上看,
这和指定好是等价的,但看上去挺滑稽的。
谁能释疑解惑一下?谢了。
m*h
发帖数: 2750
3
我给你研究了一下:
The delegates were chosen over the weekend at the state Republican
convention, but they won't know who they're representing until the primary
results. Of the 41 elected delegates, 40 were Cruz supporters. However,
under party rules, each delegate is bound to the primary results for the
first round of voting at the national convention.
41个delegates 中,40个事ted支持者。但是,他们支持谁是不算数的。要看今天vote
的结果。说白了就是,虽然他们个人支持cruz,他们七月去cleveland 投谁不是他们说
了算,要今天的结果说了算.
放心了?:)
link:http://www.star-telegram.com/new... 阅读全帖
m*h
发帖数: 2750
4
我给你研究了一下:
The delegates were chosen over the weekend at the state Republican
convention, but they won't know who they're representing until the primary
results. Of the 41 elected delegates, 40 were Cruz supporters. However,
under party rules, each delegate is bound to the primary results for the
first round of voting at the national convention.
41个delegates 中,40个事ted支持者。但是,他们支持谁是不算数的。要看今天vote
的结果。说白了就是,虽然他们个人支持cruz,他们七月去cleveland 投谁不是他们说
了算,要今天的结果说了算.
放心了?:)
link:http://www.star-telegram.com/new... 阅读全帖
h*h
发帖数: 27852
5
【 以下文字转载自 Military 讨论区 】
发信人: hsh (nidaye), 信区: Military
标 题: Why Can't Islam be Reformed? By Ali Sina
发信站: BBS 未名空间站 (Wed Jun 15 17:39:38 2016, 美东)
Why Can't Islam be Reformed?
By Ali Sina
Dear Mr. Sina,
I am a Muslim woman living in the USA I read some of your articles and
totally agree with you on many points.
I am still a Muslim but at the same time I hold rather peculiar positions on
many points.
There are five pillars of Islam and six pillars of faith that cannot be
modified. That... 阅读全帖
a*****1
发帖数: 3817
6
来自主题: USANews版 - trump懵逼了,trump轮集体被打脸
自己去看美国宪法
United States Constitution
From Wikipedia, the free encyclopedia
Jump to: navigation, search
United States Constitution
Constitution of the United States, page 1.jpg
Page one of the original copy of the Constitution
Created
September 17, 1787
Ratified
June 21, 1788
Date effective
March 4, 1789; 227 years ago
Location
National Archives,
Washington, D.C.
Author(s)
Philadelphia Convention
Signatories
39 of the 55 delegates
Purpose
To replace the Articles of Confederation (177... 阅读全帖
a*****1
发帖数: 3817
7
来自主题: USANews版 - trump懵逼了,trump轮集体被打脸
自己去看美国宪法
United States Constitution
From Wikipedia, the free encyclopedia
Jump to: navigation, search
United States Constitution
Constitution of the United States, page 1.jpg
Page one of the original copy of the Constitution
Created
September 17, 1787
Ratified
June 21, 1788
Date effective
March 4, 1789; 227 years ago
Location
National Archives,
Washington, D.C.
Author(s)
Philadelphia Convention
Signatories
39 of the 55 delegates
Purpose
To replace the Articles of Confederation (177... 阅读全帖
a*****1
发帖数: 3817
8
自己去看美国宪法
United States Constitution
From Wikipedia, the free encyclopedia
Jump to: navigation, search
United States Constitution
Constitution of the United States, page 1.jpg
Page one of the original copy of the Constitution
Created
September 17, 1787
Ratified
June 21, 1788
Date effective
March 4, 1789; 227 years ago
Location
National Archives,
Washington, D.C.
Author(s)
Philadelphia Convention
Signatories
39 of the 55 delegates
Purpose
To replace the Articles of Confederation (1777)
This articl... 阅读全帖
b*****d
发帖数: 61690
9
Oregon Sens. Jeff Merkley and Ron Wyden have announced plans to block
President Trump’s nominee for the San Francisco-based 9th Circuit Court of
Appeals.
In a letter to the White House on Thursday, the two Democrats said they do
not intend to return blue slips for Ryan Bounds “or any other nominee that
has not been selected through our judicial process.”
“As you are aware, in May we wrote you to explain Oregon’s long bipartisan
tradition of working together to identify the most qualified candida... 阅读全帖

发帖数: 1
10
http://foreignpolicy.com/2017/06/29/the-next-internment-would-chinese-in-the-u-s-be-rounded-up-during-a-war/
The next internment: Would Chinese in the U.S. be rounded up during a war?
Present U.S. leadership seems both to make war more likely through its
bellicose rhetoric and to heighten the risk that the conflict would lead to
violence against the American-Chinese population.
BY THOMAS E. RICKS | JUNE 29, 2017, 10:15 AM
Map_of_World_War_II_Japanese_American_internment_camps
By Giacomo Bagarell... 阅读全帖

发帖数: 1
11
这篇文章对可行性研究进行了分析。
The next internment: Would Chinese in the U.S. be rounded up during a war?
http://foreignpolicy.com/2017/06/29/the-next-internment-would-chinese-in-the-u-s-be-rounded-up-during-a-war/
By Giacomo Bagarella
Best Defense office of future operations
Present U.S. leadership seems both to make war more likely through its
bellicose rhetoric and to heighten the risk that the conflict would lead to
violence against the American-Chinese population.
As the title of one recent book on the s... 阅读全帖
b*****d
发帖数: 61690
12
来自主题: USANews版 - 澳大利亚不给气候变暖捐钱了
Australia's new prime minister says the country will no longer contribute to
a global fund that assists developing countries with climate change
adaptation and that Australia is not bound to any previous emissions-cutting
promises.
Asked if his country would be held to the target established under the
landmark Paris climate agreement to reduce emissions between 26 and 28
percent from 2005 levels, Scott Morrison told Australian radio station 2GB
Radio on Sunday, “No, we won’t … we’re not held to ... 阅读全帖
a******s
发帖数: 141
13
2009年7月24日,辽宁丹东海关工作人员在丹东口岸,对准备出境进入朝鲜的运输车辆
进行例行检查时,查获六箱被伪装成水果包装的稀有金属钒,共计68瓶,重约70公斤,
价值近20万元人民币。金属钒是我国严格控制出口的稀有金属,是制造合金钢等用途广
泛的工业原料。海关部门目前正在做近一步调查。钒及其合金,氧化物是制造飞机发动
机、宇航船舱骨架、导弹、军舰的水翼和引进器、蒸汽涡轮机叶片、火箭发动机壳等重
要原料。此外,钒合金还应用于磁性材料、硬质合金、超导材料(如v,Ca)及核反应堆
材料等领域。
China seizes smuggled metal bound for North Korea
AP News 28 mins ago
BEIJING (Reuters) – Chinese border police have seized 70 kg (154 lb) of the
strategic metal vanadium bound for North Korea, a local newspaper said on
Tuesday, foiling an attempt to
u****n
发帖数: 7521
14
【 以下文字转载自 Military 讨论区 】
发信人: ubcumn (ubcumn), 信区: Military
标 题: 看到你的祖国死去很痛苦,只有止不住的叹息和哭泣zz
发信站: BBS 未名空间站 (Thu Jan 13 14:16:38 2011, 美东)
http://www.thetrumpet.com/index.php?q=7835.6441.0.0
It’s Hard to Watch Your Country Die -One can’t help but sigh and cry.
看到你的祖国死去很痛苦,只有止不住的叹息和哭泣。
America suffers with several ills from which it will not recover. This
reality is becoming inescapably plain.
美国正在遭受病痛的折磨,这个病好不了了。这是一个不可避免的(inescapable)而
且很简单的( plain)事实。
原文链接+全文
========================
It’s Hard t... 阅读全帖
t**********3
发帖数: 12623
15
来自主题: Automobile版 - NYC <--> I-95 S 省$4过路费攻略
第一张图所示路线是所有GPS和绝大多数司机默认走的一条路线,这条走I-78 W的路线
不比下图快很多,但是却多$4的过路费
第二张图的路线是可以节省至少$4过路费的路线:
1) South Bound从Holland Tunnel出来,靠左行驶进入US 1-9 South,然后进入1-9
South Express,一般并不经常堵车,堵车的是1-9 South Local,然后过了ERW机场的
出口靠右上NJ-81/I-95 Turnpike的ramp,然后就到收费站入口了
2) North Bound从I-95 N往NYC走,在13A出口出来,往NJ-81/Newark Liberty Airport
方向走,然后顺到US 1-9 North Express,最后进入Holland Tunnel前这段比I-78要快
堵车几率小很多
l**4
发帖数: 2989
16
来自主题: Automobile版 - 闹迪A3 - sedan 。。。。
US-bound Audi A3 Sedan spied testing
http://www.autoblog.com/2013/01/25/us-bound-audi-a3-sedan-spied
竟然/果然是sedan,不过是双门的,hatchback不知道有没有了
m*********2
发帖数: 2788
17
来自主题: Automobile版 - 出车祸了,求助
呼唤逻辑, 首先楼主的情况是别人在他撞上去之前已经左转了全部或大部(拥有right
- of - way),他自己不规避(并不是说你直行就牛B)。 再说,就有人胆大敢这样转(
违规也好,抢道也好),难道你也要直别别的撞上去,而不是为了自己和公众的安全而
进行有效的规避?
当然,如果楼主撞的是左转车的前半部分,那一定是左转车的责任,撞到中间可以
argue是左转车的责任,现在明显是楼主撞到左转车的尾部部分,那还有什么话好讲?
再问大家一个问题:如果你在driving south bound, 而north bound有特种车开过来,
你是不是一定要靠边停?
b********c
发帖数: 310
18
考古 联通美洲卡
[在 BR (bounded rationality) 的大作中提到:]
:【 以下文字转载自 Money 讨论区 】
:发信人: BR (bounded rationality), 信区: Money
:...........
h**G
发帖数: 9825
19
方圆几10里就找到这个
Regular Extended
Mon 5:45 PM 8:45 PM
Tue 5:45 PM 8:45 PM
Wed 5:45 PM 8:45 PM
Thu 5:45 PM 8:45 PM
Fri 5:45 PM 8:45 PM
Sat 5:00 PM
Sun No Pickup
Extended Express Dropoff timeWe offer extended Express drop-off times at
this location. This extended Express drop-off time applies to next-
business-day shipments bound for certain destinations throughout Alaska,
California, Hawaii, Nevada and also major cities in Arizona, Idaho,
Oregon, Utah... 阅读全帖
e****e
发帖数: 2010
20
来自主题: ebiz版 - MasterCard 20 刀
Term在这里, 哪里说Gift Card 不Qualified? 没看到呀
------------------------------------------------------
Holiday Campaign Terms & Conditions
Offer Terms & Conditions ("Terms").
Offline, PIN-based & International Transactions Ineligible.
This Offer begins 11/15/11, 12:00:01AM Central Time ("CT") & ends 12/31/11,
11:59:59PM CT, or while supplies last ("Offer Period"). Internet access is
required for participation & redemption. Eligibility: Open to MasterCard&#
174; cardholders who are legal residents of the ... 阅读全帖
j********8
发帖数: 297
21
谢谢各位牛人哈。唉,是我自己没说清楚。
这个是tracking # a6539176271 大牛没你们看看吧。
online显示
Delivered On:
Wednesday, 11/26/2014 at 7:19 A.M. (我家的地址是Springfield, nj)
但是:
Shipment Progress 显示
Last Location:
Bound Brook, NJ,(这个不是我们家的location) United States, Wednesday, 11
/26/2014 9:08 A.M. Out
For Delivery
所以很奇怪呀。
Shipment Progress
Location Date Local Time Activity
Bound Brook, NJ, 11/26/2014 9:08 A.M. Out for Delivery
11/26/2014 9:07 A.M. Arrival Scan
... 阅读全帖
o****y
发帖数: 790
22
来自主题: Faculty版 - Wonderlich该你出手了
知易行难。
Show me a 杰青, I'll show something special about him!
Never underestimate the surfers in this board, including me! :) Top50 is
NOT even in my 法眼。
I am not bound to succeed, but I am bound to live by the light that I have.
p***o
发帖数: 1252
23
来自主题: Faculty版 - texify,pdftexify, hyperref
Better to convert eps files to pdf files first using epstopdf.
Then you can use pdflatex.
There maybe some bounding box issues but you can always edit
the eps file manually. The unit is 72 points/inch, very easy
to measure if you use something like visio to draw the figure.
Also if you are generating eps files from ps files, gswin32
can automatically decide the correct bounding box since
more than 4 yours ago.
i********w
发帖数: 2223
24
来自主题: Faculty版 - texify,pdftexify, hyperref
我那个例子里面根本就没有图片
怎么会是图片 bounding box的问题?

嗯,bounding box的问题
用acrobat 把图片裁剪大小合适,在转换成eps就木有问题了
i********w
发帖数: 2223
25
来自主题: Faculty版 - texify,pdftexify, hyperref
是better to convert esp files to pdf
还是have to convert esp file to pdf

Better to convert eps files to pdf files first using epstopdf.
Then you can use pdflatex.
There maybe some bounding box issues but you can always edit
the eps file manually. The unit is 72 points/inch, very easy
to measure if you use something like visio to draw the figure.
Also if you are generating eps files from ps files, gswin32
can automatically decide the correct bounding box since
more than 4 yours ago.
z***t
发帖数: 2374
26
来自主题: Faculty版 - machine learning textbook
HTF这种写法是对
他们不是不懂learning theory,相反他们理解的相当出色
这书是拿来做课本用的,不是会议文集
如果说HTF不做ML理论,那做ML理论的人很少了
ML理论不只是去证明bound,而且大部分发在COLT,SODA上的bound都没用
只有很少一部分有实际指导意义
z***t
发帖数: 2374
27
来自主题: Faculty版 - machine learning textbook
HTF这种写法是对
他们不是不懂learning theory,相反他们理解的相当出色
这书是拿来做课本用的,不是会议文集
如果说HTF不做ML理论,那做ML理论的人很少了
ML理论不只是去证明bound,而且大部分发在COLT,SODA上的bound都没用
只有很少一部分有实际指导意义
c**i
发帖数: 6973
28
来自主题: Food版 - Hazelnut 榛
Christine Mulhke, Field Report: Nut Worth; Hazelnut farming can be more
rewarding when the whole family pitches in. New York Times Magazine, Jan 16,
2011.
http://www.nytimes.com/2011/01/16/magazine
/16Food-t-000.html?_r=1&scp=1&sq=hazelnut&st=cse
My comment:
(a) Fritz is (German) pet form of Friedrich. That is why Freddy is later
used in the article (In English, Fred is short for Frederick and Freddy is a
nickname).
(b) Oregon Hazelnuts
http://oregonhazelnuts.org/
(Hazelnut is the name coined by... 阅读全帖
c**i
发帖数: 6973
29
来自主题: Food版 - Scallop + Oyster
(1) 成都火锅业者“宣誓”废弃老油火锅. BBC Chinese, Aug 4, 2011
http://www.bbc.co.uk/zhongwen/simp
/chinese_news/2011/08/110804_sichuan_hotpot.shtml
("日前,媒体报道说成都的火锅店家将客人食用后的火锅锅底回收,经过过滤、称之为
'老油',加温之后再出售给其他客人食用。媒体的报道还说,这是成都火锅店的惯常做
法;店家对此解释说,老油是成都火锅的传统制作工艺")
(2) 中国中产种菜确保吃得安心. BBC Chinese, Aug 4, 2011
http://www.bbc.co.uk/zhongwen/simp
/chinese_news/2011/08/110804_china_allotments_food.shtml
(3) 唐山养殖户不满油污事故调查结果. BBC Chinese, Aug 4, 2011.
http://www.bbc.co.uk/zhongwen/simp
/chinese_news/2011/08/110804_china_oil_spill... 阅读全帖
f*********r
发帖数: 68
30
来自主题: JobHunting版 - careercup上看的一道题
f(N^3) = 7*f(N^3/8)+O(1)
=> f(N^3) = O(N^3*log_8^{7}, not O(logN^3)
x-sum problems have a lower performance bound Omega(n^ceil(x/2)) for
comparison based method. so low bound for 3-sum is O(n^2), maybe google wants you to prove this results.
c*********n
发帖数: 1057
31
来自主题: JobHunting版 - 昨天面试的题目
根据第一个数排序,然后一个个range往后比对,维护一个global right bound,
每次都把这个right bound和rang的left value比较就好了吧?

efficient
range
a
x***y
发帖数: 633
32
来自主题: JobHunting版 - 昨天面试的题目
1. Sort the lower boundary, and the upper boundary separately (O(nlogn)),
from the smallest lower boundary min_low (6 in your e.g), and assume upp is
the upper boundary corresponding(10 in e.g) to lower boundary, set old_upp
to min_low;
2. find position of upp in the array of lower boundary, and in the lower
boundary for all the values less than upp, if the largest corresponding
upper bound is bigger than upp, set old_upp to upp and set upp to the
largest corresponding upper bound, and do step
x***y
发帖数: 633
33
来自主题: JobHunting版 - 讨论个Binary search tree的题目
Actually, a node is always a lower bound for the right tree(<), and upper
bound for the left tree (>=), we can modify that guy program:
if (node->data=data>max) return(false);
// otherwise check the subtrees recursively,
// tightening the min or max constraint
return
isBSTUtil(node->left, min, node->data) &&
isBSTUtil(node->right, node->data, max)
M******k
发帖数: 51
34
来自主题: JobHunting版 - 面经
能不能更详细一些说一下:CPU bound and I/O bound situation, how to
multithread.
z*j
发帖数: 42
35
来自主题: JobHunting版 - 面经
tow types of tasks: cpu bound and i/o bound
on multi-cpu(32 cpu) machine and single-cpu machine, how to handle tasks.
I wasn't very sure about my answers. I don't have experience on multi-cpu
optimization. So I only mentioned some very basic ideas, like DMA, thread
pool.
y*c
发帖数: 904
36
来自主题: JobHunting版 - 征解几道large scale的数字题
For 4, use binary search. Find the disk first and if lower bound and upper
bound are close enough and in one disk. We can bring them into memory.
Hi, jntl, do you mind zz or copy your post in 面试高手俱乐部? that one is
focused on the CS interview questions.
c*********u
发帖数: 361
37
来自主题: JobHunting版 - Google 2nd interview questions
don't know just think I've thought it before.
One way to solve this is to do a binary search regarding to the lower bound
and upper bound.
t********t
发帖数: 5415
38
来自主题: JobHunting版 - Google 2nd interview questions
同意,并没要求最短。例如:
string = hohowl
pattern = howl
如果只要求lz说的true or false,这个肯定是true,但是如果要求最短的话,state
machine就得加入针对pattern首字符的reset。时间上应该是O(len(string))就好了。
第一题给的arrays是sort好的吗?是的话是不是可以这么做:
造个数组ind[n],每个元素初始化为某word第一次出现的index。然后记录ind[n]中最大/最小元素之差为distance。把最小元素move到该单词下一次出现的index,再算ind[n]中最大/最小元素之差,如果比distance小就替换掉。如此反复直到某次移动导致out of bound。(这个bound不是整个text的长度,而应该是某单词出现的次数)。如果有错还请指出
s***e
发帖数: 793
39
你的DP有点小问题,不是很精确( (x-m)*(m+1)/2 是k=2是的特例,不能做dp方程)
,探讨一下
F(l,u,k) 是最坏可能下需要的天数。 l 是可能范围的lower bound, u 是upper
bound
K 表示最大可以接受的投诉次数。
F(1,100,2)就是本题所优化的。
当k = 1时, 只能从大往小试, 承诺99,98,97,。。。。1,所须天数是100+99+98+
97。。。+2。
F(l,u,1) = u + (u-1) + (u-2) … (l+1) = (u+l+1)*(u-l)/2
动态方程是
F(l,u,k) = min { m + 1 + Max( F( l,m,k),F(m+1,u,k-1))} l<=m<=u;
x***y
发帖数: 633
40
Hi, I'm sorry I did not check out your approach carefully and I made a
little mistake in the above analysis. It's right there are at most logM+logN
division at most, but actually in each divide, it only decreases the # of
elements; but the totaly number of rows and cols are still the name.
Consider the worse case, that each division splits the matrix into one
subMatrix with one row and subMatrix with n-1 rows, where n is # of rows of
current Matrix. If this type of split is true for evry step, t... 阅读全帖
a***c
发帖数: 2443
41
来自主题: JobHunting版 - Life in bay area gets harder
for 1), the assumption made here is that interview questions can be
made infinitely hard, but that's not true as there is certainly a
limit as to how hard you really can physically make them (the
difficulty is limited by the length of the interview and the the
material covered, in other words, suitability, among other factors;
you obviously can't have a problem that's too hard that it will take
too long to solve or a problem that is entirely unrelated to what the
interviewee claims to know.)
Als... 阅读全帖
b***e
发帖数: 1419
42
来自主题: JobHunting版 - 请教一道 Google 面试题
I don't think this will need DP eventually, coz it's too slow. Given n,
you need O(n) to compute f(n).
We know the 6-pattern
4 * f(n-6)
is giving the highest exponential rate. As a result, if the input n is
big, in the beginning we will always apply this pattern, until some
certain
point n0. So the end of the day, the time would be O(log(n)).
The next question is to give an upper bound of n0. One naive upper
bound
would be:
n0 = (4 + 5 + 7 + 8 + 9) * 5 = 165
This is the max you can go withou... 阅读全帖
l*****a
发帖数: 559
43
来自主题: JobHunting版 - 找硬币的经典问题
那我能理解的exponential就只是upper bound,不像是tight bound。
g*********s
发帖数: 1782
44
来自主题: JobHunting版 - 经典题atoi的溢出处理
发信人: lolhaha (haha), 信区: JobHunting
标 题: Re: str2int中overflow该如何处理?
发信站: BBS 未名空间站 (Sun Feb 20 18:18:40 2011, 美东)
之前处理也可以,也许更直接
目标 result*10+str[i]-'0'<=MAX_INT
1) result 2) result=MAX_INT/10 && str[i]-'0'<=MAX_INT/10
but notice the negative bound is different from the positive bound. that's
why i say it's tricky.
i**********e
发帖数: 1145
45
来自主题: JobHunting版 - 这么多G的面经,我也想想 ~~
另外一点,关于复杂度的分析:
log N^(1/2) + log N^(1/3) + ... + log N^(1/log N)
= log N (1/2 + 1/3 + ... + 1/log N)
一个很明显的 upper bound 肯定是 O( (log N)^2 ).
1/2 + 1/3 + ... + 1/log N
这个其实跟著名的 harmonic series 很类似:
http://en.wikipedia.org/wiki/Harmonic_series_%28mathematics%29
根据以上的文章,
1/2 + 1/3 + ... + 1/log N
= ln( log N ) + γ - 1 ,当 N 很大的时候
那么,一个比较 tight 的 upper bound 应该是:
O( log N * ln(log N) )
不知道有没有分析错误,如有的话,请欢迎指正。
一些常见面试题的答案与总结 -
http://www.ihas1337code.com
n*******w
发帖数: 687
46
来自主题: JobHunting版 - 代码写全对不容易
嗯,bs变种挺多的。
有重复key的时候返回lower bound或者upper bound,
key不存在的时候返回比key小的最大值或者比key大的最小值等等。。。
导致循环条件不一样,比较条件也不一样,最后可能还得多比较一次。但是每趟的过程差不多。
S******t
发帖数: 151
47
来自主题: JobHunting版 - facebook一题
It is easy to come up with an $O(SL)$ algorithm for this problem but what is
good about this problem is that it actually has a linear time solution:
Let’s first make some notations clear:
1) |S| -> The length of S.
2) |L| -> The number of words in the list $L$.
3) $len_L$ -> The length of each string in $L$.
First we use an Aho-Corasick automaton to find out the occurrences of all
patterns. The time complexity of this step is $O(|S| + |L| * len_L + z)$
where $z$ is the number of output matches. ... 阅读全帖
l********r
发帖数: 140
48
来自主题: JobHunting版 - 数学牛人?
其实好像是基本的平面几何问题啦,谁知道答案?
There is a rectangle (rectangle A) on a 2D space, with known width and
height.
Let's assume its upper left corner is (0, 0).
There is a point (point P) inside this rectangle, at (x,y).
Now, let's rotate rectangle A by k degree (k between 0 and 360), using point
P as center for rotation. For the resulting rectangle, let's get its
bounding rectangle as C.
Assume the bounding rectangle C's upper left point is our new (0, 0), what
are the new location of point A?
y*c
发帖数: 904
49
来自主题: JobHunting版 - 最快速度拷贝10G文件到100台机器
say push file with size F to N nodes, each node has download speed and
upload speed di and si, the lower bound of completion time is max{F/u_s, F/
min{di}, NF/(u_s + sum{ui})} and I think this lower bound can be achieved
closely.
example, F=16G, N=16, divide the file into 16 pieces
after 1s: each node has one piece
after 1s: each node has two pieces by exchanging (0-1, 2-3, etc)
after 2s: each node has four ((01)-(23), etc)
after 4s: each node has eight
after 8s: each node has 16
total 16s
p********n
发帖数: 20
50
来自主题: JobHunting版 - 说好得FG面经,回馈板上GGJJ
直接这样是不对的吧...
貌似应该是先二分找到lower bound;然后在lower bound到n的范围内,再二分找到最
大的以prefix为前缀的串...
首页 上页 1 2 3 4 5 6 7 8 9 10 下页 末页 (共10页)