reading lines in pairs from file in ksh

I need to read pairs of lines from a file and compare them. We can assume that the number of lines in the file is even. Can i do it in korn shell?

Well, first, the obligatory question: is this a homework question? If so, we can't help you.

Assuming that it's not, can you show us what you've gotten so far?

Regards

it's not a homework, it's a workwork. So far i got nothing as the only tool i know is while read, and it does not let you read the second line (as far as I know).

Is there is way to detect EOF in ksh?

First try to Google on "compare files unix".
Once you have more specific questions, please return and we'd be more than happy to answer them!

Regards

What is not specific here? And when you say "we" who exactly do you mean?

I doubt you read my question because it has nothing to do with comaring files.