How can I maximize my chances on an exam? I have an exam tomorrow, there are 18 topics, the professor gives only one. But it is not enitrely random how he gives the topic. 
First he gives an interval like 18-52, 30-62, 30-68 etc, then we both independently write down a whole number from this interval, and the sum of these numbers modulo 18 will be the topic one has to talk about.
Can I somehow affect my chances, like I say the middle of the interval, or the end of the interval?
 A: Since you do not know the number that will be written by the professor, you have to assume that he can write any of them. The following approach offers a way how to know all possible questions, given your action.
Let your number be denoted $a$ while the professor's $\omega$. The set of questions you can be asked, for given $a$ is
$$Q_a =\{i=(\omega+a)\%18|\omega\in I\}$$
where $I$ is the considered interval. 
More information could be obtained if you would know the strategy how the professor writes $\omega$. Assuming that it is a random number with probability mass function $p(\omega)$, you can transform the $Q_a$ to conditional probability mass functions $p(i|a)$:
$$
p(i|a)=\sum_{\omega\in I:(a+\omega)\%18 =i}p(\omega)
$$
Afterwards, you can find $a$ that maximizes  your chances
$$
a^{*}=\arg\min_{a} p(i|a) z(i)
$$
where $z(i)=0$ if you do not know the topic and $z(i)=1$ if you know it.
If you do not know the professor's strategy, you can ask your classmates for his choices and to reconstruct the strategy on your own. Alternatively, you can try some common sense strategies (uniform, for example).
A: If the interval is randomly generated by your professor on the D-Day, I don't think there is a bias towards a specific topic.
The only chance you have would be to pre-define a strategy accepted by all your classmates. A general strategy may be hard to formalize if the interval is more narrow than 18. But with a large interval (like 19-37 for example), N-1 students has to pick a multiple of 18 (36 for this example) and the last one would pick a K such as K=18*k + t with t being the topic you collectively decided to target (K=20 in this example if you target the topic 2).
