We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
// Create an obj with email->namearr[emailID]=firstName;for(emailinarr){letvalue=arr[email];// If regex pass push to arrayif(email.search(/@gmail.com$/)>0)match.push(value);}// Format to desired styleconsole.log(match.sort().toString().replace(/,/gi,'\n'));
Day 28: RegEx, Patterns, and Intro to Databases
You are viewing a single comment's thread. Return to all comments →
My code Javascript: