What is the difference between a file and a random access file?

What is the difference between a file and a random access file?

+3
source share
2 answers

A random access file is a file in which you can "jump" anywhere inside it, without having to read sequentially to the position in which you are interested.

For example, let's say that you have a 1MB file, and you are interested in 5 bytes that start after 100k of data. The random access file will allow you to "go" to the 100th position in one operation. A non-random access file will require first reading 100 thousand bytes, and then reading the data you are interested in.

Hope this helps.

: - /.

+9

. , , ( ) , . , , . , , .

+4

Source: https://habr.com/ru/post/1709013/


All Articles