Write a regular expression to get the value xxx from the
string 'xxx@yyy.com'

Answer Posted / tclgeek

set url "xxx@yyy.com"
regexp {([^@]+)@([^.]+).([a-z]+)} $url match match1
puts " Match....$match1"

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a php tag?

521


What is data type in php?

520


Where php language is used?

522


What are the two types of variables?

526


When to use self over $this?

551






Why do we use htaccess

630


Does empty check for null?

540


Php program to generate fibonacci series?

545


What is apache and php?

491


What are the new features available in php 7?

540


What is the difference between static and dynamic websites?

503


Can constructor be private in php?

531


What is a php array?

492


Explain the purpose of output buffering in php.

508


How to make horizonatl menu and vertical menu responsive

1867