ae.utils.math

Number stuff

Members

Functions

bitsFor
ubyte bitsFor(T n)

Returns the number of bits needed to store a number up to n (inclusive).

ilog2
ubyte ilog2(T n)

Integer log2.

Meta

Authors

Vladimir Panteleev <vladimir@thecybershadow.net>

License

This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.