Suppose that you are to play a series of $n$ games of tennis, from which you are eligible to win a prize if you win any $r < n$ consecutive games in the series. The probability of you winning a match, given that you serve, is $p_1$, and it is $p_2$ if you don't serve. Here, $p_1 > p_2$. (Note that $p_1 + p_2 \neq 1$).If you serve in the first game, you don't serve in the second game, but you serve in third game, and so on. To maximise the probability of you winning the prize, how should you choose to play the series? Should you choose to serve first?
My initial guess is that whenever $n$ is even, your choice does not matter since the sequence of the games is symmetric irrespective of your decision to serve in the first match. For the case of odd $n$, consider when $n=3$ and $r=2$. In this scenario it is beneficial to start the series letting the opponent serve, to ensure that you get to serve in the 2nd match, and it is crucial to win the 2nd match to have a streak of 2 matches in any case. Mathematically,
$$\text{Pr(Win | Serve)} = p_1p_2 + (1-p_1)p_2 p_1 $$ $$ = (2 - p_1)p_1p_2 $$
Since you either win the first two games, or loose the first one and win the other two. Similarly, $$\text{Pr(Win | Don't Serve)} = p_2p_1 + (1-p_2)p_1 p_2 $$ $$ = (2 - p_2)p_1p_2 $$
And it is clear that $2 - p_1 < 2 - p_2$.
However, I am unable to generalise this result for general $n$ and $r$. I tried to extend my reasoning using induction on $n$ but couldn't really get anywhere.
As you guessed and lulu elaborated in a comment, a symmetry argument shows that if $n$ is even it doesn’t matter who serves first.
For $n$ odd, you can use a similar argument to the one you used for $n=3$ and $r=2$ to show that it’s better not to serve first if $r$ is even but to serve first if $r$ is odd.
Consider first $r$ even (of which your $r=2$ is a special case). We can treat $n-1$ games as a group and add an $n$-th game either with serve to one end of the group or without serve to the other end:
$$ (+)-+-+-+\,(-)\;, $$
where I denoted serving by $+$ and not serving by $-$ and marked the two possible $n$-th games at the ends with parentheses. If we win using only the $n-1$ games, it doesn’t matter where we add the $n$-th one. So we can concentrate on the case where we don’t win using only the $n-1$ games, but we do win when we add the $n$-th game. I’ll mark the corresponding wins ($\checkmark$) and losses ($\times$) above the games for the game added at the right and below the games for the game added at the left:
$$ \;\;\;?\;\,?\;\,?\;\,?\,\times\,\checkmark\;\checkmark\\ (+)-+-+-+\,(-)\;.\\ \,\checkmark\;\checkmark\;\times\,\;?\;\,?\;\,?\;\,?\quad\quad $$
The question marks represent some sequence of results that doesn’t include a run of $r$ wins. The diagram is for $r=2$, but the argument works for any even $r$. Note that (up to symmetry) the question marks have the same sequence of serves in both cases, so the probability that they don’t include a winning run is the same. The wins likewise have the same probability by symmetry. Only the losses differ: on the right/top, the loss is in a game where we don’t serve, and on the left/bottom it’s in a game where we serve. Since the loss is more likely when we don’t serve, the case on the right is more favourable; so we should choose not to serve in the first and last games.
Now for odd $r$. Here’s the corresponding diagram for $r=3$:
$$ \;\;\;?\;\,?\;\,?\;\times\,\checkmark\,\checkmark\;\checkmark\\ (+)-+-+-+\,(-)\;.\\ \,\checkmark\;\checkmark\;\checkmark\;\times\,\;?\;\,?\;\,?\quad\quad $$
Now the situation is a bit more complicated. The loss now favours the left/bottom. The wins are no longer the same in both cases, and they also favour the left/bottom, since there’s one more $+$ there. And the question marks are also no longer the same. Here we can use induction over $n$. For $n\lt r$, there are no potential winning runs, so it doesn’t matter who serves first. For $n=r$, there’s only one potential winning run, so we should clearly serve first. Those are the base cases for the induction. Now assume that for all odd $n'\lt n$ serving first is at least as good as not serving first. Then the question marks are at least as good on the left/bottom as on the right/top. Since the loss and the wins favour the left/bottom, it follows that serving first is better also for $n$.