I want to extract email ids from string. I have Regex pattern for email
const val EMAIL_REGEX = "^[A-Za-z](.*)([@])(.+)(\\.)(.{1,})"
i tried this but its not extracting emails.
const val EMAIL_REGEX = "^[A-Za-z](.*)([@])(.+)(\\.)(.{1,})"
val emailMatcher = EMAIL_REGEX.toRegex()
val tmpList = emailMatcher.findAll(html).map { it.value }.toList()
but I am getting same string as it is.
I want the same result which we can get from this Python code.
re.findall(r"[a-z0-9.\-+_]+@[a-z0-9.\-+_]+\.[a-z]+", response.text, re.I)