home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Practical Programming in Tcl & Tk (4th Edition)
/
TCLBOOK4.BIN
/
pc
/
exsource.old
/
11_2.tcl
< prev
next >
Wrap
Text File
|
2003-04-15
|
182b
|
15 lines
#
# Example 11-2
# Using regular expressions to parse a string.
#
set env(DISPLAY) sage:0.1
regexp {([^:]*):} $env(DISPLAY) match host
#=> 1
set match
#=> sage:
set host
#=> sage