I need to create a Java method to return true or false randomly. How can I do this?
true
false
(Math.random() < 0.5) returns true or false randomly
(Math.random() < 0.5)