Наведите на правильную мысль, уже всяко пробовал.По 3 пункту не прохожу...
package com.javarush.task.task18.task1803;
import java.io.BufferedReader;
import java.io.FileInputStream;
import java.io.InputStreamReader;
import java.io.UnsupportedEncodingException;
import java.util.ArrayList;
import java.util.Collections;
/*
Самые частые байты
*/
public class Solution {
public static void main(String[] args) throws Exception {
//test();
BufferedReader reader =new BufferedReader(new InputStreamReader(System.in));
FileInputStream inputStream = new FileInputStream(reader.readLine());
//FileInputStream inputStream=new FileInputStream(new BufferedReader(new InputStreamReader(System.in)).readLine());
long[] arr=new long[256];
while(inputStream.available()>0) {
arr[inputStream.read()]++;
}
inputStream.close();
for(int i=256;i>0;i++){
if(arr[i]==1)
System.out.print(i+" ");}
//System.out.print(Collections.max(bytes) + Collections.max(bytes));
//System.out.println(Collections.max(bytes) - Collections.min(bytes));
}
/*public static void test() throws UnsupportedEncodingException {
String str = "abc";
//str.getBytes();
System.out.println(str.getBytes("UTF-16"));
}*/
}