#!/usr/bin/perl -w while (<>) { m#(\w+$)#; print "$1\n"; }