Solution for 3th task published.

Algo with fixed molecule-string and shift right 2*N-1 times
rolecule-string. Hard test (test/myhard.txt) takes about 300 minutes.
Solution for 3th problem upgraded.

Added smart using of time.
1. We read all tasks and perform tasks at first with small string length.
2. If we spend all time which have then break and print "zaglushkis".
Last point give me 70/200 scores.