Signal9Signal9 — home
online
back to labs

Dojo: Harvest the Email Addresses

MediumOne-Liner Dojo10 min
The brief

The file /root/contacts.txt is free-form text with email addresses scattered through it (some repeated). In ONE line, extract every address, de-duplicate, sort, and write them (one per line) to /root/answer.txt.

grep can print just the MATCHING part of a line, not the whole line — that's the key to pulling addresses out of prose.

What you'll do
  • Extract, dedupe, and sort all email addresses from /root/contacts.txt into /root/answer.txt, in one line

Hands-on lab: you work on a real Linux box in your browser, graded on the machine's actual state.