2018-09-30 22:01:58 +00:00
---
id: 5900f48a1000cf542c50ff9d
title: 'Problem 286: Scoring probabilities'
2020-11-27 18:02:05 +00:00
challengeType: 5
2019-08-05 16:17:33 +00:00
forumTopicId: 301937
2021-01-13 02:31:00 +00:00
dashedName: problem-286-scoring-probabilities
2018-09-30 22:01:58 +00:00
---
2020-11-27 18:02:05 +00:00
# --description--
2018-09-30 22:01:58 +00:00
2021-07-22 03:38:46 +00:00
Barbara is a mathematician and a basketball player. She has found that the probability of scoring a point when shooting from a distance $x$ is exactly ($1 - \frac{x}{q}$), where $q$ is a real constant greater than 50.
2018-09-30 22:01:58 +00:00
2021-07-22 03:38:46 +00:00
During each practice run, she takes shots from distances $x = 1, x = 2, \ldots, x = 50$ and, according to her records, she has precisely a 2 % chance to score a total of exactly 20 points.
2018-09-30 22:01:58 +00:00
2021-07-22 03:38:46 +00:00
Find $q$ and give your answer rounded to 10 decimal places.
2018-09-30 22:01:58 +00:00
2020-11-27 18:02:05 +00:00
# --hints--
2018-09-30 22:01:58 +00:00
2021-07-22 03:38:46 +00:00
`scoringProbabilities()` should return `52.6494571953` .
2018-09-30 22:01:58 +00:00
2020-11-27 18:02:05 +00:00
```js
2021-07-22 03:38:46 +00:00
assert.strictEqual(scoringProbabilities(), 52.6494571953);
2018-09-30 22:01:58 +00:00
```
2020-11-27 18:02:05 +00:00
# --seed--
2018-09-30 22:01:58 +00:00
2020-11-27 18:02:05 +00:00
## --seed-contents--
2018-09-30 22:01:58 +00:00
```js
2021-07-22 03:38:46 +00:00
function scoringProbabilities() {
2020-09-15 16:57:40 +00:00
2018-09-30 22:01:58 +00:00
return true;
}
2021-07-22 03:38:46 +00:00
scoringProbabilities();
2018-09-30 22:01:58 +00:00
```
2020-11-27 18:02:05 +00:00
# --solutions--
2018-09-30 22:01:58 +00:00
```js
// solution required
```