Talk:Happy numbers: Difference between revisions
→On caching (and laziness): slight fix: It's not really the first part, because you don't actually do it; but it can still be seen as "half" of the step, so the argument remains
(→On caching (and laziness): No caching is needed (and I don't believe the described optimized cache saves much)) |
(→On caching (and laziness): slight fix: It's not really the first part, because you don't actually do it; but it can still be seen as "half" of the step, so the argument remains) |
||
Line 3:
: You don't need ''any'' caching (see the alternative C++ version I've just added). Of course you'll do more calculations anyway, so this is still a time/space tradeof.
: Also note that your "normal form" is
|