icpc2007dA swift (untested)