▲ 433 ▼ Who cares about time complexity (lemmy.world) submitted 1 year ago by qaz@lemmy.world to c/programmer_humor@programming.dev 51 comments fedilink hide all child comments
[–] bleistift2@sopuli.xyz 16 points 1 year ago (6 children) The word you’re looking for is recursion (see recursion). permalink fedilink source parent hideshow 6 child comments replies: [–] lugal@lemmy.dbzer0.com 5 points 1 year ago Thanks. I knew something was off permalink fedilink source parent [–] Gonzako@lemmy.world 6 points 1 year ago (4 children) Nah, I'd like to un-see recursion. It was way overblown on uni, I barely ever use it. permalink fedilink source parent hideshow 4 child comments replies: [–] Cethin@lemmy.zip 10 points 1 year ago (3 children) Recursion is amazing for a small selection of problems. Most of the time you don't need, or want, it. When it is useful though, it tends to be really useful. I don't understand people's issue with it. I always found it easy. Maybe that's why I feel this way. Maybe if you find it challenging you want to avoid it, even when it's a good solution. permalink fedilink source parent hideshow 3 child comments replies: [–] Ephera@lemmy.ml 4 points 1 year ago (1 child) I think, their point (and also my experience) is that you get taught about it in university a lot more than about simple loops, so it feels more important even though you rarely use it in reality. Same thing goes for linked lists and inheritance... permalink fedilink source parent hideshow 1 child comment replies: [–] embed_me@programming.dev 2 points 1 year ago Linked lists are encountered somewhat frequently in low level systems programming. permalink fedilink source parent [–] kamstrup@programming.dev 1 point 1 year ago Most devs I know like recursion. Trouble is that many popular languages don't support tail recursion, but throw a stackoverflow error after a few thousand levels. So you have to keep track of max recursion depth manually, and it starts to look like a complicated solution permalink fedilink source parent
[–] lugal@lemmy.dbzer0.com 5 points 1 year ago Thanks. I knew something was off permalink fedilink source parent
[–] Gonzako@lemmy.world 6 points 1 year ago (4 children) Nah, I'd like to un-see recursion. It was way overblown on uni, I barely ever use it. permalink fedilink source parent hideshow 4 child comments replies: [–] Cethin@lemmy.zip 10 points 1 year ago (3 children) Recursion is amazing for a small selection of problems. Most of the time you don't need, or want, it. When it is useful though, it tends to be really useful. I don't understand people's issue with it. I always found it easy. Maybe that's why I feel this way. Maybe if you find it challenging you want to avoid it, even when it's a good solution. permalink fedilink source parent hideshow 3 child comments replies: [–] Ephera@lemmy.ml 4 points 1 year ago (1 child) I think, their point (and also my experience) is that you get taught about it in university a lot more than about simple loops, so it feels more important even though you rarely use it in reality. Same thing goes for linked lists and inheritance... permalink fedilink source parent hideshow 1 child comment replies: [–] embed_me@programming.dev 2 points 1 year ago Linked lists are encountered somewhat frequently in low level systems programming. permalink fedilink source parent [–] kamstrup@programming.dev 1 point 1 year ago Most devs I know like recursion. Trouble is that many popular languages don't support tail recursion, but throw a stackoverflow error after a few thousand levels. So you have to keep track of max recursion depth manually, and it starts to look like a complicated solution permalink fedilink source parent
[–] Cethin@lemmy.zip 10 points 1 year ago (3 children) Recursion is amazing for a small selection of problems. Most of the time you don't need, or want, it. When it is useful though, it tends to be really useful. I don't understand people's issue with it. I always found it easy. Maybe that's why I feel this way. Maybe if you find it challenging you want to avoid it, even when it's a good solution. permalink fedilink source parent hideshow 3 child comments replies: [–] Ephera@lemmy.ml 4 points 1 year ago (1 child) I think, their point (and also my experience) is that you get taught about it in university a lot more than about simple loops, so it feels more important even though you rarely use it in reality. Same thing goes for linked lists and inheritance... permalink fedilink source parent hideshow 1 child comment replies: [–] embed_me@programming.dev 2 points 1 year ago Linked lists are encountered somewhat frequently in low level systems programming. permalink fedilink source parent [–] kamstrup@programming.dev 1 point 1 year ago Most devs I know like recursion. Trouble is that many popular languages don't support tail recursion, but throw a stackoverflow error after a few thousand levels. So you have to keep track of max recursion depth manually, and it starts to look like a complicated solution permalink fedilink source parent
[–] Ephera@lemmy.ml 4 points 1 year ago (1 child) I think, their point (and also my experience) is that you get taught about it in university a lot more than about simple loops, so it feels more important even though you rarely use it in reality. Same thing goes for linked lists and inheritance... permalink fedilink source parent hideshow 1 child comment replies: [–] embed_me@programming.dev 2 points 1 year ago Linked lists are encountered somewhat frequently in low level systems programming. permalink fedilink source parent
[–] embed_me@programming.dev 2 points 1 year ago Linked lists are encountered somewhat frequently in low level systems programming. permalink fedilink source parent
[–] kamstrup@programming.dev 1 point 1 year ago Most devs I know like recursion. Trouble is that many popular languages don't support tail recursion, but throw a stackoverflow error after a few thousand levels. So you have to keep track of max recursion depth manually, and it starts to look like a complicated solution permalink fedilink source parent