Better HN
topnewbestaskshowjobs
Log inSign up

hermanbergwerf

1 karma · joined Nov 22, 2015 (11y ago) · 2 submissions

Submissions

comment 9y ago · link · parent

Didn't read the article. I usually don't have trouble with recursion, however lately I have started to avoid it more and more often. It is true that linear solutions usually look more complex. However in my opinion they also allow better reuse of local variables. Their complexity also depends on the datastructure. Designing a linear datastructure for nested problems is sometimes possible and can allow simple non-recursive solutions which I find more elegant.

comment 10y ago · link · parent

Yeah, that sounds pretty cool.