4th refactor - removed need to thisAmount variable inside statement() and replaced with call to function