結果 : how to find max and min of a function with derivatives