2 solutions

  • 1
    @ 2026-6-6 14:42:57

    #include<bits/stdc++.h> using namespace std; int main() { int a; cin>>a; int b=0; for(int i=1;i<=a;i++) { b+=i*i; } cout<<b; return 0;

    • [ ] | Column | | | - | - | | | | | | | | | | | | |

    Information

    ID
    2885
    Time
    1000ms
    Memory
    256MiB
    Difficulty
    4
    Tags
    # Submissions
    42
    Accepted
    21
    Uploaded By