#include<stdio.h> int main(){ int n,h=0; scanf("%d",&n); for(int i=1;i<=n;i++){ h=h+i*(i+1); } printf("%d",h); return 0; }
觉得有用的话采纳一下哈