Submission #27707

# Submission time Handle Problem Language Result Execution time Memory
27707 2017-07-13T13:52:56 Z repeating Wombats (IOI13_wombats) C++11
0 / 100
3 ms 9852 KB
#include <bits/stdc++.h>
#include "wombats.h"
#define F first
#define S second
#define P push
#define pb push_back
#define MEM(dp,i) memset(dp,i,sizeof(dp))
#define WH while
#define RE return
#define CO continue
#define SI size()
#define ll long long
#define ld long double
#define pll pair<ll,ll>
#define pii pair<int,int>
#define SF(x) scanf("%I64d",&x)
#define SF2(x,y) scanf("%I64d%I64d",&x,&y)
#define SF3(x,y,z) scanf("%I64d%I64d%I64d",&x,&y,&z)
#define SF4(x,y,z,o) scanf("%I64d%I64d%I64d%I64d",&x,&y,&z,&o)
#define all(v) v.begin(),v.end()

using namespace std;
const long long INF = 1e9;
const int MX=100005;

int n,m;
int a[5005];
int res;
void init(int R_, int C_, int H[5000][200], int V[5000][200]) {
    n=R_,m=C_;

    for(int i=0;i<n-1;i++){
        for(int j=0;j<m;j++){
            a[i]=V[i][j];
        }
    }
}
void changeH(int p, int q, int W) {

}

void changeV(int p, int q, int W) {
    res+=W;
    res-=a[p];
    a[p]=W;
}
int escape(int V1, int V2) {
    return res;
}
//#include <stdio.h>
//#include <stdlib.h>
//
//#define fail(s, x...) do { \
//		fprintf(stderr, s "\n", ## x); \
//		exit(1); \
//	} while(0)
//
//static int H[5000][200];
//static int V[5000][200];
//
//int main() {
//	int R, C, E, P, Q, W, V1, V2, event, i, j;
//	int res;
//
//	res = scanf( "%d%d", &R, &C);
//    for (i = 0; i < R; ++i)
//        for (j = 0; j < C-1; ++j)
//            res = scanf( "%d", &H[i][j]);
//    for (i = 0; i < R-1; ++i)
//        for (j = 0; j < C; ++j)
//            res = scanf( "%d", &V[i][j]);
//
//    init(R, C, H, V);
//
//	res = scanf( "%d", &E);
//	for (i = 0; i < E; i++) {
//		res = scanf( "%d", &event);
//        if (event == 1) {
//            res = scanf( "%d%d%d", &P, &Q, &W);
//            changeH(P, Q, W);
//        } else if (event == 2) {
//            res = scanf( "%d%d%d", &P, &Q, &W);
//            changeV(P, Q, W);
//        } else if (event == 3) {
//            res = scanf( "%d%d", &V1, &V2);
//            printf("%d\n", escape(V1, V2));
//        } else
//            fail("Invalid event type.");
//	}
//
//	return 0;
//}

Compilation message

grader.c: In function 'int main()':
grader.c:15:6: warning: variable 'res' set but not used [-Wunused-but-set-variable]
  int res;
      ^
wombats.cpp:53:1: warning: multi-line comment [-Wcomment]
 //#define fail(s, x...) do { \
 ^
# Verdict Execution time Memory Grader output
1 Correct 3 ms 9852 KB Output is correct
2 Incorrect 3 ms 9852 KB Output isn't correct
3 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 9852 KB Output is correct
2 Incorrect 0 ms 9852 KB Output isn't correct
3 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 3 ms 9852 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 9852 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 3 ms 9852 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 3 ms 9852 KB Output isn't correct
2 Halted 0 ms 0 KB -