Which pattern comes before? - Tossing fair coins

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
3
down vote

favorite
2












Suppose you are tossing a fair coin again and again.



The problem is: If you choose one pattern among following 8 patterns of$$HHH, HHT, HTH, THH, HTT,THT,TTH,TTT$$ where H denotes head and T denotes tail, then I can always find another pattern such that my pattern comes before your pattern with probability strictly greater than 1/2.



I could do it for $HHH$; if you choose $HHH$, then I choose $THH$. The probability of $THH$ coming before $HHH$ is greater than 1/2; unless the first three results are all $H$, which is of probability 1/8, $THH$ comes before $HHH$.



By a similar argument, I could solve it for $TTT$. However, I find it puzzling when it comes to other cases. Any good idea? Thanks and regards.



By the way, this problem is from Weighing the odds by David Williams.







share|cite|improve this question















  • 1




    Here is the numberphie video on this exact same problem.youtube.com/watch?v=Sa9jLWKrX0c
    – Piyush Divyanakar
    Jul 27 at 5:01







  • 2




    This is Penney's Game, en.wikipedia.org/wiki/Penney%27s_game See also math.stackexchange.com/questions/66670/… and math.stackexchange.com/questions/18405/… and math.stackexchange.com/questions/20468/… and math.stackexchange.com/questions/2012805/…
    – Gerry Myerson
    Jul 27 at 7:14











  • ...and mathoverflow.net/questions/306162/…
    – David G. Stork
    Jul 27 at 7:50














up vote
3
down vote

favorite
2












Suppose you are tossing a fair coin again and again.



The problem is: If you choose one pattern among following 8 patterns of$$HHH, HHT, HTH, THH, HTT,THT,TTH,TTT$$ where H denotes head and T denotes tail, then I can always find another pattern such that my pattern comes before your pattern with probability strictly greater than 1/2.



I could do it for $HHH$; if you choose $HHH$, then I choose $THH$. The probability of $THH$ coming before $HHH$ is greater than 1/2; unless the first three results are all $H$, which is of probability 1/8, $THH$ comes before $HHH$.



By a similar argument, I could solve it for $TTT$. However, I find it puzzling when it comes to other cases. Any good idea? Thanks and regards.



By the way, this problem is from Weighing the odds by David Williams.







share|cite|improve this question















  • 1




    Here is the numberphie video on this exact same problem.youtube.com/watch?v=Sa9jLWKrX0c
    – Piyush Divyanakar
    Jul 27 at 5:01







  • 2




    This is Penney's Game, en.wikipedia.org/wiki/Penney%27s_game See also math.stackexchange.com/questions/66670/… and math.stackexchange.com/questions/18405/… and math.stackexchange.com/questions/20468/… and math.stackexchange.com/questions/2012805/…
    – Gerry Myerson
    Jul 27 at 7:14











  • ...and mathoverflow.net/questions/306162/…
    – David G. Stork
    Jul 27 at 7:50












up vote
3
down vote

favorite
2









up vote
3
down vote

favorite
2






2





Suppose you are tossing a fair coin again and again.



The problem is: If you choose one pattern among following 8 patterns of$$HHH, HHT, HTH, THH, HTT,THT,TTH,TTT$$ where H denotes head and T denotes tail, then I can always find another pattern such that my pattern comes before your pattern with probability strictly greater than 1/2.



I could do it for $HHH$; if you choose $HHH$, then I choose $THH$. The probability of $THH$ coming before $HHH$ is greater than 1/2; unless the first three results are all $H$, which is of probability 1/8, $THH$ comes before $HHH$.



By a similar argument, I could solve it for $TTT$. However, I find it puzzling when it comes to other cases. Any good idea? Thanks and regards.



By the way, this problem is from Weighing the odds by David Williams.







share|cite|improve this question











Suppose you are tossing a fair coin again and again.



The problem is: If you choose one pattern among following 8 patterns of$$HHH, HHT, HTH, THH, HTT,THT,TTH,TTT$$ where H denotes head and T denotes tail, then I can always find another pattern such that my pattern comes before your pattern with probability strictly greater than 1/2.



