Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
chain-able-deps / dist / typings / math / range.d.ts
Size: Mime:
/**
 * Generate an integer Array containing an arithmetic progression. A port of
 * the native Python `range()` function. See
 * [the Python documentation](http://docs.python.org/library/functions.html#range).
 *
 * @name range
 * @since 5.0.0-beta.6
 * @memberOf math
 *
 * @param {number} start starting number
 * @param {number} [stop] ending number, defaultsTo(start)
 * @param {number} [step] step, defaultsto(-1 || 1)
 * @return {Array<number>} [start...stop]
 *
 * {@link https://github.com/jashkenas/underscore/blob/master/underscore.js#L714 underscore-range}
 * @see {@link underscore-range}
 *
 * @example
 *
 *   range(10)
 *   //=> [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
 *   range(1, 11)
 *   //=> [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
 *   range(0, 30, 5)
 *   //=> [0, 5, 10, 15, 20, 25]
 *   range(0, -10, -1)
 *   //=> [0, -1, -2, -3, -4, -5, -6, -7, -8, -9]
 *   range(0)
 *   //=> []
 *
 */
export default function range(start: number, stop?: number, step?: number): any[];