Skip to content Skip to sidebar Skip to footer
Showing posts with the label Bit Manipulation

Javascript Endian Encoding?

A response on SO got me thinking, does JavaScript guarantee a certain endian encoding across OSs an… Read more Javascript Endian Encoding?

Bitwise Operations Php And Js Different

Why does php and js give different results to the same thing: JS: 1085 Solution 1: The operands o… Read more Bitwise Operations Php And Js Different

2.9999999999999999 >> .5?

I heard that you could right-shift a number by .5 instead of using Math.floor(). I decided to check… Read more 2.9999999999999999 >> .5?

Replicating Javascript Bitwise Operation In Python

I'm trying to replicate a simple bitwise Javascript operation in Python. [Javascript] > 0xA8… Read more Replicating Javascript Bitwise Operation In Python

Javascript's Shift Right With Zero-fill Operator (>>>) Yielding Unexpected Result

First, (-1 >>> 0) === (2**32 - 1) which I expect is due to adding a new zero to the left, … Read more Javascript's Shift Right With Zero-fill Operator (>>>) Yielding Unexpected Result