add an o(n) solution for Jump-Game-II.cpp