ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1472. Martian Army

Ai?
Posted by Anton [SUrSU] 24 Sep 2006 16:09
What is the minimal value for Ai?
Re: Ai?
Posted by Tbilisi SU: Andrew Lutsenko 6 Oct 2006 20:49
0
Use DP ;)
Re: Ai?
Posted by Taek 23 May 2007 20:25
"Let a commander and his subordinate have computers with numbers i and k respectively. According to the contract with the provider, the traffic between the computers i and k must be not less than Ai–Ak."
Can Ai-Ak<0 ?
Re: Ai?
Posted by Ostap Korkuna (Lviv NU) 25 Aug 2007 15:22
You should consider both (Ai-Ak) and (Ak-Ai). Thus traffic >= max(Ai-Ak , Ak-Ai).
Re: Ai?
Posted by Denis Koshman 31 Jul 2008 21:14
My AC solution assumes
Traffic = max(Ai-Ak, 0)