how to create a calculator