SRM627 div1 easy, div2 medium