Skip to main content
Module

x/fun/mod.ts>number.mod

A collection of algebraic data types, lenses, and schemables based on a light weight higher kinded type implementation. Written for deno.
Latest
function number.mod
import { number } from "https://deno.land/x/fun@v2.0.0/mod.ts";
const { mod } = number;

Return the positive modulus of two numbers.

Examples

Example 1

import * as N from "./number.ts";
import { pipe } from "./fn.ts";

const result = pipe(11, N.mod(2)); // 1

Parameters

second: number

Returns

(first: number) => number