Discussion:
Pattern that doesn't include any alternative from the set.
(too old to reply)
Volodymyr Lyubinets
2011-09-21 00:48:54 UTC
Permalink
We have seen how to write echo patterns like [!a]b* , which exclude a
character, but we haven't seen how to exclude strings. I thought the
mechanism was the same (for example, {!ab,cd}u* ), however it doesn't work.

How can I do this?
Brad Lushman
2011-09-21 02:41:17 UTC
Permalink
Post by Volodymyr Lyubinets
We have seen how to write echo patterns like [!a]b* , which exclude a
character, but we haven't seen how to exclude strings. I thought the
mechanism was the same (for example, {!ab,cd}u* ), however it doesn't work.
How can I do this?
All of the questions on the assignment can be solved by use of a combination
of techniques presented in class. Note that ! only means "not" when it
occurs as the first character of a [!...] pattern. And such patterns only
match single characters.

Brad

Loading...