I can\'t figure out how to use switches in combination with an enum. Could you please tell me what I\'m doing wrong, and how to fix it? I have to use an enum to make a basic
All the other answers are correct, but you also need to call your method correctly:
Calculate(5, 5, Operator.PLUS))
And since you use int for left and right, the result will be int as well (3/2 will result in 1). you could cast to double before calculating the result or modify your parameters to accept double