Skip to content

Instantly share code, notes, and snippets.

@quydm
Created December 13, 2016 09:27
Show Gist options
  • Save quydm/c2615e4330d302c911e61df2cdca19f8 to your computer and use it in GitHub Desktop.
Save quydm/c2615e4330d302c911e61df2cdca19f8 to your computer and use it in GitHub Desktop.
xxHash sample
#include <stdio.h>
#include <string.h>
#include "xxhash.h"
int main(int argc, const char * argv[]) {
const char *str = "Lorem ipsum dolor sit amet, consectetur adipiscing elit";
unsigned int sum = XXH32(str, strlen(str), 0);
printf("hash: %08x\n", sum);
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment