Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/web3/types/bignumber.d.ts>BigNumber#multipliedBy

Deno / TypeScript to Ethereum Connector
Latest
method BigNumber.prototype.multipliedBy
import { BigNumber } from "https://deno.land/x/web3@v0.11.1/types/bignumber.d.ts";

Returns a BigNumber whose value is the value of this BigNumber multiplied by n.

The return value is always exact and unrounded.

0.6 * 3                                // 1.7999999999999998
x = new BigNumber(0.6)
y = x.multipliedBy(3)                  // '1.8'
BigNumber('7e+500').multipliedBy(y)    // '1.26e+501'
x.multipliedBy('-a', 16)               // '-6'

Parameters

n: BigNumber.Value

A numeric value.

optional
base: number