Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(curriculum): Updated step 74 of spreadsheet project and added step 75 and step 76 #54417

Original file line number Diff line number Diff line change
Expand Up @@ -310,120 +310,128 @@
"title": "Step 74"
},
{
"id": "646d40c543943ec250039682",
"id": "661f48f412d7631a1d9c30e6",
"title": "Step 75"
},
{
"id": "646d40fe4b7b50c30c2b4cd8",
"id": "661f49650572031c6ebdb8e3",
"title": "Step 76"
},
{
"id": "646d41e23b583fc3b8cc4579",
"id": "646d40c543943ec250039682",
"title": "Step 77"
},
{
"id": "646d423fade4a9c4636acd13",
"id": "646d40fe4b7b50c30c2b4cd8",
"title": "Step 78"
},
{
"id": "646d42f58deb2fc52adc6611",
"id": "646d41e23b583fc3b8cc4579",
"title": "Step 79"
},
{
"id": "646d43587d926bc5b6cb2e50",
"id": "646d423fade4a9c4636acd13",
"title": "Step 80"
},
{
"id": "646d448479c8fdc8dcec868c",
"id": "646d42f58deb2fc52adc6611",
"title": "Step 81"
},
{
"id": "646d44da986f2bc9b72f5fe2",
"id": "646d43587d926bc5b6cb2e50",
"title": "Step 82"
},
{
"id": "646d451c2e44afca71b67818",
"id": "646d448479c8fdc8dcec868c",
"title": "Step 83"
},
{
"id": "646d4554721d43cb19a68bc4",
"id": "646d44da986f2bc9b72f5fe2",
"title": "Step 84"
},
{
"id": "646d45b739da5ecbf830c108",
"id": "646d451c2e44afca71b67818",
"title": "Step 85"
},
{
"id": "646d45ee725632cca2555146",
"id": "646d4554721d43cb19a68bc4",
"title": "Step 86"
},
{
"id": "646d4626420eeecd51f241c2",
"id": "646d45b739da5ecbf830c108",
"title": "Step 87"
},
{
"id": "646d467c6994f4ce0dc416a4",
"id": "646d45ee725632cca2555146",
"title": "Step 88"
},
{
"id": "646d46c03e7d02cecb30f021",
"id": "646d4626420eeecd51f241c2",
"title": "Step 89"
},
{
"id": "646d4717a689e1cfa232e357",
"id": "646d467c6994f4ce0dc416a4",
"title": "Step 90"
},
{
"id": "646d4769ba65f1d05ef6b634",
"id": "646d46c03e7d02cecb30f021",
"title": "Step 91"
},
{
"id": "646d47c8f58107d10f1e5106",
"id": "646d4717a689e1cfa232e357",
"title": "Step 92"
},
{
"id": "646d4813c17b37d1e261a566",
"id": "646d4769ba65f1d05ef6b634",
"title": "Step 93"
},
{
"id": "646d486aec20f7d2a581cc36",
"id": "646d47c8f58107d10f1e5106",
"title": "Step 94"
},
{
"id": "646d48b936802fd34c3f05af",
"id": "646d4813c17b37d1e261a566",
"title": "Step 95"
},
{
"id": "646d498c8ebc31d3f753b22e",
"id": "646d486aec20f7d2a581cc36",
"title": "Step 96"
},
{
"id": "646d49bfff9079d4b38df115",
"id": "646d48b936802fd34c3f05af",
"title": "Step 97"
},
{
"id": "646d4a07a8fb14d55cd70e09",
"id": "646d498c8ebc31d3f753b22e",
"title": "Step 98"
},
{
"id": "6491d38f5b09a021c4b5d5fe",
"id": "646d49bfff9079d4b38df115",
"title": "Step 99"
},
{
"id": "646d4a5b32a1cad6165df286",
"id": "646d4a07a8fb14d55cd70e09",
"title": "Step 100"
},
{
"id": "646d4a8dbc04c6d6bb0001f8",
"id": "6491d38f5b09a021c4b5d5fe",
"title": "Step 101"
},
{
"id": "646d4ab9b3b4c5d74fdd2154",
"id": "646d4a5b32a1cad6165df286",
"title": "Step 102"
},
{
"id": "646d4b3d80ea98d824c8a4f9",
"id": "646d4a8dbc04c6d6bb0001f8",
"title": "Step 103"
},
{
"id": "646d4ab9b3b4c5d74fdd2154",
"title": "Step 104"
},
{
"id": "646d4b3d80ea98d824c8a4f9",
"title": "Step 105"
}
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,72 +11,48 @@ In your `highPrecedence` function, declare a `regex` variable. Assign it a regul

