제출 #735728

#제출 시각아이디문제언어결과실행 시간메모리
735728myrcella친구 (IOI14_friend)C++17
컴파일 에러
0 ms0 KiB
#include "friend.h" // Find out best sample int findSample(int n,int confidence[],int host[],int protocol[]){ int ans=0; rep(i,0,n) ans += confidence[i]; return ans; }

컴파일 시 표준 에러 (stderr) 메시지

friend.cpp: In function 'int findSample(int, int*, int*, int*)':
friend.cpp:6:6: error: 'i' was not declared in this scope
    6 |  rep(i,0,n) ans += confidence[i];
      |      ^
friend.cpp:6:2: error: 'rep' was not declared in this scope
    6 |  rep(i,0,n) ans += confidence[i];
      |  ^~~