The for loop in Go is more flexible than the one in C though. I just started with Go, and it's surprising how much they chose to diverge from other C-like languages.
I posses great passion in technologies that help to improve better living. I have a deep interest in working in the field of technical evangelism.
Author of Iris web framework.
Location
Greece
Education
International Hellenic University
Work
Back End Go Engineer at PNOĒ | https://www.pnoe.com
Go only has for loops so there's not much of a choice there 😂
In Python I use for as well combined with various iterators. List comprehensions are favored over map and reduce there.
The for loop in Go is more flexible than the one in C though. I just started with Go, and it's surprising how much they chose to diverge from other C-like languages.
I like go's for a lot. It can be a for, a while, or an infinite loop. It's all in how you use it.
The same idea shows up all over the place in it: "here's some minimal core, fiddle it however you want". It's one of its main attractions ♥️
Exacltly. I was ready to post the same about Go xD
Though go is kind of cheating since it's "for" loop can behave in many ways.
Honestly it's one of many reasons Go is great, no bikeshedding about iteration