Reverse mathematics and the equivalence of definitions for well and better quasi-orders