Write a function that multiplies all the positive elements in a list! I tried to make it, but I need help because it is not working. Can anybody help me what is the problem and how can I fix it?
positive :: (Num a, Ord a) => [a] -> a
positive x
| x> 0 = x * y
| otherwise = Nothing
Example:
positive [1..10] == 3628800
positive ([1..10] ++ [-2, -5, -6]) == 3628800
positive [3, 5, 66, -8, -4, 5, 6, 93, -4567, 56] == 154677600