Algorithm to solve a tangram

yes, I did.