Fixed the output issue w/ Joe's help and a handy dandy higher order function.