s = list(map(int, input().split())) print((sum(s)-max(s)-min(s))/4)