code: function slice(v, start, end, step) {
    var r = [];
    var i = void 0;
    if (step > 0) {
      for (i = start; i < end; i += step) {
        r.push(v[i]);
      }
    } else {
      for (i = start; i > end; i += step) {
        r.push(v[i]);
      }
    }
    return r;
  }
docs: 模仿 Python 的分片操作
  @param v
  @param start
  @param end
  @param step
  @returns {Array}