Что не так
package com.javarush.task.task18.task1810;
import java.io.*;
/*
DownloadException
*/
public class Solution {
public static void main(String[] args) throws DownloadException, IOException {
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
FileInputStream inputStream = null;
while(true) {
inputStream = new FileInputStream(reader.readLine());
int count=0;
while (inputStream.available() > 0) {
count += inputStream.read();
}
if (count < 1000) {
inputStream.close();
reader.close();
throw new DownloadException();
}
}
}
public static class DownloadException extends Exception {
}
}