Basically, I need a function that accepts two lists and attempts to return a 2-list containing the head elements of both the input lists. Couple of corner cases: if both input lists are empty, the result must be an empty list. If only one list is non-empty, its head element must be returned wrapped in a list.
So far, I have tried this:
(+|+) :: [a] -> [a] -> [a]
+|+ [] [] = []
+|+ (x : _) [] = [x]
+|+ [] (y : _) = [y]
+|+ (x : _) (y : _) = [x, y]
Now, when I declare the operator as above, Haskell:
What am I doing wrong here?

Operators are defined infix.
If you really want to use prefix form, you can wrap it in parentheses, as needed for prefix form in other places.
For the definition, you might consider: