I want to print, for each line of a given document, the ﬁrst names and the ages of people (which are entries of the document). What linux command would I use? Hopefully based around grep using a regex pattern.
Example of input document:
Linda:F:Las Vegas, USA:18:telnet Steve:M:Leipzig, Germany:33:ftp Henry:M:Milan, Italy:19:sftp Alice:F:Izmir, Turkey:32:pop3s Robert:M:Verona, Italy:21:scp Olga:F:Gorontalo, Indonesia:19:pop3s Kimberly:F:Lille, France:25:ping Henry:M:Oslo, Norway:26:ftp Carol:F:New Delhi, India:23:pop3s Thomas:M:New Delhi, India:32:http