From 939a0ad80eefa79c0a997af54032fb5411298402 Mon Sep 17 00:00:00 2001
From: Nisarg-Chokshi <101206240+Nisarg-Chokshi@users.noreply.github.com>
Date: Tue, 27 Sep 2022 16:47:12 +0530
Subject: [PATCH] Adding Arithmetic & Bitwise operators - JS roadmap (#1878)
* Adding Arithmetic & Bitwise operators
* Rectified Typos in the existing files
---
.../101-history-of-javascript.md | 2 +-
.../103-how-to-run-javascript.md | 2 +-
.../100-variable-declarations/readme.md | 2 +-
.../101-javascript-variables/101-hoisting.md | 2 +-
.../content/101-javascript-variables/readme.md | 2 +-
.../101-object/100-prototype.md | 2 +-
.../100-indexed-collections/100-arrays.md | 2 +-
.../103-for-statement.md | 2 +-
.../102-arithmetic-operators.md | 15 ++++++++++++++-
.../103-bitwise-operators.md | 18 +++++++++++++++++-
.../100-recursion.md | 2 +-
.../101-lexical-scoping.md | 2 +-
.../102-closures.md | 2 +-
.../111-javascript-this-keyword/readme.md | 2 +-
.../104-promises/readme.md | 2 +-
.../114-javascript-iterators-and-generators.md | 2 +-
16 files changed, 45 insertions(+), 16 deletions(-)
diff --git a/content/roadmaps/106-javascript/content/100-javascript-introduction/101-history-of-javascript.md b/content/roadmaps/106-javascript/content/100-javascript-introduction/101-history-of-javascript.md
index f66968dbd..0a30ca884 100644
--- a/content/roadmaps/106-javascript/content/100-javascript-introduction/101-history-of-javascript.md
+++ b/content/roadmaps/106-javascript/content/100-javascript-introduction/101-history-of-javascript.md
@@ -1,6 +1,6 @@
# History of JavaScript
-JavaScript was initially created by Brendan Eich of NetScape and was first announced in a press release by Netscape in 1995. It has a bizarre history of naming; initally it was named Mocha by the creator, which was later renamed to LiveScript. In 1996, about a year later after the release, NetScape decided to rename it to be JavaScript with hopes of capitalizing on the Java community (although JavaScript did not have any relationship with Java) and released Netscape 2.0 with the official support of JavaScript.
+JavaScript was initially created by Brendan Eich of NetScape and was first announced in a press release by Netscape in 1995. It has a bizarre history of naming; initially, it was named Mocha by the creator, which was later renamed LiveScript. In 1996, about a year later after the release, NetScape decided to rename it to JavaScript with hopes of capitalizing on the Java community (although JavaScript did not have any relationship with Java) and released Netscape 2.0 with the official support of JavaScript.
Free Content
Brief History of JavaScript
diff --git a/content/roadmaps/106-javascript/content/100-javascript-introduction/103-how-to-run-javascript.md b/content/roadmaps/106-javascript/content/100-javascript-introduction/103-how-to-run-javascript.md
index 780d20764..3d849d042 100644
--- a/content/roadmaps/106-javascript/content/100-javascript-introduction/103-how-to-run-javascript.md
+++ b/content/roadmaps/106-javascript/content/100-javascript-introduction/103-how-to-run-javascript.md
@@ -1,6 +1,6 @@
# How to run Javascript
-JavaScript can be run in the browser by including the external script file using the `script` tag, write it within the HTML page using the `script` tag again, run it in the browser console or you can also use [REPL](https://www.digitalocean.com/community/tutorials/how-to-use-the-node-js-repl).
+JavaScript can be run in the browser by including the external script file using the `script` tag, writing it within the HTML page using the `script` tag again, running it in the browser console or you can also use [REPL](https://www.digitalocean.com/community/tutorials/how-to-use-the-node-js-repl).
Free Content
How To Add JavaScript to HTML
diff --git a/content/roadmaps/106-javascript/content/101-javascript-variables/100-variable-declarations/readme.md b/content/roadmaps/106-javascript/content/101-javascript-variables/100-variable-declarations/readme.md
index aee92e899..791e79419 100644
--- a/content/roadmaps/106-javascript/content/101-javascript-variables/100-variable-declarations/readme.md
+++ b/content/roadmaps/106-javascript/content/101-javascript-variables/100-variable-declarations/readme.md
@@ -1,6 +1,6 @@
# Variable Declarations
-To use variables in JavaScript, we first need to create it i.e. declare a variable. To declare variables, we use one of the `var`, `let` or `const` keywords.
+To use variables in JavaScript, we first need to create it i.e. declare a variable. To declare variables, we use one of the `var`, `let`, or `const` keywords.
Free Content
Storing the information you need — Variables
diff --git a/content/roadmaps/106-javascript/content/101-javascript-variables/101-hoisting.md b/content/roadmaps/106-javascript/content/101-javascript-variables/101-hoisting.md
index c94874996..f219e787b 100644
--- a/content/roadmaps/106-javascript/content/101-javascript-variables/101-hoisting.md
+++ b/content/roadmaps/106-javascript/content/101-javascript-variables/101-hoisting.md
@@ -1,6 +1,6 @@
# Hoisting
-JavaScript Hoisting refers to the process whereby the interpreter appears to move the declaration of functions, variables or classes to the top of their scope, prior to execution of the code.
+JavaScript Hoisting refers to the process whereby the interpreter appears to move the declaration of functions, variables, or classes to the top of their scope, prior to execution of the code.
Free Content
What is Hoisting - MDN Docs
diff --git a/content/roadmaps/106-javascript/content/101-javascript-variables/readme.md b/content/roadmaps/106-javascript/content/101-javascript-variables/readme.md
index 008758544..166b8e3f6 100644
--- a/content/roadmaps/106-javascript/content/101-javascript-variables/readme.md
+++ b/content/roadmaps/106-javascript/content/101-javascript-variables/readme.md
@@ -1,6 +1,6 @@
# Javascript Variables
-Most of the time, a JavaScript application needs to work with information. To store and represent this information in JavaScript codebase, we use variables. A variable is a container for a value.
+Most of the time, a JavaScript application needs to work with information. To store and represent this information in the JavaScript codebase, we use variables. A variable is a container for a value.
Free Content
JavaScript Variables
diff --git a/content/roadmaps/106-javascript/content/102-javascript-datatypes/101-object/100-prototype.md b/content/roadmaps/106-javascript/content/102-javascript-datatypes/101-object/100-prototype.md
index 20bdf20c0..bebec3e7d 100644
--- a/content/roadmaps/106-javascript/content/102-javascript-datatypes/101-object/100-prototype.md
+++ b/content/roadmaps/106-javascript/content/102-javascript-datatypes/101-object/100-prototype.md
@@ -1,6 +1,6 @@
# Prototypes
-JavaScript is an object-oriented language built around a prototype model. In JavaScript, every object inherits properties from its prototype, if there is any. A prototype is simply an object from which another object inherits properties. To create complex programs using JavaScript, one has to be proficient in working with prototypes — they form the very core of OOP in the language.
+JavaScript is an object-oriented language built around a prototype model. In JavaScript, every object inherits properties from its prototype, if there are any. A prototype is simply an object from which another object inherits properties. To create complex programs using JavaScript, one has to be proficient in working with prototypes — they form the very core of OOP in the language.
Free Content
Prototypes in JavaScript - A Comprehensive Guide
diff --git a/content/roadmaps/106-javascript/content/104-javascript-data-structures/100-indexed-collections/100-arrays.md b/content/roadmaps/106-javascript/content/104-javascript-data-structures/100-indexed-collections/100-arrays.md
index 96581402c..98d18f2fd 100644
--- a/content/roadmaps/106-javascript/content/104-javascript-data-structures/100-indexed-collections/100-arrays.md
+++ b/content/roadmaps/106-javascript/content/104-javascript-data-structures/100-indexed-collections/100-arrays.md
@@ -1,6 +1,6 @@
# Arrays
-Arrays are objects that store a collection of items and can be assigned to a variable. They have their own methods that can perform operations on the array.
+Arrays are objects that store a collection of items and can be assigned to a variable. They have their methods that can perform operations on the array.
Free Content
Working with Arrays in JavaScript
diff --git a/content/roadmaps/106-javascript/content/106-javascript-loops-iterations/103-for-statement.md b/content/roadmaps/106-javascript/content/106-javascript-loops-iterations/103-for-statement.md
index 80c22b7bf..9a0893ce4 100644
--- a/content/roadmaps/106-javascript/content/106-javascript-loops-iterations/103-for-statement.md
+++ b/content/roadmaps/106-javascript/content/106-javascript-loops-iterations/103-for-statement.md
@@ -1,6 +1,6 @@
# The `for` loop
-The `for` loop is a standard control-flow construct in many programming languages, including JavaScript. It's commonly used to iterate over given sequences or iterate a known number of times, and execute a piece of code for each iteration.
+The `for` loop is a standard control-flow construct in many programming languages, including JavaScript. It's commonly used to iterate over given sequences or iterate a known number of times and execute a piece of code for each iteration.
Free Content
JavaScript `for` Loop - CodeGuage
diff --git a/content/roadmaps/106-javascript/content/108-javascript-expressions-and-operators/102-arithmetic-operators.md b/content/roadmaps/106-javascript/content/108-javascript-expressions-and-operators/102-arithmetic-operators.md
index 461e9fd10..5df5323e3 100644
--- a/content/roadmaps/106-javascript/content/108-javascript-expressions-and-operators/102-arithmetic-operators.md
+++ b/content/roadmaps/106-javascript/content/108-javascript-expressions-and-operators/102-arithmetic-operators.md
@@ -1 +1,14 @@
-# Arithmetic operators
\ No newline at end of file
+# Arithmetic operators
+
+The Arithmetic operators perform addition, subtraction, multiplication, division, exponentiation, and remainder perations.
+
+Arithmetic operators in JavaScript are as follows:
+- `+` (Addition)
+- `-` (Subtraction)
+- `*` (Multiplication)
+- `/` (Division)
+- `%` (Remainder)
+- `**` (Exponentiation)
+
+Arithmetic Operators - MDN
+Arithmetic Operators - JavaScript.info
diff --git a/content/roadmaps/106-javascript/content/108-javascript-expressions-and-operators/103-bitwise-operators.md b/content/roadmaps/106-javascript/content/108-javascript-expressions-and-operators/103-bitwise-operators.md
index b0b417f19..a9a05fad0 100644
--- a/content/roadmaps/106-javascript/content/108-javascript-expressions-and-operators/103-bitwise-operators.md
+++ b/content/roadmaps/106-javascript/content/108-javascript-expressions-and-operators/103-bitwise-operators.md
@@ -1 +1,17 @@
-# Bitwise operators
\ No newline at end of file
+# Bitwise operators
+
+Bitwise operators treat arguments as 32-bits (zeros & ones) and work on the level of their binary representation.
+Ex. Decimal number `9` has a binary representation of `1001`. Bitwise operators perform their operations on such binary representations, but they return standard JavaScript numerical values.
+
+Bitwise operators in JavaScript are as follows:
+
+- `&` (AND)
+- `|` (OR)
+- `^` (XOR)
+- `~` (NOT)
+- `<<` (Left SHIFT)
+- `>>` (Right SHIFT)
+- `>>>` (Zero-Fill Right SHIFT)
+
+Bitwise Operators - MDN
+Bitwise Operators - JavaScript.info
\ No newline at end of file
diff --git a/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/100-recursion.md b/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/100-recursion.md
index 6f5657b80..4415dc5be 100644
--- a/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/100-recursion.md
+++ b/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/100-recursion.md
@@ -1,6 +1,6 @@
# Recursion
-One of the most powerfula and elegant concept of functions, recursion is when a function invokes itself. Such a function is called a **_recursive function_**. As recursion happens, the underlying code of the recursive function gets executed again and again until a terminating condition, called the _base case_, gets fulfilled. As you dive into the world of algorithms, you'll come across recursion in many many instances.
+One of the most powerful and elegant concept of functions, recursion is when a function invokes itself. Such a function is called a **_recursive function_**. As recursion happens, the underlying code of the recursive function gets executed again and again until a terminating condition, called the _base case_, gets fulfilled. As you dive into the world of algorithms, you'll come across recursion in many many instances.
Free Content
Recursion and Stack
diff --git a/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/101-lexical-scoping.md b/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/101-lexical-scoping.md
index df348e03d..7c321c3ca 100644
--- a/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/101-lexical-scoping.md
+++ b/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/101-lexical-scoping.md
@@ -1,6 +1,6 @@
# Lexical scoping
-Before one can make intuition of closures in JavaScript, it's important to first get the hang of the term '**_lexical environment_**'. In simple words, the lexical environment for a function `f` simply refers to the environment enclosing that function's definition in the source code.
+Before one can make an intuition of closures in JavaScript, it's important to first get the hang of the term '**_lexical environment_**'. In simple words, the lexical environment for a function `f` simply refers to the environment enclosing that function's definition in the source code.
Free Content
What is a lexical environment? - JavaScript - CodeGuage
diff --git a/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/102-closures.md b/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/102-closures.md
index 020e8f5bb..aa4003a09 100644
--- a/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/102-closures.md
+++ b/content/roadmaps/106-javascript/content/109-javascript-functions/105-scope-and-function-stack/102-closures.md
@@ -1,6 +1,6 @@
# Closures
-Function closures are one of the most powerful, yet most misunderstood, concepts of JavaScript that are actually really simple to understand. A closure refers to a function along with its lexical environment. It is essentially what allows us to return a function `A`, from another function `B`, that remembers the local variables defined in `B`, even after `B` exits. The idea of closures is employed in nearly every other JavaScript program, hence, it's paramount for a JavaScript developer to know of it really well.
+Function closures are one of the most powerful, yet most misunderstood, concepts of JavaScript that are actually really simple to understand. A closure refers to a function along with its lexical environment. It is essentially what allows us to return a function `A`, from another function `B`, that remembers the local variables defined in `B`, even after `B` exits. The idea of closures is employed in nearly every other JavaScript program, hence, it's paramount for a JavaScript developer to know it really well.
Free Content
JavaScript Closures - The Simplest Explanation
diff --git a/content/roadmaps/106-javascript/content/111-javascript-this-keyword/readme.md b/content/roadmaps/106-javascript/content/111-javascript-this-keyword/readme.md
index c706f9142..1f3be6938 100644
--- a/content/roadmaps/106-javascript/content/111-javascript-this-keyword/readme.md
+++ b/content/roadmaps/106-javascript/content/111-javascript-this-keyword/readme.md
@@ -1,6 +1,6 @@
# This Keyword
-In JavaScript, the `this` keyword is a little different compared to other languages. It refers to an object, but it depends on how or where its being invoked. It also has some differences between strict mode and non-strict mode.
+In JavaScript, the `this` keyword is a little different compared to other languages. It refers to an object, but it depends on how or where it is being invoked. It also has some differences between strict mode and non-strict mode.
- In an object method, `this` refers to the object
- Alone, `this` refers to the global object
diff --git a/content/roadmaps/106-javascript/content/112-javascript-asynchronous-javascript/104-promises/readme.md b/content/roadmaps/106-javascript/content/112-javascript-asynchronous-javascript/104-promises/readme.md
index 0a4501bf2..57aefbe51 100644
--- a/content/roadmaps/106-javascript/content/112-javascript-asynchronous-javascript/104-promises/readme.md
+++ b/content/roadmaps/106-javascript/content/112-javascript-asynchronous-javascript/104-promises/readme.md
@@ -1,6 +1,6 @@
# Promises
-Promises are a much better way to work with asynchronous code in JavaScript than the old and error-prone callback approach. They were introduced into JavaScript with ECMAScript 6. Using promises, we can manage extremely complex asynchronous code with rigorous error-handling set up, write code in a more or less synchronous style, and keep ourselves from running into the so-called callback hell.
+Promises are a much better way to work with asynchronous code in JavaScript than the old and error-prone callback approach. They were introduced into JavaScript with ECMAScript 6. Using promises, we can manage extremely complex asynchronous code with rigorous error-handling setup, write code in a more or less synchronous style, and keep ourselves from running into the so-called callback hell.
Free Content
A Detailed Introduction to Promises
diff --git a/content/roadmaps/106-javascript/content/114-javascript-iterators-and-generators.md b/content/roadmaps/106-javascript/content/114-javascript-iterators-and-generators.md
index e70af0d56..f7913bf95 100644
--- a/content/roadmaps/106-javascript/content/114-javascript-iterators-and-generators.md
+++ b/content/roadmaps/106-javascript/content/114-javascript-iterators-and-generators.md
@@ -1,6 +1,6 @@
# Javascript Iterators and Generators
-Iterators and generators, introduced into JavaScript with ECMAScript 6, represent an extremely useful concept related to iteration in the language. Iterators are objects, abiding by the iterator protocol, that allow us to easily iterate over a given sequence in various ways, such as using the `for...of` loop. Generators, on the other hand, allow us to use functions and the `yield` keyword to easily define iterable sequences that are iterators as well.
+Iterators and generators, introduced into JavaScript with ECMAScript 6, represent an extremely useful concept related to iteration in the language. Iterators are objects, abiding by the iterator protocol, that allows us to easily iterate over a given sequence in various ways, such as using the `for...of` loop. Generators, on the other hand, allow us to use functions and the `yield` keyword to easily define iterable sequences that are iterators as well.
Free Content
Introduction to Iterators - Advanced JavaScript