loading...

Discussion on: Daily Challenge #272 - Printer Errors

Collapse
qm3ster profile image
Mihail Malo

how to count with javascript regex

const perro = wurd => {
  const re = /[^a-m]/g
  let i = 0
  while (re.test(wurd)) i++
  return `${i}/${wurd.length}`
}