I could do it for $HHH$; if you choose $HHH$, then I choose $THH$. The probability of $THH$ coming before $HHH$ is greater than 1/2; unless the first three results are all $H$, which is of probability 1/8, $THH$ comes before $HHH$.



By a similar argument, I could solve it for $TTT$. However, I find it puzzling when it comes to other cases. Any good idea? Thanks and regards.



By the way, this problem is from Weighing the odds by David Williams.









share|cite|improve this question










share|cite|improve this question




share|cite|improve this question









asked Jul 27 at 4:26









Mhr

3949




3949







  • 1




    Here is the numberphie video on this exact same problem.youtube.com/watch?v=Sa9jLWKrX0c
    – Piyush Divyanakar
    Jul 27 at 5:01







  • 2




    This is Penney's Game, en.wikipedia.org/wiki/Penney%27s_game See also math.stackexchange.com/questions/66670/… and math.stackexchange.com/questions/18405/… and math.stackexchange.com/questions/20468/… and math.stackexchange.com/questions/2012805/…
    – Gerry Myerson
    Jul 27 at 7:14











  • ...and mathoverflow.net/questions/306162/…
    – David G. Stork
    Jul 27 at 7:50












  • 1




    Here is the numberphie video on this exact same problem.youtube.com/watch?v=Sa9jLWKrX0c
    – Piyush Divyanakar
    Jul 27 at 5:01







  • 2




    This is Penney's Game, en.wikipedia.org/wiki/Penney%27s_game See also math.stackexchange.com/questions/66670/… and math.stackexchange.com/questions/18405/… and math.stackexchange.com/questions/20468/… and math.stackexchange.com/questions/2012805/…
    – Gerry Myerson
    Jul 27 at 7:14











  • ...and mathoverflow.net/questions/306162/…
    – David G. Stork
    Jul 27 at 7:50







1




1




Here is the numberphie video on this exact same problem.youtube.com/watch?v=Sa9jLWKrX0c
– Piyush Divyanakar
Jul 27 at 5:01





Here is the numberphie video on this exact same problem.youtube.com/watch?v=Sa9jLWKrX0c
– Piyush Divyanakar
Jul 27 at 5:01





2




2




This is Penney's Game, en.wikipedia.org/wiki/Penney%27s_game See also math.stackexchange.com/questions/66670/… and math.stackexchange.com/questions/18405/… and math.stackexchange.com/questions/20468/… and math.stackexchange.com/questions/2012805/…
– Gerry Myerson
Jul 27 at 7:14





This is Penney's Game, en.wikipedia.org/wiki/Penney%27s_game See also math.stackexchange.com/questions/66670/… and math.stackexchange.com/questions/18405/… and math.stackexchange.com/questions/20468/… and math.stackexchange.com/questions/2012805/…
– Gerry Myerson
Jul 27 at 7:14













...and mathoverflow.net/questions/306162/…
– David G. Stork
Jul 27 at 7:50




...and mathoverflow.net/questions/306162/…
– David G. Stork
Jul 27 at 7:50










2 Answers
2






active

oldest

votes

















up vote
3
down vote



accepted










You can do the same thing for $HHT$ (and likewise for $TTH$) as you did for $HHH$. If I choose $HHT$, choose $THH$; unless the first two results are both $H$, with probability $frac14$, $THH$ comes before $HHT$.



More generally, you want the longest prefix of mine to be a suffix of yours and the shortest possible suffix of mine to be a prefix of yours.



So if I choose $HTT$, you want $HT$ as a suffix and neither $TT$ nor $T$ as a prefix, so you choose $HHT$. If I choose $HTH$, you want $HT$ as a suffix and ideally neither $TH$ nor $H$ as a prefix; since you can't avoid both, you avoid the longer one, $TH$, and again choose $HHT$.



