Collection¶
This text will be useful if you want to work on problems in our Collections, and it will also be useful if you want to include this material in your teaching as a teacher.
Collections are only in Serbian.
All materials that follow official curricula in Serbia are written in Serbian. Competitions on Arena are also conducted in Serbian. With that in mind, we have not translated the Collections of Problems into English.
You can find our collections in Serbian in the Library at the following link: https://petlja.org/sr-Latn-RS/biblioteka#type-problems&type-problem-questions
For each problem in the collections, you need to write a program that, for input data in a precisely defined format, produces the expected output values within a limited time frame and with limited memory usage, similar to competitions on Arena.
A good portion of the problems in the collections are solved, and many problems are solved in several ways. All solution methods are explained in detail, and the source code representing the solution is provided in C++, C#, and Python. In addition to the problems themselves, these solutions are what make the collections very useful in teaching, as the solution texts explain some of the key concepts in programming.
The availability of solutions depends on the type of user account. Users with a teacher account have access to solutions for all problems. Solutions can be found below the problems themselves. Regular users, unlike teachers, cannot see solutions for all problems. These users are allowed to see solutions for some problems because we believe it is necessary, if they cannot solve a problem on their own, to help their learning in this way. However, since we do not want students to resort to viewing solutions even when, with a little effort, they could solve the problem themselves, the solution is hidden for them, and they need to click the View Solution button and then confirm that they want to view the solution to access it.
In addition to viewing solutions, users on some problems have the option to view test cases. When they click the test cases button, they will download a file containing all the input and output files of the tests used for automatic solution checking.
When the test cases are downloaded, the files need to be extracted and opened in any text editor (all computers using the Windows operating system have the Notepad program, which can be used to read these files), and you will see the input for which your code was tested, as well as the expected output for that input (a file with the same number as the input data file). This is especially useful because the user does not have to look at the complete solution and explanation of the problem, which can be seen when clicking Show problem solution, but based on these test cases, they can independently see for which cases their code does not return the correct solution and try to fix their code accordingly. When a user submits a solution for checking, they receive a result indicating for which test cases the submitted code works and for which it does not. Their previously submitted solutions can be found below the problem statement, and by clicking the magnifying glass icon, they can check for which test case their code does not work.
They will get results that look like the image below. The user can then see which values were used in the third test case and try to figure out why their code does not work for that test case, and then try to fix their code without looking at the problem solution.
There are also problems whose solutions are available only to users with a teacher account and are not available to users with other types of accounts. The reason for this is simple: when solving real programming problems, it is common that we do not have ready-made tests available to check the quality of the program. That is why competitors during competitions do not have access to the tests used for solution evaluation, and it should be the same during any programming learning. Therefore, access to tests is limited as a form of assistance in mastering programming skills, because that skill involves the ability to write correct and efficient programs in real situations, where a solution evaluation system is not given or does not exist.