Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/rimbu/typical/num.ts>Inc

Rimbu is a TypeScript library focused on immutable, performant, and type-safe collections and other tools.
Go to Latest
type alias Inc
import { type Inc } from "https://deno.land/x/rimbu@1.0.2/typical/num.ts";

Add 1 to the given natural number.

Examples

Example 1

Inc<4> => 5
Inc<312> => 313
Inc<-3> => never

Type Parameters

N extends number
definition: Add<N, 1>