packages feed

code-conjure-0.5.8: bench/take-drop.out

drop :: Int -> [A] -> [A]
-- testing 360 combinations of argument values
-- pruning with 4/7 rules
-- looking through 2 candidates of size 1
-- looking through 3 candidates of size 2
-- looking through 4 candidates of size 3
-- looking through 9 candidates of size 4
-- looking through 10 candidates of size 5
-- looking through 28 candidates of size 6
-- looking through 50 candidates of size 7
-- tested 63 candidates
drop 0 xs  =  xs
drop x []  =  []
drop x (y:xs)  =  drop (x - 1) xs

take :: Int -> [A] -> [A]
-- testing 143 combinations of argument values
-- pruning with 14/21 rules
-- looking through 2 candidates of size 1
-- looking through 3 candidates of size 2
-- looking through 4 candidates of size 3
-- looking through 9 candidates of size 4
-- looking through 10 candidates of size 5
-- looking through 28 candidates of size 6
-- looking through 50 candidates of size 7
-- looking through 83 candidates of size 8
-- looking through 133 candidates of size 9
-- tested 249 candidates
take 0 xs  =  []
take x []  =  []
take x (y:xs)  =  y:take (x - 1) xs