[resolved] Cs equivalent of (0..10).map [Answered]
In rust I'd write smoething like (0..10).map( to iterate over a range of numbers. Obviously I can do it with a for loop but I'd prefer an IEnumerable that I can select on.
que11248/16/2022
I really just want to call a function 10 times and make an IEnumerable out of the results
Orannis8/16/2022
Enumerable.Range(0, 10).Select(...)
que11248/16/2022
That'll do it
que11248/16/2022
Thanks
Orannis8/16/2022
There's a /close command
que11248/16/2022
Got it, next time
mtreit8/16/2022
You do Rust programming Nathaniel?
que11248/16/2022
@406536255426396160 Yes outside work most of what I write is rust.
mtreit8/16/2022
Nice. I have dabbled with it and think it has a lot of potential if it matures well.
que11248/16/2022
I enjoy it quite a bit. Much more difficult learning curve than c# but really let's you dive into the details which I love.
que11248/16/2022
Definitely not the right tool for every project but a joy in the right niche.
mtreit8/16/2022
I've been trying to find an excuse to use it at work 🙂
que11248/16/2022
Haha someone snuck some f# into our codebase and they've never heard the end of it
que11248/16/2022
So I will learn from their mistake xD
que11248/16/2022
Definitely recommend if you have a chance to use it
que11248/16/2022
I've been pleasently surprised by c# (only used it here) and other than null handling I'm quite happy.