← Back to topics
Topic

trojke

M
MilosRadic
how can i solve this task?
i tried sorting and then adding but it is TLE
D
Dgleich
Your Sorting is too slow... Try learning some other sort algorithm like quicksort?
M
MilosRadic
but are u sure it can be solved this way?
its np to try some other sorting but can this be solved in pascal with time limit of 0.1 sec.
In the contest the limit was 1 sec
p
picsel
Yes, sort faster