Skip to content

Commit 94540a5

Browse files
committed
Added new translaions in the tasks and solutions
1 parent b85092b commit 94540a5

File tree

3 files changed

+11
-11
lines changed

3 files changed

+11
-11
lines changed

1-js/02-first-steps/08-operators/1-increment-order/solution.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11

2-
The answer is:
2+
Die Antwort ist:
33

44
- `a = 2`
55
- `b = 2`
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
The reason is that prompt returns user input as a string.
1+
Der Grund liegt darin, dass promt Nutzereingaben als string zurückgibt.
22

3-
So variables have values `"1"` and `"2"` respectively.
3+
Somit haben die Variablen die Were `"1"`beziehungsweise `"2"`.
44

55
```js run
66
let a = "1"; // prompt("First number?", 1);
@@ -9,9 +9,9 @@ let b = "2"; // prompt("Second number?", 2);
99
alert(a + b); // 12
1010
```
1111

12-
What we should to is to convert strings to numbers before `+`. For example, using `Number()` or prepending them with `+`.
12+
Was wir stattdessen tun sollten ist die Strings zu Zahlen zu konvertieren, bevor wir sie mit `+` addieren, z.B, durch `Number()` , oder indem man den String vorne ein `+` hinzufügt.
1313

14-
For example, right before `prompt`:
14+
Zum Beispiel kurz vor `prompt`:
1515

1616
```js run
1717
let a = +prompt("First number?", 1);
@@ -20,7 +20,7 @@ let b = +prompt("Second number?", 2);
2020
alert(a + b); // 3
2121
```
2222

23-
Or in the `alert`:
23+
Oder in `alert`:
2424

2525
```js run
2626
let a = prompt("First number?", 1);
@@ -29,4 +29,4 @@ let b = prompt("Second number?", 2);
2929
alert(+a + +b); // 3
3030
```
3131

32-
Using both unary and binary `+` in the latest code. Looks funny, doesn't it?
32+
Wir benutzen hier sowohl das unäre als auch das binäre `+`. Sieht komisch aus, oder?

1-js/02-first-steps/08-operators/4-fix-prompt/task.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@ importance: 5
22

33
---
44

5-
# Fix the addition
5+
# Korrigere die Addition
66

7-
Here's a code that asks the user for two numbers and shows their sum.
7+
Hier ist ein Code, der den Nutzer nach zwei Zahlen frägt und deren Summe anzeigt.
88

9-
It works incorrectly. The output in the example below is `12` (for default prompt values).
9+
Der Code hat einen Fehler. Die Ausgabe des Beispiels unten ist `12` (für default promt Werte).
1010

11-
Why? Fix it. The result should be `3`.
11+
Warum ist das so? Korrigiere den Code, sodass das Ergebnis `3` ist.
1212

1313
```js run
1414
let a = prompt("First number?", 1);

0 commit comments

Comments
 (0)