back to labs
Regex: Anchor to Line Start (^)
EasyRegular Expressions3-5 minThe brief
Extract lines that START with 'Error' — not merely contain it — from /root/work/log.txt into /root/work/out.txt.
A line like 'saw an Error later' contains Error but doesn't begin with it, so it must not appear in your output.
What you'll do
- out.txt holds exactly the lines beginning with 'Error'
Hands-on lab: you work on a real Linux box in your browser, graded on the machine's actual state.
