jacobus
Newbie level 5

hello. everyone.
I have a large EDA report about several giga bytes,
and I need to extract some lines from the report, for example, the last 100 lines and then print these lines in an reverse order in another file.
Since for some line, it may contain about 1M byte data, it seems very inefficient to use fseek to locate the file, read the line and then write the file word by word.
So I want to know if there is any more efficient way to extract the last 100 lines from the EDA file?
And due to my platform and knowledge limitation, I only can use C or Perl to realize such a script.
Thanks a lot!
I have a large EDA report about several giga bytes,
and I need to extract some lines from the report, for example, the last 100 lines and then print these lines in an reverse order in another file.
Since for some line, it may contain about 1M byte data, it seems very inefficient to use fseek to locate the file, read the line and then write the file word by word.
So I want to know if there is any more efficient way to extract the last 100 lines from the EDA file?
And due to my platform and knowledge limitation, I only can use C or Perl to realize such a script.
Thanks a lot!