Question: A random boolean that has a chance = p of being true

Hello,

 

I have another question. I would like to construct a code, demonstrating the loss of information when sending codewords.  Usually, one assumes that each entry of the codeword has a chance equal to p  (like p=0.17) of being incorrectly sent.  How can I have such a random element in my code?  

 

Thank you,

fredbel6

Please Wait...