def Trim(t, p=0.01):
 n = int((p * len(t)))
 t = sorted(t)[n:(- n)]
 return t

def Trim ( t , p = 0.01 ) : n = int ( ( p * len ( t ) ) ) t = sorted ( t ) [ n : ( - n ) ] return t
trims the largest and smallest elements of t .