답안 #4085

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
4085 2013-09-01T02:41:35 Z tncks0121 카드 (tutorial6) C++
컴파일 오류
0 ms 0 KB
#include "jeehak.h"

void jeehak (int A[]) {
  int i, s=0; for(i=1; i<=5; i++) s^=A[i];
  send(s&3, 0);
  send(s>>2, 1);
}
#include "friends.h"

void  friends(int A[],int N,int X[],int Y[]) {
  int s = 0, x = 0;
  for(int i = 1; i <= N; i++) if(Y[i] == 0) s |= X[i]; else s |= X[i] << 2;
  for(int i = 1; i <= 5; i++) if(A[i] > 0) x ^= A[i];
  report(s ^ x);
}

Compilation message

friends.cpp: In function 'void friends(int*, int, int*, int*)':
friends.cpp:7:15: error: 'report' was not declared in this scope
grader_friends.c: In function 'int main()':
grader_friends.c:46:15: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
grader_friends.c:52:26: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
grader_friends.c:53:68: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
grader_friends.c: At global scope:
grader_friends.c:18:12: warning: '__now__' defined but not used [-Wunused-variable]