Project #52138 - C++ calculator

Write a program and call it calc.cpp which is the basic calculator and receives three values from input via keyboard.
 
ï‚· The first value as an operator (Op1) should be a char type and one of (+, -, *, /, s) characters with the following meanings:
o ‘+’ for addition (num1 + num2)
o ‘-’ for subtraction (num1 - num2)
o ‘*’ for multiplication (num1 * num2)
o ‘/’ for division (num1 / num2)
o ‘s’ for swap
 
ï‚· Program should receive another two operands (Num1, Num2) which could be float or integer.
 
ï‚· The program should apply the first given operator (Op1) into the operands (Num1, Num2) and prints the relevant results with related messages in the screen.
 
ï‚· Swap operator exchanges the content (swap) of two variables, for this task you are not allowed to use any further variables (You should use just two variables to swap).

Subject Computer
Due By (Pacific Time) 12/30/2014 12:00 am
Report DMCA
TutorRating
pallavi

Chat Now!

out of 1971 reviews
More..
amosmm

Chat Now!

out of 766 reviews
More..
PhyzKyd

Chat Now!

out of 1164 reviews
More..
rajdeep77

Chat Now!

out of 721 reviews
More..
sctys

Chat Now!

out of 1600 reviews
More..
sharadgreen

Chat Now!

out of 770 reviews
More..
topnotcher

Chat Now!

out of 766 reviews
More..
XXXIAO

Chat Now!

out of 680 reviews
More..
All Rights Reserved. Copyright by AceMyHW.com - Copyright Policy