MCPcopy Create free account
hub / github.com/Effect-TS/effect / sqrt

Function sqrt

packages/effect/src/BigInt.ts:723–724  ·  view source on GitHub ↗
(n: bigint)

Source from the content-addressed store, hash-verified

721 * @since 2.0.0
722 */
723export const sqrt = (n: bigint): Option.Option<bigint> =>
724 isGreaterThanOrEqualTo(n, bigint0) ? Option.some(sqrtUnsafe(n)) : Option.none()
725
726/**
727 * Takes an `Iterable` of `bigint`s and returns their sum as a single `bigint`. Returns `0n` for an empty iterable.

Callers

nothing calls this directly

Calls 3

isGreaterThanOrEqualToFunction · 0.85
sqrtUnsafeFunction · 0.85
someMethod · 0.80

Tested by

no test coverage detected