Skip to content

Commit

Permalink
add (programmers - level1 1문제): js 풀이
Browse files Browse the repository at this point in the history
  • Loading branch information
padosum committed Dec 28, 2022
1 parent 2e9c1b7 commit adcdc7c
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions programmers/level1/옹알이 (2).js
@@ -0,0 +1,10 @@
function solution(babbling) {
const result = babbling.filter((word) => {
if (!/(aya|ye|woo|ma)\1+/g.test(word)) {
return /^(aya|ye|woo|ma)+$/g.test(word)
}
})

return result.length
}

0 comments on commit adcdc7c

Please sign in to comment.