+ 6
0 and 1 are the only possible outputs. Math.random() generates value between 0.0 to 1.0 And rounding it to nearest will result in either 0 or 1.
7th Oct 2020, 7:05 AM
Raj Chhatrala
Raj Chhatrala - avatar