Skip to content

Instantly share code, notes, and snippets.

@HRezaei
Created November 6, 2016 16:49
Show Gist options
  • Save HRezaei/15efdaebac3b4d93d52a80f0b9661c19 to your computer and use it in GitHub Desktop.
Save HRezaei/15efdaebac3b4d93d52a80f0b9661c19 to your computer and use it in GitHub Desktop.
Computes hamming distance of two hexadecimal integers
select bit_count((conv('7c0c8e868ee0e988', 16, 10) ^ conv('183e3c1c1e587e02', 16, 10)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment