V
V
Vladislav Vinokurov2018-11-12 15:54:59
Java
Vladislav Vinokurov, 2018-11-12 15:54:59

What is the most efficient way to determine if a file contains a string?

There is a need to go through the file system and look for files that contain certain text. Files can be up to one gigabyte. How to do it as efficiently as possible? Thanks in advance

Answer the question

In order to leave comments, you need to log in

1 answer(s)
K
Kirill Romanov, 2018-11-12
@Djaler

new BufferedReader(...).lines().anyMatch(...)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question