S = sorted([int(x) for x in input().split()]) print("{:.2f}".format(sum(S[1:5])/(len(S)-2)))