REF=R[0-9]* { T=R VAL=* { R=$$#R } TOL = 5% FN=*% { TOL=${$#%} } break REF // end break again } /* pattern: () * ? . subst: $1 ... $field substring: $1, $2, ... variable: $foo, ... with curly braces: ${foo}, ... unit conversion: $foo#V ${1#R} input variable: $$ */