Skip to content

Commit 49b40e8

Browse files
authored
Merge pull request #117 from javascript-tutorial/sync-1ce5644a
Sync with upstream @ 1ce5644
2 parents f0c7ed2 + 7826c09 commit 49b40e8

File tree

6 files changed

+29
-4
lines changed

6 files changed

+29
-4
lines changed

1-js/02-first-steps/04-variables/article.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,14 +162,22 @@ let message = "That"; // SyntaxError: 'message' has already been declared
162162

163163
```smart header="Functional languages"
164164
<<<<<<< HEAD
165+
<<<<<<< HEAD
165166
Είναι ενδιαφέρον να σημειωθεί ότι υπάρχουν [functional](https://en.wikipedia.org/wiki/Functional_programming) γλώσσες προγραμματισμού, όπως [Scala](http://www.scala-lang.org/) ή [Erlang](http://www.erlang.org/) που απαγορεύουν την αλλαγή τιμής στις μεταβλητές.
166167
=======
167168
It's interesting to note that there exist [functional](https://en.wikipedia.org/wiki/Functional_programming) programming languages, like [Scala](https://www.scala-lang.org/) or [Erlang](https://www.erlang.org/) that forbid changing variable values.
168169
>>>>>>> 5dff42ba283bce883428c383c080fa9392b71df8
170+
=======
171+
It's interesting to note that there exist so-called [pure functional](https://en.wikipedia.org/wiki/Purely_functional_programming) programming languages, such as [Haskell](https://en.wikipedia.org/wiki/Haskell), that forbid changing variable values.
172+
>>>>>>> 1ce5644a15ee141fbe78c0fb79c8f40d870d7043
169173
170174
Σε τέτοιες γλώσσες, όταν η τιμή αποθηκευτεί "στο κουτί", είναι εκεί για πάντα. Εάν χρειαστεί να αποθηκεύσουμε κάτι άλλο, η γλώσσα μας αναγκάζει να δημιουργήσουμε ένα νέο πλαίσιο (δηλώστε μια νέα μεταβλητή). Δεν μπορούμε να επαναχρησιμοποιήσουμε το παλιό.
171175
176+
<<<<<<< HEAD
172177
Αν και μπορεί να φαίνεται λίγο περίεργο με την πρώτη ματιά, αυτές οι γλώσσες είναι αρκετά ικανές για σοβαρή ανάπτυξη. Επιπλέον, υπάρχουν περιοχές όπως οι παράλληλοι υπολογισμοί, όπου αυτός ο περιορισμός παρέχει ορισμένα οφέλη. Η μελέτη μιας τέτοιας γλώσσας (ακόμα κι αν δεν σκοπεύετε να τη χρησιμοποιήσετε σύντομα) συνιστάται να διευρύνετε το μυαλό.
178+
=======
179+
Though it may seem a little odd at first sight, these languages are quite capable of serious development. More than that, there are areas like parallel computations where this limitation confers certain benefits.
180+
>>>>>>> 1ce5644a15ee141fbe78c0fb79c8f40d870d7043
173181
```
174182

175183
## Ονομασία μεταβλητής [#variable-naming]

1-js/02-first-steps/08-operators/article.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,15 @@
4949

5050
Για παράδειγμα:
5151
```js run
52+
<<<<<<< HEAD
5253
alert( 5 % 2 ); // 1, ένα υπόλοιπο 5 διαιρούμενο με 2
5354
alert( 8 % 3 ); // 2, ένα υπόλοιπο 8 διαιρούμενο με 3
5455
alert( 8 % 4 ); // 3, ένα υπόλοιπο 8 διαιρούμενο με 4
56+
=======
57+
alert( 5 % 2 ); // 1, the remainder of 5 divided by 2
58+
alert( 8 % 3 ); // 2, the remainder of 8 divided by 3
59+
alert( 8 % 4 ); // 0, the remainder of 8 divided by 4
60+
>>>>>>> 1ce5644a15ee141fbe78c0fb79c8f40d870d7043
5561
```
5662

