Remix.run Logo
▲ elcritch 2 days ago

I like doing a mix of either in Nim depending on situation: for i in 0 ..< n: total += a[i]

Sometimes: for x in a: total += x

Sometimes even: foo.foldl(a + b)