Here's the summation: $$ S = \sum_{i=1}^{n}\left\lfloor\frac{n}{i}\right\rfloor $$
It can also be written as $$ S = \sum_{i=1}^{n}\left\lfloor\frac{n- (n \mod i)}{i}\right\rfloor $$
The answer will always be an integer, but I can't figure out how to solve it. I tried separating them and taking n common, then solving $ \sum_{i=1}^{n}\frac{1}{i} $, but there's no way you can get the exact integral answer that way.
Any help will be appreciated.