Skip to content

Instantly share code, notes, and snippets.

View compilade's full-sized avatar

compilade

View GitHub Profile
@compilade
compilade / fractional-difficulty.c
Last active April 22, 2025 21:14
Fractional difficulty proof of concept, related to https://github.com/TecharoHQ/anubis/issues/106
#include <math.h>
#include <stdbool.h>
#include <stdlib.h>
#include <stdint.h>
#include <stdio.h>
#include <string.h>
#include <sys/random.h>
void print_hex(FILE * stream, uint8_t * hash, int size) {
for (int i = 0; i < size; ++i) {