Find the maximum and minimum values of f(x,y,z)=x+4y+5z on the sphere x^2+y^2+z^2=1.

You need to use the method of Lagrange multipliers. It is explained here:

http://en.wikipedia.org/wiki/Lagrange_multipliers