Validate International Securities Identification Number: Difference between revisions
Validate International Securities Identification Number (view source)
Revision as of 17:45, 30 May 2017
, 7 years ago→{{header|Haskell}}: used quotRem in lieu of divMod
(→{{header|Haskell}}: added missing test case to 1st version (+ minor linting)) |
m (→{{header|Haskell}}: used quotRem in lieu of divMod) |
||
Line 938:
(`mod` 10) .
sum .
fmap (uncurry (+) . (`
zipWith id (cycle [id, (2 *)]) . stringInts . reverse
Line 947:
capitals, digits :: String
capitals = ['A' .. 'Z']
digits = ['0' .. '9']
|