Hi everyone, i am creating a contest for my group but i dont'n know how to check in a many answer problem. This is my checker code:
include <bits/stdc++.h>
include "testlib.h"
typedef long long ll; using namespace std; int a[1000100], b[1000100]; int main(int argc, char * argv[]) { setName("Compare test"); registerTestlibCmd(argc, argv); int n = ans.readInt(); int m = inf.readInt(); if (n == m && n == 0) quitf(_ok, "correct !!");
if (n > m) quitf(_wa, "Are you kidding me ??"); for (int i=1; i<=m; i++) b[i] = inf.readInt(); for (int i=1; i<=n; i++) a[i] = ans.readInt(); int our = b[1]; ll s = 0, t = our; for (int i=2; i<=m; i++) { t += (ll)b[i]; } for (int i=1; i<=n; i++) { if (b[a[i]] > our/2 && a[i] > 1) quitf(_wa,"nooooo!!"); s += (ll)b[a[i]]; } if (s > t/2) quitf(_ok,"Correct!!"); else quitf(_wa, "False!!");
} <\code><\p>
I don't know why when my test is true it have to quit _ok but it return ERROR: Unexpected verdict PRESENTATION_ERROR wrong output format Extra information in the output file. Anyone can help me?? please!!!