solve problem 249, got "234ms 5367kb".