Warm up with a game.
Three small games right in your browser – no sign-up: guess outputs, solve code puzzles and hunt bugs. Collect points, keep your energy up and beat your high score.
Output Flash
What does the code print? Ten questions, three energy bars. Every correct answer in a row earns more points.
-
print(2 * 3)
2365 -
console.log("3" + 4)734Error -
print(len("Koda"))45Koda -
console.log(10 % 3)
310 -
print("Hi" * 2)Hi2HiHiError -
x = [1, 2, 3] print(x[-1])
13Error -
console.log(typeof 42)
number42string -
print(7 // 2)
3.534 -
console.log([1, 2, 3].length)
234 -
for i in range(3): print(i)1 2 30 1 2 30 1 2
Code Puzzle
The lines got mixed up. Put them in the right order so the program works.
-
Python: print every number in the list.
zahlen = [1, 2, 3]
for z in zahlen:
print(z)
-
JavaScript: greet Koda.
function gruss(name) {return "Hallo " + name;
}
console.log(gruss("Koda")); -
HTML: build a small web page.
<!doctype html>
<html>
<body>
<p>Hallo!</p>
</body>
</html>
-
Python: count to three, then say “Los!”.
zahl = 1
while zahl <= 3:
print(zahl)
zahl = zahl + 1
print("Los!")
Bug Hunt
Every program hides exactly one mistake. Find the line – Bugsy then explains what was wrong.
-
alter = 3
name = "Koda"
print("Hallo " + Name)Python is case-sensitive: the variable is called name, not Name.
-
const leben = 3;
leben = leben - 1;
console.log(leben);
A const value can't be changed. For a value that changes you need let.
-
<h1>Willkommen</h1>
<p>Schön, dass du da bist.</p>
<a href="kurse.html">Kurse</b>
An <a> has to be closed with </a>, not with </b>.
-
zahlen = [4, 8, 15]
for z in zahlen
print(z)
The for line is missing its colon: for z in zahlen:
-
SELECT name, alter
FORM kurse
WHERE alter > 12;
The keyword is FROM, not FORM – a classic typo.
Want more?
Thousands of tasks like these are waiting in the learning app – with explanations, a learning path and your streak.