Editorial for COCI '15 Contest 3 #2 Esej
Submitting an official solution before solving the problem yourself is a bannable offence.
In this task, we needed to find a large enough number of distinct words. How can we, for instance, generate
One solution is to notice that it is very easy to output a sufficient number of different numbers. For example, we can output them sequentially: a
, b
, c
, and so on. For instance, the number efb
. If we use this way to transform every integer from
If we hadn't thought of this solution, we could have output rand()
in C/C++ or the module random
in Python). This approach will be valid because all given words will be distinct with a high probability.
Comments