Vectorized code. 13x faster. Thanks to Christian for the lesson.