To calculate the winning probabilities in these cases, label the possible non-terminal states according to the two most recent results, and note that since both our patterns start with $H$, the initial state is equivalent to $TT$. From this state, we get back to the same state as long as we get $T$, so at some point we end up in the state $TH$. Now consider the next two results:



  • With probability $frac14$ we immediately get my pattern.

  • With probability $frac14$ we immediately get your pattern.

  • With probability $frac14$ we get $HH$ and then eventually get your pattern.

  • With probability $frac14$ we get the remaining possibility ($TH$ in the first case, $TT$ in the second case) and either immediately or eventually return to the state $TH$.

Thus, every time we reach the state $TH$, you have twice my chance of winning, so you win with probability $frac23$ and I win with probability $frac13$.



By the way, note that this shows that not only the winning probability but also the expected duration of the game depends on the patterns. The only difference between the two cases was that if I choose $HTT$ and you choose $HHT$, we immediately return to $TH$ in the fourth option, whereas if I choose $HTH$ and you choose $HHT$, we eventually return to $TH$ after first reaching $TT$, so the expected duration of the game is longer in the second case.






share|cite|improve this answer























  • "you want ... the shortest possible suffix of mine to be a prefix of yours"? But if "mine" is $HHH$ you want "your" prefix to be $T,$ which is not a suffix of "mine".
    – David K
    Jul 27 at 11:52










  • @DavidK: Exactly. The shortest possible suffix is the zero-length suffix. More formally stated: "You" want the maximal $k$ such that "my" suffix of length $k$ is a prefix of "yours" to be as small as possible, ideally $k=0$. As the example of choosing $HHT$ when "I" choose $HTH$ shows, it's not always possible to achieve $k=0$ while also having the longest prefix of "mine" as a suffix of "yours".
    – joriki
    Jul 27 at 12:35







  • 1




    Aha. You want to minimize $n$ such that the last $n$ letters in your sequence is the same as the first $n$ letter of mine. That actually is the logical way to interpret what you wrote, I just had trouble parsing it.
    – David K
    Jul 27 at 12:42











  • @DavidK: I admit that I was perhaps overly prioritizing succinctness over clarity :-)
    – joriki
    Jul 27 at 12:48

















up vote
2
down vote













From here:



An easy way to remember the sequence for using as a bar trick is for the second player to start with the opposite of the middle choice of the first player, then follow it with the first player's first two choices.



So for the first player's choice of 1-2-3
the second player must choose (not-2)-1-2
where (not-2) is the opposite of the second choice of the first player.1



An intuitive explanation for this result, is that in any case that the sequence is not immediately the first player's choice, the chances for the first player getting their sequence-beginning, the opening two choices, are usually the chance that the second player will be getting their full sequence. So the second player will most likely "finish before" the first player.1






