problem_id stringlengths 6 6 | buggy_code stringlengths 8 526k | fixed_code stringlengths 12 526k | labels listlengths 0 15 ⌀ | buggy_submission_id int64 1 1.54M | fixed_submission_id int64 2 1.54M | user_id stringlengths 10 10 | language stringclasses 8
values |
|---|---|---|---|---|---|---|---|
p02384 | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long top, front, right, left, back, bottom;
Dice(long top, long front);
void north();
void south();
void west();
void east();
void showTop();
void guessRightFromTopAndFront(long top, long front, long *r... | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long top, front, right, left, back, bottom;
Dice(long top, long front);
void north();
void south();
void west();
void east();
void showTop();
void guessRightFromTopAndFront(long top, long front, long *r... | [
"call.arguments.add"
] | 137,720 | 137,721 | u564420347 | cpp |
p02384 | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long top, front, right, left, back, bottom;
Dice(long top, long front);
void north();
void south();
void west();
void east();
void showTop();
void guessRightFromTopAndFront(long top, long front, long *r... | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long top, front, right, left, back, bottom;
Dice(long top, long front);
void north();
void south();
void west();
void east();
void showTop();
void guessRightFromTopAndFront(long top, long front, long *r... | [
"call.arguments.add"
] | 137,723 | 137,721 | u564420347 | cpp |
p02384 | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long top, front, right, left, back, bottom;
Dice(long top, long front);
void north();
void south();
void west();
void east();
void showTop();
void guessRightFromTopAndFront(long top, long front, long *r... | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long top, front, right, left, back, bottom;
Dice(long top, long front);
void north();
void south();
void west();
void east();
void showTop();
void guessRightFromTopAndFront(long top, long front, long *r... | [
"call.arguments.add"
] | 137,725 | 137,721 | u564420347 | cpp |
p02384 | #include <stdio.h>
int a[6], q, s, t, u, v;
const int r[6][6] = {{7, 2, 4, 1, 3, 7}, {3, 7, 0, 5, 7, 2},
{1, 5, 7, 7, 0, 4}, {4, 0, 7, 7, 5, 1},
{2, 7, 5, 0, 7, 3}, {7, 3, 1, 4, 2, 7}};
int main() {
for (int i = 0; i < 6; i++)
scanf("%d", &a[i]);
scanf("%d", &q);
for ... | #include <stdio.h>
int a[6], q, s, t, u, v;
const int r[6][6] = {{7, 2, 4, 1, 3, 7}, {3, 7, 0, 5, 7, 2},
{1, 5, 7, 7, 0, 4}, {4, 0, 7, 7, 5, 1},
{2, 7, 5, 0, 7, 3}, {7, 3, 1, 4, 2, 7}};
int main() {
for (int i = 0; i < 6; i++)
scanf("%d", &a[i]);
scanf("%d", &q);
for ... | [
"expression.operation.binary.remove"
] | 137,729 | 137,730 | u823513038 | cpp |
p02384 | #include <stdio.h>
int a[6], q, s, t, u, v;
const int r[6][6] = {{7, 2, 4, 1, 3, 7}, {3, 7, 0, 5, 7, 2},
{1, 5, 7, 7, 0, 4}, {4, 0, 7, 7, 5, 1},
{2, 7, 5, 0, 7, 3}, {7, 3, 1, 4, 2, 7}};
int main() {
for (int i = 0; i < 6; i++)
scanf("%d", &a[i]);
scanf("%d", &q);
for ... | #include <stdio.h>
int a[6], q, s, t, u, v;
const int r[6][6] = {{7, 2, 4, 1, 3, 7}, {3, 7, 0, 5, 7, 2},
{1, 5, 7, 7, 0, 4}, {4, 0, 7, 7, 5, 1},
{2, 7, 5, 0, 7, 3}, {7, 3, 1, 4, 2, 7}};
int main() {
for (int i = 0; i < 6; i++)
scanf("%d", &a[i]);
scanf("%d", &q);
for ... | [
"expression.operation.binary.remove"
] | 137,731 | 137,730 | u823513038 | cpp |
p02384 | /********
* ???????????????
*********/
/*********??¢?????´?????????
* ??????????????????????????????????????\????????¢???????????????4??¢???1??????????????????????????????
* ???????????´??¢?????????????????????????????§??????????????????
*********/
#include <iostream>
#include <stdio.h>
using namespace std;
int ... | /********
* ???????????????
*********/
/*********??¢?????´?????????
* ??????????????????????????????????????\????????¢???????????????4??¢???1??????????????????????????????
* ???????????´??¢?????????????????????????????§??????????????????
*********/
#include <iostream>
#include <stdio.h>
using namespace std;
int ... | [
"literal.number.change",
"variable_access.subscript.index.change",
"io.output.change"
] | 137,732 | 137,733 | u979799212 | cpp |
p02384 | /********
* ???????????????
*********/
/*********??¢?????´?????????
* ??????????????????????????????????????\????????¢???????????????4??¢???1??????????????????????????????
* ???????????´??¢?????????????????????????????§??????????????????
*********/
#include <iostream>
#include <stdio.h>
using namespace std;
int ... | /********
* ???????????????
*********/
/*********??¢?????´?????????
* ??????????????????????????????????????\????????¢???????????????4??¢???1??????????????????????????????
* ???????????´??¢?????????????????????????????§??????????????????
*********/
#include <iostream>
#include <stdio.h>
using namespace std;
int ... | [
"literal.number.change",
"variable_access.subscript.index.change",
"io.output.change"
] | 137,734 | 137,733 | u979799212 | cpp |
p02384 | #include <bits/stdc++.h>
using namespace std;
int main() {
vector<int> data(7);
map<int, int> d;
for (size_t i = 1; i <= 6; i++) {
cin >> data[i];
d[data[i]] = i;
}
int N;
cin >> N;
for (size_t i = 0; i < N; i++) {
int a, b;
cin >> a >> b;
int x = d[a], y = d[b];
if (x == 1) {
... | #include <bits/stdc++.h>
using namespace std;
int main() {
vector<int> data(7);
map<int, int> d;
for (size_t i = 1; i <= 6; i++) {
cin >> data[i];
d[data[i]] = i;
}
int N;
cin >> N;
for (size_t i = 0; i < N; i++) {
int a, b;
cin >> a >> b;
int x = d[a], y = d[b];
if (x == 1) {
... | [
"literal.number.change",
"variable_access.subscript.index.change",
"io.output.change"
] | 137,736 | 137,737 | u018134297 | cpp |
p02384 | #include <bits/stdc++.h>
#define rep(i, a, n) for (int i = a; i < n; i++)
#define repb(i, a, b) for (int i = a; i >= b; i--)
#define all(a) a.begin(), a.end()
#define int long long
using namespace std;
class dice {
public:
int top, bottom, right, left, front, back;
void North();
void East();
void South();
vo... | #include <bits/stdc++.h>
#define rep(i, a, n) for (int i = a; i < n; i++)
#define repb(i, a, b) for (int i = a; i >= b; i--)
#define all(a) a.begin(), a.end()
#define int long long
using namespace std;
class dice {
public:
int top, bottom, right, left, front, back;
void North();
void East();
void South();
vo... | [
"literal.string.change",
"variable_declaration.value.change",
"literal.number.change",
"assignment.value.change"
] | 137,738 | 137,739 | u188938853 | cpp |
p02384 | #include <iostream>
#include <string>
using namespace std;
class Dice {
private:
int D1;
int D2;
int D3;
int D4;
int D5;
int D6;
public:
Dice(int d1, int d2, int d3, int d4, int d5, int d6) {
D1 = d1;
D2 = d2;
D2 = d2;
D3 = d3;
D4 = d4;
D5 = d5;
D6 = d6;
}
void roll(cha... | #include <iostream>
#include <string>
using namespace std;
class Dice {
private:
int D1;
int D2;
int D3;
int D4;
int D5;
int D6;
public:
Dice(int d1, int d2, int d3, int d4, int d5, int d6) {
D1 = d1;
D2 = d2;
D2 = d2;
D3 = d3;
D4 = d4;
D5 = d5;
D6 = d6;
}
void roll(cha... | [
"literal.number.change",
"control_flow.loop.for.condition.change",
"expression.off_by_one",
"expression.operation.binary.change"
] | 137,742 | 137,743 | u064835577 | cpp |
p02384 | #include <iostream>
using namespace std;
int Dice[6];
void shake(char c) {
if (c == 'E') {
swap(Dice[0], Dice[3]);
swap(Dice[3], Dice[5]);
swap(Dice[5], Dice[2]);
}
if (c == 'N') {
swap(Dice[0], Dice[1]);
swap(Dice[1], Dice[5]);
swap(Dice[5], Dice[4]);
}
if (c == 'S') {
swap(Dice... | #include <iostream>
using namespace std;
int Dice[6];
void shake(char c) {
if (c == 'E') {
swap(Dice[0], Dice[3]);
swap(Dice[3], Dice[5]);
swap(Dice[5], Dice[2]);
}
if (c == 'N') {
swap(Dice[0], Dice[1]);
swap(Dice[1], Dice[5]);
swap(Dice[5], Dice[4]);
}
if (c == 'S') {
swap(Dice... | [
"variable_declaration.add",
"identifier.change",
"variable_access.subscript.index.change",
"call.arguments.change",
"assignment.variable.change",
"control_flow.loop.for.initializer.change",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change"
] | 137,744 | 137,745 | u622377948 | cpp |
p02384 | #include <iostream>
using namespace std;
int main() {
int Dice[6];
int q;
int up;
int forward;
int tmp;
int i, j, k;
for (i = 0; i < 6; i++) {
cin >> Dice[i];
}
cin >> q;
for (i = 0; i < q; i++) {
cin >> up >> forward;
for (j = 0; j < 4; j++) {
tmp = Dice[0];
Dice[0] = Di... | #include <iostream>
using namespace std;
int main() {
int Dice[6];
int q;
int up;
int forward;
int tmp;
int i, j, k;
for (i = 0; i < 6; i++) {
cin >> Dice[i];
}
cin >> q;
for (i = 0; i < q; i++) {
cin >> up >> forward;
for (j = 0; j < 4; j++) {
tmp = Dice[0];
Dice[0] = Di... | [
"assignment.variable.change",
"identifier.change",
"control_flow.loop.for.initializer.change",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change"
] | 137,748 | 137,749 | u017730994 | cpp |
p02384 | #include <iostream>
using namespace std;
class dice {
private:
int status[6];
public:
dice();
int showright(void);
bool is(int, int);
bool isfront(int);
void rotate(char);
};
dice::dice() {
for (int i = 0; i < 6; i++)
cin >> status[i];
}
bool dice::isfront(int a) {
if (status[1] == a)
return ... | #include <iostream>
using namespace std;
class dice {
private:
int status[6];
public:
dice();
int showright(void);
bool is(int, int);
bool isfront(int);
void rotate(char);
};
dice::dice() {
for (int i = 0; i < 6; i++)
cin >> status[i];
}
bool dice::isfront(int a) {
if (status[1] == a)
return ... | [
"expression.operator.compare.change",
"control_flow.loop.for.condition.change",
"expression.off_by_one",
"expression.operation.binary.change",
"literal.number.change",
"control_flow.branch.if.condition.change"
] | 137,750 | 137,751 | u835844653 | cpp |
p02384 | #include <bits/stdc++.h>
using namespace std;
struct die {
int val[6];
void N() {
int tmp[6];
for (int i = 0; i < 6; i++) {
tmp[i] = val[i];
}
val[0] = tmp[1];
val[4] = tmp[0];
val[5] = tmp[4];
val[1] = tmp[5];
}
void E() {
int tmp[6];
for (int i = 0; i < 6; i++) {
... | #include <bits/stdc++.h>
using namespace std;
struct die {
int val[6];
void N() {
int tmp[6];
for (int i = 0; i < 6; i++) {
tmp[i] = val[i];
}
val[0] = tmp[1];
val[4] = tmp[0];
val[5] = tmp[4];
val[1] = tmp[5];
}
void E() {
int tmp[6];
for (int i = 0; i < 6; i++) {
... | [
"literal.number.change",
"variable_access.subscript.index.change",
"control_flow.branch.if.condition.change"
] | 137,752 | 137,753 | u527286045 | cpp |
p02384 | #include "bits/stdc++.h"
using namespace std;
class Cube {
public:
int f[6];
Cube() {}
void roll_z() { roll(1, 2, 4, 3); }
void roll_y() { roll(0, 2, 5, 3); } // to W
void roll_x() { roll(0, 1, 5, 4); } // to N
void roll(int i, int j, int k, int l) {
int t = f[i];
f[i] = f[j];
f[j] = f[k];
... | #include "bits/stdc++.h"
using namespace std;
class Cube {
public:
int f[6];
Cube() {}
void roll_z() { roll(1, 2, 4, 3); }
void roll_y() { roll(0, 2, 5, 3); } // to W
void roll_x() { roll(0, 1, 5, 4); } // to N
void roll(int i, int j, int k, int l) {
int t = f[i];
f[i] = f[j];
f[j] = f[k];
... | [] | 137,757 | 137,758 | u944777079 | cpp |
p02384 | #include <iostream>
#include <string>
using namespace std;
class Dice {
public:
int a, s, e, w, n, b;
int r[6] = {1, 2, 3, 4, 5, 6};
void setint(int a1, int s1, int e1, int w1, int n1, int b1);
int geta();
int gets();
int getn();
int gete();
int getw();
int getb();
void moveS();
void moveN();
v... | #include <iostream>
#include <string>
using namespace std;
class Dice {
public:
int a, s, e, w, n, b;
int r[6] = {1, 2, 3, 4, 5, 6};
void setint(int a1, int s1, int e1, int w1, int n1, int b1);
int geta();
int gets();
int getn();
int gete();
int getw();
int getb();
void moveS();
void moveN();
v... | [
"control_flow.branch.if.condition.change",
"control_flow.loop.for.condition.change"
] | 137,762 | 137,763 | u565258889 | cpp |
p02384 | #include <iostream>
#include <math.h>
#include <stdio.h>
#include <string>
#include <vector>
class dice {
private:
int a, b, c, d, e, f, inas, inbs, ans;
std::vector<int> list = {0, 1, 2, 3, 4, 5};
std::vector<int> listb = {0, 1, 2, 3, 4, 5};
std::vector<int> listc = {0, 1, 2, 3, 4, 5};
public:
dice(int i, i... | #include <iostream>
#include <math.h>
#include <stdio.h>
#include <string>
#include <vector>
class dice {
private:
int a, b, c, d, e, f, inas, inbs, ans;
std::vector<int> list = {0, 1, 2, 3, 4, 5};
std::vector<int> listb = {0, 1, 2, 3, 4, 5};
std::vector<int> listc = {0, 1, 2, 3, 4, 5};
public:
dice(int i, i... | [
"literal.number.change",
"assignment.value.change",
"control_flow.branch.if.condition.change"
] | 137,764 | 137,765 | u840175389 | cpp |
p02384 | //============================================================================
// Name : ITP_1_11_B.cpp
// Author :
// Version :
// Copyright : Your copyright notice
// Description : Hello World in C++, Ansi-style
//============================================================================
#include... | //============================================================================
// Name : ITP_1_11_B.cpp
// Author :
// Version :
// Copyright : Your copyright notice
// Description : Hello World in C++, Ansi-style
//============================================================================
#include... | [
"identifier.replace.add",
"literal.replace.remove",
"function.return_value.change"
] | 137,766 | 137,767 | u263859629 | cpp |
p02384 | //============================================================================
// Name : ITP_1_11_B.cpp
// Author :
// Version :
// Copyright : Your copyright notice
// Description : Hello World in C++, Ansi-style
//============================================================================
#include... | #include <iostream>
using namespace std;
class dice {
public:
int getTopFace(void);
int getRightFace(int top, int front);
void rotate(char dir);
void setFaceNumber(int *number);
private:
int face[6];
};
int dice::getTopFace(void) { return face[0]; }
void dice::rotate(char dir) {
int temp;
switch (dir)... | [
"identifier.replace.add",
"literal.replace.remove",
"function.return_value.change"
] | 137,766 | 137,768 | u263859629 | cpp |
p02384 | #include <stdio.h>
typedef struct Dice {
int d[6];
int r[6];
int b[6];
} dice;
int main(void) {
dice num;
int q, i, c;
int u[24], p[24], re[24] = {0};
for (i = 0; i < 6; i++) {
scanf("%d", &num.d[i]);
}
scanf("%d", &q);
for (i = 0; i < q; i++) {
scanf("%d %d", &u[i], &p[i]);
}
for (int k... | #include <stdio.h>
typedef struct Dice {
int d[6];
int r[6];
int b[6];
} dice;
int main(void) {
dice num;
int q, i, c;
int u[24], p[24], re[24] = {0};
for (i = 0; i < 6; i++) {
scanf("%d", &num.d[i]);
}
scanf("%d", &q);
for (i = 0; i < q; i++) {
scanf("%d %d", &u[i], &p[i]);
}
for (int k... | [] | 137,769 | 137,770 | u726704931 | cpp |
p02384 | #include <iostream>
#include <map>
using namespace std;
int main() {
map<int, int> m;
map<int, int> r;
int a[6], n, x, y;
int d[6][6] = {{0, 3, 5, 2, 4, 0}, {4, 0, 1, 6, 0, 3}, {2, 6, 0, 0, 1, 5},
{6, 1, 0, 0, 6, 2}, {3, 0, 6, 1, 0, 4}, {0, 4, 2, 5, 3, 0}};
for (int i = 0; i < 6; i++) {
... | #include <iostream>
#include <map>
using namespace std;
int main() {
map<int, int> m;
map<int, int> r;
int a[6], n, x, y;
int d[6][6] = {{0, 3, 5, 2, 4, 0}, {4, 0, 1, 6, 0, 3}, {2, 6, 0, 0, 1, 5},
{5, 1, 0, 0, 6, 2}, {3, 0, 6, 1, 0, 4}, {0, 4, 2, 5, 3, 0}};
for (int i = 0; i < 6; i++) {
... | [
"literal.number.change"
] | 137,771 | 137,772 | u096656118 | cpp |
p02384 | #include <iostream>
#include <math.h>
#include <string>
#define MEN 6
#include <iomanip>
using namespace std;
struct DICE {
int num;
};
int main() {
DICE A[MEN];
int out[24];
int q, x, y;
int i = 0;
for (int i = 0; i < MEN; i++) {
cin >> A[i].num;
}
cin >> q;
for (int i = 0; i < q; i++) {
... | #include <iostream>
#include <math.h>
#include <string>
#define MEN 6
#include <iomanip>
using namespace std;
struct DICE {
int num;
};
int main() {
DICE A[MEN];
int out[24];
int q, x, y;
int i = 0;
for (int i = 0; i < MEN; i++) {
cin >> A[i].num;
}
cin >> q;
for (int i = 0; i < q; i++) {
... | [
"literal.number.change",
"variable_access.subscript.index.change",
"expression.operation.binary.change",
"assignment.value.change"
] | 137,777 | 137,778 | u169109925 | cpp |
p02384 | #include <bits/stdc++.h>
using namespace std;
struct dice {
vector<int> diceindex{0, 1, 2, 3, 4, 5};
vector<int> dicenum{1, 2, 3, 4, 5, 6};
void setNumber(vector<int> &setnum) {
for (int i = 0; i < 6; i++) {
dicenum[diceindex[i]] = setnum[diceindex[i]];
}
return;
}
vector<int> getNumber(... | #include <bits/stdc++.h>
using namespace std;
struct dice {
vector<int> diceindex{0, 1, 2, 3, 4, 5};
vector<int> dicenum{1, 2, 3, 4, 5, 6};
void setNumber(vector<int> &setnum) {
for (int i = 0; i < 6; i++) {
dicenum[diceindex[i]] = setnum[diceindex[i]];
}
return;
}
vector<int> getNumber(... | [
"literal.number.change",
"control_flow.loop.for.condition.change",
"expression.off_by_one",
"expression.operation.binary.change"
] | 137,779 | 137,780 | u020019294 | cpp |
p02384 | #include <cstdio>
using namespace std;
class Dice {
public:
int face[6];
Dice() {}
int roll(int a, int b, int c, int d) {
int temp = face[a];
face[a] = face[b];
face[b] = face[c];
face[c] = face[d];
face[d] = temp;
return 0;
}
int move(char c) {
if (c == 'W')
roll(0, 2, 5, 3... | #include <cstdio>
using namespace std;
class Dice {
public:
int face[6];
Dice() {}
int roll(int a, int b, int c, int d) {
int temp = face[a];
face[a] = face[b];
face[b] = face[c];
face[c] = face[d];
face[d] = temp;
return 0;
}
int move(char c) {
if (c == 'W')
roll(0, 2, 5, 3... | [
"literal.number.change",
"control_flow.branch.if.condition.change"
] | 137,781 | 137,782 | u721279180 | cpp |
p02384 | #include <iostream>
#include <string>
using namespace std;
class dice {
public:
int t[7][6];
dice() { //??????????????????????????????
}
void ready() {
t[1][1] = t[5][0], t[1][2] = t[4][0], t[1][3] = t[2][0], t[1][4] = t[5][0],
t[1][5] = t[5][0];
t[2][1] = t[1][0], t[2][2] = t[4][0], t[2][3] = t[... | #include <iostream>
#include <string>
using namespace std;
class dice {
public:
int t[7][6];
dice() { //??????????????????????????????
}
void ready() {
t[1][1] = t[5][0], t[1][2] = t[4][0], t[1][3] = t[2][0], t[1][4] = t[3][0],
t[1][5] = t[5][0];
t[2][1] = t[1][0], t[2][2] = t[4][0], t[2][3] = t[... | [
"literal.number.change",
"assignment.value.change",
"variable_access.subscript.index.change",
"control_flow.loop.for.condition.change",
"expression.off_by_one",
"expression.operation.binary.change"
] | 137,785 | 137,786 | u950835578 | cpp |
p02384 | #include <iostream>
using namespace std;
int faces[1 + 6];
void roll(int f) {
int tmp = faces[f];
faces[f] = faces[1];
faces[1] = faces[7 - f];
faces[7 - f] = faces[6];
faces[6] = tmp;
}
int main() {
int input[1 + 6];
for (int i = 1; i <= 6; i++) {
cin >> input[i];
}
int n, top, front, right,... | #include <iostream>
using namespace std;
int faces[1 + 6];
void roll(int f) {
int tmp = faces[f];
faces[f] = faces[1];
faces[1] = faces[7 - f];
faces[7 - f] = faces[6];
faces[6] = tmp;
}
int main() {
int input[1 + 6];
for (int i = 1; i <= 6; i++) {
cin >> input[i];
}
int n, top, front, right,... | [
"control_flow.break.remove",
"control_flow.continue.add"
] | 137,787 | 137,788 | u556857282 | cpp |
p02384 | #include <cstdlib>
#include <iomanip>
#include <iostream>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
using namespace std;
int main() {
int x[7];
for (int i = 1; i < 7; i++) {
cin >> x[i];
}
int n = 0;
cin >> n;
bool t[7][7];
memset(t, 0, 7 * 7 * sizeof(bool));
t... | #include <cstdlib>
#include <iomanip>
#include <iostream>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
using namespace std;
int main() {
int x[7];
for (int i = 1; i < 7; i++) {
cin >> x[i];
}
int n = 0;
cin >> n;
bool t[7][7];
memset(t, 0, 7 * 7 * sizeof(bool));
t... | [
"io.output.change"
] | 137,789 | 137,790 | u721602113 | cpp |
p02384 | #include <cctype>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <sstream>
using namespace std;
#define MPI 3.14159265358979323846
struct Dice {
int num[6];
void roll(int, int, int &);
};
void Dice::roll(int c1, int c2, int &ans) {
if (c1 == num[0]) {
if (c2 == num[1])
... | #include <cctype>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <sstream>
using namespace std;
#define MPI 3.14159265358979323846
struct Dice {
int num[6];
void roll(int, int, int &);
};
void Dice::roll(int c1, int c2, int &ans) {
if (c1 == num[0]) {
if (c2 == num[1])
... | [
"literal.number.change",
"assignment.value.change",
"variable_access.subscript.index.change"
] | 137,791 | 137,792 | u307963077 | cpp |
p02384 | #include <iostream>
using namespace std;
int main() {
int d[7], g;
cin >> d[1] >> d[2] >> d[3] >> d[4] >> d[5] >> d[6] >> g;
for (int i = 0; i < g; i++) {
int x, y;
cin >> x >> y;
if (x != d[1]) {
if (x == d[2]) {
int t = d[2];
d[2] = d[6];
d[6] = d[5];
d[5] = d[... | #include <iostream>
using namespace std;
int main() {
int d[7], g;
cin >> d[1] >> d[2] >> d[3] >> d[4] >> d[5] >> d[6] >> g;
for (int i = 0; i < g; i++) {
int x, y;
cin >> x >> y;
if (x != d[1]) {
if (x == d[2]) {
int t = d[2];
d[2] = d[6];
d[6] = d[5];
d[5] = d[... | [
"assignment.add",
"assignment.change"
] | 137,793 | 137,794 | u610263790 | cpp |
p02384 | #include <bits/stdc++.h>
using namespace std;
/*
if(x=='N')
{m1=d2;m2=d6;m6=d5;m5=d1;
}
if(x=='S')
{m1=d5;m5=d6;m6=d2;m2=d1;
}
if(x=='W')
{m3=d6;m6=d4;m4=d1;m1=d3;
}
if(x=='E')
{m6=d3;m3=d1;m1=d4;m4=d6;
}
*/
int main() {
// DICE input
int d1, d2, d3, d... | #include <bits/stdc++.h>
using namespace std;
/*
if(x=='N')
{m1=d2;m2=d6;m6=d5;m5=d1;
}
if(x=='S')
{m1=d5;m5=d6;m6=d2;m2=d1;
}
if(x=='W')
{m3=d6;m6=d4;m4=d1;m1=d3;
}
if(x=='E')
{m6=d3;m3=d1;m1=d4;m4=d6;
}
*/
int main() {
// DICE input
int d1, d2, d3, d... | [
"literal.number.change",
"control_flow.branch.if.condition.change"
] | 137,795 | 137,796 | u575569688 | cpp |
p02384 | #include <iostream>
using namespace std;
class Dice {
public:
int face[6];
Dice() {}
void rotateX() { rotate(0, 1, 5, 4); }
void rotateY() { rotate(0, 2, 5, 3); }
void rotateZ() { rotate(0, 1, 5, 4); }
void rotate(int a, int b, int c, int d) {
int t = face[a];
face[a] = face[b];
face[b] = face... | #include <iostream>
using namespace std;
class Dice {
public:
int face[6];
Dice() {}
void rotateX() { rotate(0, 1, 5, 4); }
void rotateY() { rotate(0, 2, 5, 3); }
void rotateZ() { rotate(1, 2, 4, 3); }
void rotate(int a, int b, int c, int d) {
int t = face[a];
face[a] = face[b];
face[b] = face... | [
"call.arguments.change",
"literal.number.change",
"call.arguments.add"
] | 137,800 | 137,801 | u906532016 | cpp |
p02385 | #include <iostream>
#include <string>
using namespace std;
class DICE {
private:
const int dice_tem[5][6] = {
{3, 2, 6, 1, 5, 4},
{2, 6, 3, 4, 1, 5},
{5, 1, 3, 4, 6, 2},
{4, 2, 1, 6, 5, 3},
{1, 2, 3, 4, 5, 6}}; //{0}:W {1}:N {2}:S {3}:E {4}:defalut
const string dice_rl = "AWWWNWWWNWWW... | #include <iostream>
#include <string>
using namespace std;
class DICE {
private:
const int dice_tem[5][6] = {
{3, 2, 6, 1, 5, 4},
{2, 6, 3, 4, 1, 5},
{5, 1, 3, 4, 6, 2},
{4, 2, 1, 6, 5, 3},
{1, 2, 3, 4, 5, 6}}; //{0}:W {1}:N {2}:S {3}:E {4}:defalut
const string dice_rl = "AWWWNWWWNWWW... | [
"identifier.change"
] | 137,967 | 137,968 | u437044058 | cpp |
p02385 | #include <iostream>
#include <string>
using namespace std;
class DICE {
private:
const int dice_tem[5][6] = {
{3, 2, 6, 1, 5, 4},
{2, 6, 3, 4, 1, 5},
{5, 1, 3, 4, 6, 2},
{4, 2, 1, 6, 5, 3},
{1, 2, 3, 4, 5, 6}}; //{0}:W {1}:N {2}:S {3}:E {4}:defalut
const string dice_rl = "AWWWNWWWNWWW... | #include <iostream>
#include <string>
using namespace std;
class DICE {
private:
const int dice_tem[5][6] = {
{3, 2, 6, 1, 5, 4},
{2, 6, 3, 4, 1, 5},
{5, 1, 3, 4, 6, 2},
{4, 2, 1, 6, 5, 3},
{1, 2, 3, 4, 5, 6}}; //{0}:W {1}:N {2}:S {3}:E {4}:defalut
const string dice_rl = "AWWWNWWWNWWW... | [
"identifier.change",
"assignment.add"
] | 137,969 | 137,968 | u437044058 | cpp |
p02385 | #include <iostream>
#include <string>
using namespace std;
class DICE {
private:
const int dice_tem[5][6] = {
{3, 2, 6, 1, 5, 4},
{2, 6, 3, 4, 1, 5},
{5, 1, 3, 4, 6, 2},
{4, 2, 1, 6, 5, 3},
{1, 2, 3, 4, 5, 6}}; //{0}:W {1}:N {2}:S {3}:E {4}:defalut
const string dice_rl = "AWWWNWWWNWWW... | #include <iostream>
#include <string>
using namespace std;
class DICE {
private:
const int dice_tem[5][6] = {
{3, 2, 6, 1, 5, 4},
{2, 6, 3, 4, 1, 5},
{5, 1, 3, 4, 6, 2},
{4, 2, 1, 6, 5, 3},
{1, 2, 3, 4, 5, 6}}; //{0}:W {1}:N {2}:S {3}:E {4}:defalut
const string dice_rl = "AWWWNWWWNWWW... | [
"identifier.change",
"assignment.variable.change",
"assignment.change"
] | 137,970 | 137,968 | u437044058 | cpp |
p02385 | #include <iostream>
using namespace std;
class Dice {
public:
int f[7];
Dice() {}
void roll_x() { roll(1, 4, 6, 3); } // to E
void roll_y() { roll(1, 2, 6, 5); } // to N
void roll_z() { roll(2, 3, 5, 4); } // 上から見て時計回り
void roll(int i, int j, int k, int l) {
int t = f[i];
f[i] = f[j];
f[j] = f[... | #include <iostream>
using namespace std;
class Dice {
public:
int f[7];
Dice() {}
void roll_x() { roll(1, 4, 6, 3); } // to E
void roll_y() { roll(1, 2, 6, 5); } // to N
void roll_z() { roll(2, 3, 5, 4); } // 上から見て時計回り
void roll(int i, int j, int k, int l) {
int t = f[i];
f[i] = f[j];
f[j] = f[... | [
"identifier.change",
"call.function.change",
"control_flow.branch.if.condition.change"
] | 137,977 | 137,978 | u306715188 | cpp |
p02385 | #include <iostream>
using namespace std;
class Dice {
public:
int f[6];
Dice() {}
void roll_x() { roll(1, 4, 6, 3); } // to E
void roll_y() { roll(1, 2, 6, 5); } // to N
void roll_z() { roll(2, 3, 5, 4); } // 上から見て時計回り
void roll(int i, int j, int k, int l) {
int t = f[i];
f[i] = f[j];
f[j] = f[... | #include <iostream>
using namespace std;
class Dice {
public:
int f[7];
Dice() {}
void roll_x() { roll(1, 4, 6, 3); } // to E
void roll_y() { roll(1, 2, 6, 5); } // to N
void roll_z() { roll(2, 3, 5, 4); } // 上から見て時計回り
void roll(int i, int j, int k, int l) {
int t = f[i];
f[i] = f[j];
f[j] = f[... | [
"literal.number.change",
"variable_declaration.array_dimensions.change"
] | 137,979 | 137,978 | u306715188 | cpp |
p02385 | #include <algorithm>
#include <iostream>
#define REP(i, a, b) for (i = a; i < b; i++)
#define rep(i, n) REP(i, 0, n)
using namespace std;
class Dice {
private:
int tmp;
public:
int lab[6];
void rE() {
tmp = lab[0];
lab[0] = lab[3];
lab[3] = lab[5];
lab[5] = lab[2];
lab[2] = tmp;
}
void... | #include <algorithm>
#include <iostream>
#define REP(i, a, b) for (i = a; i < b; i++)
#define rep(i, n) REP(i, 0, n)
using namespace std;
class Dice {
private:
int tmp;
public:
int lab[6];
void rE() {
tmp = lab[0];
lab[0] = lab[3];
lab[3] = lab[5];
lab[5] = lab[2];
lab[2] = tmp;
}
void... | [] | 137,984 | 137,985 | u328607523 | cpp |
p02385 | #include <algorithm>
#include <cctype>
#include <cmath>
#include <iostream>
#include <list>
#include <map>
#include <string>
#include <utility>
#include <vector>
using namespace std;
enum FACE { TOP, BACK, RIGHT, LEFT, FRONT, BOTTOM };
template <class T> class dice {
public:
dice() {
id[TOP] = 0;
id[FRONT] =... | #include <algorithm>
#include <cctype>
#include <cmath>
#include <iostream>
#include <list>
#include <map>
#include <string>
#include <utility>
#include <vector>
using namespace std;
enum FACE { TOP, BACK, RIGHT, LEFT, FRONT, BOTTOM };
template <class T> class dice {
public:
dice() {
id[TOP] = 0;
id[FRONT] =... | [
"literal.string.change",
"literal.string.case.change",
"io.output.change"
] | 137,986 | 137,987 | u033222986 | cpp |
p02385 | #include <iostream>
#include <limits.h>
#include <stdio.h>
#include <string.h>
#include <string>
#include <vector>
using namespace std;
void north(int *faces) {
int tmp[7];
// top(1) to back(5)
tmp[5] = faces[1];
// front(2) to top(1)
tmp[1] = faces[2];
// right(3) to right(3)
tmp[3] = faces[3];
//... | #include <iostream>
#include <limits.h>
#include <stdio.h>
#include <string.h>
#include <string>
#include <vector>
using namespace std;
void north(int *faces) {
int tmp[7];
// top(1) to back(5)
tmp[5] = faces[1];
// front(2) to top(1)
tmp[1] = faces[2];
// right(3) to right(3)
tmp[3] = faces[3];
//... | [
"misc.opposites",
"function.return_value.change"
] | 138,000 | 138,001 | u004641776 | cpp |
p02385 | #include <iostream>
#include <string>
using namespace std;
class Dice {
public:
static const int SURFACE_NUM = 6; // ?????????????????¢??°
static const int DIR_NUM = 4; // ?????¢?????????????????°
static const int ROUND_NUM = 4; // ?????¢????????¢?????°
enum DIR { N, W, S, E }; // ?????¢??????
... | #include <iostream>
#include <string>
using namespace std;
class Dice {
public:
static const int SURFACE_NUM = 6; // ?????????????????¢??°
static const int DIR_NUM = 4; // ?????¢?????????????????°
static const int ROUND_NUM = 4; // ?????¢????????¢?????°
enum DIR { N, W, S, E }; // ?????¢??????
... | [
"identifier.change",
"call.arguments.change",
"literal.number.change",
"variable_access.subscript.index.change",
"control_flow.branch.if.condition.change"
] | 138,002 | 138,003 | u973694800 | cpp |
p02385 | #include <iostream>
#include <string>
using namespace std;
class Dice {
public:
static const int SURFACE_NUM = 6; // ?????????????????¢??°
static const int DIR_NUM = 4; // ?????¢?????????????????°
static const int ROUND_NUM = 4; // ?????¢????????¢?????°
enum DIR { N, W, S, E }; // ?????¢??????
... | #include <iostream>
#include <string>
using namespace std;
class Dice {
public:
static const int SURFACE_NUM = 6; // ?????????????????¢??°
static const int DIR_NUM = 4; // ?????¢?????????????????°
static const int ROUND_NUM = 4; // ?????¢????????¢?????°
enum DIR { N, W, S, E }; // ?????¢??????
... | [
"identifier.change",
"call.arguments.change"
] | 138,004 | 138,003 | u973694800 | cpp |
p02385 | #include <iostream>
using namespace std;
struct Dice {
int top;
int north;
int east;
int south;
int west;
int bottom;
};
void rotn(Dice &d);
void rote(Dice &d);
// void rots(Dice& d);
// void rotw(Dice& d);
void rotc(Dice &d);
bool judge(Dice &d1, Dice &d2);
Dice d1, d2;
int tmp;
bool flag = false;
int ... | #include <iostream>
using namespace std;
struct Dice {
int top;
int north;
int east;
int south;
int west;
int bottom;
};
void rotn(Dice &d);
void rote(Dice &d);
// void rots(Dice& d);
// void rotw(Dice& d);
void rotc(Dice &d);
bool judge(Dice &d1, Dice &d2);
Dice d1, d2;
int tmp;
bool flag = false;
int ... | [
"literal.string.change",
"io.output.change"
] | 138,005 | 138,006 | u389538742 | cpp |
p02385 | #include <iostream>
using namespace std;
class Dice {
public:
int n1, n2, n3, n4, n5, n6;
void East() {
int t = n1;
n1 = n4;
n4 = n6;
n6 = n3;
n3 = t;
}
void West() {
int t = n1;
n1 = n3;
n3 = n6;
n6 = n4;
n4 = t;
}
void South() {
int t = n1;
n1 = n5;
n5 ... | #include <iostream>
using namespace std;
class Dice {
public:
int n1, n2, n3, n4, n5, n6;
void East() {
int t = n1;
n1 = n4;
n4 = n6;
n6 = n3;
n3 = t;
}
void West() {
int t = n1;
n1 = n3;
n3 = n6;
n6 = n4;
n4 = t;
}
void South() {
int t = n1;
n1 = n5;
n5 ... | [] | 138,007 | 138,008 | u813832396 | cpp |
p02385 | #include <iostream>
using namespace std;
#include <string>
class dice {
public:
int F[6];
dice();
void roll_a();
void roll_b();
bool check(const dice &d);
};
dice::dice() {
for (int i = 0; i < 6; i++)
cin >> F[i];
}
void dice::roll_a() {
static int i, j;
i = F[0];
F[0] = F[2];
F[2] = F[1];
... | #include <iostream>
using namespace std;
#include <string>
class dice {
public:
int F[6];
dice();
void roll_a();
void roll_b();
bool check(const dice &d);
};
dice::dice() {
for (int i = 0; i < 6; i++)
cin >> F[i];
}
void dice::roll_a() {
static int i, j;
i = F[0];
F[0] = F[2];
F[2] = F[1];
... | [
"identifier.change",
"variable_access.subscript.index.change",
"control_flow.branch.if.condition.change"
] | 138,009 | 138,010 | u986478725 | cpp |
p02385 | #include <bits/stdc++.h>
#define rep(i, a, n) for (int i = a; i < n; i++)
#define repb(i, a, b) for (int i = a; i >= b; i--)
#define all(a) a.begin(), a.end()
#define int long long
using namespace std;
// ITPC dice3
class dice {
public:
int top, bottom, right, left, front, back;
void North();
void East();
voi... | #include <bits/stdc++.h>
#define rep(i, a, n) for (int i = a; i < n; i++)
#define repb(i, a, b) for (int i = a; i >= b; i--)
#define all(a) a.begin(), a.end()
#define int long long
using namespace std;
// ITPC dice3
class dice {
public:
int top, bottom, right, left, front, back;
void North();
void East();
voi... | [
"literal.string.change",
"variable_declaration.value.change"
] | 138,011 | 138,012 | u188938853 | cpp |
p02385 | #include <bits/stdc++.h>
#define rep(i, a, n) for (int i = a; i < n; i++)
#define repb(i, a, b) for (int i = a; i >= b; i--)
#define all(a) a.begin(), a.end()
#define int long long
using namespace std;
// ITPC dice3
class dice {
public:
int top, bottom, right, left, front, back;
void North();
void East();
voi... | #include <bits/stdc++.h>
#define rep(i, a, n) for (int i = a; i < n; i++)
#define repb(i, a, b) for (int i = a; i >= b; i--)
#define all(a) a.begin(), a.end()
#define int long long
using namespace std;
// ITPC dice3
class dice {
public:
int top, bottom, right, left, front, back;
void North();
void East();
voi... | [
"literal.string.change",
"variable_declaration.value.change"
] | 138,013 | 138,012 | u188938853 | cpp |
p02385 | #include <algorithm>
#include <cmath>
#include <cstdio>
#include <iostream>
#include <random>
#include <vector>
using namespace std;
#define REP(i, n) for (int(i) = 0; (i) < (n); (i)++)
#define For(i, a, b) for (int(i) = (a); (i) < (b); (i)++)
class Dice {
vector<int> v;
public:
Dice(int a, int b, int c, int d, ... | #include <algorithm>
#include <cmath>
#include <cstdio>
#include <iostream>
#include <random>
#include <vector>
using namespace std;
#define REP(i, n) for (int(i) = 0; (i) < (n); (i)++)
#define For(i, a, b) for (int(i) = (a); (i) < (b); (i)++)
class Dice {
vector<int> v;
public:
Dice(int a, int b, int c, int d, ... | [
"assignment.value.change",
"identifier.change",
"variable_access.subscript.index.change",
"expression.operation.binary.change"
] | 138,019 | 138,020 | u956279155 | cpp |
p02385 | #include <iostream>
using namespace std;
class Cube {
public:
int f[6];
Cube() {}
void roll_x() { roll(0, 1, 5, 4); }
void roll_y() { roll(0, 2, 5, 3); }
void roll_z() { roll(1, 2, 4, 3); }
void roll(int i, int j, int k, int l) {
int t = f[i];
f[i] = f[j];
f[j] = f[k];
f[k] = f[l];
f[l]... | #include <iostream>
using namespace std;
class Cube {
public:
int f[6];
Cube() {}
void roll_x() { roll(0, 1, 5, 4); }
void roll_y() { roll(0, 2, 5, 3); }
void roll_z() { roll(1, 2, 4, 3); }
void roll(int i, int j, int k, int l) {
int t = f[i];
f[i] = f[j];
f[j] = f[k];
f[k] = f[l];
f[l]... | [
"literal.string.change",
"literal.string.case.change",
"io.output.change"
] | 138,031 | 138,032 | u608789460 | cpp |
p02385 | #include <iostream>
using namespace std;
int d1[6], d2[6];
void _n() {
int tmp = d2[0];
d2[0] = d2[1];
d2[1] = d2[5];
d2[5] = d2[4];
d2[4] = tmp;
}
void _s() {
int tmp = d2[0];
d2[0] = d2[4];
d2[4] = d2[5];
d2[5] = d2[1];
d2[1] = tmp;
}
void _e() {
int tmp = d2[0];
d2[0] = d2[3];
d2[3] = d2[5]... | #include <iostream>
using namespace std;
int d1[6], d2[6];
void _n() {
int tmp = d2[0];
d2[0] = d2[1];
d2[1] = d2[5];
d2[5] = d2[4];
d2[4] = tmp;
}
void _s() {
int tmp = d2[0];
d2[0] = d2[4];
d2[4] = d2[5];
d2[5] = d2[1];
d2[1] = tmp;
}
void _e() {
int tmp = d2[0];
d2[0] = d2[3];
d2[3] = d2[5]... | [] | 138,033 | 138,034 | u557138543 | cpp |
p02385 | #include <bits/stdc++.h>
using namespace std;
struct cww {
cww() {
ios::sync_with_stdio(false);
cin.tie(0);
}
} star;
#define P(x) cout << (x) << endl
#define p(x) cout << (x)
#define all(c) (c).begin(), (c).end()
#define rall(c) (c).rbegin(), (c).rend()
#define vv(type, c, m, n, i) vector<vector<type>> c(m... | #include <bits/stdc++.h>
using namespace std;
struct cww {
cww() {
ios::sync_with_stdio(false);
cin.tie(0);
}
} star;
#define P(x) cout << (x) << endl
#define p(x) cout << (x)
#define all(c) (c).begin(), (c).end()
#define rall(c) (c).rbegin(), (c).rend()
#define vv(type, c, m, n, i) vector<vector<type>> c(m... | [
"literal.number.change",
"call.arguments.change",
"literal.string.change",
"literal.string.case.change"
] | 138,038 | 138,039 | u426534722 | cpp |
p02385 | #include <iostream>
using namespace std;
int main() {
int d1[6], d2[6], tmp, cnt, j, a = 1;
for (int i = 0; i < 6; i++) {
cin >> d1[i];
}
for (int i = 0; i < 6; i++) {
cin >> d2[i];
}
cnt = 0;
for (j = 0; j < 6; j++)
if (d1[j] == d2[j])
cnt++;
if (cnt == 6)
a = 0;
while (a) {... | #include <iostream>
using namespace std;
int main() {
int d1[6], d2[6], tmp, cnt, j, a = 1;
for (int i = 0; i < 6; i++) {
cin >> d1[i];
}
for (int i = 0; i < 6; i++) {
cin >> d2[i];
}
cnt = 0;
for (j = 0; j < 6; j++)
if (d1[j] == d2[j])
cnt++;
if (cnt == 6)
a = 0;
while (a) {... | [
"literal.number.change",
"control_flow.loop.condition.change"
] | 138,059 | 138,055 | u658200782 | cpp |
p02385 | //???????????£?¨?
class Dice {
public:
Dice(int top, int front, int right, int left, int back,
int bottom); //?????????????????????(?????°??????)
int get_top();
int get_front();
int get_right();
int get_left();
int get_back();
int get_bottom();
bool roll_topfront(int top, int front);
void roll... | //???????????£?¨?
class Dice {
public:
Dice(int top, int front, int right, int left, int back,
int bottom); //?????????????????????(?????°??????)
int get_top();
int get_front();
int get_right();
int get_left();
int get_back();
int get_bottom();
bool roll_topfront(int top, int front);
void roll... | [
"literal.string.change",
"variable_declaration.value.change"
] | 138,067 | 138,068 | u772369495 | cpp |
p02385 | #include <iostream>
#include <string>
using namespace std;
class dice {
public:
int d[7];
dice() { //??????????????????????????????
}
void east() {
d[0] = d[1], d[1] = d[4], d[4] = d[6], d[6] = d[3], d[3] = d[0];
}
void north() {
d[0] = d[5], d[5] = d[1], d[1] = d[2], d[2] = d[6], d[6] = d[0];
... | #include <iostream>
#include <string>
using namespace std;
class dice {
public:
int d[7];
dice() { //??????????????????????????????
}
void east() {
d[0] = d[1], d[1] = d[4], d[4] = d[6], d[6] = d[3], d[3] = d[0];
}
void north() {
d[0] = d[5], d[5] = d[1], d[1] = d[2], d[2] = d[6], d[6] = d[0];
... | [
"literal.string.change",
"io.output.change"
] | 138,071 | 138,072 | u950835578 | cpp |
p02385 | #include <iostream>
using namespace std;
void moveE(int dice[6]) {
int tmp = dice[0];
dice[0] = dice[3];
dice[3] = dice[5];
dice[5] = dice[2];
dice[2] = tmp;
}
void moveN(int dice[6]) {
int tmp = dice[0];
dice[0] = dice[1];
dice[1] = dice[5];
dice[5] = dice[4];
dice[4] = tmp;
}
void moveS(int dice[6... | #include <iostream>
using namespace std;
void moveE(int dice[6]) {
int tmp = dice[0];
dice[0] = dice[3];
dice[3] = dice[5];
dice[5] = dice[2];
dice[2] = tmp;
}
void moveN(int dice[6]) {
int tmp = dice[0];
dice[0] = dice[1];
dice[1] = dice[5];
dice[5] = dice[4];
dice[4] = tmp;
}
void moveS(int dice[6... | [
"literal.string.change",
"literal.string.case.change",
"io.output.change"
] | 138,073 | 138,074 | u335078377 | cpp |
p02385 | #include <stdio.h>
#include <string.h>
#define rep(i, n) for (int i = 0; i < n; ++i)
class dice {
private:
int f[6];
public:
dice(int *a) {
int i;
rep(i, 6) f[i] = a[i];
}
void n() {
int t;
t = f[0];
f[0] = f[1];
f[1] = f[5];
f[5] = f[4];
f[4] = t;
}
void s() {
int t;
... | #include <stdio.h>
#include <string.h>
#define rep(i, n) for (int i = 0; i < n; ++i)
class dice {
private:
int f[6];
public:
dice(int *a) {
int i;
rep(i, 6) f[i] = a[i];
}
void n() {
int t;
t = f[0];
f[0] = f[1];
f[1] = f[5];
f[5] = f[4];
f[4] = t;
}
void s() {
int t;
... | [
"literal.string.change",
"call.arguments.change",
"control_flow.branch.if.replace.add",
"control_flow.branch.else_if.replace.remove"
] | 138,075 | 138,076 | u428870975 | cpp |
p02385 |
#include <iostream>
#include <string>
using namespace std;
class Dice {
// ----------
// | S[0] |
// | |
// | |
// | |
// --------------------------------------------
// | S[3] | S[1] | S[2] | S[4] ... |
#include <iostream>
#include <string>
using namespace std;
class Dice {
// ----------
// | S[0] |
// | |
// | |
// | |
// --------------------------------------------
// | S[3] | S[1] | S[2] | S[4] ... | [
"literal.string.change",
"io.output.change"
] | 138,090 | 138,091 | u560211345 | cpp |
p02385 | #include <algorithm>
#include <cmath>
#include <iostream>
#include <stdio.h>
#include <string>
using namespace std;
class dice {
public:
int num[6], tmp;
void moveS() {
tmp = num[0];
num[0] = num[4];
num[4] = num[5];
num[5] = num[1];
num[1] = tmp;
}
void moveN() {
tmp = num[0];
num[0... | #include <algorithm>
#include <cmath>
#include <iostream>
#include <stdio.h>
#include <string>
using namespace std;
class dice {
public:
int num[6], tmp;
void moveS() {
tmp = num[0];
num[0] = num[4];
num[4] = num[5];
num[5] = num[1];
num[1] = tmp;
}
void moveN() {
tmp = num[0];
num[0... | [
"literal.number.change",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change",
"call.function.change"
] | 138,336 | 138,337 | u333223739 | cpp |
p02386 | #include <iostream>
using namespace std;
#define check \
cnt = 0; \
for (j = 0; j < 6; j++) \
if (d[q][j] == d[r][j]) ... | #include <iostream>
using namespace std;
#define check \
cnt = 0; \
for (j = 0; j < 6; j++) \
if (d[q][j] == d[r][j]) ... | [
"control_flow.branch.else.remove"
] | 138,339 | 138,340 | u658200782 | cpp |
p02386 | #include <iostream>
using namespace std;
class Cube {
public:
int f[6];
Cube() {}
void roll_z() { roll(1, 2, 3, 4); }
void roll_y() { roll(0, 2, 5, 3); }
void roll_x() { roll(0, 1, 5, 4); }
void roll(int i, int j, int k, int l) {
int t = f[i];
f[i] = f[j];
f[j] = f[k];
f[k] = f[l];
f[l]... | #include <iostream>
using namespace std;
class Cube {
public:
int f[6];
Cube() {}
void roll_z() { roll(1, 2, 4, 3); }
void roll_y() { roll(0, 2, 5, 3); }
void roll_x() { roll(0, 1, 5, 4); }
void roll(int i, int j, int k, int l) {
int t = f[i];
f[i] = f[j];
f[j] = f[k];
f[k] = f[l];
f[l]... | [
"call.arguments.change",
"call.arguments.add"
] | 138,341 | 138,342 | u001068672 | cpp |
p02386 | //???????????£?¨?
class Dice {
public:
Dice(int top, int front, int right, int left, int back,
int bottom); //?????????????????????(?????°??????)
int get_top();
int get_front();
int get_right();
int get_left();
int get_back();
int get_bottom();
bool roll_topfront(int top, int front);
void roll... | //???????????£?¨?
class Dice {
public:
Dice(int top, int front, int right, int left, int back,
int bottom); //?????????????????????(?????°??????)
int get_top();
int get_front();
int get_right();
int get_left();
int get_back();
int get_bottom();
bool roll_topfront(int top, int front);
void roll... | [
"literal.string.change",
"io.output.change"
] | 138,344 | 138,345 | u772369495 | cpp |
p02386 | #include <cstdio>
using namespace std;
class Dice {
public:
int face[6];
Dice() {}
int roll(int a, int b, int c, int d) {
int temp = face[a];
face[a] = face[b];
face[b] = face[c];
face[c] = face[d];
face[d] = temp;
return 0;
}
int move(char c) {
if (c == 'W')
roll(0, 2, 5, 3... | #include <cstdio>
using namespace std;
class Dice {
public:
int face[6];
Dice() {}
int roll(int a, int b, int c, int d) {
int temp = face[a];
face[a] = face[b];
face[b] = face[c];
face[c] = face[d];
face[d] = temp;
return 0;
}
int move(char c) {
if (c == 'W')
roll(0, 2, 5, 3... | [
"identifier.replace.add",
"literal.replace.remove",
"control_flow.loop.for.initializer.change"
] | 138,346 | 138,347 | u721279180 | cpp |
p02386 | #include <iostream>
using namespace std;
struct dice {
int x[6];
void roll(char c) {
int tmp;
if (c == 'E') {
tmp = x[0];
x[0] = x[3];
x[3] = x[5];
x[5] = x[2];
x[2] = tmp;
}
if (c == 'N') {
tmp = x[0];
x[0] = x[1];
x[1] = x[5];
x[5] = x[4];
... | #include <iostream>
using namespace std;
struct dice {
int x[6];
void roll(char c) {
int tmp;
if (c == 'E') {
tmp = x[0];
x[0] = x[3];
x[3] = x[5];
x[5] = x[2];
x[2] = tmp;
}
if (c == 'N') {
tmp = x[0];
x[0] = x[1];
x[1] = x[5];
x[5] = x[4];
... | [
"identifier.change",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change"
] | 138,372 | 138,370 | u796103607 | cpp |
p02376 | #include <bits/stdc++.h>
using namespace std;
const int INF = 1e9 + 1;
const int MAX_V = 575;
// O(|E||V|^2)
struct Edge {
Edge(int _to, int _cap, int _rev) : to(_to), cap(_cap), rev(_rev) {}
int to;
int cap; // 容量
int rev; // 逆辺
};
vector<Edge> G[MAX_V]; // グラフの隣接リスト表現
int level[MAX_V]; // sからの距離
int it... | #include <bits/stdc++.h>
using namespace std;
const int INF = 1e9 + 1;
const int MAX_V = 575;
// O(|E||V|^2)
struct Edge {
Edge(int _to, int _cap, int _rev) : to(_to), cap(_cap), rev(_rev) {}
int to;
int cap; // 容量
int rev; // 逆辺
};
vector<Edge> G[MAX_V]; // グラフの隣接リスト表現
int level[MAX_V]; // sからの距離
int it... | [
"assignment.value.change",
"expression.operation.unary.arithmetic.remove"
] | 138,405 | 138,406 | u437626158 | cpp |
p02376 |
#include <algorithm>
#include <bitset>
#include <cctype>
#include <cmath>
#include <complex>
#include <cstdint>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <deque>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#include <list>
#include <map>
#inclu... | #include <algorithm>
#include <bitset>
#include <cctype>
#include <cmath>
#include <complex>
#include <cstdint>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <deque>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#include <list>
#include <map>
#includ... | [
"literal.number.change",
"variable_declaration.value.change"
] | 138,409 | 138,410 | u864932042 | cpp |
p02376 |
#include <algorithm>
#include <bitset>
#include <cctype>
#include <cmath>
#include <complex>
#include <cstdint>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <deque>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#include <list>
#include <map>
#inclu... |
#include <algorithm>
#include <bitset>
#include <cctype>
#include <cmath>
#include <complex>
#include <cstdint>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <deque>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#include <list>
#include <map>
#inclu... | [
"literal.number.change",
"variable_declaration.value.change"
] | 138,411 | 138,412 | u864932042 | cpp |
p02376 | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
struct edge {
int to, cap, rev;
};
int V, E, used[109];
vector<edge> G[109];
void add_edge(int v1, int v2, int cap) {
G[v1].push_back(edge{v2, cap, (int)G[v2].size()});
G[v2].push_back(edge{v1, cap, (int)G[v1].size() - 1});
}
int rec(... | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
struct edge {
int to, cap, rev;
};
int V, E, used[109];
vector<edge> G[109];
void add_edge(int v1, int v2, int cap) {
G[v1].push_back(edge{v2, cap, (int)G[v2].size()});
G[v2].push_back(edge{v1, 0, (int)G[v1].size() - 1});
}
int rec(in... | [
"identifier.replace.remove",
"literal.replace.add",
"call.arguments.change",
"expression.operator.compare.change",
"control_flow.branch.if.condition.change"
] | 138,452 | 138,451 | u823513038 | cpp |
p02376 | #include <algorithm>
#include <iostream>
#include <vector>
#define rep(i, n) for (int i = 0; i < (n); i++)
using namespace std;
typedef pair<int, int> pii;
const int INF = 0x3fffffff;
class Flow {
public:
int N;
vector<vector<int>> F, C, edge;
Flow(int n, int e)
: F(n, vector<int>(n)), C(n, vector<int>(... | #include <algorithm>
#include <iostream>
#include <vector>
#define rep(i, n) for (int i = 0; i < (n); i++)
using namespace std;
typedef pair<int, int> pii;
const int INF = 0x3fffffff;
class Flow {
public:
int N;
vector<vector<int>> F, C, edge;
Flow(int n, int e)
: F(n, vector<int>(n)), C(n, vector<int>(... | [
"identifier.change",
"call.arguments.change"
] | 138,461 | 138,462 | u265137214 | cpp |
p02376 | #include <algorithm>
#include <queue>
#include <stdio.h>
#include <vector>
using namespace std;
const int D_MAX_V = 10000;
struct D_wolf {
int t, c, r;
D_wolf() {}
D_wolf(int t1, int c1, int r1) {
t = t1;
c = c1;
r = r1;
}
};
vector<D_wolf> D_G[D_MAX_V];
int D_level[D_MAX_V];
int D_iter[D_MAX_V];
vo... | #include <algorithm>
#include <queue>
#include <stdio.h>
#include <vector>
using namespace std;
const int D_MAX_V = 10000;
struct D_wolf {
int t, c, r;
D_wolf() {}
D_wolf(int t1, int c1, int r1) {
t = t1;
c = c1;
r = r1;
}
};
vector<D_wolf> D_G[D_MAX_V];
int D_level[D_MAX_V];
int D_iter[D_MAX_V];
vo... | [
"assignment.variable.change",
"variable_access.subscript.index.change"
] | 138,463 | 138,464 | u676399799 | cpp |
p02376 | #include <algorithm>
#include <iostream>
#include <vector>
#define REP(i, n) for (int i = 0; i < (n); i++)
using namespace std;
const int INF = 1e9;
struct edge {
int to, cap, rev;
edge(int to, int cap, int rev) : to(to), cap(cap), rev(rev) {}
};
int v, e;
vector<vector<edge>> G; //??°???????????£??\???????????¨... | #include <algorithm>
#include <iostream>
#include <vector>
#define REP(i, n) for (int i = 0; i < (n); i++)
using namespace std;
const int INF = 1e9;
struct edge {
int to, cap, rev;
edge(int to, int cap, int rev) : to(to), cap(cap), rev(rev) {}
};
int v, e;
vector<vector<edge>> G; //??°???????????£??\???????????¨... | [
"literal.number.change",
"variable_declaration.array_dimensions.change",
"identifier.change",
"call.arguments.change"
] | 138,479 | 138,480 | u651717359 | cpp |
p02376 | #include <algorithm>
#include <iostream>
#include <vector>
#define REP(i, n) for (int i = 0; i < (n); i++)
using namespace std;
const int INF = 1e9;
struct edge {
int to, cap, rev;
edge(int to, int cap, int rev) : to(to), cap(cap), rev(rev) {}
};
int v, e;
vector<vector<edge>> G; //??°???????????£??\???????????¨... | #include <algorithm>
#include <iostream>
#include <vector>
#define REP(i, n) for (int i = 0; i < (n); i++)
using namespace std;
const int INF = 1e9;
struct edge {
int to, cap, rev;
edge(int to, int cap, int rev) : to(to), cap(cap), rev(rev) {}
};
int v, e;
vector<vector<edge>> G; //??°???????????£??\???????????¨... | [
"identifier.change",
"call.arguments.change"
] | 138,481 | 138,480 | u651717359 | cpp |
p02376 | // clang-format off
#include <bits/stdc++.h>
#define int long long
#define main signed main()
#define loop(i, a, n) for (int i = (a); i < (n); i++)
#define rep(i, n) loop(i, 0, n)
#define forever for (;;)
#define all(v) (v).begin(), (v).end()
#define rall(v) (v).rbegin(), (v).rend()
#define prec(n) fixed << setprecisio... | // clang-format off
#include <bits/stdc++.h>
#define int long long
#define main signed main()
#define loop(i, a, n) for (int i = (a); i < (n); i++)
#define rep(i, n) loop(i, 0, n)
#define forever for (;;)
#define all(v) (v).begin(), (v).end()
#define rall(v) (v).rbegin(), (v).rend()
#define prec(n) fixed << setprecisio... | [
"control_flow.loop.for.condition.change"
] | 138,506 | 138,507 | u449960815 | cpp |
p02376 | #include <bits/stdc++.h>
using namespace std;
#define INF 1000000007
#define MAX_V 1000
struct edge {
int to, cap, rev;
};
vector<edge> G[MAX_V];
bool used[MAX_V];
void add_edge(int from, int to, int cap) {
G[from].push_back((edge){to, cap, G[to].size()});
G[to].push_back((edge){from, 0, G[from].size() - 1});
}... | #include <bits/stdc++.h>
using namespace std;
#define INF 1000000007
#define MAX_V 1000
struct edge {
int to, cap, rev;
};
vector<edge> G[MAX_V];
bool used[MAX_V];
void add_edge(int from, int to, int cap) {
G[from].push_back((edge){to, cap, G[to].size()});
G[to].push_back((edge){from, 0, G[from].size() - 1});
}... | [
"expression.operation.unary.add",
"control_flow.branch.if.condition.change"
] | 138,513 | 138,514 | u278641778 | cpp |
p02376 | #include <algorithm>
#include <list>
#include <stdio.h>
#include <vector>
using namespace std;
typedef vector<int> VInt;
typedef vector<VInt> VVInt;
typedef list<int> LInt;
typedef vector<LInt> VLInt;
typedef LInt::iterator LIter;
typedef vector<LIter> VLIter;
// Input: the network
int n, src, dest;
VVInt c;
// Out... | #include <algorithm>
#include <list>
#include <stdio.h>
#include <vector>
using namespace std;
typedef vector<int> VInt;
typedef vector<VInt> VVInt;
typedef list<int> LInt;
typedef vector<LInt> VLInt;
typedef LInt::iterator LIter;
typedef vector<LIter> VLIter;
// Input: the network
int n, src, dest;
VVInt c;
// Out... | [
"literal.string.change",
"call.arguments.change"
] | 138,522 | 138,523 | u057373096 | cpp |
p02376 | #include <algorithm>
#include <fstream>
#include <iostream>
#include <list>
#include <vector>
using namespace std;
void lift(int u, vector<int> &e, vector<list<int>> &nei, vector<vector<int>> &c,
vector<vector<int>> &f, vector<int> &h, int n) {
int height = 2 * n;
for (auto it = nei[u].begin(); it != nei... | #include <algorithm>
#include <fstream>
#include <iostream>
#include <list>
#include <vector>
using namespace std;
void lift(int u, vector<int> &e, vector<list<int>> &nei, vector<vector<int>> &c,
vector<vector<int>> &f, vector<int> &h, int n) {
int height = 2 * n;
for (auto it = nei[u].begin(); it != nei... | [
"identifier.change",
"expression.operation.binary.change",
"io.output.newline.add"
] | 138,524 | 138,525 | u057373096 | cpp |
p02376 | /* Дан неориентированный связный граф.
* Требуется найти вес минимального остовного дерева в этом графе с помощью
* алгоритма Борувки.*/
// T(N, M) = O(|E|log|V|)
// M(N, M) = O(|V| + |E|)
#include <bits/stdc++.h>
using namespace std;
const int INF = 2000000000; // константа, отвечающая за "бесконечность".
typedef u... | /* Дан неориентированный связный граф.
* Требуется найти вес минимального остовного дерева в этом графе с помощью
* алгоритма Борувки.*/
// T(N, M) = O(|E|log|V|)
// M(N, M) = O(|V| + |E|)
#include <bits/stdc++.h>
using namespace std;
const int INF = 2000000000; // константа, отвечающая за "бесконечность".
typedef u... | [
"expression.operation.binary.remove"
] | 138,527 | 138,528 | u811445781 | cpp |
p02386 | #include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
const static int NUM_S = 6;
int a[NUM_S];
Dice(void) {}
void set(int _a[]) {
a[0] = _a[0];
a[1] = _a[1];
a[2] = _a[2];
a[3] = _a[3];
a[4] = _a[4];
a[5] = _a[5];
}
bool isEqual(Dice &o) {
return ... | #include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
const static int NUM_S = 6;
int a[NUM_S];
Dice(void) {}
void set(int _a[]) {
a[0] = _a[0];
a[1] = _a[1];
a[2] = _a[2];
a[3] = _a[3];
a[4] = _a[4];
a[5] = _a[5];
}
bool isEqual(Dice &o) {
return ... | [
"identifier.replace.add",
"literal.replace.remove",
"control_flow.loop.for.initializer.change"
] | 139,013 | 139,014 | u404591357 | cpp |
p02386 | #include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
int dice[6];
void move(char c) {
int tmp;
switch (c) {
case ('S'):
tmp = dice[5];
dice[5] = dice[1];
dice[1] = dice[0];
dice[0] = dice[4];
dice[4] = tmp;
break;
case ('N'):
tm... | #include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
int dice[6];
void move(char c) {
int tmp;
switch (c) {
case ('S'):
tmp = dice[5];
dice[5] = dice[1];
dice[1] = dice[0];
dice[0] = dice[4];
dice[4] = tmp;
break;
case ('N'):
tm... | [
"control_flow.loop.for.initializer.change"
] | 139,025 | 139,026 | u539796523 | cpp |
p02386 | #include <iostream>
#include <vector>
using namespace std;
// http://www.prefield.com/algorithm/misc/dice.html
enum FACE { TOP, BOTTOM, FRONT, BACK, LEFT, RIGHT };
class dice {
public:
dice() {
id[TOP] = 1;
id[FRONT] = 2;
id[LEFT] = 3;
id[RIGHT] = 4;
id[BACK] = 5;
id[BOTTOM] = 6;
}
dice(i... | #include <iostream>
#include <vector>
using namespace std;
// http://www.prefield.com/algorithm/misc/dice.html
enum FACE { TOP, BOTTOM, FRONT, BACK, LEFT, RIGHT };
class dice {
public:
dice() {
id[TOP] = 1;
id[FRONT] = 2;
id[LEFT] = 3;
id[RIGHT] = 4;
id[BACK] = 5;
id[BOTTOM] = 6;
}
dice(i... | [
"identifier.change",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change",
"literal.string.change",
"io.output.change"
] | 139,027 | 139,028 | u300645821 | cpp |
p02386 | #include <iostream>
#include <vector>
using namespace std;
// http://www.prefield.com/algorithm/misc/dice.html
enum FACE { TOP, BOTTOM, FRONT, BACK, LEFT, RIGHT };
class dice {
public:
dice() {
id[TOP] = 1;
id[FRONT] = 2;
id[LEFT] = 3;
id[RIGHT] = 4;
id[BACK] = 5;
id[BOTTOM] = 6;
}
dice(i... | #include <iostream>
#include <vector>
using namespace std;
// http://www.prefield.com/algorithm/misc/dice.html
enum FACE { TOP, BOTTOM, FRONT, BACK, LEFT, RIGHT };
class dice {
public:
dice() {
id[TOP] = 1;
id[FRONT] = 2;
id[LEFT] = 3;
id[RIGHT] = 4;
id[BACK] = 5;
id[BOTTOM] = 6;
}
dice(i... | [
"literal.string.change",
"io.output.change"
] | 139,029 | 139,028 | u300645821 | cpp |
p02386 | #include <iostream>
#include <sstream>
using namespace std;
class Dice {
public:
static int rollingface[][4];
static int sideface[][4];
int face[6];
Dice(string &face_data);
// ~Dice();
void roll(const char &op);
int top();
int front_face(int top, int right);
void print_faces();
bool operator==(co... | #include <iostream>
#include <sstream>
using namespace std;
class Dice {
public:
static int rollingface[][4];
static int sideface[][4];
int face[6];
Dice(string &face_data);
// ~Dice();
void roll(const char &op);
int top();
int front_face(int top, int right);
void print_faces();
bool operator==(co... | [] | 139,030 | 139,031 | u813270418 | cpp |
p02386 | #include <stdio.h>
int main() {
int vector[3][4] = {{0, 2, 5, 3}, {0, 1, 5, 4}, {1, 2, 4, 3}};
int ii, i, j, k, l, m, n, c, cc = 0;
scanf("%d", &n);
int dice[2][6];
for (i = 0; i < n; i++) {
for (j = 0; j < 6; j++) {
scanf("%d", &dice[i][j]);
}
}
// for(i=0;i<n;i++)printf("dice[%d] : %d %d %... | #include <stdio.h>
int main() {
int vector[3][4] = {{0, 2, 5, 3}, {0, 1, 5, 4}, {1, 2, 4, 3}};
int ii, i, j, k, l, m, n, c, cc = 0;
scanf("%d", &n);
int dice[n][6];
for (i = 0; i < n; i++) {
for (j = 0; j < 6; j++) {
scanf("%d", &dice[i][j]);
}
}
// for(i=0;i<n;i++)printf("dice[%d] : %d %d %... | [
"identifier.replace.add",
"literal.replace.remove",
"variable_declaration.array_dimensions.change"
] | 139,039 | 139,040 | u290226505 | cpp |
p02386 | #include <iostream>
using namespace std;
class Dice {
public:
static const int SURFACE_NUM = 6; // ?????????????????¢??°
static const int DIR_NUM = 4; // ?????¢?????????????????°
static const int ROUND_NUM = 4; // ?????¢????????¢?????°
enum DIR { N, W, S, E }; // ?????¢??????
private:
static ... | #include <iostream>
using namespace std;
class Dice {
public:
static const int SURFACE_NUM = 6; // ?????????????????¢??°
static const int DIR_NUM = 4; // ?????¢?????????????????°
static const int ROUND_NUM = 4; // ?????¢????????¢?????°
enum DIR { N, W, S, E }; // ?????¢??????
private:
static ... | [] | 139,049 | 139,050 | u973694800 | cpp |
p02386 | #include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long r[6];
Dice(){};
void roll(long a, long b, long c, long d) {
swap(r[a], r[b]);
swap(r[b], r[c]);
swap(r[c], r[d]);
}
void spinW() { roll(0, 2, 5, 3); }
void spinN() { roll(0, 1, 5, 4); }
};
int main() {
int a... | #include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long r[6];
Dice(){};
void roll(long a, long b, long c, long d) {
swap(r[a], r[b]);
swap(r[b], r[c]);
swap(r[c], r[d]);
}
void spinW() { roll(0, 2, 5, 3); }
void spinN() { roll(0, 1, 5, 4); }
};
int main() {
int a... | [
"control_flow.loop.for.condition.change",
"misc.off_by_one",
"expression.operator.compare.change",
"expression.off_by_one",
"expression.operation.binary.change"
] | 139,051 | 139,052 | u564420347 | cpp |
p02386 | #include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long r[6];
Dice(){};
void roll(long a, long b, long c, long d) {
swap(r[a], r[b]);
swap(r[b], r[c]);
swap(r[c], r[d]);
}
void spinW() { roll(0, 2, 5, 3); }
void spinN() { roll(0, 1, 5, 4); }
};
int main() {
int a... | #include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long r[6];
Dice(){};
void roll(long a, long b, long c, long d) {
swap(r[a], r[b]);
swap(r[b], r[c]);
swap(r[c], r[d]);
}
void spinW() { roll(0, 2, 5, 3); }
void spinN() { roll(0, 1, 5, 4); }
};
int main() {
bool ... | [
"variable_declaration.type.primitive.change",
"control_flow.loop.for.condition.change",
"misc.off_by_one",
"expression.operator.compare.change",
"expression.off_by_one",
"expression.operation.binary.change"
] | 139,051 | 139,053 | u564420347 | cpp |
p02386 | #include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long r[6];
Dice(){};
void roll(long a, long b, long c, long d) {
swap(r[a], r[b]);
swap(r[b], r[c]);
swap(r[c], r[d]);
}
void spinW() { roll(0, 2, 5, 3); }
void spinN() { roll(0, 1, 5, 4); }
};
int main() {
int a... | #include <iostream>
#include <vector>
using namespace std;
class Dice {
public:
long r[6];
Dice(){};
void roll(long a, long b, long c, long d) {
swap(r[a], r[b]);
swap(r[b], r[c]);
swap(r[c], r[d]);
}
void spinW() { roll(0, 2, 5, 3); }
void spinN() { roll(0, 1, 5, 4); }
};
int main() {
bool ... | [
"variable_declaration.type.primitive.change",
"control_flow.loop.for.condition.change",
"misc.off_by_one",
"expression.operator.compare.change",
"expression.off_by_one",
"expression.operation.binary.change"
] | 139,051 | 139,054 | u564420347 | cpp |
p02386 | #include <iostream>
#include <map>
#include <vector>
using namespace std;
class Dice {
private:
public:
vector<int> d;
void spin(string s) {
if (s == "S") {
swap(d[0], d[4]);
swap(d[4], d[1]);
swap(d[4], d[5]);
}
if (s == "E") {
swap(d[0], d[3]);
swap(d[2], d[3]);
sw... | #include <iostream>
#include <map>
#include <vector>
using namespace std;
class Dice {
private:
public:
vector<int> d;
void spin(string s) {
if (s == "S") {
swap(d[0], d[4]);
swap(d[4], d[1]);
swap(d[4], d[5]);
}
if (s == "E") {
swap(d[0], d[3]);
swap(d[2], d[3]);
sw... | [
"expression.operation.unary.add",
"control_flow.branch.if.condition.change"
] | 139,055 | 139,056 | u630224637 | cpp |
p02386 | #include <iostream>
#include <string>
#include <vector>
using namespace std;
vector<int> x[100];
int n, t;
bool same(vector<int> a, vector<int> b) {
for (int i = 0; i < 4; i++) {
for (int j = 0; j < 4; j++) {
for (int k = 0; k < 4; k++) {
for (int l = 0; l < 4; l++) {
string s;
f... | #include <iostream>
#include <string>
#include <vector>
using namespace std;
vector<int> x[100];
int n, t;
bool same(vector<int> a, vector<int> b) {
for (int i = 0; i < 4; i++) {
for (int j = 0; j < 4; j++) {
for (int k = 0; k < 4; k++) {
for (int l = 0; l < 4; l++) {
string s;
f... | [
"expression.operation.unary.logical.remove",
"control_flow.branch.if.condition.change"
] | 139,057 | 139,058 | u823513038 | cpp |
p02386 | #include <iostream>
const int N = 7;
const int DICE_COUNT = 100;
const int ROTATION_MAX = 4;
const int ROTATION_KIND = 3;
const int ROTATION_PATTERN_COUNT = ROTATION_MAX * ROTATION_MAX * ROTATION_MAX;
const int ROTATION_X = 0;
const int ROTATION_Y = 1;
const int ROTATION_Z = 2;
const int ROTATION_MAP[3][N] = {
... | #include <iostream>
const int N = 7;
const int DICE_COUNT = 100;
const int ROTATION_MAX = 4;
const int ROTATION_KIND = 3;
const int ROTATION_PATTERN_COUNT = ROTATION_MAX * ROTATION_MAX * ROTATION_MAX;
const int ROTATION_X = 0;
const int ROTATION_Y = 1;
const int ROTATION_Z = 2;
const int ROTATION_MAP[3][N] = {
... | [
"expression.operation.unary.add",
"control_flow.branch.if.condition.change"
] | 139,059 | 139,060 | u212165333 | cpp |
p02386 | /*#include <iostream>
using namespace std;
class Dice{
public:
int num[6],t;//t=top
void North(){
/*
dice.num[0] = ???
dice.num[1] = ???
dice.num[2] = ???
dice.num[3] = ???
dice.num[4] = ???
d... | /*#include <iostream>
using namespace std;
class Dice{
public:
int num[6],t;//t=top
void North(){
/*
dice.num[0] = ???
dice.num[1] = ???
dice.num[2] = ???
dice.num[3] = ???
dice.num[4] = ???
d... | [] | 139,061 | 139,062 | u890344471 | cpp |
p02386 | /*#include <iostream>
using namespace std;
class Dice{
public:
int num[6],t;//t=top
void North(){
/*
dice.num[0] = ???
dice.num[1] = ???
dice.num[2] = ???
dice.num[3] = ???
dice.num[4] = ???
d... | /*#include <iostream>
using namespace std;
class Dice{
public:
int num[6],t;//t=top
void North(){
/*
dice.num[0] = ???
dice.num[1] = ???
dice.num[2] = ???
dice.num[3] = ???
dice.num[4] = ???
d... | [
"control_flow.loop.for.condition.change",
"expression.operation.binary.remove",
"control_flow.branch.if.condition.change"
] | 139,063 | 139,062 | u890344471 | cpp |
p02386 | #include <iostream>
#include <string>
using namespace std;
class Dice {
public:
int num[6], t; // t=top
void North() {
/*
dice.num[0] = ???
dice.num[1] = ???
dice.num[2] = ???
dice.num[3] = ???
dice.num[4] = ???
dice.num[5] = ???*/
t = num[0];
num[0] = num[1]; //??????1?????¨??... | #include <iostream>
using namespace std;
class Dice {
public:
int num[6], t; // t=top
void North() {
/*
dice.num[0] = ???
dice.num[1] = ???
dice.num[2] = ???
dice.num[3] = ???
dice.num[4] = ???
dice.num[5] = ???*/
t = num[0];
num[0] = num[1]; //??????1?????¨???
num[1] = num[... | [] | 139,064 | 139,065 | u890344471 | cpp |
p02386 | #include <iostream>
using namespace std;
class Dice {
public:
int num[6], t; // t=top
void North() {
/*
dice.num[0] = ???
dice.num[1] = ???
dice.num[2] = ???
dice.num[3] = ???
dice.num[4] = ???
dice.num[5] = ???*/
t = num[0];
num[0] = num[1]; //??????1?????¨???
num[1] = num[... | #include <iostream>
using namespace std;
class Dice {
public:
int num[6], t; // t=top
void North() {
/*
dice.num[0] = ???
dice.num[1] = ???
dice.num[2] = ???
dice.num[3] = ???
dice.num[4] = ???
dice.num[5] = ???*/
t = num[0];
num[0] = num[1]; //??????1?????¨???
num[1] = num[... | [] | 139,066 | 139,065 | u890344471 | cpp |
p02386 | #include <cstdio>
#include <iostream>
using namespace std;
class Dice {
public:
int face[6];
Dice() {}
Dice(int face1, int face2, int face3, int face4, int face5, int face6) {
face[0] = face1;
face[1] = face2;
face[2] = face3;
face[3] = face4;
face[4] = face5;
face[5] = face6;
}
vo... | #include <cstdio>
#include <iostream>
using namespace std;
class Dice {
public:
int face[6];
Dice() {}
Dice(int face1, int face2, int face3, int face4, int face5, int face6) {
face[0] = face1;
face[1] = face2;
face[2] = face3;
face[3] = face4;
face[4] = face5;
face[5] = face6;
}
vo... | [
"literal.string.change",
"io.output.change"
] | 139,068 | 139,069 | u612243550 | cpp |
p02388 | #include <iostream>
using namespace std;
int main() {
int x;
cin >> x;
cout << x * x << endl;
return 0;
}
| #include <iostream>
using namespace std;
int main() {
int x;
cin >> x;
cout << x * x * x << endl;
return 0;
}
| [
"expression.operation.binary.add"
] | 141,539 | 141,538 | u299382464 | cpp |
p02388 | #include <iostream>
using namespace std;
int main() {
int x, x3;
cin >> x;
x3 = x ^ 3;
cout << x3 << endl;
return 0;
}
| #include <iostream>
using namespace std;
int main() {
int x, x3;
cin >> x;
x3 = x * x * x;
cout << x3 << endl;
return 0;
}
| [
"assignment.change"
] | 141,543 | 141,544 | u829576116 | cpp |
p02388 | #include <iostream>
using namespace std;
int main() {
int x;
int sanjo;
cin >> x;
sanjo = x * x * x;
cout << "sanjo\n" << endl;
return 0;
}
| #include <iostream>
using namespace std;
int main() {
int x;
int sanjo;
cin >> x;
sanjo = x * x * x;
cout << sanjo << endl;
return 0;
}
| [
"io.output.change"
] | 141,547 | 141,548 | u053643559 | cpp |
p02388 | #include <iostream>
using namespace std;
int main() {
int x;
int sanjo;
cin >> x;
sanjo = x * x * x;
cout << "sanjo\n" << endl;
return 0;
}
| #include <iostream>
using namespace std;
int main() {
int x;
int sanjo;
cin >> x;
sanjo = x * x * x;
cout << sanjo << endl;
return 0;
}
| [
"io.output.change"
] | 141,547 | 141,550 | u053643559 | cpp |
p02388 | #include <iostream>
using namespace std;
int main() {
int x;
int sanjo;
cin >> x;
sanjo = x * x * x;
cout << "sanjo\n" << endl;
return 0;
}
| #include <iostream>
using namespace std;
int main() {
int x, sanjo;
cin >> x;
sanjo = x * x * x;
cout << sanjo << endl;
return 0;
}
| [
"io.output.change"
] | 141,547 | 141,551 | u053643559 | cpp |
p02388 | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
int main() {
vector<vector<int>> vec(100, vector<int>(100, 0));
cin >> vec.at(99).at(99);
int num = vec.at(99).at(99);
cout << pow(num, 3) << endl;
}
| #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
int main() {
vector<vector<int>> vec(100, vector<int>(100, 0));
cin >> vec.at(99).at(99);
int num = vec.at(99).at(99);
cout << num * num * num << endl;
}
| [
"call.remove"
] | 141,552 | 141,553 | u650022417 | cpp |
p02388 | #include <stdio.h>
int main(void) {
int a;
scanf("%d", &a);
printf("%d\n", a);
return (0);
}
| #include <stdio.h>
int main(void) {
int a;
scanf("%d", &a);
printf("%d\n", a * a * a);
return (0);
}
| [
"expression.operation.binary.add"
] | 141,560 | 141,561 | u241862429 | cpp |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.