Create a function that accepts a string, checks if it's a valid email address and returns either true or false, depending on the evaluation.
@ character.. character.@ must have at least one character in front of it.
"[email protected]" is valid while "@innokodakademija.com" is invalid.. and the @ must be in the appropriate places.
"hello.email@com" is invalid while "[email protected]" is valid.If the string passes these tests, it's considered a valid email address.
validateEmail("@gmail.com") ➞ false
validateEmail("hello.gmail@com") ➞ false
validateEmail("gmail") ➞ false
validateEmail("hello@gmail") ➞ false
validateEmail("[email protected]") ➞ true