Made denomination value a dynamic value for loop with Matt's guidance