Why Did God Command the Destruction of the Canaanites?

A fair question. So what is the answer?