Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

Basic algorithms 101 : Coin toss (unbiased and biased)

Welcome to the first post of the new Series “simple algorithms”. In this series we will be dealing with simple to understand programming algorithms. If you are a beginner at programming or aspiring to be a programmer, this series is meant for you.  For convenience we will be taking python as an example for the code.
In this first post, will be dealing with a very simple algorithm which is “The Coin Toss algorithm”. In case you don’t know a coin has two sides, a head and a tail. When you flip it, the outcome is either a head or a tail.  As you can see, there are only two cases. So that makes it very easy.  Some people might want to know the algorithm for a biased coin. So we will be looking at that too. The biased one is slightly trickier than the unbiased one. First, let’s look at the unbiased and then get to the biased coin.  So without any further ado, let’s just get right into it.
Read more »


This post first appeared on TECKGUIDE, please read the originial post: here

Share the post

Basic algorithms 101 : Coin toss (unbiased and biased)

×

Subscribe to Teckguide

Get updates delivered right to your inbox!

Thank you for your subscription

×