https://gaviki.com/blog/matlab-code-performance-which-of-the-following-is-slower/