Skip to content

Instantly share code, notes, and snippets.

@cedricbellet
Created December 26, 2017 14:17
Show Gist options
  • Save cedricbellet/c3a9669e989b9bc2b268c9da6ecef91f to your computer and use it in GitHub Desktop.
Save cedricbellet/c3a9669e989b9bc2b268c9da6ecef91f to your computer and use it in GitHub Desktop.
for (i of [2, 3, 5, 7, 11, 13, 17, 19]) {
input_block = parseInt((Math.sqrt(i) % 1).toString(2).slice(2, 34), 2);
console.log(input_block.toString(16), input_block.toString(2).padStart(32, '0'));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment