Hi, I work as an Actuary and love statistics (and blackjack). There's a blackjack-related problem that I've been trying to wrap my head around, but I can't quite figure it out.

Thanks in advance!

To make the math easier (even though they're not perfectly accurate), here are a few assumptions:

-Assume that the probability of winning a hand of blackjack is .5.
-Also assume that all bets placed are the same size (1 unit bets).
-An example of "going up" 2 hands in any given series would be WLWW or WW or LWWW (wins and losses cancel out).
-Similarly, an example of "going down" 3 hands in a given series would be LLL or WLWLLLL or LWLLL.

Question: In any given series of hands dealt, what is the probability of going up 5 hands before going down 10 hands? Or, a similar question, what's the probability of going up 3 hands before going down 5 hands? This is similar to a geometric distribution but the solution is slightly different. I'm looking for a formula that can be applied to any scenario of "going up" x hands before "going down" y hands.

Any thoughts?