Polygon is a service to prepares programming problems and contests. It is usually used to prepare problems for olympiads/programming contests but it is also often used to prepare educational content. It is located at https://polygon.codeforces.com/ and is open to everybody.
Here are three recent new features:
- IOI-like Graders for Python
- Problem Materials
- User Groups
IOI-like Graders for Python
About 3 years ago we announced support of IOI graders for C++ in Polygon (Please read the old post). Now we have added support for graders written in Python. However, since there is no concept of linkage in Python, Python graders are different from C++ ones.
In the case of Python, the grader entry point file must have the name "main.py", placed into the “Resource Files” section and marked as a compile-time resource. This file will be invoked instead of the participant's solution while testing. Participant’s solution will be available as a Python module "solution" from main.py.
Also, you can add any other modules that will be available from the participant's solution. To do that, upload it to resource files and mark it as a compile-time resource.
All Polygon users already have access to the example problem "a-plus-b-graders".
Now Polygon has a feature to specify which problem materials should be separately published as a downloadable zip-archive by a judging system (a judging system needs to support it). Codeforces already supports this feature: problem materials appear in the sidebar inside the contest:
To create a publishable archive with problem materials, you need to click "Add Material" on the "Packages" tab. You will see the following:
The material archive is automatically generated and stored in the problem package based on what you choose to publish (by clicking the “Add item” link). In the pop-up window, you can choose which elements the archive should contain.
There are three options for publishing:
NONE, which means not to publish at all, just put it to the problem package,
WITH_TUTORIAL, which means to publish at the end of the competition, and
WITH_STATEMENT, which means to publish at the start of the competition.
User groups make it possible to manage access rights to problems and contests for multiple users, as if for a single user. For example, if there is a well-established group of problem authors, you can not list all users when granting access, but simply specify the name of the group. Users in a group will have access to the problem automatically.
Here, @codeforces-team is a user group:
You can see your user groups by clicking the link in the top menu:
To manage user group members you have to click the “Enter” link on the corresponding group. You will see the list of all group members.
Note, that there are two roles: Member and Manager. Managers are allowed to edit the list of group members and Members are not.
To refer to the group on managing access pages (both in problems and contests) you should use
Example of a user group in contests interface: