Adding machine factorizations and iterations of quadratic polynomials