Added divide by zero checker when generating a question