Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
160632 赖泓宇 序列变换 C++ Runtime Error 0 MS 268 KB 466 2026-09-25 19:00:23

Tests(0/10):


Code:

#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ int a[101]={0},s[101]={0},n,b; cin>>n; for(int i=1;i<=n;i++){ cin>>a[i]; }for(int j=1;j<=n;j++){ b+=a[j]; s[j]+=a[j]; cout<<s[b]<<" "; b==0; } }


Run Info:

Runtime Error:Segmentation fault