Code I wrote for programming contests