factorial :: Int -> Int
-- testing 4 combinations of argument values
-- pruning with 27/65 rules
-- 3 candidates of size 1
-- 0 candidates of size 2
-- 6 candidates of size 3
-- 0 candidates of size 4
-- 23 candidates of size 5
-- 0 candidates of size 6
-- 147 candidates of size 7
-- tested 173 candidates
factorial 0  =  1
factorial x  =  x * factorial (x - 1)

-- 8 candidates of size 8
-- tested 182 candidates
factorial 1  =  1
factorial x  =  x * factorial (x - 1)

-- 941 candidates of size 9
-- tested 1115 candidates
factorial 0  =  0
factorial 1  =  1
factorial x  =  x * factorial (x - 1)

-- tested 1123 candidates
factorial 0  =  1
factorial 1  =  1
factorial x  =  x * factorial (x - 1)

-- 49 candidates of size 10
-- 6490 candidates of size 11
-- tested 7239 candidates
factorial 0  =  1
factorial x  =  x + x * (factorial (x - 1) - 1)

-- tested 7421 candidates
factorial 0  =  1
factorial x  =  x - x * (1 - factorial (x - 1))

-- tested 7544 candidates
factorial 0  =  1
factorial x  =  (0 - x) * (0 - factorial (x - 1))

-- tested 7667 candidates
factorial n  =  undefined  -- search exhausted

