I came across the following argument in my discrete maths textbook:
Since $n=O(n), 2n=O(n)$ etc., we have: $$ S(n)=\sum_{k=1}^nkn=\sum_{k=1}^nO(n)=O(n^2) $$
The accompanying question in the book is: What is wrong with the above argument?
Attempt: Performing the summation for $n=2,3$ gives: $$ \sum_{k=1}^2k(2)\leq\sum_{k=1}^22(2)=2(2^2)=O(2^2) $$ $$ \sum_{k=1}^3k(3)\leq\sum_{k=1}^33(3)=3(3^2)=O(3^2) $$ Thus, it seems like the argument is correct. However, I know that I am not correct.