diff --git a/1-js/01-getting-started/1-intro/article.md b/1-js/01-getting-started/1-intro/article.md
index 2f4f518f3e..c48e308d4f 100644
--- a/1-js/01-getting-started/1-intro/article.md
+++ b/1-js/01-getting-started/1-intro/article.md
@@ -1,122 +1,32 @@
-# An Introduction to JavaScript
-
-Let's see what's so special about JavaScript, what we can achieve with it, and what other technologies play well with it.
-## What is JavaScript?
+# An Introduction to JavaScript
*JavaScript* was initially created to "make web pages alive".
The programs in this language are called *scripts*. They can be written right in a web page's HTML and run automatically as the page loads.
-Scripts are provided and executed as plain text. They don't need special preparation or compilation to run.
-
-In this aspect, JavaScript is very different from another language called [Java](https://en.wikipedia.org/wiki/Java_(programming_language)).
-
```smart header="Why is it called JavaScript?"
-When JavaScript was created, it initially had another name: "LiveScript". But Java was very popular at that time, so it was decided that positioning a new language as a "younger brother" of Java would help.
-
-But as it evolved, JavaScript became a fully independent language with its own specification called [ECMAScript](http://en.wikipedia.org/wiki/ECMAScript), and now it has no relation to Java at all.
-```
-
-Today, JavaScript can execute not only in the browser, but also on the server, or actually on any device that has a special program called [the JavaScript engine](https://en.wikipedia.org/wiki/JavaScript_engine).
-
-The browser has an embedded engine sometimes called a "JavaScript virtual machine".
-
-Different engines have different "codenames". For example:
-
-- [V8](https://en.wikipedia.org/wiki/V8_(JavaScript_engine)) -- in Chrome, Opera and Edge.
-- [SpiderMonkey](https://en.wikipedia.org/wiki/SpiderMonkey) -- in Firefox.
-- ...There are other codenames like "Chakra" for IE, "JavaScriptCore", "Nitro" and "SquirrelFish" for Safari, etc.
-
-The terms above are good to remember because they are used in developer articles on the internet. We'll use them too. For instance, if "a feature X is supported by V8", then it probably works in Chrome, Opera and Edge.
-
-```smart header="How do engines work?"
-
-Engines are complicated. But the basics are easy.
-
-1. The engine (embedded if it's a browser) reads ("parses") the script.
-2. Then it converts ("compiles") the script to machine code.
-3. And then the machine code runs, pretty fast.
-
-The engine applies optimizations at each step of the process. It even watches the compiled script as it runs, analyzes the data that flows through it, and further optimizes the machine code based on that knowledge.
-```
-
-## What can in-browser JavaScript do?
-
-Modern JavaScript is a "safe" programming language. It does not provide low-level access to memory or the CPU, because it was initially created for browsers which do not require it.
+When JavaScript was created, it initially had another name: "LiveScript". But another language named Java was very popular at that time, so it was decided that positioning a new language as a "younger brother" of Java would help.
-JavaScript's capabilities greatly depend on the environment it's running in. For instance, [Node.js](https://wikipedia.org/wiki/Node.js) supports functions that allow JavaScript to read/write arbitrary files, perform network requests, etc.
-
-In-browser JavaScript can do everything related to webpage manipulation, interaction with the user, and the webserver.
-
-For instance, in-browser JavaScript is able to:
-
-- Add new HTML to the page, change the existing content, modify styles.
-- React to user actions, run on mouse clicks, pointer movements, key presses.
-- Send requests over the network to remote servers, download and upload files (so-called [AJAX](https://en.wikipedia.org/wiki/Ajax_(programming)) and [COMET](https://en.wikipedia.org/wiki/Comet_(programming)) technologies).
-- Get and set cookies, ask questions to the visitor, show messages.
-- Remember the data on the client-side ("local storage").
-
-## What CAN'T in-browser JavaScript do?
-
-JavaScript's abilities in the browser are limited to protect the user's safety. The aim is to prevent an evil webpage from accessing private information or harming the user's data.
-
-Examples of such restrictions include:
-
-- JavaScript on a webpage may not read/write arbitrary files on the hard disk, copy them or execute programs. It has no direct access to OS functions.
-
- Modern browsers allow it to work with files, but the access is limited and only provided if the user does certain actions, like "dropping" a file into a browser window or selecting it via an `` tag.
-
- There are ways to interact with the camera/microphone and other devices, but they require a user's explicit permission. So a JavaScript-enabled page may not sneakily enable a web-camera, observe the surroundings and send the information to the [NSA](https://en.wikipedia.org/wiki/National_Security_Agency).
-- Different tabs/windows generally do not know about each other. Sometimes they do, for example when one window uses JavaScript to open the other one. But even in this case, JavaScript from one page may not access the other page if they come from different sites (from a different domain, protocol or port).
-
- This is called the "Same Origin Policy". To work around that, *both pages* must agree for data exchange and must contain special JavaScript code that handles it. We'll cover that in the tutorial.
-
- This limitation is, again, for the user's safety. A page from `http://anysite.com` which a user has opened must not be able to access another browser tab with the URL `http://gmail.com`, for example, and steal information from there.
-- JavaScript can easily communicate over the net to the server where the current page came from. But its ability to receive data from other sites/domains is crippled. Though possible, it requires explicit agreement (expressed in HTTP headers) from the remote side. Once again, that's a safety limitation.
-
-
-
-Such limitations do not exist if JavaScript is used outside of the browser, for example on a server. Modern browsers also allow plugins/extensions which may ask for extended permissions.
-
-## What makes JavaScript unique?
-
-There are at least *three* great things about JavaScript:
-
-```compare
-+ Full integration with HTML/CSS.
-+ Simple things are done simply.
-+ Supported by all major browsers and enabled by default.
+...As it evolved, JavaScript became a fully independent language with its own specification called [ECMAScript](http://en.wikipedia.org/wiki/ECMAScript), and now it has no relation to Java at all.
```
-JavaScript is the only browser technology that combines these three things.
-
-That's what makes JavaScript unique. That's why it's the most widespread tool for creating browser interfaces.
-That said, JavaScript can be used to create servers, mobile applications, etc.
+## JavaScript engine
-## Languages "over" JavaScript
+A "JavaScript engine", sometimes also called a "JavaScript virtual machine" – is a piece of software which can be embedded in a browser or another bigger program and can execute JavaScript.
-The syntax of JavaScript does not suit everyone's needs. Different people want different features.
+Historically, web development is the main field of application for JavaScript.
-That's to be expected, because projects and requirements are different for everyone.
+This is because of its wide adoption and uniquely tight integration with HTML/CSS.
-So, recently a plethora of new languages appeared, which are *transpiled* (converted) to JavaScript before they run in the browser.
+**Nowadays though, JavaScript can execute not only in the browser, but also on the server, or on any device which supports a JavaScript engine.**
-Modern tools make the transpilation very fast and transparent, actually allowing developers to code in another language and auto-converting it "under the hood".
-
-Examples of such languages:
-
-- [CoffeeScript](https://coffeescript.org/) is "syntactic sugar" for JavaScript. It introduces shorter syntax, allowing us to write clearer and more precise code. Usually, Ruby devs like it.
-- [TypeScript](https://www.typescriptlang.org/) is concentrated on adding "strict data typing" to simplify the development and support of complex systems. It is developed by Microsoft.
-- [Flow](https://flow.org/) also adds data typing, but in a different way. Developed by Facebook.
-- [Dart](https://www.dartlang.org/) is a standalone language that has its own engine that runs in non-browser environments (like mobile apps), but also can be transpiled to JavaScript. Developed by Google.
-- [Brython](https://brython.info/) is a Python transpiler to JavaScript that enables the writing of applications in pure Python without JavaScript.
-- [Kotlin](https://kotlinlang.org/docs/reference/js-overview.html) is a modern, concise and safe programming language that can target the browser or Node.
+Different engines have different "codenames". For example:
-There are more. Of course, even if we use one of these transpiled languages, we should also know JavaScript to really understand what we're doing.
+- [V8](https://en.wikipedia.org/wiki/V8_(JavaScript_engine)) -- in Chrome, Opera and Edge.
+- [SpiderMonkey](https://en.wikipedia.org/wiki/SpiderMonkey) -- in Firefox.
+- ...There are other codenames like "JavaScriptCore", "Nitro" and "SquirrelFish" for Safari, etc.
-## Summary
+The terms above are good to remember because they are often mentioned. For instance, if your hear that "a feature X is supported by V8", then it probably works in Chrome, Opera and Edge browsers.
-- JavaScript was initially created as a browser-only language, but it is now used in many other environments as well.
-- Today, JavaScript has a unique position as the most widely-adopted browser language, fully integrated with HTML/CSS.
-- There are many languages that get "transpiled" to JavaScript and provide certain features. It is recommended to take a look at them, at least briefly, after mastering JavaScript.
+As mentioned, engines can execute not only in the browser. For instance, [Node.js](https://nodejs.org/) allows to execute JavaScript code without any browser at all. It's based on V8 engine. One can install it locally on your computer and write JavaScript code for to assist in daily tasks or make a web server using it.
diff --git a/1-js/01-getting-started/1-intro/limitations.svg b/1-js/01-getting-started/1-intro/limitations.svg
deleted file mode 100644
index 76ea43fd7a..0000000000
--- a/1-js/01-getting-started/1-intro/limitations.svg
+++ /dev/null
@@ -1 +0,0 @@
-
\ No newline at end of file
diff --git a/1-js/01-getting-started/2-manuals-specifications/article.md b/1-js/01-getting-started/2-manuals-specifications/article.md
index 3fa2433363..1796dffd26 100644
--- a/1-js/01-getting-started/2-manuals-specifications/article.md
+++ b/1-js/01-getting-started/2-manuals-specifications/article.md
@@ -1,37 +1,34 @@
# Manuals and specifications
-This book is a *tutorial*. It aims to help you gradually learn the language. But once you're familiar with the basics, you'll need other resources.
+You're now reading a *tutorial*. It aims to help you gradually learn the language. Once you're familiar with the basics, you'll need other resources, so here's a brief list.
-## Specification
-
-[The ECMA-262 specification](https://www.ecma-international.org/publications/standards/Ecma-262.htm) contains the most in-depth, detailed and formalized information about JavaScript. It defines the language.
+If you're new to JavaScript, then you don't (yet) need them now. But you will need them later, so make a bookmark.
-But being that formalized, it's difficult to understand at first. So if you need the most trustworthy source of information about the language details, the specification is the right place. But it's not for everyday use.
+## Specification
-A new specification version is released every year. Between these releases, the latest specification draft is at .
+[The ECMA-262 specification](https://www.ecma-international.org/publications/standards/Ecma-262.htm) is a formal definition of the language.
-To read about new bleeding-edge features, including those that are "almost standard" (so-called "stage 3"), see proposals at .
+It contains the most in-depth, detailed and formalized information about JavaScript! If you ever need the ultimately trustworthy source of information, the specification is the right place. However, its highly formal writing style makes it difficult to read. So it's not for everyday use.
-Also, if you're developing for the browser, then there are other specifications covered in the [second part](info:browser-environment) of the tutorial.
+- A new specification version is released every year. Between these releases, the latest specification draft is at .
+- To read about new bleeding-edge features, including those that are "almost standard" (so-called "stage 3"), see proposals at .
-## Manuals
+## MDN manual
-- **MDN (Mozilla) JavaScript Reference** is the main manual with examples and other information. It's great to get in-depth information about individual language functions, methods etc.
+[MDN (Mozilla) JavaScript Reference](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference) is a great manual with examples.
- You can find it at .
+It contains a lot of information both about JavaScript and its browser-specific usage.
-Although, it's often best to use an internet search instead. Just use "MDN [term]" in the query, e.g. to search for the `parseInt` function.
+Instead of accessing it directly, it's often faster to use an internet search, such as Google. Just search for "MDN ..." and the query, for example [MDN parseInt](https://google.com/search?q=MDN+parseInt) to search for the `parseInt` function in MDN.
## Compatibility tables
-JavaScript is a developing language, new features get added regularly.
-
-To see their support among browser-based and other engines, see:
+JavaScript continues to evolve, new features get added to the specification (and hence to the language) regularly.
-- - per-feature tables of support, e.g. to see which engines support modern cryptography functions: .
-- - a table with language features and engines that support those or don't support.
+However, when a new feature appears in the specification, it doesn't really mean that everyone can use it. JavaScript engines need time to adopt it. So before actually using a fresh language capability, it's best to make sure that it's well-supported.
-All these resources are useful in real-life development, as they contain valuable information about language details, their support, etc.
+To see the current state of support, there're two great resources:
-Please remember them (or this page) for the cases when you need in-depth information about a particular feature.
+- – per-feature tables of support, e.g. to see which engines support modern cryptography functions: .
+- – a table with a list of language features and engines that support those or don't support.
diff --git a/1-js/01-getting-started/3-code-editors/article.md b/1-js/01-getting-started/3-code-editors/article.md
deleted file mode 100644
index ca61947412..0000000000
--- a/1-js/01-getting-started/3-code-editors/article.md
+++ /dev/null
@@ -1,49 +0,0 @@
-# Code editors
-
-A code editor is the place where programmers spend most of their time.
-
-There are two main types of code editors: IDEs and lightweight editors. Many people use one tool of each type.
-
-## IDE
-
-The term [IDE](https://en.wikipedia.org/wiki/Integrated_development_environment) (Integrated Development Environment) refers to a powerful editor with many features that usually operates on a "whole project." As the name suggests, it's not just an editor, but a full-scale "development environment."
-
-An IDE loads the project (which can be many files), allows navigation between files, provides autocompletion based on the whole project (not just the open file), and integrates with a version management system (like [git](https://git-scm.com/)), a testing environment, and other "project-level" stuff.
-
-If you haven't selected an IDE yet, consider the following options:
-
-- [Visual Studio Code](https://code.visualstudio.com/) (cross-platform, free).
-- [WebStorm](https://www.jetbrains.com/webstorm/) (cross-platform, paid).
-
-For Windows, there's also "Visual Studio", not to be confused with "Visual Studio Code". "Visual Studio" is a paid and mighty Windows-only editor, well-suited for the .NET platform. It's also good at JavaScript. There's also a free version [Visual Studio Community](https://www.visualstudio.com/vs/community/).
-
-Many IDEs are paid, but have a trial period. Their cost is usually negligible compared to a qualified developer's salary, so just choose the best one for you.
-
-## Lightweight editors
-
-"Lightweight editors" are not as powerful as IDEs, but they're fast, elegant and simple.
-
-They are mainly used to open and edit a file instantly.
-
-The main difference between a "lightweight editor" and an "IDE" is that an IDE works on a project-level, so it loads much more data on start, analyzes the project structure if needed and so on. A lightweight editor is much faster if we need only one file.
-
-In practice, lightweight editors may have a lot of plugins including directory-level syntax analyzers and autocompleters, so there's no strict border between a lightweight editor and an IDE.
-
-There are many options, for instance:
-
-- [Sublime Text](https://www.sublimetext.com/) (cross-platform, shareware).
-- [Notepad++](https://notepad-plus-plus.org/) (Windows, free).
-- [Vim](https://www.vim.org/) and [Emacs](https://www.gnu.org/software/emacs/) are also cool if you know how to use them.
-
-## Let's not argue
-
-The editors in the lists above are those that either I or my friends whom I consider good developers have been using for a long time and are happy with.
-
-There are other great editors in our big world. Please choose the one you like the most.
-
-The choice of an editor, like any other tool, is individual and depends on your projects, habits, and personal preferences.
-
-The author's personal opinion:
-
-- I'd use [Visual Studio Code](https://code.visualstudio.com/) if I develop mostly frontend.
-- Otherwise, if it's mostly another language/platform and partially frontend, then consider other editors, such as XCode (Mac), Visual Studio (Windows) or Jetbrains family (Webstorm, PHPStorm, RubyMine etc, depending on the language).
diff --git a/1-js/01-getting-started/3-code-structure/article.md b/1-js/01-getting-started/3-code-structure/article.md
new file mode 100644
index 0000000000..ee8f54dd7e
--- /dev/null
+++ b/1-js/01-getting-started/3-code-structure/article.md
@@ -0,0 +1,231 @@
+
+# Hello, world!
+
+Let's start coding!
+
+You can do it right here, in this tutorial, using the code editor at the right side of this text (if you're using a narrow screen, then use a toggler at the page bottom to switch to the editor).
+
+Try something, for example type `console.log("Hello, world!")` and click "Run".
+
+This is a *statement* that outputs a string `"Hello, world!"`. You can see the output produced by this command in the "Console" tab at the bottom.
+
+
+TODO: arrow with "statement"
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+```js
+console.log('Hello 1');
+console.log('Hello 2');
+console.log('Hello 3');
+console.log('Hello 4');
+console.log('Hello 5');
+console.log('Hello 6');
+console.log('Hello 7');
+```
+
+## Statements
+
+Statements are syntax constructs and commands that perform actions.
+
+We've already seen a statement, `console.log('Hello, world!')`, which shows the message "Hello, world!".
+
+We can have as many statements in our code as we want. Statements can be separated with a semicolon.
+
+For example, let's split "Hello World" into two outputs:
+
+TODO: arrows with "statement"
+
+```js run no-beautify
+*!*console.log('Hello')*/!*; *!*console.log('World')*/!*;
+```
+
+A semicolon signals the end of the first statement, so that we can start with the second.
+
+Usually, statements are written on separate lines to make the code more readable:
+
+```js run no-beautify
+console.log('Hello');
+console.log('World');
+```
+
+### Are semicolons necessary? [#semicolon]
+
+A newline usually implies a semicolon. In other words, when a line ends, JavaScript automatically assumes that there's a semicolon there. This language feature is called an [automatic semicolon insertion](https://tc39.github.io/ecma262/#sec-automatic-semicolon-insertion).
+
+The same code will still work if we cut out the semicolons:
+
+```js run no-beautify
+console.log('Hello')
+console.log('World')
+```
+
+
+However, there are situations when a newline doesn't mean a statement end.
+
+Such as this:
+
+```js run no-beautify
+console.log(3 +
+1
++ 2);
+```
+
+This is a single statement which spans on multiple lines. It outputs `6`.
+
+It is intuitively obvious that if the line ends with a plus `"+"`, then it is an "incomplete expression", so a semicolon there is not needed.
+
+JavaScript has intricate internal rules to figure out rare cases a newline doesn't mean the "statement end", but they are not 100% reliable. In this particular case it gets things right. However, it's not always so.
+
+To avoid any issues, it's recommended to be explicit: always put a semicolon at a statement end.
+
+````smart header="An example of an error caused by an omitted semicolon"
+Let's see an example of a situation when JavaScript syntax rules do not align with a programmer's intention, and an omitted semicolon causes an error.
+
+Run this code:
+
+```js run
+console.log("Hello");
+
+[1, 2].forEach(console.log);
+```
+
+No need to think about the meaning of the brackets `[]` and `forEach` yet. We'll study them later. For now, just remember the result of running the code: it shows `Hello`, then two more lines.
+
+Now let's say a lazy programmer forgot to put the semicolon after the `console.log`:
+
+```js run no-beautify
+console.log("Hello")
+
+[1, 2].forEach(console.log);
+```
+
+The difference compared to the code above is only one character: the semicolon at the end of the first line is gone.
+
+If we run this code, only the first `Hello` shows and no more lines – that's because of an error.
+
+In our last example, JavaScript assumes that a square bracket `[` means that the expression has not ended yet, and so doesn't auto-insert the semicolon, similar to the plus `+` character before.
+
+So, the code in the last example is treated as a single statement.
+
+Here's how the engine sees it:
+
+```js run no-beautify
+console.log("Hello")[1, 2].forEach(console.log);
+```
+
+Looks weird, right? Such merging in this case is just wrong. We need to put a semicolon after `console.log` for the code to work correctly.
+
+This can happen in other situations also.
+````
+
+We recommend putting semicolons between statements even if they are separated by newlines. This rule is widely adopted by the community. To put it short -- *it is possible* to leave out semicolons most of the time. But it's safer -- especially for a beginner -- to use them.
+
+## Comments [#code-comments]
+
+As time goes on, programs become more and more complex. It becomes necessary to add *comments* which describe what the code does and why.
+
+Comments can be put into any place of a script. They don't affect its execution because the engine simply ignores them.
+
+**One-line comments start with two forward slash characters `//`.**
+
+The rest of the line is a comment. It may occupy a full line of its own or follow a statement.
+
+Like here:
+
+TODO: comment picture
+
+```js run
+*!*
+// This comment occupies a line of its own
+*/!*
+console.log('Hello');
+
+console.log('World'); *!*// This comment follows the statement*/!*
+```
+
+**Multiline comments start with a forward slash and an asterisk /* and end with an asterisk and a forward slash */.**
+
+Like this:
+
+TODO: comment picture
+
+```js run
+*!*
+/* An example with two messages.
+This is a multiline comment.
+*/
+*/!*
+console.log('Hello');
+console.log('World');
+```
+
+The content of comments is ignored, so if we put code inside /* ... */, it won't execute.
+
+Sometimes it can be handy to temporarily disable ("comment out") a part of code:
+
+TODO: comment picture
+
+```js run
+*!*
+/*
+console.log('Hello');
+*/
+*/!*
+console.log('World');
+```
+
+```smart header="Use hotkeys!"
+In most editors, a line of code can be commented out by pressing the `key:Ctrl+/` hotkey for a single-line comment and something like `key:Ctrl+Shift+/` -- for multiline comments (select a piece of code and press the hotkey). For Mac, try `key:Cmd` instead of `key:Ctrl` and `key:Option` instead of `key:Shift`.
+```
+
+````warn header="Nested comments are not supported!"
+There may not be `/*...*/` inside another `/*...*/`.
+
+Such code will exit with a syntax error:
+
+```js run no-beautify
+/*
+ /* nested comment ?!? */
+*/
+console.log( 'World' );
+```
+````
+
+Please, don't hesitate to comment your code.
+
+Comments increase the overall code length, but that's not a problem at all. There are many tools which minify code before publishing to a production server. They remove comments, so they don't appear in the working scripts. Therefore, comments do not have negative effects on production at all.
+
+## Strict mode
+
+...And a one more minor thing.
+
+Sometimes you may see scripts starting with the line `"use strict";`.
+
+```js
+"use strict";
+
+// ...the code...
+```
+
+This is a so-called "strict directive". It switches the script to the "strict mode", which actually isn't that strict. It simply switches a few language features to behave in modern and correct way.
+
+This mode is enabled automatically when a script uses modules, classes and some other modern syntax. So this directive is rarely needed.
+
+However, if you run a very simple script without this directive, for example just to test how things work, then it may run in the "old mode".
+
+To avoid confusion, we will specifically mention language features which behave differently in the old mode. Luckily, there're only a few of them, and the difference is small.
+
+All code in this tutorial assumes strict mode, unless specified otherwise.
diff --git a/1-js/01-getting-started/3-code-structure/statement.svg b/1-js/01-getting-started/3-code-structure/statement.svg
new file mode 100644
index 0000000000..65d3d8f134
--- /dev/null
+++ b/1-js/01-getting-started/3-code-structure/statement.svg
@@ -0,0 +1,11 @@
+
diff --git a/1-js/01-getting-started/4-devtools/article.md b/1-js/01-getting-started/4-devtools/article.md
deleted file mode 100644
index 50926d4f76..0000000000
--- a/1-js/01-getting-started/4-devtools/article.md
+++ /dev/null
@@ -1,63 +0,0 @@
-# Developer console
-
-Code is prone to errors. You will quite likely make errors... Oh, what am I talking about? You are *absolutely* going to make errors, at least if you're a human, not a [robot](https://en.wikipedia.org/wiki/Bender_(Futurama)).
-
-But in the browser, users don't see errors by default. So, if something goes wrong in the script, we won't see what's broken and can't fix it.
-
-To see errors and get a lot of other useful information about scripts, "developer tools" have been embedded in browsers.
-
-Most developers lean towards Chrome or Firefox for development because those browsers have the best developer tools. Other browsers also provide developer tools, sometimes with special features, but are usually playing "catch-up" to Chrome or Firefox. So most developers have a "favorite" browser and switch to others if a problem is browser-specific.
-
-Developer tools are potent; they have many features. To start, we'll learn how to open them, look at errors, and run JavaScript commands.
-
-## Google Chrome
-
-Open the page [bug.html](bug.html).
-
-There's an error in the JavaScript code on it. It's hidden from a regular visitor's eyes, so let's open developer tools to see it.
-
-Press `key:F12` or, if you're on Mac, then `key:Cmd+Opt+J`.
-
-The developer tools will open on the Console tab by default.
-
-It looks somewhat like this:
-
-
-
-The exact look of developer tools depends on your version of Chrome. It changes from time to time but should be similar.
-
-- Here we can see the red-colored error message. In this case, the script contains an unknown "lalala" command.
-- On the right, there is a clickable link to the source `bug.html:12` with the line number where the error has occurred.
-
-Below the error message, there is a blue `>` symbol. It marks a "command line" where we can type JavaScript commands. Press `key:Enter` to run them.
-
-Now we can see errors, and that's enough for a start. We'll come back to developer tools later and cover debugging more in-depth in the chapter .
-
-```smart header="Multi-line input"
-Usually, when we put a line of code into the console, and then press `key:Enter`, it executes.
-
-To insert multiple lines, press `key:Shift+Enter`. This way one can enter long fragments of JavaScript code.
-```
-
-## Firefox, Edge, and others
-
-Most other browsers use `key:F12` to open developer tools.
-
-The look & feel of them is quite similar. Once you know how to use one of these tools (you can start with Chrome), you can easily switch to another.
-
-## Safari
-
-Safari (Mac browser, not supported by Windows/Linux) is a little bit special here. We need to enable the "Develop menu" first.
-
-Open Preferences and go to the "Advanced" pane. There's a checkbox at the bottom:
-
-
-
-Now `key:Cmd+Opt+C` can toggle the console. Also, note that the new top menu item named "Develop" has appeared. It has many commands and options.
-
-## Summary
-
-- Developer tools allow us to see errors, run commands, examine variables, and much more.
-- They can be opened with `key:F12` for most browsers on Windows. Chrome for Mac needs `key:Cmd+Opt+J`, Safari: `key:Cmd+Opt+C` (need to enable first).
-
-Now we have the environment ready. In the next section, we'll get down to JavaScript.
diff --git a/1-js/01-getting-started/4-devtools/bug.html b/1-js/01-getting-started/4-devtools/bug.html
deleted file mode 100644
index edb02375ca..0000000000
--- a/1-js/01-getting-started/4-devtools/bug.html
+++ /dev/null
@@ -1,17 +0,0 @@
-
-
-
-
-
-
-
-
-
- There is an error in the script on this page.
-
-
-
-
-
\ No newline at end of file
diff --git a/1-js/01-getting-started/4-devtools/chrome.png b/1-js/01-getting-started/4-devtools/chrome.png
deleted file mode 100644
index 4cb3ea2f46..0000000000
Binary files a/1-js/01-getting-started/4-devtools/chrome.png and /dev/null differ
diff --git a/1-js/01-getting-started/4-devtools/chrome@2x.png b/1-js/01-getting-started/4-devtools/chrome@2x.png
deleted file mode 100644
index b87404a8f4..0000000000
Binary files a/1-js/01-getting-started/4-devtools/chrome@2x.png and /dev/null differ
diff --git a/1-js/01-getting-started/4-devtools/safari.png b/1-js/01-getting-started/4-devtools/safari.png
deleted file mode 100644
index 64c7a3f6ca..0000000000
Binary files a/1-js/01-getting-started/4-devtools/safari.png and /dev/null differ
diff --git a/1-js/01-getting-started/4-devtools/safari@2x.png b/1-js/01-getting-started/4-devtools/safari@2x.png
deleted file mode 100644
index 27def4d09b..0000000000
Binary files a/1-js/01-getting-started/4-devtools/safari@2x.png and /dev/null differ
diff --git a/1-js/01-getting-started/4-hello-world/article.md b/1-js/01-getting-started/4-hello-world/article.md
new file mode 100644
index 0000000000..0a8a4af75a
--- /dev/null
+++ b/1-js/01-getting-started/4-hello-world/article.md
@@ -0,0 +1,9 @@
+# My first code
+
+In this tutorial you don't just get the knowledge. You need to apply it as well, this is the only way to ensure you really get things right.
+
+This can be done using the editor at the right side of this page.
+
+To try things out, write the code to output "Hello, World" and press "run".
+
+Also run tests.
diff --git a/1-js/01-getting-started/4-hello-world/solution.js b/1-js/01-getting-started/4-hello-world/solution.js
new file mode 100644
index 0000000000..ed54d039cc
--- /dev/null
+++ b/1-js/01-getting-started/4-hello-world/solution.js
@@ -0,0 +1,3 @@
+// Write your code here
+
+console.log("Hello, World");
\ No newline at end of file
diff --git a/1-js/01-getting-started/4-hello-world/source.js b/1-js/01-getting-started/4-hello-world/source.js
new file mode 100644
index 0000000000..7056c69324
--- /dev/null
+++ b/1-js/01-getting-started/4-hello-world/source.js
@@ -0,0 +1 @@
+// Write your code here
\ No newline at end of file
diff --git a/1-js/02-first-steps/04-variables/1-hello-variables/solution.md b/1-js/01-getting-started/5-variables/1-hello-variables/solution.md
similarity index 100%
rename from 1-js/02-first-steps/04-variables/1-hello-variables/solution.md
rename to 1-js/01-getting-started/5-variables/1-hello-variables/solution.md
diff --git a/1-js/02-first-steps/04-variables/1-hello-variables/task.md b/1-js/01-getting-started/5-variables/1-hello-variables/task.md
similarity index 100%
rename from 1-js/02-first-steps/04-variables/1-hello-variables/task.md
rename to 1-js/01-getting-started/5-variables/1-hello-variables/task.md
diff --git a/1-js/02-first-steps/04-variables/2-declare-variables/solution.md b/1-js/01-getting-started/5-variables/2-declare-variables/solution.md
similarity index 100%
rename from 1-js/02-first-steps/04-variables/2-declare-variables/solution.md
rename to 1-js/01-getting-started/5-variables/2-declare-variables/solution.md
diff --git a/1-js/02-first-steps/04-variables/2-declare-variables/task.md b/1-js/01-getting-started/5-variables/2-declare-variables/task.md
similarity index 100%
rename from 1-js/02-first-steps/04-variables/2-declare-variables/task.md
rename to 1-js/01-getting-started/5-variables/2-declare-variables/task.md
diff --git a/1-js/02-first-steps/04-variables/3-uppercast-constant/solution.md b/1-js/01-getting-started/5-variables/3-uppercast-constant/solution.md
similarity index 100%
rename from 1-js/02-first-steps/04-variables/3-uppercast-constant/solution.md
rename to 1-js/01-getting-started/5-variables/3-uppercast-constant/solution.md
diff --git a/1-js/02-first-steps/04-variables/3-uppercast-constant/task.md b/1-js/01-getting-started/5-variables/3-uppercast-constant/task.md
similarity index 100%
rename from 1-js/02-first-steps/04-variables/3-uppercast-constant/task.md
rename to 1-js/01-getting-started/5-variables/3-uppercast-constant/task.md
diff --git a/1-js/01-getting-started/5-variables/article.md b/1-js/01-getting-started/5-variables/article.md
new file mode 100644
index 0000000000..95680f7fc6
--- /dev/null
+++ b/1-js/01-getting-started/5-variables/article.md
@@ -0,0 +1,203 @@
+# Variables
+
+If we want to create a JavaScript application bigger than "Hello, World", we need variables.
+
+A [variable](https://en.wikipedia.org/wiki/Variable_(computer_science)) is a "named storage" for data.
+
+For example:
+1. An online shop -- variables can store information about goods being sold and a shopping cart.
+2. A chat application -- variables store information about users, messages, and much more.
+
+## Declaration
+
+To create a variable in JavaScript, use the `let` keyword.
+
+The statement below creates (in other words: *declares*) a variable with the name "message":
+
+```js
+let message;
+```
+
+One can think of a variable as a "box" for data, with a uniquely-named sticker on it.
+
+We've just created such box:
+
+
+
+We can put any value in the box using an assignment `=`.
+
+For instance, let's store a string `Hello!`.
+
+```js run
+let message;
+
+message = 'Hello!';
+```
+
+
+
+The string is now saved into the memory area associated with the variable. We can access it using the variable name:
+
+```js run
+let message;
+
+message = 'Hello!';
+
+*!*
+console.log(message); // shows the variable content
+*/!*
+```
+
+To be concise, we can combine the variable declaration and assignment into a single line:
+
+```js run
+*!*
+let message = 'Hello!'; // define the variable and assign the value
+*/!*
+
+console.log(message); // Hello!
+```
+
+We can also change it as many times as we want:
+
+```js run
+let message;
+
+message = 'Hello!';
+
+*!*
+message = 'World!'; // value changed
+*/!*
+
+console.log(message); // World!
+```
+
+When the value is changed, the old data is automatically removed from the variable:
+
+
+
+
+We can also declare two variables and copy data from one into the other.
+
+```js run
+let hello = 'Hello world!';
+
+let message;
+
+*!*
+// copy 'Hello world' from hello
+message = hello;
+*/!*
+
+// now two variables hold the same data
+console.log(hello); // Hello world!
+console.log(message); // Hello world!
+```
+
+````warn header="Declaring twice triggers an error"
+A variable should be declared only once.
+
+A repeated declaration of the same variable is an error:
+
+```js run
+let message = "This";
+
+// repeated 'let' leads to an error
+let message = "That"; // SyntaxError: 'message' has already been declared
+```
+So, the variable should be declared once, and then we can assign to it (or use otherwise) without `let`.
+````
+
+```smart header="The outdated `var` keyword"
+A long time ago, JavaScript used another keyword: `var` to declare variables. It still works.
+
+However, there're subtle differences between `var` and `let`, in short: `let` is better, while `var` is an artifact from the past of JavaScript. Nowadays, people don't `var` it any more, so neither will we.
+
+The only reason to mention `var` is that you may see it in some really old scripts.
+```
+
+## Variable naming [#variable-naming]
+
+There are two limitations on variable names:
+
+1. The name must contain only letters, digits, or the symbols `$` and `_`.
+2. The first character must not be a digit.
+
+Examples of valid names:
+
+```js
+let userName;
+let test123;
+```
+
+When the name contains multiple words, [camelCase](https://en.wikipedia.org/wiki/CamelCase) is commonly used. That is: words go one after another, each word except first starting with a capital letter: `myVeryLongName`.
+
+What's interesting -- the dollar sign `'$'` and the underscore `'_'` can also be used in names. They are regular symbols, just like letters, without any special meaning.
+
+These names are valid:
+
+```js run untrusted
+let $ = 1; // declared a variable with the name "$"
+let _ = 2; // and now a variable with the name "_"
+
+// these variables are regular, such characters have no special meaning
+console.log($ + _); // 3
+```
+
+Examples of incorrect variable names:
+
+```js no-beautify
+let 1a; // cannot start with a digit
+
+let my-name; // hyphens '-' aren't allowed in the name
+```
+
+```smart header="Case matters"
+Variables named `apple` and `APPLE` are two different variables.
+```
+
+````smart header="Non-Latin letters are allowed, but not recommended"
+It is possible to use any language, including Cyrillic letters, Chinese logograms and so on, like this:
+
+```js
+let имя = '...';
+let 我 = '...';
+```
+
+Technically, there is no error here. However, there is an international convention to use English in variable names. Even if we're writing a small script, it may have a long life ahead. People from other countries may need to read it sometime.
+````
+
+````warn header="Reserved names"
+There is a [list of reserved words](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Lexical_grammar#Keywords), which cannot be used as variable names because they are used by the language itself.
+
+For example: `let`, `class`, `return`, and `function` are reserved.
+
+The code below gives a syntax error:
+
+```js run no-beautify
+let let = 5; // can't name a variable "let", error!
+let return = 5; // also can't name it "return", error!
+```
+````
+
+````warn header="An assignment without `use strict`"
+Normally, we need to define a variable before using it. But in the old times, it was technically possible to create a variable by a mere assignment of the value without using `let`. This still works now if we don't put `use strict` in our scripts to maintain compatibility with old scripts.
+
+```js run no-strict
+// note: no "use strict" in this example
+
+num = 5; // the variable "num" is created if it didn't exist
+
+console.log(num); // 5
+```
+
+This is a bad practice and would cause an error in strict mode:
+
+```js run
+"use strict";
+
+*!*
+num = 5; // error: num is not defined
+*/!*
+```
+````
diff --git a/1-js/01-getting-started/5-variables/variable-change.svg b/1-js/01-getting-started/5-variables/variable-change.svg
new file mode 100644
index 0000000000..7bcf5c48d7
--- /dev/null
+++ b/1-js/01-getting-started/5-variables/variable-change.svg
@@ -0,0 +1,53 @@
+
\ No newline at end of file
diff --git a/1-js/01-getting-started/5-variables/variable-message.svg b/1-js/01-getting-started/5-variables/variable-message.svg
new file mode 100644
index 0000000000..b9b8e2f35c
--- /dev/null
+++ b/1-js/01-getting-started/5-variables/variable-message.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/1-js/01-getting-started/5-variables/variable.svg b/1-js/01-getting-started/5-variables/variable.svg
new file mode 100644
index 0000000000..52c409d8ac
--- /dev/null
+++ b/1-js/01-getting-started/5-variables/variable.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/1-js/01-getting-started/6-constants/article.md b/1-js/01-getting-started/6-constants/article.md
new file mode 100644
index 0000000000..29a8c31418
--- /dev/null
+++ b/1-js/01-getting-started/6-constants/article.md
@@ -0,0 +1,56 @@
+# Constants
+
+To declare a constant (unchanging) variable, use `const` instead of `let`:
+
+```js
+const myBirthDate = '18.04.1982';
+```
+
+Variables declared using `const` are called "constants". They cannot be reassigned. An attempt to do so would cause an error:
+
+```js run
+const myBirthDate = '18.04.1982';
+
+myBirthDate = '01.01.2001'; // error, can't reassign the constant!
+```
+
+When we are sure that a variable must never change, we should declare it with `const` – not only to technically guarantee it, but also to clearly communicate this fact to future readers and maintainers of our code.
+
+## Uppercase constants
+
+There is a widespread practice to use constants as aliases for difficult-to-remember values.
+
+Such constants are named using capital letters and underscores.
+
+For instance, let's make constants for colors in so-called "web" (hexadecimal) format:
+
+```js run
+const COLOR_RED = "#F00";
+const COLOR_GREEN = "#0F0";
+const COLOR_BLUE = "#00F";
+const COLOR_ORANGE = "#FF7F00";
+
+// ...when we need to pick a color
+let color = COLOR_ORANGE;
+console.log(color); // #FF7F00
+```
+
+Benefits:
+
+- `COLOR_ORANGE` is much easier to remember than `"#FF7F00"`.
+- It is much easier to mistype in `"#FF7F00"` than in `COLOR_ORANGE`.
+- When reading the code, `COLOR_ORANGE` is much more meaningful than `#FF7F00`.
+
+When should we use capitals for a constant? Let's make that clear.
+
+Being a "constant" just means that a variable's value never changes. But some constants are known before execution. People also call them "hard-coded", because their values (such as the hexadecimal value for red) are embedded into the code. For them we should use capital letters.
+
+On the other hand, some constants are *calculated* at run time, during the execution, but do not change after their initial assignment.
+
+For instance, after a web page is loaded, we can store the time it took into a variable:
+
+```js
+const pageLoadTime = /* time taken by a webpage to load */;
+```
+
+The value of `pageLoadTime` will never change, so it's a constant. However, it's not known before the execution, it's not "hard-coded", this is why its name is not capitalized.
diff --git a/1-js/02-first-steps/05-types/1-string-quotes/solution.md b/1-js/01-getting-started/7-types/1-string-quotes/solution.md
similarity index 100%
rename from 1-js/02-first-steps/05-types/1-string-quotes/solution.md
rename to 1-js/01-getting-started/7-types/1-string-quotes/solution.md
diff --git a/1-js/02-first-steps/05-types/1-string-quotes/task.md b/1-js/01-getting-started/7-types/1-string-quotes/task.md
similarity index 100%
rename from 1-js/02-first-steps/05-types/1-string-quotes/task.md
rename to 1-js/01-getting-started/7-types/1-string-quotes/task.md
diff --git a/1-js/02-first-steps/05-types/article.md b/1-js/01-getting-started/7-types/article.md
similarity index 70%
rename from 1-js/02-first-steps/05-types/article.md
rename to 1-js/01-getting-started/7-types/article.md
index 26f3bcd53d..7d3d91798a 100644
--- a/1-js/02-first-steps/05-types/article.md
+++ b/1-js/01-getting-started/7-types/article.md
@@ -2,9 +2,11 @@
A value in JavaScript is always of a certain type. For example, a string or a number.
-There are eight basic data types in JavaScript. Here, we'll cover them in general and in the next chapters we'll talk about each of them in detail.
+There are 8 basic data types in JavaScript. Here we'll introduce them, and in the next chapters we'll talk about each of them in detail.
-We can put any type in a variable. For example, a variable can at one moment be a string and then store a number:
+JavaScript is a "dynamically typed" language. It means that a variable can store a value of any type, and it can change dynamically during execition.
+
+For example, `message` can store a string, and then be reassigned to a number:
```js
// no error
@@ -12,8 +14,6 @@ let message = "hello";
message = 123456;
```
-Programming languages that allow such things, such as JavaScript, are called "dynamically typed", meaning that there exist data types, but variables are not bound to any of them.
-
## Number
```js
@@ -32,29 +32,33 @@ Besides regular numbers, there are so-called "special numeric values" which also
We can get it as a result of division by zero:
```js run
- alert( 1 / 0 ); // Infinity
+ console.log( 1 / 0 ); // Infinity
```
Or just reference it directly:
```js run
- alert( Infinity ); // Infinity
+ console.log( Infinity ); // Infinity
```
- `NaN` represents a computational error. It is a result of an incorrect or an undefined mathematical operation, for instance:
```js run
- alert( "not a number" / 2 ); // NaN, such division is erroneous
+ console.log( "hello" / 2 ); // NaN, such division is erroneous
```
- `NaN` is sticky. Any further mathematical operation on `NaN` returns `NaN`:
+ `NaN` is "sticky". Any further mathematical operation on `NaN` returns `NaN`:
```js run
- alert( NaN + 1 ); // NaN
- alert( 3 * NaN ); // NaN
- alert( "not a number" / 2 - 1 ); // NaN
+ console.log( NaN + 1 ); // NaN
+ console.log( 3 * NaN ); // NaN
+ console.log( "hello" / 2 - 1 ); // NaN
+
+ // The only exception to this rule is:
+ console.log( NaN ** 0 ); // 1
+ // the double star ** is a "raising to power" operation
```
- So, if there's a `NaN` somewhere in a mathematical expression, it propagates to the whole result (there's only one exception to that: `NaN ** 0` is `1`).
+ This is natural, because `NaN` value represents an error, and there's no sense in doing computations with an error. So, if there's a `NaN` somewhere in a mathematical expression, it propagates to the whole result.
```smart header="Mathematical operations are safe"
Doing maths is "safe" in JavaScript. We can do anything: divide by zero, treat non-numeric strings as numbers, etc.
@@ -64,51 +68,38 @@ The script will never stop with a fatal error ("die"). At worst, we'll get `NaN`
Special numeric values formally belong to the "number" type. Of course they are not numbers in the common sense of this word.
-We'll see more about working with numbers in the chapter .
-
## BigInt [#bigint-type]
-In JavaScript, the "number" type cannot safely represent integer values larger than (253-1) (that's `9007199254740991`), or less than -(253-1) for negatives.
+In JavaScript, the "number" type cannot safely represent integer values larger than (253-1) (that's `9007199254740991`), or less than -(253-1) for negatives. There's a similar limitation for floating type values as well.
-To be really precise, the "number" type can store larger integers (up to 1.7976931348623157 * 10308), but outside of the safe integer range ±(253-1) there'll be a precision error, because not all digits fit into the fixed 64-bit storage. So an "approximate" value may be stored.
+Technically, we can assigns any numeric value, and there won't be an error. However, if the number is outside of this range, then some digits "won't fit" and will be lost, so we'll see an "approximate" value when we try to read from it.
-For example, these two numbers (right above the safe range) are the same:
+For example, let's try to store these two numbers, which are right above the safe range:
```js
console.log(9007199254740991 + 1); // 9007199254740992
console.log(9007199254740991 + 2); // 9007199254740992
```
-So to say, all odd integers greater than (253-1) can't be stored at all in the "number" type.
+As you can see, both outputs are identical. This is exactly for this reason – they don't fit and a tiny bit of precision is lost.
-For most purposes ±(253-1) range is quite enough, but sometimes we need the entire range of really big integers, e.g. for cryptography or microsecond-precision timestamps.
+For most real-life purposes ±(253-1) range is quite enough. However, sometimes we need to work with really big numbers, e.g. for cryptography purposes or to store a time with microsecond precision.
-`BigInt` type was recently added to the language to represent integers of arbitrary length.
+`BigInt` type can represent integers of arbitrary length.
A `BigInt` value is created by appending `n` to the end of an integer:
```js
// the "n" at the end means it's a BigInt
-const bigInt = 1234567890123456789012345678901234567890n;
+const bigInt = 1234567890123456789012345678901234567890*!*n*/!*;
```
-As `BigInt` numbers are rarely needed, we don't cover them here, but devoted them a separate chapter . Read it when you need such big numbers.
-
-
-```smart header="Compatibility issues"
-Right now, `BigInt` is supported in Firefox/Chrome/Edge/Safari, but not in IE.
-```
-
-You can check [*MDN* BigInt compatibility table](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/BigInt#Browser_compatibility) to know which versions of a browser are supported.
-
## String
-A string in JavaScript must be surrounded by quotes.
+A string in JavaScript must be enclosed into quotes, like this:
```js
let str = "Hello";
-let str2 = 'Single quotes are ok too';
-let phrase = `can embed another ${str}`;
```
In JavaScript, there are 3 types of quotes.
@@ -117,7 +108,7 @@ In JavaScript, there are 3 types of quotes.
2. Single quotes: `'Hello'`.
3. Backticks: `Hello`.
-Double and single quotes are "simple" quotes. There's practically no difference between them in JavaScript.
+Double and single quotes are "simple" quotes. There's no difference between them in JavaScript, besides being different characters.
Backticks are "extended functionality" quotes. They allow us to embed variables and expressions into a string by wrapping them in `${…}`, for example:
@@ -125,17 +116,17 @@ Backticks are "extended functionality" quotes. They allow us to embed variables
let name = "John";
// embed a variable
-alert( `Hello, *!*${name}*/!*!` ); // Hello, John!
+console.log( `Hello, *!*${name}*/!*!` ); // Hello, John!
// embed an expression
-alert( `the result is *!*${1 + 2}*/!*` ); // the result is 3
+console.log( `the result is *!*${1 + 2}*/!*` ); // the result is 3
```
The expression inside `${…}` is evaluated and the result becomes a part of the string. We can put anything in there: a variable like `name` or an arithmetical expression like `1 + 2` or something more complex.
Please note that this can only be done in backticks. Other quotes don't have this embedding functionality!
```js run
-alert( "the result is ${1 + 2}" ); // the result is ${1 + 2} (double quotes do nothing)
+console.log( "the result is ${1 + 2}" ); // the result is ${1 + 2} (double quotes do nothing)
```
We'll cover strings more thoroughly in the chapter .
@@ -164,7 +155,7 @@ Boolean values also come as a result of comparisons:
```js run
let isGreater = 4 > 1;
-alert( isGreater ); // true (the comparison result is "yes")
+console.log( isGreater ); // true (the comparison result is "yes")
```
We'll cover booleans more deeply in the chapter .
@@ -196,7 +187,7 @@ If a variable is declared, but not assigned, then its value is `undefined`:
```js run
let age;
-alert(age); // shows "undefined"
+console.log(age); // shows "undefined"
```
Technically, it is possible to explicitly assign `undefined` to a variable:
@@ -207,7 +198,7 @@ let age = 100;
// change the value to undefined
age = undefined;
-alert(age); // "undefined"
+console.log(age); // "undefined"
```
...But we don't recommend doing that. Normally, one uses `null` to assign an "empty" or "unknown" value to a variable, while `undefined` is reserved as a default initial value for unassigned things.
@@ -250,7 +241,7 @@ typeof null // "object" (2)
*/!*
*!*
-typeof alert // "function" (3)
+typeof console.log // "function" (3)
*/!*
```
@@ -258,7 +249,7 @@ The last three lines may need additional explanation:
1. `Math` is a built-in object that provides mathematical operations. We will learn it in the chapter . Here, it serves just as an example of an object.
2. The result of `typeof null` is `"object"`. That's an officially recognized error in `typeof`, coming from very early days of JavaScript and kept for compatibility. Definitely, `null` is not an object. It is a special value with a separate type of its own. The behavior of `typeof` is wrong here.
-3. The result of `typeof alert` is `"function"`, because `alert` is a function. We'll study functions in the next chapters where we'll also see that there's no special "function" type in JavaScript. Functions belong to the object type. But `typeof` treats them differently, returning `"function"`. That also comes from the early days of JavaScript. Technically, such behavior isn't correct, but can be convenient in practice.
+3. The result of `typeof console.log` is `"function"`, because `console.log` is a function. We'll study functions in the next chapters where we'll also see that there's no special "function" type in JavaScript. Functions belong to the object type. But `typeof` treats them differently, returning `"function"`. That also comes from the early days of JavaScript. Technically, such behavior isn't correct, but can be convenient in practice.
```smart header="The `typeof(x)` syntax"
You may also come across another syntax: `typeof(x)`. It's the same as `typeof x`.
diff --git a/1-js/02-first-steps/01-hello-world/1-hello-alert/index.html b/1-js/02-first-steps/01-hello-world/1-hello-alert/index.html
deleted file mode 100644
index ff1d871b08..0000000000
--- a/1-js/02-first-steps/01-hello-world/1-hello-alert/index.html
+++ /dev/null
@@ -1,12 +0,0 @@
-
-
-
-
-
-
-
-
-
-
diff --git a/1-js/02-first-steps/01-hello-world/1-hello-alert/solution.md b/1-js/02-first-steps/01-hello-world/1-hello-alert/solution.md
deleted file mode 100644
index 81552913b9..0000000000
--- a/1-js/02-first-steps/01-hello-world/1-hello-alert/solution.md
+++ /dev/null
@@ -1,2 +0,0 @@
-
-[html src="http://github.com/index.html"]
diff --git a/1-js/02-first-steps/01-hello-world/1-hello-alert/solution.view/index.html b/1-js/02-first-steps/01-hello-world/1-hello-alert/solution.view/index.html
deleted file mode 100644
index 45e6744b3a..0000000000
--- a/1-js/02-first-steps/01-hello-world/1-hello-alert/solution.view/index.html
+++ /dev/null
@@ -1,12 +0,0 @@
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/1-js/02-first-steps/01-hello-world/1-hello-alert/task.md b/1-js/02-first-steps/01-hello-world/1-hello-alert/task.md
deleted file mode 100644
index afed6a91d3..0000000000
--- a/1-js/02-first-steps/01-hello-world/1-hello-alert/task.md
+++ /dev/null
@@ -1,12 +0,0 @@
-importance: 5
-
----
-
-# Show an alert
-
-Create a page that shows a message "I'm JavaScript!".
-
-Do it in a sandbox, or on your hard drive, doesn't matter, just ensure that it works.
-
-[demo src="http://github.com/solution"]
-
diff --git a/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/alert.js b/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/alert.js
deleted file mode 100644
index 4de725971d..0000000000
--- a/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/alert.js
+++ /dev/null
@@ -1 +0,0 @@
-alert("I'm JavaScript!");
\ No newline at end of file
diff --git a/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/index.html b/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/index.html
deleted file mode 100644
index 10895f8fe2..0000000000
--- a/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/index.html
+++ /dev/null
@@ -1,10 +0,0 @@
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/solution.md b/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/solution.md
deleted file mode 100644
index f42c41e6db..0000000000
--- a/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/solution.md
+++ /dev/null
@@ -1,8 +0,0 @@
-The HTML code:
-
-[html src="http://github.com/index.html"]
-
-For the file `alert.js` in the same folder:
-
-[js src="http://github.com/alert.js"]
-
diff --git a/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/task.md b/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/task.md
deleted file mode 100644
index 26168d6a76..0000000000
--- a/1-js/02-first-steps/01-hello-world/2-hello-alert-ext/task.md
+++ /dev/null
@@ -1,9 +0,0 @@
-importance: 5
-
----
-
-# Show an alert with an external script
-
-Take the solution of the previous task . Modify it by extracting the script content into an external file `alert.js`, residing in the same folder.
-
-Open the page, ensure that the alert works.
diff --git a/1-js/02-first-steps/01-hello-world/article.md b/1-js/02-first-steps/01-hello-world/article.md
deleted file mode 100644
index 35f82bf5d7..0000000000
--- a/1-js/02-first-steps/01-hello-world/article.md
+++ /dev/null
@@ -1,132 +0,0 @@
-# Hello, world!
-
-This part of the tutorial is about core JavaScript, the language itself.
-
-But we need a working environment to run our scripts and, since this book is online, the browser is a good choice. We'll keep the amount of browser-specific commands (like `alert`) to a minimum so that you don't spend time on them if you plan to concentrate on another environment (like Node.js). We'll focus on JavaScript in the browser in the [next part](/ui) of the tutorial.
-
-So first, let's see how we attach a script to a webpage. For server-side environments (like Node.js), you can execute the script with a command like `"node my.js"`.
-
-
-## The "script" tag
-
-JavaScript programs can be inserted almost anywhere into an HTML document using the `
-*/!*
-
-