Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
lvass
on Aug 24, 2022
|
parent
|
context
|
favorite
| on:
Rust – A hard decision pays off
The first version isn't what I'd write in a purely functional language either, a recursive version would be much saner. Isn't recursion idiomatic in rust?
steveklabnik
on Aug 24, 2022
|
next
[–]
Rust doesn't guarantee TCO and so recursion is a bit dicer than in many functional languages.
throwaway894345
on Aug 24, 2022
|
prev
[–]
In addition to Steve's sibling comment, I'm responding narrowly to iterators versus for-loops. Recursion is out of scope.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: