Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

Re:一种建素数表的方法

Posted by allenlowesy at 2008-07-31 22:44:25 on Problem 2262
In Reply To:一种建素数表的方法 Posted by:hmlog at 2008-07-28 13:16:03
> 先把整个表标记为true,然后从2开始往上扫描,第一次把2的倍数标记为false,第二次把3的倍数标记为false,第三次把5的倍数标记为false...以此类推。
> 当然了这种方法效率不高,我的代码用了400ms+。
我就这么干的  TLE了。。。

Followed by:

Post your reply here:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator