The original problem

sin^3x+cos^3x

---------------- = 1-sinxcosx

sinx+cosx

Now I have this awesome book that tells how to do the problems step by step but it doesn't do a very good job of explaining how it went from step 1 to step 2. For example the book gives me

sinx^3+cosx^3 _ _ (sinx+cosx)(sinx^2-sinxcosx+cosx^2)

--------------- = ------------------------------------ = ... = 1-sinxcosx

sinx+cosx _ _ _ _ _ _ _ _ _ sinx+cosx

SO my question is how do you get (sinx^2-sinxcosx+cosx^2) from factoring (sinx+cosx) out of (sinx^3+cox^3).

Oh and the _ _ _ _ _ _ _ _ _ is where spaces would be if the forum didn't cut out multiple spaces