в чем проблема? Считывает байты, ищет макс байт
package com.javarush.task.task18.task1801;
import java.io.FileInputStream;
import java.util.LinkedList;
/*
Максимальный байт
*/
public class Solution {
public static void main(String[] args) throws Exception {
FileInputStream fileName = new FileInputStream("C://A.txt");
LinkedList<Integer> map = new LinkedList<Integer>();
while (fileName.available() > 0){
map.add(fileName.read());
}
fileName.close();
int max = map.get(0);
for (int i = 1; i < map.size(); i++){
if (max < map.get(i)){
max = map.get(i);
}
}
System.out.println(max);
}
}