Perhaps today and/or tomorrow due to a power outage there may be disruptions in the work of Codeforces and Polygon. Please do not plan any important events during this time. If there are details or the exact time, we will definitely publish them. Estimated time of maintenance: from 2 Aug, 16:00 (UTC) to 2 Aug, 20:00 (UTC).
 
 
 
 
Freemarker manual

This is brief manual for generating test scripts using Freemarker Template Engine
Freemarker Template Engine is an engine, created to process text files. It process only parts of text files, that are surrounded with special Freemarker directives. Everything else is copied directly to the output. So if the file does not contain Freemarker at all, that the result of the processing such file is an exact copy of this file.
Input:
 
Output:
Variables are created automatically during their first assignment. To assign a value to the variable #assign directive is used.
<#assign i = 10/>
To evaluate some expression with variables you should enclose it in ${} symbols.
<#assign i = 10/>
gen ${i} ${i*2 + 1} ${i*i + 10} > $
Input:
 
Output:
To iterate through the range of integers, #list directive is used.
<#list 10..20 as iter></#list>
For example:
<#list 10..20 as iter>
gen 100 200 ${iter*iter + 10} > $
</#list>
Of course, loops can be nested. And all variables, that were declared previously, can be used inside.
Input:
 
Output:
For more detailed tutorial please see Freemarker Documentation