Croatian Open Competition in Informatics — COCI 2022/2023
Internet online contest series
As part of the COCI series, we are hosting an Internet online contest with problems from the Croatian Olympiad in Informatics 2023. The contest is primarily intended for high school contestants, but is open to all interested!
This contest is used in Croatia to select members of the IOI 2023 team. There will be three to five tasks and the contest will be five hours long. The contestants will have full feedback with at most 50 submissions per task.
The problems were set by dorijanlendvaj, ipaljak, keko37 and myself.
It will be held on Sunday, May 21, starting at 15:30 (GMT/UTC).
We have been notified about the clash with the AtCoder round. The starting time has changed, the new starting time is the one above, the old one was 14:00 GMT/UTC.
Check out your local times at https://hsin.hr/coci/next_contest.html.
You may use Python, Pascal, C, C++ or Java as your programming language of choice.
The two relevant websites are:
https://hsin.hr/coci/ — information about the contest
https://evaluator.hsin.hr/ — judging system
We hope that you will join us or encourage your students to do so!
Clashes with AGC...
We have been made aware. The contest has been postponed for an hour and a half. The new starting time is 15:30 (GMT/UTC).
It also clashed with APIO for some, second year in a row :(
Is it possible to participate within a time window of, say 24 hours? Fixed time contest is not accessible all over the world due to time zone problems.
Can anyone tell me that why did I get those downvotes? What did do I do wrong by "requesting" a time window? Is it wrong even to request something?
The Task statements text file is empty
They were uploaded 5 minutes after the contest started.
Can discussion start now? If so, what is the solution to problem 4?
For each number $$$i (1<=i<=n)$$$ let $$$l[i], r[i]$$$ be the start position of the first and the last segment of size $$$K$$$ in permutation $$$q$$$ containing $$$i$$$ respectively.
Now you can iterate over $$$p$$$ and add $$$1$$$ to range $$$[l[p[i]], r[p[i]]]$$$ and add $$$-1$$$ to range $$$[l[p[i — k], r[p[i — k]]]$$$ and keep track of Max and their Counts (this is just sliding window). This can be done using lazy segment tree.
In order to get $$$100$$$ points, you can store $$$N$$$ versions of this segment tree (make it persistent) and for each swap of consecutive numbers you only need to update $$$2$$$ out of these $$$N$$$ segment trees. Let $$$t$$$ and $$$t+1$$$ be the positions we swap. One can easily notice that only the segments ending at $$$t$$$ and starting at $$$t+1$$$ changes (for sure if such a segment of size $$$K$$$ exists).
You can use another segment tree (a simple one) in order to find $$$(Max, Count)$$$ over the roots of these $$$N$$$ segment trees.
Instead of using a persistent segment tree, you can do everything offline; when you get to the i-th version of the segment tree, do the updates that you're supposed to do for that segment tree and then revert them before going to the (i+1)-th version.
Where can we submit solutions?
They will be added soon.
EDIT: It is now available under the categories Srednje škole > 2023 > HIO.
Why don't you publish standings?
Can anyone explain problem 3?