The problem
Consider an equation such as "3 ± 2 ± 4 ± 1 = 4" and determine if there exists a sequence of pluses and minuses that makes it arithmetically correct. If it exists, exhibit it. For instance, [-, +, -] works in this case: "3 - 2 + 4 - 1 = 4".
Sometimes it's impossible: e.g. "3 ± 5 = 7" has no solution. Your code needs to determine this.
Other times, multiple solutions are possible: for "1 ± 2 ± 4 ± 3 ± 1 = 1" , both [-, +, -, +] and [+, -, +, -] are valid. Your code only needs to exhibit one but may also exhibit all.
The challenge
Code golf: write the shortest function or program that solves the problem.
Assumptions
All numbers (both left and right of the equal sign) are non-negative integers. There may be zeroes.
There is just one number to the right of the equal sign.
There is no ± at the left of the first number.
(2 ± 3 = 1 has no solution)
Partial sums may be negative (but the total sum will be non-negative).
There are at least 3 numbers in the input (i.e. at least 2 on the left hand side, plus the result).
I/O
You will take a sequence of N numbers ([a1, a2, ...aN-1, aN]), where a1, a2, ...aN-1 are addends and aN is the result.
Alternatively, you may choose to get aN separately from the rest.
You are free to choose what is a "sequence" (a list, or an array, or literals via stdin separated by space or newline or comma, or ...).
If there is a solution, you should output a sequence of N-2 "plus"-signifying and "minus"-signifying constants, which may be represented as you prefer (("+", "-"), or (+1, -1,), or (+1, 0), or (NaN, 4), or ...).
There are N-2 symbols total. You must not output the (implicit) "plus" to the left of the first addend.
If there is no solution, you should have a predictable behaviour that signifies "no solution". This can be returning/printing a specific constant or throwing an exception or terminating without output.
Having a program that predictably doesn't terminate is also acceptable.
Examples
3 2 4 1 4
→- + -
3 5 7
→none
1 2 4 3 1 1
→+ - + -
or- + - +
or both2 3 1
→none
11 3 0 8
→- +
or- -
or both0 15 15
→+
4 9 6 1
→- +
8 2 3 3
→- -
8 4 5 1 16
→+ + -