Skip to content

Instantly share code, notes, and snippets.

@notblizzard
Created December 4, 2014 04:59
Show Gist options
  • Save notblizzard/3c73849849e49e4ddad2 to your computer and use it in GitHub Desktop.
Save notblizzard/3c73849849e49e4ddad2 to your computer and use it in GitHub Desktop.
--not mine, from http://www.codewars.com/kata/hamming-distance/solutions?show-solutions=1 by mtthw123
module Hamming where
hamming :: String -> String -> Int
hamming a b = length . filter id $ zipWith (/=) a b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment