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 1396. Maximum. Version 2

Problemset Maintainer NEW PROBLEM 1396 “Maximum. Version 2” has been added. (-) [25] // Problem 1396. Maximum. Version 2 10 May 2006 19:33
This problem is the same as 1079 “Maximum” but with bigger limitations.

Edited by author 10.05.2006 19:37
Dmitry 'Diman_YES' Kovalioff. Retired I have a proposal (+) [2] // Problem 1396. Maximum. Version 2 11 May 2006 12:20
The problem is just added, so it may be easily modified. Let it be more than 10000 lines in input - so that the TL would be strict enough and my solution get TLE ;)

Edited by author 11.05.2006 12:21
Problemset Maintainer Your solution is fast enough, don't tount at me (-) [1] // Problem 1396. Maximum. Version 2 11 May 2006 12:58
Burunduk1, please, resubmit your solution for N < 10^18. I will use your solution to generate new tests ;-)

Edited by author 11.05.2006 15:31
Burunduk1 I've resubmited it. (ID=1187372) [12] // Problem 1396. Maximum. Version 2 11 May 2006 19:02
Problemset Maintainer Re: I've resubmited it. (ID=1187372) [11] // Problem 1396. Maximum. Version 2 11 May 2006 19:30
This code will get WA with N < 10^18.
Guess why?
Burunduk1 Re: This code will get WA with N < 10^18. [10] // Problem 1396. Maximum. Version 2 11 May 2006 20:10
And for N < 10^17 ?
Try to change "__int64" to "unsigned __int64".
Problemset Maintainer Yes, for N < 10^17 too [9] // Problem 1396. Maximum. Version 2 11 May 2006 20:24
Burunduk1 Re: Yes, for N < 10^17 too [8] // Problem 1396. Maximum. Version 2 11 May 2006 20:28
Please, give me my AC solution!!! (to sk1@hotbox.ru)
I modified it (of course without backup) and now it
doesn't pass second test. (or you've already added new tests?)

PS: This ability (to view submitted solutions) is useful.
Problemset Maintainer Sent (+) [7] // Problem 1396. Maximum. Version 2 11 May 2006 20:37
And now there is only one test
Burunduk1 Re: Sent (+) [6] // Problem 1396. Maximum. Version 2 11 May 2006 20:39
I see... (know the same solution gets WA 1)
Problemset Maintainer Have you received my letter? [5] // Problem 1396. Maximum. Version 2 11 May 2006 20:41
Burunduk1 Re: Have you received my letter? [1] // Problem 1396. Maximum. Version 2 11 May 2006 20:42
AC ;)
!!!
:)
Problemset Maintainer My congratulations! // Problem 1396. Maximum. Version 2 11 May 2006 20:43
Burunduk1 Re: Have you received my letter? [2] // Problem 1396. Maximum. Version 2 11 May 2006 20:43
The bug was in this:
I calculated F[i] int 32-bit integer.
Ilya Grebnov[Ivanovo SPU] Re: Have you received my letter? [1] // Problem 1396. Maximum. Version 2 11 May 2006 22:04
Do you use any precalculations?
Burunduk1 Re: Have you received my letter? // Problem 1396. Maximum. Version 2 11 May 2006 23:19
My solution consists of only precalc.
I calculate all different maximums on [1..x]
where x is any integer between 1 and 10^18.
Dmitry 'Diman_YES' Kovalioff. Retired Oups... I need a new solution for 10^18 ;) (-) // Problem 1396. Maximum. Version 2 11 May 2006 20:19
Problemset Maintainer Limitations were changed, problem rejudged [6] // Problem 1396. Maximum. Version 2 11 May 2006 20:32
I see...
And why you haven't got AC?
Problemset Maintainer My solution is bad :) It work for N < 10^11 only (-) [4] // Problem 1396. Maximum. Version 2 11 May 2006 20:39
Dmitry 'Diman_YES' Kovalioff. Retired I wish I had a supercomputer ;) P.S. The problem seems to have only one test (-) [3] // Problem 1396. Maximum. Version 2 11 May 2006 20:54
Problemset Maintainer Oh! You got AC! Where did you find supercomputer? [2] // Problem 1396. Maximum. Version 2 12 May 2006 00:48
I have found O(logN) solution in one book.
Very nice idea.
Гладких Максим Re: Oh! You got AC! Where did you find supercomputer? // Problem 1396. Maximum. Version 2 22 Sep 2006 00:55
As far as I know solution of this problem in O(logN) can be found in Shens book...

Edited by author 22.09.2006 00:57

Edited by author 22.09.2006 00:57

Edited by author 22.09.2006 02:01