poj 2421 (prim algorithm)