diff --git a/02_Day_Data_types/02_day_data_types.md b/02_Day_Data_types/02_day_data_types.md index e27d43d7e..ef8c555ad 100644 --- a/02_Day_Data_types/02_day_data_types.md +++ b/02_Day_Data_types/02_day_data_types.md @@ -450,7 +450,7 @@ console.log(firstName.length) // 8 2. *Accessing characters in a string*: We can access each character in a string using its index. In programming, counting starts from 0. The first index of the string is zero, and the last index is the length of the string minus one. - ![Accessing sting by index](../images/string_indexes.png) + ![Accessing string by index](../images/string_indexes.png) Let us access different characters in 'JavaScript' string. diff --git a/03_Day_Booleans_operators_date/03_booleans_operators_date.md b/03_Day_Booleans_operators_date/03_booleans_operators_date.md index bb376ae46..861f5cf51 100644 --- a/03_Day_Booleans_operators_date/03_booleans_operators_date.md +++ b/03_Day_Booleans_operators_date/03_booleans_operators_date.md @@ -556,7 +556,7 @@ console.log(`${date}/${month}/${year} ${hours}:${minutes}`) // 4/1/2020 0:56 The area of the triangle is 100 ``` -1. Write a script that prompt the user to enter side a, side b, and side c of the triangle and and calculate the perimeter of triangle (perimeter = a + b + c) +1. Write a script that prompt the user to enter side a, side b, and side c of the triangle and calculate the perimeter of triangle (perimeter = a + b + c) ```sh Enter side a: 5 @@ -613,7 +613,7 @@ console.log(`${date}/${month}/${year} ${hours}:${minutes}`) // 4/1/2020 0:56 You are 15. You will be allowed to drive after 3 years. ``` -1. Write a script that prompt the user to enter number of years. Calculate the number of seconds a person can live. Assume some one lives just hundred years +1. Write a script that prompt the user to enter number of years. Calculate the number of seconds a person can live. Assume someone lives just hundred years ```sh Enter number of years you live: 100 diff --git a/04_Day_Conditionals/04_day_conditionals.md b/04_Day_Conditionals/04_day_conditionals.md index 010084499..eab68898f 100644 --- a/04_Day_Conditionals/04_day_conditionals.md +++ b/04_Day_Conditionals/04_day_conditionals.md @@ -318,12 +318,12 @@ isRaining 2 is an even number Enter a number: 9 - 9 is is an odd number. + 9 is an odd number. ``` ### Exercises: Level 2 -1. Write a code which can give grades to students according to theirs scores: +1. Write a code which can give grades to students according to their scores: - 80-100, A - 70-89, B - 60-69, C diff --git a/08_Day_Objects/08_day_objects.md b/08_Day_Objects/08_day_objects.md index 69f5dc429..9119bd73c 100644 --- a/08_Day_Objects/08_day_objects.md +++ b/08_Day_Objects/08_day_objects.md @@ -430,7 +430,7 @@ console.log(copyPerson.hasOwnProperty('score')) ### Exercises: Level 1 1. Create an empty object called dog -1. Print the the dog object on the console +1. Print the dog object on the console 1. Add name, legs, color, age and bark properties for the dog object. The bark property is a method which return _woof woof_ 1. Get name, legs, color, age and bark value from the dog object 1. Set new properties the dog object: breed, getDogInfo diff --git a/10_Day_Sets_and_Maps/10_day_Sets_and_Maps.md b/10_Day_Sets_and_Maps/10_day_Sets_and_Maps.md index 25dafe988..bdc9fa3c9 100644 --- a/10_Day_Sets_and_Maps/10_day_Sets_and_Maps.md +++ b/10_Day_Sets_and_Maps/10_day_Sets_and_Maps.md @@ -222,7 +222,7 @@ Set(5) {5, 3, 2, 9, 4} ### Union of sets -To find a union to two sets can be achieved using spread operator. Lets find the union of set A and set B (A U B) +To find a union of two sets can be achieved using spread operator. Let's find the union of set A and set B (A U B) ```js let a = [1, 2, 3, 4, 5] @@ -242,7 +242,7 @@ Set(6) {1, 2, 3, 4, 5,6} ### Intersection of sets -To find an intersection of two sets can be achieved using filter. Lets find the intersection of set A and set B (A ∩ B) +To find an intersection of two sets can be achieved using filter. Let's find the intersection of set A and set B (A ∩ B) ```js let a = [1, 2, 3, 4, 5] @@ -263,7 +263,7 @@ Set(3) {3, 4, 5} ### Difference of sets -To find an the difference between two sets can be achieved using filter. Lets find the different of set A and set B (A \ B) +To find the difference between two sets can be achieved using filter. Let's find the difference of set A and set B (A \ B) ```js let a = [1, 2, 3, 4, 5] diff --git a/14_Day_Error_handling/13_day_console_object_methods.md b/14_Day_Error_handling/13_day_console_object_methods.md index d9fba8dbd..36b66794d 100644 --- a/14_Day_Error_handling/13_day_console_object_methods.md +++ b/14_Day_Error_handling/13_day_console_object_methods.md @@ -82,7 +82,7 @@ ReferenceError: fistName is not defined at :4:20 In any case it will be executed ``` -The catch block take a parameter. It is common to pass e, err or error as a parameter to the catch block. This parameter is an object and it has name and message keys. Lets use the name and message. +The catch block takes a parameter. It is common to pass e, err or error as a parameter to the catch block. This parameter is an object and it has name and message keys. Let's use the name and message. ```js try { let lastName = 'Yetayeh' diff --git a/17_Day_Web_storages/17_day_web_storages.md b/17_Day_Web_storages/17_day_web_storages.md index 348123233..44c58d1bf 100644 --- a/17_Day_Web_storages/17_day_web_storages.md +++ b/17_Day_Web_storages/17_day_web_storages.md @@ -75,7 +75,7 @@ Some use case of Web Storages are For the examples mentioned above, it makes sense to use localStorage. You may be wondering, then, when we should use sessionStorage. -In cases, we want to to get rid of the data as soon as the window is closed. Or, perhaps, if we do not want the application to interfere with the same application that’s open in another window. These scenarios are served best with sessionStorage. +In cases, we want to get rid of the data as soon as the window is closed. Or, perhaps, if we do not want the application to interfere with the same application that’s open in another window. These scenarios are served best with sessionStorage. Now, let us see how make use of these Web Storage APIs. diff --git a/20_Day_Writing_clean_codes/20_day_writing_clean_codes.md b/20_Day_Writing_clean_codes/20_day_writing_clean_codes.md index 8579b6b6a..afc0ba674 100644 --- a/20_Day_Writing_clean_codes/20_day_writing_clean_codes.md +++ b/20_Day_Writing_clean_codes/20_day_writing_clean_codes.md @@ -180,12 +180,12 @@ const showDateTime = () => { } ``` -The `new Dat().toLocaleString()` can also be used to display current date time. The `toLocaleString()` methods takes different arguments. You may learn more about date and time from this [link](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString). +The `new Date().toLocaleString()` can also be used to display current date time. The `toLocaleString()` methods takes different arguments. You may learn more about date and time from this [link](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toLocaleString). #### Loops -We coverer many types of loops in this challenges. The regular for loop, while loop, do while loop, for of loop, forEach loop and for in loop. -Lets see how we use them: +We covered many types of loops in this challenge. The regular for loop, while loop, do while loop, for of loop, forEach loop and for in loop. +Let's see how we use them: ```js for (let i = 0; i < n; i++){ diff --git a/21_Day_DOM/21_day_dom.md b/21_Day_DOM/21_day_dom.md index af46260f0..4b12664a2 100644 --- a/21_Day_DOM/21_day_dom.md +++ b/21_Day_DOM/21_day_dom.md @@ -154,7 +154,7 @@ const allTitles = document.querySelectorAll('.title') // the same goes for selec ### Adding attribute -An attribute is added in the opening tag of HTML which gives additional information about the element. Common HTML attributes: id, class, src, style, href,disabled, title, alt. Lets add id and class for the fourth title. +An attribute is added in the opening tag of HTML which gives additional information about the element. Common HTML attributes: id, class, src, style, href, disabled, title, alt. Let's add id and class for the fourth title. ```js const titles = document.querySelectorAll('h1') @@ -351,7 +351,7 @@ As you have notice, the properties of css when we use it in JavaScript is going ### Exercise: Level 1 1. Create an index.html file and put four p elements as above: Get the first paragraph by using **_document.querySelector(tagname)_** and tag name -2. Get each of the the paragraph using **_document.querySelector('#id')_** and by their id +2. Get each of the paragraphs using **_document.querySelector('#id')_** and by their id 3. Get all the p as nodeList using **_document.querySelectorAll(tagname)_** and by their tag name 4. Loop through the nodeList and get the text content of each paragraph 5. Set a text content to paragraph the fourth paragraph,**_Fourth Paragraph_**