S = list(map(int, input().split())) S = sorted(S) print(int(sum(S[1:-1]) * 100 / 4) / 100)