Anyone for tennis? Your chances of winning a tie-break game - MATLAB Cody - MATLAB Central

Problem 44503. Anyone for tennis? Your chances of winning a tie-break game

Difficulty:Rate

Imagine you are playing tennis and the score has reached 'six games all' in a Tie-break Set, so therefore the next game shall be a 'tie-break game', which is now to be played to decide the outcome of this set. For each point played in the tie-break game your chance of winning is x % (input as a uint8). Given the ITF's scoring system for a "tie-break game" of tennis (excerpted below), please determine your likelihood of winning the tie-break game (output as a single).

Note that as x is taken to be the same for every point in this problem, it does not matter whether you are serving or not.

EXAMPLE

 x = uint8(40)
 chance = single(0.2125443387076924)

-----

" During a tie-break game, points are scored “Zero”, “1”, “2”, “3”, etc. The first player/team to win seven points wins the “Game” and “Set”, provided there is a margin of two points over the opponent(s). If necessary, the tie-break game shall continue until this margin is achieved. "

-----

See also Problem 44502. Anyone for tennis? Your chances of winning a (standard) game.

Solution Stats

13.95% Correct | 86.05% Incorrect
Last Solution submitted on Oct 03, 2023

Problem Comments

Solution Comments

Show comments

Problem Recent Solvers4

Suggested Problems

More from this Author32

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Go to top of page