等差数列求和公式 class Solution { public: int Sum_Solution(int n) { // 等差数列公式 return (1 + n) * (n - 1 + 1) / 2; } };