From e1b87166e8d9a7edc3e0e5681e0e282b3455e651 Mon Sep 17 00:00:00 2001 From: Joseph Bak <36170953+josephbak@users.noreply.github.com> Date: Sat, 2 Apr 2022 18:21:21 -0400 Subject: [PATCH] Some fixes in 10_day_Sets_and_Maps.md Fixed typos, wrong outputs, and indents in 10_day_Sets_and_Maps.md. --- 10_Day_Sets_and_Maps/10_day_Sets_and_Maps.md | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) 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 c888bb5..0acdd1c 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 @@ -44,8 +44,8 @@ ## Set -Set is a collection of elements. Set can only contains unique elements. -Lets see how to create a set +Set is a collection of elements. Set can only contain unique elements. +Let's see how to create a set ### Creating an empty set @@ -55,7 +55,7 @@ console.log(companies) ``` ```sh -{} +Set(0) {} ``` ### Creating set from array @@ -170,7 +170,7 @@ console.log(companies) ``` ```sh -{} +Set(0) {} ``` @@ -202,7 +202,7 @@ console.log(counts) ``` ```js -;[ +[ { lang: 'English', count: 3 }, { lang: 'Finnish', count: 1 }, { lang: 'French', count: 2 }, @@ -345,7 +345,7 @@ Helsinki ### Checking key in Map -Check if a key exist in a map using _has_ method. It returns _true_ or _false_. +Check if a key exists in a map using _has_ method. It returns _true_ or _false_. ```js console.log(countriesMap.has('Finland')) @@ -364,14 +364,14 @@ for (const country of countriesMap) { ``` ```sh -(2) ["Finland", "Helsinki"] -(2) ["Sweden", "Stockholm"] -(2) ["Norway", "Oslo"] +["Finland", "Helsinki"] +["Sweden", "Stockholm"] +["Norway", "Oslo"] ``` ```js for (const [country, city] of countriesMap){ -console.log(country, city) + console.log(country, city) } ```