Solutions for programming contests tasks