Where do you have problems? What did you try?
The general approach is simple:
- read the file line-by-line
- for each line, extract the date (e.g. by a regex)
- compare the date with your target-dates (Date::Calc has some handy functions for this, e.g. Delta_YMDHMS
)
- process the fitting lines
Of course you can optimize due to the knowledge that your lines are sorted, e.g. abort processing once you found a line with a date later than your second one ....
HTH, Rata