Skip to content

Instantly share code, notes, and snippets.

View ncblair's full-sized avatar

Nathan Blair ncblair

View GitHub Profile
@ncblair
ncblair / prng_test.c
Last active June 15, 2023 15:50
Fast Real-Time Safe Pseudorandom Number Generator + Benchmark
#include <stdint.h>
#include <stdio.h>
#include <time.h>
#include <math.h>
// xorshift code taken from wikipedia
struct xorshift32_state {
uint32_t a;
};