dilyana2001

Untitled

Jun 14th, 2021
257
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function exactEmails(input) {
  2.     for (let line of input) {
  3.         let regex = /\b[a-z\d]+[.]?[_]?[-]?[a-z\d]+@{1}[a-z]+[-]?[a-z]+[.]?[a-z]+[.][a-z]+\b/g
  4.         if (line.match(regex) != null) {
  5.             console.log(line.match(regex).join(''))
  6.         }
  7.     }
  8. }
Advertisement
Add Comment
Please, Sign In to add comment