Maximum given a list of integers, and any combination of the operators $( ) ,+, *$ Given a list of integers, insert the operations $( ) +$ and $*$ to yield the maximum value.
Examples:
$2$ $1$ $1$ $2$ is maximized with $(2 + 1)  * (2 + 1) = 9,$ and $1$ $1$ $1$ $1$ $1$ $1$ is maximized with $(1 + 1 + 1) * (1 + 1 + 1) = 9.$
Is there an algorithm that works every time to solve this problem?
 A: First, we will proof an optimal constructive method, next proof that constructive methods gives the best solution.
a)
Let $a=a_0a_1a_2\cdots$ the optimal solution found until now (where $a_i$ can be an addition of numbers). Let $x=a_0$ and $y=a_1a_2\cdots$, $a=xy$. 
Now, we must include number $z$ in the solution. It can be included as new factor $xyz$ or as an addition to one of the already existing ones $(x+z)y$. The inequality to consider is:
$xyz \ge (x+z)y$ 
that concludes that:
if $z \ge 2$ then $xyz \ge (x+z)y$
if $z = 1$ then $xyz \lt (x+z)y$
in conclusion, new number must included multiplying all expression except if number is 1.
b) In case of new number equal to 1, add it to which existing factor?. The inequality is now:
$(x+1)y \ge x(y+1)$
with solution $y \ge x$, thus, add 1 to the smaller factor.
(initial case with $a=a_0$ is straightforward).
c) sequence to use in the constructive method.
Assume we must include two numbers $z_1$ and $z_2$. If both are greater than 1, the method will include both multiplying $a$, thus, same result if be include $z_1$ and next $z_2$ than if we include $z_2$ next $z_1$. 
If both numbers are equal to one, obviously sequence is the same. 
Finally, if we must include 1 and $z>1$, the sequences to consider are (assuming $x<y$ and $z<x$, $z<y$, remainder cases are straightforward):
$(x+1)yz \ge xy(z+1)$ 
with no solution, thus, include first $z$ next the 1.
