Coding

Longest Run of Heads

Series: Code Challenges

If we toss a coin 1000 times and get that the largest number of heads in a row was 6, is this a fair coin? What is the expected number of tosses to get a longest run of heads of 6?