Tony's Log

Algorithms, Distributed System, Machine Learning

  博客园 :: 首页 :: 博问 :: 闪存 :: 新随笔 :: 联系 :: 订阅 订阅 :: 管理 ::

2014年2月3日

摘要: My first idea wasSieve of Eratosthenes, too. But obviously my coding was not optimal and it exceeded 6s time limit. Then I googled it. Sounds like Miller-Rabin Testing is a much more serious solution.http://www.cnblogs.com/feature/articles/1824667.htmlIt is based on Fermat Little Theory and property 阅读全文
posted @ 2014-02-03 14:02 Tonix 阅读(164) 评论(0) 推荐(0)

摘要: 200: simple seconds to h:m:s. 2consecutive mod 60 and div 60. No big deal.550: simple DP-like process. A for loop: deducting one bit each time. Point is corner cases.1100: special backtrace on a tree. Direct thought like Greedy backtrace is not optimal - because it only needs a final optimal cost - 阅读全文
posted @ 2014-02-03 10:33 Tonix 阅读(195) 评论(0) 推荐(0)