+ 1

Email challenge : recogizing good and bad adresses.

1-Make a code accepting good emails and refusing the bad ones goodmails="tom.riddle@hogwarts.com ","tom.riddle+regexone@hogwarts.com","tom@hogwarts.eu.com","harry.potter.jr@hogwarts.com","hermione+regexone@hogwarts.com","accentuée@dom.fr" badmails="nodomain","tooshortdomain@c.com","space name@dot.com","fakedomaine@dom",".badname@dom.com" 2-Bonus 1 : extract the name (the part before any "+" or "@") 3-Bonus 2 : complete the goodmail and badmail lists to make the challenge even more difficult.

11th Aug 2017, 3:38 PM
VcC
VcC - avatar
10 Respostas
11th Aug 2017, 3:48 PM
CalviŐČ
CalviŐČ - avatar
+ 3
https://code.sololearn.com/c7sqhKJ7OCre/?ref=app
11th Aug 2017, 4:17 PM
Ekansh
11th Aug 2017, 4:27 PM
Ekansh
+ 1
Could explain a bit more I am confused 😅
11th Aug 2017, 4:53 PM
Ekansh
+ 1
Check again is it right now ? 😅
12th Aug 2017, 3:56 AM
Ekansh
0
Not bad but not exactly what was expected...And some of the good adresses are refused.
11th Aug 2017, 4:17 PM
VcC
VcC - avatar
0
Same. Adresses with accents are refused - many Europeans wont be able to use your site !
11th Aug 2017, 4:18 PM
VcC
VcC - avatar
0
Have your code go through the goodmails and badmails to show that first are accepted and second refused !
11th Aug 2017, 4:29 PM
VcC
VcC - avatar
0
Create two lists or arrays - one with the bad mails, the other with the good mails. Using a loop go through both lists and display the adresses accepted by your code
11th Aug 2017, 5:01 PM
VcC
VcC - avatar
0
Yes ! Now just use the lists i gave and add to them any additionnal good/bad you identified to show that you fulfilled the challenge !
12th Aug 2017, 7:20 AM
VcC
VcC - avatar