REMOVE ME -----邮件原件----- 发件人: [email protected] [mailto:[email protected]] 代表 Makandriaco 发送时间: 2012年4月30日 星期一 22:54 收件人: Google Code Jam 主题: [gcj] Re: Cruise Control Test case#4
The first car has reached the edge of the second car at 12, they are bumper to bumper, and the third car is on the side (just like your diagram), since car 1 is faster it cant go on after second 12 so it must turn off cruise control at exactly 12 (if it goes to 13 they would have crashed already) On Apr 29, 2:16 pm, xenoky <[email protected]> wrote: > Hi, > > The 4th test case in the Cruise Control problem has the following > input: > 4 > L 4 0 > L 2 29 > L 1 35 > L 1 44 > > The given solution is: > Case #4: 12 > > calculating the distance at t=12 > > 4*12=48 > 2*12+29=53 > 12+35=47 > 12+44=56 > > ordering this distance [47,48,53,56] > > The maximum distance beetween nearest triplet is 6! -> [47,48,53] > > I can put the car this way > > ##### ##### > ##### > > without accident > > Where am i wrong? > > My program answer is 13... -- You received this message because you are subscribed to the Google Groups "Google Code Jam" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-code?hl=en. -- You received this message because you are subscribed to the Google Groups "Google Code Jam" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-code?hl=en.
