Onebased
One-based, or one-based indexing, is the convention of numbering elements of a sequence starting at 1. In this scheme the first element has index 1, the second has index 2, and so on. This contrasts with zero-based indexing, where the first element is at index 0 and the nth element at index n-1.
The term is common in mathematics and in various programming languages and tools that expose user-friendly
Advantages of one-based indexing include alignment with everyday counting and many mathematical formulas, which can reduce
Disadvantages arise when interfacing with systems that use zero-based indexing. Conversions between schemes can introduce subtle
In practice, one-based indexing remains prevalent in mathematical writing and in several high-level languages and tools.
See also: zero-based indexing, off-by-one error, arrays, MATLAB, R, Lua, Fortran, spreadsheets.