poj_3050 ac code