Access by line when inputting and outputting files

Asked 1 years ago, Updated 1 years ago, 107 views

As far as I know, if you use fseek, it moves in bytes, but can't you read it in rows? Currently, we are processing it arbitrarily through fgets. I'm saving five lines of information.

c fileinputstream

2022-09-21 15:40

1 Answers

There's a getline. If you look at the management line or the page below, there is a sample code.

https://linux.die.net/man/3/getline


2022-09-21 15:40

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.