How do you make a calculator app in Xcode calculate negative numbers? What code would i use in Xcode to allow negative numbers to work with a calculator app? Whenever I test it and use a negative number, I get a really off percent then if i were to use a positive number.