MCPcopy Create free account
hub / github.com/andeya/algorithm / Log2Byte

Function Log2Byte

mathutil/mathutil.go:173–175  ·  view source on GitHub ↗

Log2Byte returns log base 2 of n. It's the same as index of the highest bit set in n. For n == 0 -1 is returned.

(n byte)

Source from the content-addressed store, hash-verified

source not stored for this graph (policy: none)

Callers 2

TestLog2Function · 0.85
BenchmarkLog2ByteFunction · 0.85

Calls

no outgoing calls

Tested by 2

TestLog2Function · 0.68
BenchmarkLog2ByteFunction · 0.68