Собираем файл: 8 уровень, 11 лекция Java Core Putting together the file: level 8, lesson 11 JavaRush

Опубликовано: 19 Октябрь 2024
на канале: Grand Ckay
75
1

Собираем файл: 8 уровень, 11 лекция Java Core /
Putting together the file: level 8, lesson 11 JavaRush


Задание от JavaRush
Собираем файл: 8 уровень, 11 лекция Java Core
Считывать с консоли имена файлов. Каждый файл имеет имя: [someName].partN. Например, Lion.avi.part1, Lion.avi.part2, ..., Lion.avi.part37.
Имена файлов подаются в произвольном порядке. Ввод заканчивается словом "end".
В папке, где находятся все прочтенные файлы, создать файл без суффикса [.partN]. Например, Lion.avi.
В него переписать все байты из файлов-частей используя буфер.
Файлы переписывать в строгой последовательности, сначала первую часть, потом вторую, ..., в конце - последнюю.
Закрыть потоки.


The task from JavaRush
Putting together the file: level 8, lesson 11 Java Core
Read filenames from the console. Each file has a name: [someName].partN. For example, Lion.avi.part1, Lion.avi.part2, ..., Lion.avi.part37.
File names are given in random order. The input ends with the word "end".
In the folder where all read files are located, create a file without the [.partN] suffix. For example, Lion.avi.
To rewrite all bytes from files-parts into it using a buffer.
Rewrite files in strict sequence, first the first part, then the second, ..., at the end - the last.
Close streams.


Java Developer
Android Studio
Язык программирования Джава
Андроид Студио


Repeat after me, then delete and write the code from memory. Create a new task and write the program yourself
Повтори за мной, затем удали и напиши код по памяти. Придумай новое задание и напиши программу самостоятельно


Thank you for watching
Спасибо за просмотр