verified code for MoveZeros2ArratEnd.java with order preserving