Replace List[T] with Vector[T] in some cases to tune up