-
Notifications
You must be signed in to change notification settings - Fork 0
/
task.html
20 lines (20 loc) · 1.44 KB
/
task.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<b>Counting unique</b> <a class=right href="https://hyperskill.org/learn/step/6649">Open on JetBrains Academy</a>
<br><br>
<html>
<head></head>
<body>
<p>Imagine you have information about subjects three students study. It could be in the following format:</p>
<pre><code class="language-python">Belov = ["Physics", "Math", "Russian"]
Smith = ["Math", "Geometry", "English"]
Sarada = ["Japanese", "Math", "Physics"]</code></pre>
<p>The subjects can be the same or differ. Your task is to find the number of <em>unique </em>subjects. For example, in the lists above we have 6 different subjects: Physics, Math, Russian, Geometry, English, and Japanese, so you should print <code class="language-python">6</code> as the answer.</p>
<p>In this task, you're given the variables to work with: <code class="language-python">Belov</code>, <code class="language-python">Smith</code>, and <code class="language-python">Sarada</code>.</p>
<p><button class="btn-sm btn-outline-secondary" onclick="getElementById('hint-689').style.display='inline'"> Hint </button> </p>
<div id="hint-689" style="display:none;">
Before converting the lists into a set, sum them up as follows
<code class="language-python">Belov + Smith + Sarada</code>.
</div>
<p></p>
</body>
</html><br><br><font color="gray">Memory limit: 256 MB</font><br><font color="gray">Time limit: 15 seconds</font><br><br>
<a href="https://hyperskill.org/learn/step/6643">Show topic summary</a>