гляньте что в передаче байтов в 3 файл не так
package com.javarush.task.task18.task1808;
import java.io.*;
/*
Разделение файла
*/
public class Solution {
public static void main(String[] args) throws Exception {
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
String file1 = reader.readLine();
String file2 = reader.readLine();
String file3 = reader.readLine();
FileInputStream fileInputStream1 = new FileInputStream(file1);
FileOutputStream fileInputStream2 = new FileOutputStream(file2);
FileOutputStream fileInputStream3 = new FileOutputStream(file3);
byte[] bytes = new byte[1000];
int a = fileInputStream1.available();
boolean b = a%2==0;
if (b) {
int count = fileInputStream1.read(bytes);
fileInputStream2.write(bytes, 0, count/2);
fileInputStream3.write(bytes, count/2, count/2);
}
else {
int count = fileInputStream1.read(bytes);
fileInputStream2.write(bytes, 0, (count/2)+1);
fileInputStream3.write(bytes, (count/2)+1, (count/2)-1);
}
fileInputStream1.close();
fileInputStream2.close();
fileInputStream3.close();
}
}