Logo
TGCATALOG
Catalog Collections Blog
Java | Interview questions

Java | Interview questions

Questions and answers for Java developer interviews.

No ratings
324
01.12.2026
324
01.12.2026
No ratings
324
01.12.2026
Safe redirect via bot
О канале

Questions and answers for Java developer interviews.

Подписчиков —
Тематика Technology
Ссылка @easy_java_ru

We also recommend

Kekaton AI | Voiceover and voice clone
Kekaton AI | Voiceover and voice clone
Bot

AI bot for text-to-speech and voice cloning in Telegram. Create audio using neural network quickly and easily.

Description

Selection of typical questions in Java interviews: from JVM basics to Spring and Hibernate. Each question with detailed explanation, code examples, and tips. Suitable for all levels.

Latest posts

Java | Interview questions
Java | Interview questions
🔒Открыть пост
и посмотреть медиа
🤔 Что знаешь об интерфейсе FileFilter? FileFilter — это интерфейс в пакете java.io, используемый для фильтрации файлов в каталогах. Он применяется в методе listFiles(FileFilter filter) класса File и позволяет выбрать только те файлы, которые соответствуют заданным критериям. 🚩Как работает `FileFilter`? Этот интерфейс содержит всего один метод: boolean accept(File pathname); 🚩Пример использования `FileFilter` Допустим, мы хотим отфильтровать все файлы .txt в заданной папке: import java.io.File; import java.io.FileFilter; public class TxtFileFilterExample { public static void main(String[] args) { File directory = new File("C:/example"); // Укажите свою папку // Используем FileFilter для выбора файлов с расширением .txt FileFilter txtFilter = new FileFilter() { @Override public boolean accept(File file) { return file.isFile() && file.getName().endsWith(".txt"); } }; // Получаем список файлов, соответствующих фильтру File[] txtFiles = directory.listFiles(txtFilter); // Выводим найденные файлы if (txtFiles != null) { for (File file : txtFiles) { System.out.println("Файл: " + file.getName()); } } } } Выходные данные (если в папке C:/example есть файлы .txt) Файл: notes.txt Файл: tasks.txt 🚩Lambda-версия (Java 8+) Вместо анонимного класса можно использовать лямбда-выражение: FileFilter txtFilter = file -> file.isFile() && file.getName().endsWith(".txt"); 🚩Разница между `FileFilter` и `FilenameFilter` FileFilter принимает объект File, позволяя фильтровать как файлы, так и каталоги. FilenameFilter принимает только имя файла (без пути). import java.io.File; import java.io.FilenameFilter; public class TxtFilenameFilterExample { public static void main(String[] args) { File directory = new File("C:/example"); // Фильтр для файлов .txt FilenameFilter txtFilter = (dir, name) -> name.endsWith(".txt"); String[] txtFiles = directory.list(txtFilter); if (txtFiles != null) { for (String file : txtFiles) { System.out.println("Файл: " + file); } } } } Ставь 👍 и забирай 📚 Базу знаний
Java | Interview questions
FAQ

Open Java | Interview questions in Telegram and press the Start button. No separate registration is required.

Yes. The service is designed to be straightforward: open the resource, follow the on-screen instructions and start using it.

No. You can use Java | Interview questions directly in Telegram unless the resource description says otherwise.

Access depends on the resource. Check the current information in Telegram after opening Java | Interview questions.

The exact features depend on the resource. Open Java | Interview questions to see its current functions, content and access conditions.

Reviews for channel Java | Interview questions

Log in to leave a review

Only registered users can share their opinion.

No reviews yet

Be the first to share your impression of this resource!

Similar resources

Loading
Switch to Light Theme
Home Catalog Collections Blog Login