added more functionality to calculator.js