Declare variable types for non-string parameters 'container' and 'duration'.