(x+y+z)^6= 1*(x^6+y^6+x^6)+6*(x^5*y+y^5*z+z^5*x)+15*(x^4*y^2+y^4*z^2+z^4*x^2)+20*(x^3*y^3+y^3*x^3+z^3*x^3)+15*(x^2*y^4+y^2*z^4+z^2*x^4)+6*(x*y^5+y*z^5+z*x^5); аналогично для (x+y+z+u)^5 = 1*(x^5+y^5+z^5+u^5)+5*(x^4*y+y^4*z+z^4*u+u^4*x)+10*(x^3*y^2+y^3*z^2+z^3*u^2+u^3*x^2) + 10*(x^2*y^3+y^2*z^3+z^2*u^3+u^2*x^3)+5*(x*y^4+y*z^4+z*u^4+u*x^4)
(x+y+z)^6= 1*(x^6+y^6+x^6)+6*(x^5*y+y^5*z+z^5*x)+15*(x^4*y^2+y^4*z^2+z^4*x^2)+20*(x^3*y^3+y^3*x^3+z^3*x^3)+15*(x^2*y^4+y^2*z^4+z^2*x^4)+6*(x*y^5+y*z^5+z*x^5); аналогично для (x+y+z+u)^5 = 1*(x^5+y^5+z^5+u^5)+5*(x^4*y+y^4*z+z^4*u+u^4*x)+10*(x^3*y^2+y^3*z^2+z^3*u^2+u^3*x^2) + 10*(x^2*y^3+y^2*z^3+z^2*u^3+u^2*x^3)+5*(x*y^4+y*z^4+z*u^4+u*x^4)