class sum{ public: sum() { cnt+=i; i++; } static int Getret() { return cnt; } private: static int cnt; static int i; }; int sum::cnt =0; int sum::i =1; class Solution { public: int Sum_Solution(int n) { sum a[n]; return sum::Getret(); } };
class sum{ public: sum() { cnt+=i; i++; } static int Getret() { return cnt; } private: static int cnt; static int i; }; int sum::cnt =0; int sum::i =1; class Solution { public: int Sum_Solution(int n) { sum a[n]; return sum::Getret(); } };