import java.util.Arrays; import java.util.Scanner; public class Main { public static void main(String[] args) { solver(); } static void solver() { Scanner sc = new Scanner(System.in); double[] s = new double[6]; double sum = 0; for (int i = 0; i < 6; i++) { s[i] = sc.nextDouble(); sum += s[i]; } Arrays.sort(s); sum = sum - s[0] - s[5]; sum = sum /4* 100; sum = (int) sum; sum = sum / 100; System.out.println(sum); } }