added loop and vectorize