large files - C# Reading only specific lines without reading line by line -
i been googling last hour , can not find answer this. i have large text file (1gb) , have file has mapped know on line x line y contains data after. my question how take lines interested in without iterating through lines in file? the main reason interested in doing way performance reasons, imagine quicker take rows 503,432 row 504,432 cycle row 1 504,432 find these rows. any tips appreciated if looking specific row number, need read rows count them anyway. can't count rows without reading file except if lines fixed length. not need save lines when read them. save linenumber need, or handle them without keeping them in memory later.