Skip to main content
Module

x/rimbu/typical/mod.ts>StrNum.IsOdd

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

Type that validates whether a given string-number is odd. Checks that the last digit is odd.

Type Parameters

N extends string
definition: U.Pred<Str.EndsWith<N,
| "1"
| "3"
| "5"
| "7"
| "9"
>>