You are not logged in. Please login at www.codechef.com to post your questions!

×

Codesprint - Working with boxes Modification

Original Problem

After an update

If the operation time < 0 at any point of time, the the time taken is 0.

I misinterpreted the problem as to resetting the total operation time to 0 when it goes negative. i.e, now order of operations matters even more.

For example, (1 1 2 2) with C = 3,

1*1 + 1*1 - 3 = -1 Total Time = -1 -> 0 2*1 + 2*1 - 3 = 1 Total Time = 0+1 = 1 ....

Or in other order

2*1 + 2*1 - 3 = 1 Total Time = 1 1*1 + 1*1 - 3 = -1 Total Time = 1-1 = 0 ....

Any ideas on this interpretation of the problem?

asked 28 Sep '14, 14:26

nims11's gravatar image

6★nims11
431135
accept rate: 20%

edited 28 Sep '14, 14:26

toggle preview
Preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported
  • mathemetical formulas in Latex between $ symbol

Question tags:

×4

question asked: 28 Sep '14, 14:26

question was seen: 373 times

last updated: 28 Sep '14, 14:26

Related questions