from decimal import Decimal S = list(map(int,input().split())) print(Decimal(str((sum(S)-min(S)-max(S))/(len(S)-2))).quantize(Decimal('0.01')))