#include <iostream> #include <algorithm> #include <cstring> using namespace std; typedef long long LL; + ; int a[maxn]; LL sum[maxn]; int main(){ std::ios::sync_with_stdio(false); int n, k; cin >> n >> k; memset(sum, , sizeof…
暴力即可!!! #include <stdio.h> #include <string.h> #include <iostream> using namespace std; typedef long long LL; const int N=1e4+10; LL a[N]; int n; int main() { int s,t; LL sum=0,k; scanf("%d%lld",&n,&k); for(int i=1;i<…