Changed allocation of inputs to be on the heap rather than the stack. Also took out lots of print statements.