提交时间:2023-12-15 14:00:52
运行 ID: 115963
#include<bits/stdc++.h> using namespace std; int main() { int n,p,a[10000],s; cin>>n>>p; p>=12; n<=500; s=2*p; for(int i=p+1;i<=n;i++) s=s+i; cout<<s; return 0; }