A number is called algebraic if there is a polynomial with rational coefficients for which the number is a root. For example,√2 is algebraic because it is a root of the polynomial x^2−2. The number √2+√3+√5 is also algebraic because it is a root of a monic polynomial of degree 8, namely x^8+ax^7+bx^6+cx^5+dx^4+ex^3+fx^2+gx+h. Find |a|+|b|+|c|+|d|+|e|+|f|+|g|+|h|.

If the coefficients are all rational, then the irrational roots must occur in conjugate pairs. So, the polynomial is

(x-(√2+√3+√5))
(x-(√2+√3-√5))
(x-(√2-√3+√5))
(x-(√2-√3-√5))
(x-(-√2+√3+√5))
(x-(-√2+√3-√5))
(x-(-√2-√3+√5))
(x-(-√2-√3-√5))

x^8 - 40x^6 + 352x^4 - 960x^2 + 576