I'm trying to write a perl script to do the followings:
1. Calculate the number of words from a string.
2. Check the last word exist in a text file. If exist move it to the beginning of the string.
3. Extract the first two word of the string.
4. Find the occurence of the word "d/o" and extract every words before that.
string = "Rajiv Mani d/o Arumugam"
...code to count the word length which is 4
if (last_word "Arumugam" is in file c:\temp\Names.txt)
code to move last_word to first_word
string = "Arumugam Rajiv Mani d/o"
if (string has "d/o")
code to extract "Arumugam Rajiv Mani"
code to retrieve "Arumugam Rajiv"