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

正反遍历一次 保存i前的2和i后的1 ans=min(i前的2+i后的1) i in [1..n]

Posted by Assassin_cpy at 2008-09-22 22:44:44 on Problem 3671 and last updated at 2008-09-22 22:45:34
In Reply To:这题o(n)的dp怎么做啊 晕 o(n*n)的超时 写了个nlogn的才过啊 我太菜了 Posted by:rush_again at 2008-09-22 22:03:59


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