How to randomise the characters '+' and '-' in java
问题 I'm coding an arithmetic game where the user is asked a series of addition questions. I want to however randomly assign an operator for each question so that the question could be either: Question 1: num1 + num2 = or Question 2: num1 - num2 = I have been using the Math.random() method to randomise num1 and num2 the last thing I am struggling on is randomly generating '+' and '-'. Is it something to do with the ASCII values of these two characters and then I can randomly pick between them?