binToDec :: String -> Int
binToDec = sum . zipWith (\p n -> n*2^p) [0..] .  map digitToInt . reverse
binToDec :: String -> Int
binToDec = sum . zipWith (\p n -> n*2^p) [0..] .  map digitToInt . reverse
binToDec = sum . zipWith (\p n -> n*2^p) [0..] .  map digitToInt . reverse