← Back to topics
Topic

BubbleNiceSS - time limit?

h
halil
It seems to me that it was given very little time for BubbleNiceSS.
Just load the data is not passed in the C++ (using scanf ("% d. ..)), as in GPC, and passes in Free Pascal. Even a trivial passing through a array does not go away even in C++, or in Pascal. If I right, please increase the time limit.
M
MilosRadic
hmm its only 1000 000 numbers so it should be possible to read em all in less than a 0.1 sec
D
Dgleich
I agree with halil, the time limit is ridiculous, I haven't succeded in reading all the numbers in 0.1s in C++. Even if we manage to make it so fast there is still time required for the solution... Can you change the time limit to 0.5s or 1s?
M
MilosRadic
still cant read in time:D
D
Dgleich
@MilosRadic, it's possible to read the numbers but you have to use your own I/O...
M
MilosRadic
ah u mean to read am as chars first...
D
Dgleich
Yep, u read the whole buffer at once using fread...
M
MilosRadic
dont feel like doing it:)
h
halil
Reading the numbers using the 'fread' and convert a series of character into numbers is tedious. Better to increase the time limit (maybe 0.8 - 1.0 sec). Because Pascal, perhaps even higher time limit.
A
Amtrix
The time limit from the BubbleCup competition was 3 secs for this task. Without reading optimizations it's impossible to solve it...
M
MilosRadic
well it is recquired O(n*logn) for calculating and plus the time to read...so u might make the time 1 sec or more cause of pascal
D
Dgleich
It's possible to solve it in O(N) :)
M
MilosRadic
how?:D
edit:ah i didnt read the task well so ok O(n) is the limit:D
e
elvircrn
moze neki hint za O(n) rjesenje? xD