The “for” loop is very similar to the “while” loop, however the “for” loop is much more commonly used. This trend is evident in other programming languages as well as in MQL4. Most likely, the “for” loop is preferred because it is more convenient. In today’s tutorial I will show you how the two loops compare to each other, and you can then decide for yourself which you prefer. Both are equally valid approaches..
Actually, this happens quite a lot in programming. Often, you can implement the same thing in two (or more) different ways, and only your personal preference will guide you to pick one. This is totally normal. Moreover, this is how people develop their own programming styles, which is natural. So congratulations! Today you are making your first step towards developing your personal unique coding style.
Get the full course here: https://www.forexboat.com/learn-mql4