#41630: 直接輸出:357389824


s210367@student.cysh.cy.edu.tw (張少謙)

學校 : 國立嘉義高級中學
編號 : 263937
來源 : [61.223.150.87]
最後登入時間 :
2025-06-14 20:55:00

cout << 357389824;

#41631: Re: 直接輸出:357389824


s210367@student.cysh.cy.edu.tw (張少謙)

學校 : 國立嘉義高級中學
編號 : 263937
來源 : [61.223.150.87]
最後登入時間 :
2025-06-14 20:55:00

cout << 357389824;

也可以用 h215 的程式

#include<bits/stdc++.h>
using namespace std;
int main(void){
    int n;
    cin >> n;
    int a = (2*pow(n,3)+3*pow(n,2)+n)/6;
    cout << a;
}