2 ms·
> “How can you sum the numbers from 1 to 10 without using a loop?” Sum = n(n+1)/2
by imglorp 1y ago
> “How can you sum the numbers from 1 to 10 without using a loop?”
Sum = n(n+1)/2
- KingMob 1y agoYeah, I assume it's missing some context that the numeric solution was off the table.
- javcasas 1y agoWhen all you know is hammers, all you can think of are nails. Screws are impossible to use and understand. How are you supposed to hammer in a screw? All those ridges are in the way!
- FredPret 1y agoNot even Erlang can beat Gauss
- robochat 1y agoI remember being amazed when I learnt about summing arithmetric series.