A-M baby
This commit is contained in:
parent
764da6cbbb
commit
db842d013d
19005 changed files with 197040 additions and 7 deletions
|
|
@ -0,0 +1,16 @@
|
|||
import Data.List
|
||||
import Control.Monad
|
||||
import Control.Arrow
|
||||
|
||||
missingPerm :: Eq a => [[a]] -> [[a]]
|
||||
missingPerm = (\\) =<< permutations . nub . join
|
||||
|
||||
deficientPermsList = ["ABCD","CABD","ACDB","DACB",
|
||||
"BCDA","ACBD","ADCB","CDAB",
|
||||
"DABC","BCAD","CADB","CDBA",
|
||||
"CBAD","ABDC","ADBC","BDCA",
|
||||
"DCBA","BACD","BADC","BDAC",
|
||||
"CBDA","DBCA","DCAB"]
|
||||
|
||||
main = do
|
||||
print $ missingPerm deficientPermsList
|
||||
Loading…
Add table
Add a link
Reference in a new issue