change math problem dynamically works