5763
### Εκθετικό **

1-js/02-first-steps/10-ifelse/article.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,10 +184,17 @@ alert( message );
184184

185185
Μπορεί να είναι δύσκολο στην αρχή να κατανοήσουμε τι συμβαίνει. Αλλά μετά από μια πιο προσεκτική ματιά, μπορούμε να δούμε ότι είναι απλώς μια συνηθισμένη σειρά δοκιμών:
186186

187+
<<<<<<< HEAD
187188
1. Το πρώτο ερωτηματικό ελέγχει εάν `age < 3`.
188189
2. Εάν είναι true -- τότε επιστρέφει `'Hi, baby!'`. Διαφορετικά, συνεχίζει στην έκφραση μετά την άνω και κάτω τελεία `'Hi, baby!'`, ελέγχοντας `age < 18`.
189190
3. Εάν αυτό είναι true -- επιστρέφει `'Hello!'`. Διαφορετικά, συνεχίζει στην έκφραση μετά την επόμενη άνω και κάτω τελεία '":"', ελέγχοντας `age < 100`.
190191
4. Αν αυτό είναι true -- επιστρέφει `'Greetings!'`. Διαφορετικά, συνεχίζει στην έκφραση μετά την τελευταία άνω και κάτω τελεία '":"', επιστρέφοντας `'What an unusual age!'`.
192+
=======
193+
1. The first question mark checks whether `age < 3`.
194+
2. If true -- it returns `'Hi, baby!'`. Otherwise, it continues to the expression after the colon ":", checking `age < 18`.
195+
3. If that's true -- it returns `'Hello!'`. Otherwise, it continues to the expression after the next colon ":", checking `age < 100`.
196+
4. If that's true -- it returns `'Greetings!'`. Otherwise, it continues to the expression after the last colon ":", returning `'What an unusual age!'`.
197+
>>>>>>> 1ce5644a15ee141fbe78c0fb79c8f40d870d7043
191198
192199
Δείτε πώς φαίνεται αυτό `if..else`:
193200

1-js/05-data-types/07-map-set/article.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Methods and properties are:
1818
- [`map.set(key, value)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/set) -- stores the value by the key.
1919
- [`map.get(key)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/get) -- returns the value by the key, `undefined` if `key` doesn't exist in map.
2020
- [`map.has(key)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/has) -- returns `true` if the `key` exists, `false` otherwise.
21-
- [`map.delete(key)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/delete) -- removes the value by the key.
21+
- [`map.delete(key)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/delete) -- removes the element (the key/value pair) by the key.
2222
- [`map.clear()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/clear) -- removes everything from the map.
2323
- [`map.size`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/size) -- returns the current element count.
2424

@@ -308,7 +308,7 @@ Methods and properties:
308308
- [`map.set(key, value)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/set) -- stores the value by the key, returns the map itself.
309309
- [`map.get(key)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/get) -- returns the value by the key, `undefined` if `key` doesn't exist in map.
310310
- [`map.has(key)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/has) -- returns `true` if the `key` exists, `false` otherwise.
311-
- [`map.delete(key)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/delete) -- removes the value by the key, returns `true` if `key` existed at the moment of the call, otherwise `false`.
311+
- [`map.delete(key)`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/delete) -- removes the element by the key, returns `true` if `key` existed at the moment of the call, otherwise `false`.
312312
- [`map.clear()`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/clear) -- removes everything from the map.
313313
- [`map.size`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map/size) -- returns the current element count.
314314

1-js/06-advanced-functions/08-settimeout-setinterval/article.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ Usually, that's a function. For historical reasons, a string of code can be pass
2727
: The delay before run, in milliseconds (1000 ms = 1 second), by default 0.
2828

2929
`arg1`, `arg2`...
30-
: Arguments for the function (not supported in IE9-)
30+
: Arguments for the function
3131

3232
For instance, this code calls `sayHi()` after one second:
3333

7-animation/1-bezier-curve/demo.svg

Lines changed: 5 additions & 1 deletion
Loading

0 commit comments

Comments
 (0)