removed for loop for performance reasons