We should probably break out these stanzas to methods so that the code in this method operates at the same level of abstraction.