#!/usr/bin/nawk -f # demonstrate the match function BEGIN { regex="[a-zA-Z0-9]+"; } { if (match(0,ドルregex)) { # RSTART is where the pattern starts # RLENGTH is the length of the pattern before = substr(0,1,ドルRSTART-1); pattern = substr(0,ドルRSTART,RLENGTH); after = substr(0,ドルRSTART+RLENGTH); printf("%s<%s>%s\n", before, pattern, after); } }

AltStyle によって変換されたページ (->オリジナル) /