From ed0085e8e5e2ccccc694c5784070e29e93081bd8 Mon Sep 17 00:00:00 2001 From: zhangxuemei Date: Wed, 21 Nov 2018 22:46:49 +0800 Subject: [PATCH] pass --- .gitignore | 4 +++- lib/anchor_end.js | 2 ++ lib/anchor_start.js | 2 ++ lib/char_class.js | 2 ++ lib/negated_char_class.js | 2 ++ 5 files changed, 11 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index b512c09..420f7de 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ -node_modules \ No newline at end of file +node_modules +yarn-error.log* +yarn.lock* \ No newline at end of file diff --git a/lib/anchor_end.js b/lib/anchor_end.js index 56e8b85..45a8903 100644 --- a/lib/anchor_end.js +++ b/lib/anchor_end.js @@ -1,3 +1,5 @@ module.exports = function (str) { // TOOD + const reg = /BANANAS$/ + return reg.test(str) } \ No newline at end of file diff --git a/lib/anchor_start.js b/lib/anchor_start.js index 56e8b85..93a11c6 100644 --- a/lib/anchor_start.js +++ b/lib/anchor_start.js @@ -1,3 +1,5 @@ module.exports = function (str) { // TOOD + const reg = /^LITERALLY/ + return reg.test(str) } \ No newline at end of file diff --git a/lib/char_class.js b/lib/char_class.js index a08ee57..397dac1 100644 --- a/lib/char_class.js +++ b/lib/char_class.js @@ -1,3 +1,5 @@ module.exports = function (str) { // TODO + const reg = /^[a1u4o]+/ + return reg.test(str) } \ No newline at end of file diff --git a/lib/negated_char_class.js b/lib/negated_char_class.js index a08ee57..cbfa8d8 100644 --- a/lib/negated_char_class.js +++ b/lib/negated_char_class.js @@ -1,3 +1,5 @@ module.exports = function (str) { // TODO + const reg = /^\D[^A-D]/ + return reg.test(str) } \ No newline at end of file