perl -e 'print((grep/Baki/,<>)[-1])' file.txt [download]
In reply to Re^4: how to find last word match ? by happy.barney in thread how to find last word match ? by bh_perl