java - Use Float as Int (without conversion) in Scala -


i'm trying implement fast inverse square root algorithm in scala. algorithm involves exploiting binary representation of 32-bit floating-point number applying bitwise , integer operations binary representation, though int. in other words, must create int out of binary representation of float, not use cast operator.

i remember doing similar while in java, , believe done using static method of integer. i'm new scala, though, , can't seem find such method. how 1 in scala?


Comments

Popular posts from this blog

javascript - ScrollTo Effect (href to div) -

javascript - ng-class not responding to change in model in Angular? -

javascript - document.registerElement extending HTMLInputElement prototype while using custom tag name to avoid implicit browser style -