Hi Frnds,
I need to find the line number of a particular line in a file and store that line number to a variable.
if a file named myfile contains following
look at the sun
look at the moon
look at the star
look at the ocean
i need to get the line number of the line 'look at the moon'
i need to get the value as 2 and store it in a variable for manipulation.
how to do this ?
Thanks in advance for the help.