a³+b³+c³-3abc
=(a³+3a²b+3ab²+b³+c³)-(3abc+3a²b+3ab²)
=[(a+b)³+c³]-3ab(a+b+c)
=(a+b+c)(a²+b²+2ab-ac-bc+c²)-3ab(a+b+c)
=(a+b+c)(a²+b²+c²+2ab-3ab-ac-bc)
=(a+b+c)(a²+b²+c²-ab-bc-ac)
a³+b³+c³-3abc
=(a³+3a²b+3ab²+b³+c³)-(3abc+3a²b+3ab²)
=[(a+b)³+c³]-3ab(a+b+c)
=(a+b+c)(a²+b²+2ab-ac-bc+c²)-3ab(a+b+c)
=(a+b+c)(a²+b²+c²+2ab-3ab-ac-bc)
=(a+b+c)(a²+b²+c²-ab-bc-ac)