This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ cat smush.c | |
#include <stdio.h> | |
#include <stdint.h> | |
static uint32_t seed = 0, i = 0; | |
uint32_t smush(){ | |
const uint32_t m = 0x5bd1e995; | |
const uint32_t k = i++ * m; | |
seed = (k ^ (k >> 24) ^ (seed * m)) * m; | |
return seed ^ (seed >> 13); |
NewerOlder