Files
freeCodeCamp/curriculum/challenges/chinese/10-coding-interview-prep/project-euler/problem-286-scoring-probabilities.chinese.md
Oliver Eyton-Williams 61460c8601 fix: insert blank line after ```
search and replace ```\n< with ```\n\n< to ensure there's an empty line
before closing tags
2020-08-16 04:45:20 +05:30

1.1 KiB
Raw Blame History

id, challengeType, title, videoUrl, localeTitle
id challengeType title videoUrl localeTitle
5900f48a1000cf542c50ff9d 5 Problem 286: Scoring probabilities 问题286计分概率

Description

447/5000 芭芭拉Barbara是数学家和篮球运动员。 她发现从距离x射击时给一个点评分的概率正好是1 -x / q其中q是大于50的实常数。

在每次练习中她从x = 1x = 2...x = 50的距离射击并且根据她的记录她恰好有2的机会总得分为20分。

找出q并将答案四舍五入到小数点后十位。

Instructions

Tests

tests:
  - text: <code>euler286()</code>应该返回52.6494571953。
    testString: assert.strictEqual(euler286(), 52.6494571953);

Challenge Seed

function euler286() {
  // Good luck!
  return true;
}

euler286();

Solution

// solution required

/section>