mercredi 26 octobre 2016

I want to return a value of true or false but force it to randomly return false 3% of the time [duplicate]

This question already has an answer here:

From user input of either char a or char b as an answer. I want to return a value of true or false from user input. Then count the number of selections between two possibilities per individual user input. Then force it to randomly return false 3% of the time. The purpose is to alter the expected outcome with a reward.

How do I go about doing this? I am new to this concept.

Aucun commentaire:

Enregistrer un commentaire