share|cite|improve this answer





















    Your Answer




    StackExchange.ifUsing("editor", function ()
    return StackExchange.using("mathjaxEditing", function ()
    StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix)
    StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
    );
    );
    , "mathjax-editing");

    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "69"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    convertImagesToLinks: true,
    noModals: false,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    noCode: true, onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );








     

    draft saved


    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f2864051%2fwhich-pattern-comes-before-tossing-fair-coins%23new-answer', 'question_page');

    );

    Post as a guest






























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    3
    down vote



    accepted










    You can do the same thing for $HHT$ (and likewise for $TTH$) as you did for $HHH$. If I choose $HHT$, choose $THH$; unless the first two results are both $H$, with probability $frac14$, $THH$ comes before $HHT$.



    More generally, you want the longest prefix of mine to be a suffix of yours and the shortest possible suffix of mine to be a prefix of yours.



    So if I choose $HTT$, you want $HT$ as a suffix and neither $TT$ nor $T$ as a prefix, so you choose $HHT$. If I choose $HTH$, you want $HT$ as a suffix and ideally neither $TH$ nor $H$ as a prefix; since you can't avoid both, you avoid the longer one, $TH$, and again choose $HHT$.



    To calculate the winning probabilities in these cases, label the possible non-terminal states according to the two most recent results, and note that since both our patterns start with $H$, the initial state is equivalent to $TT$. From this state, we get back to the same state as long as we get $T$, so at some point we end up in the state $TH$. Now consider the next two results:



    • With probability $frac14$ we immediately get my pattern.

    • With probability $frac14$ we immediately get your pattern.

    • With probability $frac14$ we get $HH$ and then eventually get your pattern.

    • With probability $frac14$ we get the remaining possibility ($TH$ in the first case, $TT$ in the second case) and either immediately or eventually return to the state $TH$.

    Thus, every time we reach the state $TH$, you have twice my chance of winning, so you win with probability $frac23$ and I win with probability $frac13$.



    By the way, note that this shows that not only the winning probability but also the expected duration of the game depends on the patterns. The only difference between the two cases was that if I choose $HTT$ and you choose $HHT$, we immediately return to $TH$ in the fourth option, whereas if I choose $HTH$ and you choose $HHT$, we eventually return to $TH$ after first reaching $TT$, so the expected duration of the game is longer in the second case.






    share|cite|improve this answer























    • "you want ... the shortest possible suffix of mine to be a prefix of yours"? But if "mine" is $HHH$ you want "your" prefix to be $T,$ which is not a suffix of "mine".
      – David K
      Jul 27 at 11:52










    • @DavidK: Exactly. The shortest possible suffix is the zero-length suffix. More formally stated: "You" want the maximal $k$ such that "my" suffix of length $k$ is a prefix of "yours" to be as small as possible, ideally $k=0$. As the example of choosing $HHT$ when "I" choose $HTH$ shows, it's not always possible to achieve $k=0$ while also having the longest prefix of "mine" as a suffix of "yours".
      – joriki
      Jul 27 at 12:35







    • 1




      Aha. You want to minimize $n$ such that the last $n$ letters in your sequence is the same as the first $n$ letter of mine. That actually is the logical way to interpret what you wrote, I just had trouble parsing it.
      – David K
      Jul 27 at 12:42











    • @DavidK: I admit that I was perhaps overly prioritizing succinctness over clarity :-)
      – joriki
      Jul 27 at 12:48














    up vote
    3
    down vote



    accepted










    You can do the same thing for $HHT$ (and likewise for $TTH$) as you did for $HHH$. If I choose $HHT$, choose $THH$; unless the first two results are both $H$, with probability $frac14$, $THH$ comes before $HHT$.



    More generally, you want the longest prefix of mine to be a suffix of yours and the shortest possible suffix of mine to be a prefix of yours.



    So if I choose $HTT$, you want $HT$ as a suffix and neither $TT$ nor $T$ as a prefix, so you choose $HHT$. If I choose $HTH$, you want $HT$ as a suffix and ideally neither $TH$ nor $H$ as a prefix; since you can't avoid both, you avoid the longer one, $TH$, and again choose $HHT$.



    To calculate the winning probabilities in these cases, label the possible non-terminal states according to the two most recent results, and note that since both our patterns start with $H$, the initial state is equivalent to $TT$. From this state, we get back to the same state as long as we get $T$, so at some point we end up in the state $TH$. Now consider the next two results:



    • With probability $frac14$ we immediately get my pattern.

    • With probability $frac14$ we immediately get your pattern.

    • With probability $frac14$ we get $HH$ and then eventually get your pattern.

    • With probability $frac14$ we get the remaining possibility ($TH$ in the first case, $TT$ in the second case) and either immediately or eventually return to the state $TH$.

    Thus, every time we reach the state $TH$, you have twice my chance of winning, so you win with probability $frac23$ and I win with probability $frac13$.



    By the way, note that this shows that not only the winning probability but also the expected duration of the game depends on the patterns. The only difference between the two cases was that if I choose $HTT$ and you choose $HHT$, we immediately return to $TH$ in the fourth option, whereas if I choose $HTH$ and you choose $HHT$, we eventually return to $TH$ after first reaching $TT$, so the expected duration of the game is longer in the second case.






    share|cite|improve this answer























    • "you want ... the shortest possible suffix of mine to be a prefix of yours"? But if "mine" is $HHH$ you want "your" prefix to be $T,$ which is not a suffix of "mine".
      – David K
      Jul 27 at 11:52










    • @DavidK: Exactly. The shortest possible suffix is the zero-length suffix. More formally stated: "You" want the maximal $k$ such that "my" suffix of length $k$ is a prefix of "yours" to be as small as possible, ideally $k=0$. As the example of choosing $HHT$ when "I" choose $HTH$ shows, it's not always possible to achieve $k=0$ while also having the longest prefix of "mine" as a suffix of "yours".
      – joriki
      Jul 27 at 12:35







    • 1




      Aha. You want to minimize $n$ such that the last $n$ letters in your sequence is the same as the first $n$ letter of mine. That actually is the logical way to interpret what you wrote, I just had trouble parsing it.
      – David K
      Jul 27 at 12:42











    • @DavidK: I admit that I was perhaps overly prioritizing succinctness over clarity :-)
      – joriki
      Jul 27 at 12:48












    up vote
    3
    down vote



    accepted







    up vote
    3
    down vote



    accepted






    You can do the same thing for $HHT$ (and likewise for $TTH$) as you did for $HHH$. If I choose $HHT$, choose $THH$; unless the first two results are both $H$, with probability $frac14$, $THH$ comes before $HHT$.



    More generally, you want the longest prefix of mine to be a suffix of yours and the shortest possible suffix of mine to be a prefix of yours.



    So if I choose $HTT$, you want $HT$ as a suffix and neither $TT$ nor $T$ as a prefix, so you choose $HHT$. If I choose $HTH$, you want $HT$ as a suffix and ideally neither $TH$ nor $H$ as a prefix; since you can't avoid both, you avoid the longer one, $TH$, and again choose $HHT$.



    To calculate the winning probabilities in these cases, label the possible non-terminal states according to the two most recent results, and note that since both our patterns start with $H$, the initial state is equivalent to $TT$. From this state, we get back to the same state as long as we get $T$, so at some point we end up in the state $TH$. Now consider the next two results:



    • With probability $frac14$ we immediately get my pattern.

    • With probability $frac14$ we immediately get your pattern.

    • With probability $frac14$ we get $HH$ and then eventually get your pattern.

    • With probability $frac14$ we get the remaining possibility ($TH$ in the first case, $TT$ in the second case) and either immediately or eventually return to the state $TH$.

    Thus, every time we reach the state $TH$, you have twice my chance of winning, so you win with probability $frac23$ and I win with probability $frac13$.



    By the way, note that this shows that not only the winning probability but also the expected duration of the game depends on the patterns. The only difference between the two cases was that if I choose $HTT$ and you choose $HHT$, we immediately return to $TH$ in the fourth option, whereas if I choose $HTH$ and you choose $HHT$, we eventually return to $TH$ after first reaching $TT$, so the expected duration of the game is longer in the second case.






    share|cite|improve this answer















    You can do the same thing for $HHT$ (and likewise for $TTH$) as you did for $HHH$. If I choose $HHT$, choose $THH$; unless the first two results are both $H$, with probability $frac14$, $THH$ comes before $HHT$.



    More generally, you want the longest prefix of mine to be a suffix of yours and the shortest possible suffix of mine to be a prefix of yours.



    So if I choose $HTT$, you want $HT$ as a suffix and neither $TT$ nor $T$ as a prefix, so you choose $HHT$. If I choose $HTH$, you want $HT$ as a suffix and ideally neither $TH$ nor $H$ as a prefix; since you can't avoid both, you avoid the longer one, $TH$, and again choose $HHT$.



    To calculate the winning probabilities in these cases, label the possible non-terminal states according to the two most recent results, and note that since both our patterns start with $H$, the initial state is equivalent to $TT$. From this state, we get back to the same state as long as we get $T$, so at some point we end up in the state $TH$. Now consider the next two results:



    • With probability $frac14$ we immediately get my pattern.

    • With probability $frac14$ we immediately get your pattern.

    • With probability $frac14$ we get $HH$ and then eventually get your pattern.

    • With probability $frac14$ we get the remaining possibility ($TH$ in the first case, $TT$ in the second case) and either immediately or eventually return to the state $TH$.

    Thus, every time we reach the state $TH$, you have twice my chance of winning, so you win with probability $frac23$ and I win with probability $frac13$.



    By the way, note that this shows that not only the winning probability but also the expected duration of the game depends on the patterns. The only difference between the two cases was that if I choose $HTT$ and you choose $HHT$, we immediately return to $TH$ in the fourth option, whereas if I choose $HTH$ and you choose $HHT$, we eventually return to $TH$ after first reaching $TT$, so the expected duration of the game is longer in the second case.







    share|cite|improve this answer















    share|cite|improve this answer



    share|cite|improve this answer








    edited Jul 27 at 8:29


























    answered Jul 27 at 6:04









    joriki

    164k10179328




    164k10179328











    • "you want ... the shortest possible suffix of mine to be a prefix of yours"? But if "mine" is $HHH$ you want "your" prefix to be $T,$ which is not a suffix of "mine".
      – David K
      Jul 27 at 11:52










    • @DavidK: Exactly. The shortest possible suffix is the zero-length suffix. More formally stated: "You" want the maximal $k$ such that "my" suffix of length $k$ is a prefix of "yours" to be as small as possible, ideally $k=0$. As the example of choosing $HHT$ when "I" choose $HTH$ shows, it's not always possible to achieve $k=0$ while also having the longest prefix of "mine" as a suffix of "yours".
      – joriki
      Jul 27 at 12:35







    • 1




      Aha. You want to minimize $n$ such that the last $n$ letters in your sequence is the same as the first $n$ letter of mine. That actually is the logical way to interpret what you wrote, I just had trouble parsing it.
      – David K
      Jul 27 at 12:42











    • @DavidK: I admit that I was perhaps overly prioritizing succinctness over clarity :-)
      – joriki
      Jul 27 at 12:48
















    • "you want ... the shortest possible suffix of mine to be a prefix of yours"? But if "mine" is $HHH$ you want "your" prefix to be $T,$ which is not a suffix of "mine".
      – David K
      Jul 27 at 11:52










    • @DavidK: Exactly. The shortest possible suffix is the zero-length suffix. More formally stated: "You" want the maximal $k$ such that "my" suffix of length $k$ is a prefix of "yours" to be as small as possible, ideally $k=0$. As the example of choosing $HHT$ when "I" choose $HTH$ shows, it's not always possible to achieve $k=0$ while also having the longest prefix of "mine" as a suffix of "yours".
      – joriki
      Jul 27 at 12:35







    • 1




      Aha. You want to minimize $n$ such that the last $n$ letters in your sequence is the same as the first $n$ letter of mine. That actually is the logical way to interpret what you wrote, I just had trouble parsing it.
      – David K
      Jul 27 at 12:42











    • @DavidK: I admit that I was perhaps overly prioritizing succinctness over clarity :-)
      – joriki
      Jul 27 at 12:48















    "you want ... the shortest possible suffix of mine to be a prefix of yours"? But if "mine" is $HHH$ you want "your" prefix to be $T,$ which is not a suffix of "mine".
    – David K
    Jul 27 at 11:52




    "you want ... the shortest possible suffix of mine to be a prefix of yours"? But if "mine" is $HHH$ you want "your" prefix to be $T,$ which is not a suffix of "mine".
    – David K
    Jul 27 at 11:52












    @DavidK: Exactly. The shortest possible suffix is the zero-length suffix. More formally stated: "You" want the maximal $k$ such that "my" suffix of length $k$ is a prefix of "yours" to be as small as possible, ideally $k=0$. As the example of choosing $HHT$ when "I" choose $HTH$ shows, it's not always possible to achieve $k=0$ while also having the longest prefix of "mine" as a suffix of "yours".
    – joriki
    Jul 27 at 12:35





    @DavidK: Exactly. The shortest possible suffix is the zero-length suffix. More formally stated: "You" want the maximal $k$ such that "my" suffix of length $k$ is a prefix of "yours" to be as small as possible, ideally $k=0$. As the example of choosing $HHT$ when "I" choose $HTH$ shows, it's not always possible to achieve $k=0$ while also having the longest prefix of "mine" as a suffix of "yours".
    – joriki
    Jul 27 at 12:35





    1




    1




    Aha. You want to minimize $n$ such that the last $n$ letters in your sequence is the same as the first $n$ letter of mine. That actually is the logical way to interpret what you wrote, I just had trouble parsing it.
    – David K
    Jul 27 at 12:42





    Aha. You want to minimize $n$ such that the last $n$ letters in your sequence is the same as the first $n$ letter of mine. That actually is the logical way to interpret what you wrote, I just had trouble parsing it.
    – David K
    Jul 27 at 12:42













    @DavidK: I admit that I was perhaps overly prioritizing succinctness over clarity :-)
    – joriki
    Jul 27 at 12:48




    @DavidK: I admit that I was perhaps overly prioritizing succinctness over clarity :-)
    – joriki
    Jul 27 at 12:48










    up vote
    2
    down vote













    From here:



    An easy way to remember the sequence for using as a bar trick is for the second player to start with the opposite of the middle choice of the first player, then follow it with the first player's first two choices.



    So for the first player's choice of 1-2-3
    the second player must choose (not-2)-1-2
    where (not-2) is the opposite of the second choice of the first player.1



    An intuitive explanation for this result, is that in any case that the sequence is not immediately the first player's choice, the chances for the first player getting their sequence-beginning, the opening two choices, are usually the chance that the second player will be getting their full sequence. So the second player will most likely "finish before" the first player.1






    share|cite|improve this answer

























      up vote
      2
      down vote













      From here:



      An easy way to remember the sequence for using as a bar trick is for the second player to start with the opposite of the middle choice of the first player, then follow it with the first player's first two choices.



      So for the first player's choice of 1-2-3
      the second player must choose (not-2)-1-2
      where (not-2) is the opposite of the second choice of the first player.1



      An intuitive explanation for this result, is that in any case that the sequence is not immediately the first player's choice, the chances for the first player getting their sequence-beginning, the opening two choices, are usually the chance that the second player will be getting their full sequence. So the second player will most likely "finish before" the first player.1






      share|cite|improve this answer























        up vote
        2
        down vote










        up vote
        2
        down vote









        From here:



        An easy way to remember the sequence for using as a bar trick is for the second player to start with the opposite of the middle choice of the first player, then follow it with the first player's first two choices.



        So for the first player's choice of 1-2-3
        the second player must choose (not-2)-1-2
        where (not-2) is the opposite of the second choice of the first player.1



        An intuitive explanation for this result, is that in any case that the sequence is not immediately the first player's choice, the chances for the first player getting their sequence-beginning, the opening two choices, are usually the chance that the second player will be getting their full sequence. So the second player will most likely "finish before" the first player.1






        share|cite|improve this answer













        From here:



        An easy way to remember the sequence for using as a bar trick is for the second player to start with the opposite of the middle choice of the first player, then follow it with the first player's first two choices.



        So for the first player's choice of 1-2-3
        the second player must choose (not-2)-1-2
        where (not-2) is the opposite of the second choice of the first player.1



        An intuitive explanation for this result, is that in any case that the sequence is not immediately the first player's choice, the chances for the first player getting their sequence-beginning, the opening two choices, are usually the chance that the second player will be getting their full sequence. So the second player will most likely "finish before" the first player.1







        share|cite|improve this answer













        share|cite|improve this answer



        share|cite|improve this answer











        answered Jul 27 at 7:48









        David G. Stork

        7,4532829




        7,4532829






















             

            draft saved


            draft discarded


























             


            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f2864051%2fwhich-pattern-comes-before-tossing-fair-coins%23new-answer', 'question_page');

            );

            Post as a guest













































































            Comments

            Popular posts from this blog

            What is the equation of a 3D cone with generalised tilt?

            Color the edges and diagonals of a regular polygon

            Relationship between determinant of matrix and determinant of adjoint?