Skip to content

Commit 3facd1a

Browse files
committed
task_2
1 parent def73eb commit 3facd1a

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

9-regular-expressions/10-regexp-greedy-and-lazy/3-find-html-comments/solution.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
We need to find the beginning of the comment `match:<!--`, then everything till the end of `match:-->`.
1+
আমাদের প্রথমে খুঁজা লাগবে কমেন্ট এর শুরুর `match:<!--` অংশ, এরপর কমেন্টের শেষ `match:-->` অংশ।
22

3-
An acceptable variant is `pattern:<!--.*?-->` -- the lazy quantifier makes the dot stop right before `match:-->`. We also need to add flag `pattern:s` for the dot to include newlines.
3+
সুতরাং প্যাটার্নটি হবে `pattern:<!--.*?-->` -- লেজি কোয়ান্টিফায়ারের ডটের জন্য এটি `match:-->` এর পূর্ব পর্যন্ত মেলে। আমাদের এই ফ্ল্যাগটি `pattern:s` দিতে হবে যেন ডট দ্বারা নিউলাইন ক্যারাক্টারকেও নির্দেশ করে।
44

5-
Otherwise multiline comments won't be found:
5+
অন্যথায় একের অধিক লাইনের কমেন্টগুলো অনুসন্ধানে আসবে না:
66

77
```js run
88
let regexp = /<!--.*?-->/gs;

9-regular-expressions/10-regexp-greedy-and-lazy/3-find-html-comments/task.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
# Find HTML comments
1+
# এইচটিএমএল কমেন্ট অনুসন্ধান
22

3-
Find all HTML comments in the text:
3+
নিচের টেক্সট হতে সকল এইচটিএমএল কমেন্ট খুঁজার একটি প্যাটার্ন লিখুন:
44

55
```js
6-
let regexp = /your regexp/g;
6+
let regexp = /আপনার প্যাটার্ন/g;
77

88
let str = `... <!-- My -- comment
9-
test --> .. <!----> ..
9+
test --> .. <!----> ..
1010
`;
1111

1212
alert( str.match(regexp) ); // '<!-- My -- comment \n test -->', '<!---->'

0 commit comments

Comments
 (0)