-
Notifications
You must be signed in to change notification settings - Fork 0
/
task.html
12 lines (12 loc) · 1.1 KB
/
task.html
1
2
3
4
5
6
7
8
9
10
11
12
<b>The average of all numbers</b> <a class=right href="https://hyperskill.org/learn/step/6071">Open on JetBrains Academy</a>
<br><br>
<html>
<head></head>
<body>
<p>Write the code that reads 2 numbers from the keyboard, <em>a</em> and <em>b</em>. As an output, it shows the mean of all numbers that lie on the interval between <em>a</em> and <em>b,</em> and can be divided by 3. </p>
<p>What does it mean? In the example, you are to calculate the mean of the numbers in the range <span class="math-tex">\( [-5; 12] \)</span></p>
<p>The numbers divided by 3 without the remainder are: <span class="math-tex">\( -3, 0, 3, 6, 9, 12 \)</span>. There are six of them, and the mean is 4.5.</p>
<p>The input interval always contains at least one dividend of 3. Remember to include the values of <em>a</em> and <em>b</em> in your calculations.</p>
</body>
</html><br><b>Sample Input:</b><br>-5<br>12<br><b>Sample Output:</b><br>4.5<br><br><br><font color="gray">Memory limit: 256 MB</font><br><font color="gray">Time limit: 5 seconds</font><br><br>
<a href="https://hyperskill.org/learn/step/6065">Show topic summary</a>