back to labs
Regex: Character Classes
EasyRegular Expressions3-5 minThe brief
Extract lines from /root/work/words.txt into /root/work/out.txt that contain either spelling of the colour word: 'gray' or 'grey'.
Match the text anywhere in the line, including inside a longer word (a line with 'grayness' or 'greying' would count too). Only those two spellings count — lines with 'groy' or 'gry' must not appear.
What you'll do
- out.txt holds exactly the lines containing 'gray' or 'grey'
Hands-on lab: you work on a real Linux box in your browser, graded on the machine's actual state.
