more codeeval. fixed icpc2012dA js.