MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/ProgrammerAnimemes/comments/fnuof3/comments_you_cant_remove/flcbp4a/?context=3
r/ProgrammerAnimemes • u/bucket3432 • Mar 23 '20
53 comments sorted by
View all comments
Show parent comment
24
Shouldn't you just have done
if (n == 0) { return 1; }
?
14 u/Tiavor Mar 24 '20 not really needed, but it would work too, that's why you can't remove the comment.at the bottom is a "return fallback", and fallback = 1. 1 u/LucasTyph Mar 24 '20 Aaah, I understood it now. Hadn't paid much attention to where the comment ended. 6 u/bucket3432 Mar 24 '20 There are lots of things you can do to improve the code. This is just one of them.
14
not really needed, but it would work too, that's why you can't remove the comment.
at the bottom is a "return fallback", and fallback = 1.
1 u/LucasTyph Mar 24 '20 Aaah, I understood it now. Hadn't paid much attention to where the comment ended.
1
Aaah, I understood it now. Hadn't paid much attention to where the comment ended.
6
There are lots of things you can do to improve the code. This is just one of them.
View all comments
Show parent comment
24
u/LucasTyph Mar 24 '20
Shouldn't you just have done
?