import Data.List main::IO() main=do getLine l<-map(read::String->Integer).words<$>getLine print$sum$filter(/=maximum l)l
why?