Each number, and the operator, should be in separate capture groups.

Incorporate the regular expression you've defined into your `highPrecedence` function to test if the provided string `str` matches the pattern. Use the `test()` method on your `regex` variable and return the result.

# --hints--

You should declare a `regex` variable in your `highPrecedence` function.

```js
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*(?:const|let|var)\s+regex/);
```

You should use `const` to declare your `regex` variable.
You should declare a `regex` variable in your `highPrecedence` function.

```js
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex/);
```

Your `regex` variable should be a regular expression.
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*(?:const|let|var)\s+regex/);

```js
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex\s*=\s*\//);
```

Your `regex` should use a capture group.
You should use `const` to declare your `regex` variable.

```js
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex\s*=\s*\/\(/);
```

Your first capture group should use a character class.
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex/);

```js
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex\s*=\s*\/\(\[/);
```

Your first capture group should match any digit or a period. Use the special `\d` character class.
Your `regex` variable should be a regular expression.

```js
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex\s*=\s*\/\(\[(?:\\d\.|\.\\d)\]/);
```

Your first capture group should match the character class one or more times.
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex\s*=\s*\//);

```js
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex\s*=\s*\/\(\[(?:\\d\.|\.\\d)\]\+\)/);
```

Your `regex` should use a second capture group.
Your highPrecedence should return `regex.test(str);`

```js
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex\s*=\s*\/\(\[(?:\\d\.|\.\\d)\]\+\)\(/);
```

Your second capture group should match a `*` or `/` operator. Use a character class in the capture group.
assert.match(code, /return\s+regex\.test\(str\);?/);

```js
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex\s*=\s*\/\(\[(?:\\d\.|\.\\d)\]\+\)\(\[(?:\*\\\/|\\\/*)\]\)/);
```

Your `regex` should use a third capture group.
Please enter a properly functioning regex.

```js
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex\s*=\s*\/\(\[(?:\\d\.|\.\\d)\]\+\)\(\[(?:\*\\\/|\\\/*)\]\)\(/);
```

Your third capture group should be the same as your first capture group.
assert.strictEqual(highPrecedence("5*3"), true);

```js
assert.match(code, /const\s+highPrecedence\s*=\s*(\(\s*str\s*\)|str)\s*=>\s*{\s*const\s+regex\s*=\s*\/\(\[(?:\\d\.|\.\\d)\]\+\)\(\[(?:\*\\\/|\\\/*)\]\)\(\[(?:\\d\.|\.\\d)\]\+\)/);
```

# --seed--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d40c543943ec250039682
title: Step 75
title: Step 77
challengeType: 0
dashedName: step-75
dashedName: step-77
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d40fe4b7b50c30c2b4cd8
title: Step 76
title: Step 78
challengeType: 0
dashedName: step-76
dashedName: step-78
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d41e23b583fc3b8cc4579
title: Step 77
title: Step 79
challengeType: 0
dashedName: step-77
dashedName: step-79
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d423fade4a9c4636acd13
title: Step 78
title: Step 80
challengeType: 0
dashedName: step-78
dashedName: step-80
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d42f58deb2fc52adc6611
title: Step 79
title: Step 81
challengeType: 0
dashedName: step-79
dashedName: step-81
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d43587d926bc5b6cb2e50
title: Step 80
title: Step 82
challengeType: 0
dashedName: step-80
dashedName: step-82
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d448479c8fdc8dcec868c
title: Step 81
title: Step 83
challengeType: 0
dashedName: step-81
dashedName: step-83
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d44da986f2bc9b72f5fe2
title: Step 82
title: Step 84
challengeType: 0
dashedName: step-82
dashedName: step-84
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d451c2e44afca71b67818
title: Step 83
title: Step 85
challengeType: 0
dashedName: step-83
dashedName: step-85
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d4554721d43cb19a68bc4
title: Step 84
title: Step 86
challengeType: 0
dashedName: step-84
dashedName: step-86
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d45b739da5ecbf830c108
title: Step 85
title: Step 87
challengeType: 0
dashedName: step-85
dashedName: step-87
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d45ee725632cca2555146
title: Step 86
title: Step 88
challengeType: 0
dashedName: step-86
dashedName: step-88
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d4626420eeecd51f241c2
title: Step 87
title: Step 89
challengeType: 0
dashedName: step-87
dashedName: step-89
---

# --description--
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
id: 646d467c6994f4ce0dc416a4
title: Step 88
title: Step 90
challengeType: 0
dashedName: step-88
dashedName: step-90
---

# --description--
Expand Down