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 9 values |
|---|---|---|---|---|---|---|---|
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double s = 1.0;
if (W / 2 != x || H / 2 != y) {
cout << W * H * s / 2 << " " << 0 << endl;
}
else {
cout << W * H * s / 2 << " " << 1 << endl;
}
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
long long W, H, x, y;
cin >> W >> H >> x >> y;
double s = 1.0;
if (W * s / 2 != x || H * s / 2 != y) {
cout << W * H * s / 2 << " " << 0 << endl;
}
else {
cout << W * H * s / 2 << " " << 1 << endl;
}
}
| [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change",
"control_flow.branch.if.condition.change"
] | 815,090 | 815,091 | u187013893 | cpp |
p03001 | #include <algorithm>
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <string>
#define FOR(i, a, b) for (int i = (a); i < (b); i++)
#define SORT(v, n) sort(v, v + n)
#define rep(i, n) FOR(i, 0, n)
#define EPS (1e-7)
#define INF (1e9)
using namespace std;
typedef long long int ll;
typedef vector<int> VI;
typedef vector<ll> VL;
typedef pair<int, int> PI;
typedef pair<ll, ll> PL;
typedef priority_queue<int> PQI;
typedef priority_queue<int, vector<int>, greater<int>> PQSI;
typedef priority_queue<ll> PQL;
typedef priority_queue<ll, vector<ll>, greater<ll>> PQSL;
const int MOD = 1000000007;
struct mint {
int n;
mint(int n_ = 0) : n(n_) {}
};
mint operator-(mint a) { return -a.n + MOD * (a.n != 0); }
mint operator+(mint a, mint b) {
int x = a.n + b.n;
return x - (x >= MOD) * MOD;
}
mint operator-(mint a, mint b) {
int x = a.n - b.n;
return x + (x < 0) * MOD;
}
mint operator*(mint a, mint b) { return (long long)a.n * b.n % MOD; }
mint &operator+=(mint &a, mint b) { return a = a + b; }
mint &operator-=(mint &a, mint b) { return a = a - b; }
mint &operator*=(mint &a, mint b) { return a = a * b; }
istream &operator>>(istream &i, mint &a) { return i >> a.n; }
ostream &operator<<(ostream &o, mint a) { return o << a.n; }
vector<mint> F_{1, 1}, R_{1, 1}, I_{0, 1};
void check_fact(int n) {
for (int i = I_.size(); i <= n; i++) {
I_.push_back(I_[MOD % i] * (MOD - MOD / i));
F_.push_back(F_[i - 1] * i);
R_.push_back(R_[i - 1] * I_[i]);
}
}
mint I(int n) {
check_fact(abs(n));
return n >= 0 ? I_[n] : -I_[n];
}
mint F(int n) {
check_fact(n);
return n < 0 ? 0 : F_[n];
}
mint R(int n) {
check_fact(n);
return n < 0 ? 0 : R_[n];
}
mint C(int n, int r) { return F(n) * R(n - r) * R(r); }
mint P(int n, int r) { return F(n) * R(n - r); }
mint H(int n, int r) { return n == 0 ? (r == 0) : C(n + r - 1, r); }
template <typename T> T gcd(T x, T y) {
if (y == 0)
return x;
else
return gcd(y, x % y);
}
template <typename T> T lcm(T x, T y) { return (x / gcd(x, y)) * y; }
template <typename T> T ceil(T x, T y) { return (x + (y - 1)) / y; }
int W1, H1, x, y;
int main(void) {
cin >> W1 >> H1 >> x >> y;
cout << W1 * H1 / 2 << " ";
if (abs(x - W1 / 2.0) < EPS and abs(y - H1 / 2.0) < EPS)
cout << 1 << endl;
else
cout << 0 << endl;
return 0;
}
| #include <algorithm>
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <string>
#define FOR(i, a, b) for (int i = (a); i < (b); i++)
#define SORT(v, n) sort(v, v + n)
#define rep(i, n) FOR(i, 0, n)
#define EPS (1e-7)
#define INF (1e9)
using namespace std;
typedef long long int ll;
typedef vector<int> VI;
typedef vector<ll> VL;
typedef pair<int, int> PI;
typedef pair<ll, ll> PL;
typedef priority_queue<int> PQI;
typedef priority_queue<int, vector<int>, greater<int>> PQSI;
typedef priority_queue<ll> PQL;
typedef priority_queue<ll, vector<ll>, greater<ll>> PQSL;
const int MOD = 1000000007;
struct mint {
int n;
mint(int n_ = 0) : n(n_) {}
};
mint operator-(mint a) { return -a.n + MOD * (a.n != 0); }
mint operator+(mint a, mint b) {
int x = a.n + b.n;
return x - (x >= MOD) * MOD;
}
mint operator-(mint a, mint b) {
int x = a.n - b.n;
return x + (x < 0) * MOD;
}
mint operator*(mint a, mint b) { return (long long)a.n * b.n % MOD; }
mint &operator+=(mint &a, mint b) { return a = a + b; }
mint &operator-=(mint &a, mint b) { return a = a - b; }
mint &operator*=(mint &a, mint b) { return a = a * b; }
istream &operator>>(istream &i, mint &a) { return i >> a.n; }
ostream &operator<<(ostream &o, mint a) { return o << a.n; }
vector<mint> F_{1, 1}, R_{1, 1}, I_{0, 1};
void check_fact(int n) {
for (int i = I_.size(); i <= n; i++) {
I_.push_back(I_[MOD % i] * (MOD - MOD / i));
F_.push_back(F_[i - 1] * i);
R_.push_back(R_[i - 1] * I_[i]);
}
}
mint I(int n) {
check_fact(abs(n));
return n >= 0 ? I_[n] : -I_[n];
}
mint F(int n) {
check_fact(n);
return n < 0 ? 0 : F_[n];
}
mint R(int n) {
check_fact(n);
return n < 0 ? 0 : R_[n];
}
mint C(int n, int r) { return F(n) * R(n - r) * R(r); }
mint P(int n, int r) { return F(n) * R(n - r); }
mint H(int n, int r) { return n == 0 ? (r == 0) : C(n + r - 1, r); }
template <typename T> T gcd(T x, T y) {
if (y == 0)
return x;
else
return gcd(y, x % y);
}
template <typename T> T lcm(T x, T y) { return (x / gcd(x, y)) * y; }
template <typename T> T ceil(T x, T y) { return (x + (y - 1)) / y; }
ll W1, H1, x, y;
int main(void) {
cin >> W1 >> H1 >> x >> y;
cout << W1 * H1 / 2.0 << " ";
if (abs(x - W1 / 2.0) < EPS and abs(y - H1 / 2.0) < EPS)
cout << 1 << endl;
else
cout << 0 << endl;
return 0;
}
| [
"variable_declaration.type.change",
"literal.number.change",
"io.output.change"
] | 815,098 | 815,099 | u097408484 | cpp |
p03001 | #include "bits/stdc++.h"
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define rep2(i, s, n) for (int i = (s); i < (int)(n); i++)
using namespace std;
const int INF = 1 << 30;
const long long MOD = 1000000000 + 7;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = W * H / 2;
double halfX = (double)W / 2;
double halfY = (double)H / 2;
if (halfX == (double)x && halfY == (double)y) {
cout << fixed << setprecision(15) << ans << " " << 1;
} else
cout << fixed << setprecision(15) << ans << " " << 0;
} | #include "bits/stdc++.h"
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define rep2(i, s, n) for (int i = (s); i < (int)(n); i++)
using namespace std;
const int INF = 1 << 30;
const long long MOD = 1000000000 + 7;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = (double)W * H / 2;
double halfX = (double)W / 2;
double halfY = (double)H / 2;
if (halfX == (double)x && halfY == (double)y) {
cout << fixed << setprecision(15) << ans << " " << 1;
} else
cout << fixed << setprecision(15) << ans << " " << 0;
} | [
"type_conversion.add"
] | 815,100 | 815,101 | u289578952 | cpp |
p03001 | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); ++i)
using namespace std;
using ll = long long;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
double ans = w * h / 2;
int a = 0;
if (w / 2 == x && h / 2 == y)
a = 1;
cout << ans << " " << a << endl;
return 0;
} | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); ++i)
using namespace std;
using ll = long long;
int main() {
double w, h, x, y;
cin >> w >> h >> x >> y;
double ans = w * h / 2;
int a = 0;
if (w / 2 == x && h / 2 == y)
a = 1;
cout << ans << " " << a << endl;
return 0;
} | [
"variable_declaration.type.primitive.change"
] | 815,105 | 815,106 | u754114382 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
if (W % 2 == 0 && x == W / 2 && H % 2 == 0 && y == H / 2) {
ll ans = H * W / 2;
cout << ans << ' ' << 1 << endl;
} else {
float ans;
ans = H * W / 2;
cout << ans << ' ' << 0 << endl;
}
}
| #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
if (W % 2 == 0 && x == W / 2 && H % 2 == 0 && y == H / 2) {
ll ans = H * W / 2;
cout << ans << ' ' << 1 << endl;
} else {
float ans;
ans = (float)H * W / 2;
cout << ans << ' ' << 0 << endl;
}
}
| [
"type_conversion.add"
] | 815,120 | 815,121 | u639032323 | cpp |
p03001 | // Jai Bhole Ki
#include <bits/stdc++.h>
using namespace std;
#define fast \
static int fastline = []() { \
std::ios::sync_with_stdio(false); \
cin.tie(NULL); \
return 0; \
}();
#define ll long long
#define LL unsigned ll
#define pb push_back
#define pi pair<ll, ll>
#define debug(x) cout << x << "\n";
#define debug cout << "debugged\n";
#define minval -2e9
#define maxval 2e9
long double PI = 3.14159265358979323846;
const ll M = 1e9 + 7;
const ll inf = 1e18;
const ll ms = 2e5 + 5;
fast;
double w, h, l, r;
void solve() {
cin >> w >> h >> l >> r;
// if(w/2==l&&h/2==r)
cout << fixed << setprecision(12) << h * w / 2 << " "
<< ((l + l) == w) + ((r + r) == h) << endl;
}
int main() {
// freopen("input.txt","r",stdin);
// freopen("output.txt","w",stdout);
// int t;cin>>t;while(t--)
{ solve(); }
return 0;
} | // Jai Bhole Ki
#include <bits/stdc++.h>
using namespace std;
#define fast \
static int fastline = []() { \
std::ios::sync_with_stdio(false); \
cin.tie(NULL); \
return 0; \
}();
#define ll long long
#define LL unsigned ll
#define pb push_back
#define pi pair<ll, ll>
#define debug(x) cout << x << "\n";
#define debug cout << "debugged\n";
#define minval -2e9
#define maxval 2e9
long double PI = 3.14159265358979323846;
const ll M = 1e9 + 7;
const ll inf = 1e18;
const ll ms = 2e5 + 5;
fast;
double w, h, l, r;
void solve() {
cin >> w >> h >> l >> r;
// if(w/2==l&&h/2==r)
cout << fixed << setprecision(12) << h * w / 2 << " "
<< (((l + l) == w) && ((r + r) == h)) << endl;
}
int main() {
// freopen("input.txt","r",stdin);
// freopen("output.txt","w",stdout);
// int t;cin>>t;while(t--)
{ solve(); }
return 0;
} | [
"io.output.change"
] | 815,122 | 815,123 | u526639495 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
int A, B, C, D;
cin >> A >> B >> C >> D;
cout << (double)(A * B) / 2 << (A / 2 == C && B / 2 == D ? 1 : 0) << endl;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
double A, B, C, D;
cin >> A >> B >> C >> D;
cout << (double)(A * B) / 2 << ' ' << (A / 2 == C && B / 2 == D ? 1 : 0)
<< endl;
}
| [
"variable_declaration.type.primitive.change",
"io.output.change"
] | 815,145 | 815,146 | u620626180 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w || 2 * y == h) {
cout << fixed << setprecision(11) << (double)w * h / 2 << " " << 0 << endl;
return 0;
}
cout << fixed << setprecision(11) << (double)w * h / 2 << " " << 1 << endl;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w && 2 * y == h) {
cout << fixed << setprecision(11) << (double)w * h / 2 << " " << 1 << endl;
return 0;
}
cout << fixed << setprecision(11) << (double)w * h / 2 << " " << 0 << endl;
return 0;
} | [
"misc.opposites",
"control_flow.branch.if.condition.change",
"literal.number.change",
"io.output.change"
] | 815,156 | 815,157 | u221391729 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w && 2 * y == h) {
cout << fixed << setprecision(11) << (double)w * (double)h / 2 << " " << 0
<< endl;
return 0;
}
cout << fixed << setprecision(11) << (double)w * (double)h / 2 << " " << 1
<< endl;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w && 2 * y == h) {
cout << fixed << setprecision(11) << (double)w * (double)h / 2 << " " << 1
<< endl;
return 0;
}
cout << fixed << setprecision(11) << (double)w * (double)h / 2 << " " << 0
<< endl;
return 0;
} | [
"literal.number.change",
"io.output.change"
] | 815,158 | 815,159 | u221391729 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w || 2 * y == h) {
cout << fixed << setprecision(11) << (double)w * (double)h / 2 << " " << 0
<< endl;
return 0;
}
cout << fixed << setprecision(11) << (double)w * (double)h / 2 << " " << 1
<< endl;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w && 2 * y == h) {
cout << fixed << setprecision(11) << (double)w * (double)h / 2 << " " << 1
<< endl;
return 0;
}
cout << fixed << setprecision(11) << (double)w * (double)h / 2 << " " << 0
<< endl;
return 0;
} | [
"misc.opposites",
"control_flow.branch.if.condition.change",
"literal.number.change",
"io.output.change"
] | 815,160 | 815,159 | u221391729 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
#define REP(i, n) for (int i = 0, i##_len = (n); i < i##_len; ++i)
#define all(x) (x).begin(), (x).end()
using ll = long long;
string char_to_string(char val) { return string(1, val); }
int char_to_int(char val) { return val - '0'; }
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
int main() {
ll W, H;
cin >> W >> H;
ll x, y;
cin >> x >> y;
ll cnt = H * W;
double ans = cnt / 2.0;
string str = "0";
if (x == W / 2 && y == H / 2)
str = "1";
cout << fixed << setprecision(10) << ans;
cout << " " << str << endl;
} | #include <bits/stdc++.h>
using namespace std;
#define REP(i, n) for (int i = 0, i##_len = (n); i < i##_len; ++i)
#define all(x) (x).begin(), (x).end()
using ll = long long;
string char_to_string(char val) { return string(1, val); }
int char_to_int(char val) { return val - '0'; }
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
int main() {
double W, H;
cin >> W >> H;
ll x, y;
cin >> x >> y;
ll cnt = H * W;
double ans = cnt / 2.0;
string str = "0";
if (x == W / 2 && y == H / 2)
str = "1";
cout << fixed << setprecision(10) << ans;
cout << " " << str << endl;
} | [
"variable_declaration.type.change"
] | 815,161 | 815,162 | u308463793 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
if (x == W / 2 && y == H / 2)
cout << W * H / 2 << " " << 1 << endl;
else
cout << W * H / 2 << " " << 0 << endl;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
int main() {
double W, H, x, y;
cin >> W >> H >> x >> y;
if (x == W / 2 && y == H / 2)
cout << W * H / 2 << " " << 1 << endl;
else
cout << W * H / 2 << " " << 0 << endl;
} | [
"variable_declaration.type.primitive.change"
] | 815,165 | 815,166 | u650236619 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using p = pair<int, int>;
#define INF 1001001001
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define repX(i, n, x) for (int i = x; i < (int)(n); i++)
#define repBack(i, n) for (int i = n; i >= 0; i--)
#define dup(x, y) (((x) + (y)-1) / (y))
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
int n = (W == x * 2 && H == y * 2);
printf("%10f %d\n", (double)(W * H / 2), n);
return 0;
} | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using p = pair<int, int>;
#define INF 1001001001
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define repX(i, n, x) for (int i = x; i < (int)(n); i++)
#define repBack(i, n) for (int i = n; i >= 0; i--)
#define dup(x, y) (((x) + (y)-1) / (y))
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
int n = (W == x * 2 && H == y * 2);
printf("%10f %d\n", (double)W * H / 2, n);
return 0;
} | [
"call.arguments.change"
] | 815,173 | 815,174 | u911917041 | cpp |
p03001 | #include <bits/stdc++.h>
#define rep(i, n) for (long long int i = 0; i < n; i++)
#define _rep(i, m, n) for (long long int i = m; i < n; i++)
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
// const int N = 1000000;
const ll mod = 1000000007;
using Graph = vector<vector<int>>;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
ll gcd(ll A, ll B) {
if (B == 0)
return A;
return gcd(B, A % B);
}
ll lcm(ll A, ll B) { return A * (B / gcd(A, B)); }
/*------------------------------------------------------------------*/
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w and 2 * y == h) {
cout << double(w) * double(h) / 2 << " " << 0 << endl;
} else {
cout << double(w) * double(h) / 2 << " " << 1 << endl;
}
} | #include <bits/stdc++.h>
#define rep(i, n) for (long long int i = 0; i < n; i++)
#define _rep(i, m, n) for (long long int i = m; i < n; i++)
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
// const int N = 1000000;
const ll mod = 1000000007;
using Graph = vector<vector<int>>;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
ll gcd(ll A, ll B) {
if (B == 0)
return A;
return gcd(B, A % B);
}
ll lcm(ll A, ll B) { return A * (B / gcd(A, B)); }
/*------------------------------------------------------------------*/
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w and 2 * y == h) {
cout << double(w) * double(h) / 2 << " " << 1 << endl;
} else {
cout << double(w) * double(h) / 2 << " " << 0 << endl;
}
} | [
"literal.number.change",
"io.output.change"
] | 815,181 | 815,182 | u999788719 | cpp |
p03001 | #include <bits/stdc++.h>
#define rep(i, n) for (long long int i = 0; i < n; i++)
#define _rep(i, m, n) for (long long int i = m; i < n; i++)
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
// const int N = 1000000;
const ll mod = 1000000007;
using Graph = vector<vector<int>>;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
ll gcd(ll A, ll B) {
if (B == 0)
return A;
return gcd(B, A % B);
}
ll lcm(ll A, ll B) { return A * (B / gcd(A, B)); }
/*------------------------------------------------------------------*/
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w and 2 * y == h) {
cout << double(w) * double(h) << " " << 0 << endl;
} else {
cout << double(w) * double(h) << " " << 1 << endl;
}
} | #include <bits/stdc++.h>
#define rep(i, n) for (long long int i = 0; i < n; i++)
#define _rep(i, m, n) for (long long int i = m; i < n; i++)
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
// const int N = 1000000;
const ll mod = 1000000007;
using Graph = vector<vector<int>>;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
ll gcd(ll A, ll B) {
if (B == 0)
return A;
return gcd(B, A % B);
}
ll lcm(ll A, ll B) { return A * (B / gcd(A, B)); }
/*------------------------------------------------------------------*/
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w and 2 * y == h) {
cout << double(w) * double(h) / 2 << " " << 1 << endl;
} else {
cout << double(w) * double(h) / 2 << " " << 0 << endl;
}
} | [
"literal.number.change",
"io.output.change"
] | 815,183 | 815,182 | u999788719 | cpp |
p03001 | #include <bits/stdc++.h>
#define rep(i, n) for (long long int i = 0; i < n; i++)
#define _rep(i, m, n) for (long long int i = m; i < n; i++)
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
// const int N = 1000000;
const ll mod = 1000000007;
using Graph = vector<vector<int>>;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
ll gcd(ll A, ll B) {
if (B == 0)
return A;
return gcd(B, A % B);
}
ll lcm(ll A, ll B) { return A * (B / gcd(A, B)); }
/*------------------------------------------------------------------*/
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w and 2 * y == h) {
cout << double(w) * double(h) << " " << 1 << endl;
} else {
cout << double(w) * double(h) << " " << 0 << endl;
}
} | #include <bits/stdc++.h>
#define rep(i, n) for (long long int i = 0; i < n; i++)
#define _rep(i, m, n) for (long long int i = m; i < n; i++)
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
// const int N = 1000000;
const ll mod = 1000000007;
using Graph = vector<vector<int>>;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
ll gcd(ll A, ll B) {
if (B == 0)
return A;
return gcd(B, A % B);
}
ll lcm(ll A, ll B) { return A * (B / gcd(A, B)); }
/*------------------------------------------------------------------*/
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w and 2 * y == h) {
cout << double(w) * double(h) / 2 << " " << 1 << endl;
} else {
cout << double(w) * double(h) / 2 << " " << 0 << endl;
}
} | [
"expression.operation.binary.add"
] | 815,184 | 815,182 | u999788719 | cpp |
p03001 | #include <iostream>
using namespace std;
int main() {
int a, b, x, y;
cin >> a >> b >> x >> y;
printf("%lf %d", double(a) * double(y) / 2, x + x == a && y + y == b);
return 0;
}
| #include <iostream>
using namespace std;
int main() {
int a, b, x, y;
cin >> a >> b >> x >> y;
printf("%lf %d", double(a) * double(b) / 2, x + x == a && y + y == b);
return 0;
}
| [
"identifier.change",
"call.arguments.change",
"expression.operation.binary.change",
"io.output.change"
] | 815,194 | 815,195 | u798562499 | cpp |
p03001 | #define _GLIBCXX_DEBUG
#include <bits/stdc++.h>
using namespace std;
#define ll long long
#define ld long double
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define repo(i, n) for (int i = 1; i < (int)(n); i++)
#define pb push_back
#define mp make_pair
#define np next_permutation
#define fi first
#define se second
#define all(x) (x).begin(), (x).end()
#define mod 1000000007
#define pi acos(-1.0)
// cout << fixed << setprecision (20); 小数点以下20桁まで
// intの最大値2147483647 ≒ 2×10^9
// long longの最大値9223372036854775807 ≒ 9×10^18
//'0'+=16; で大文字に
//'大文字'+=32; で小文字に
// s[i]-'0'でchar文字→int数に;
// string s = to_string(int数);
// int n = stoi(string文字列)
//実行時間制約2秒では2×10^8回くらいまで計算できる
int main() {
ll n, m, x, y;
cin >> n >> m >> x >> y;
cout << (ld)(n / 2) * m << " ";
cout << (2 * x == n && 2 * y == m ? "1" : "0") << endl;
}
| #define _GLIBCXX_DEBUG
#include <bits/stdc++.h>
using namespace std;
#define ll long long
#define ld long double
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define repo(i, n) for (int i = 1; i < (int)(n); i++)
#define pb push_back
#define mp make_pair
#define np next_permutation
#define fi first
#define se second
#define all(x) (x).begin(), (x).end()
#define mod 1000000007
#define pi acos(-1.0)
// cout << fixed << setprecision (20); 小数点以下20桁まで
// intの最大値2147483647 ≒ 2×10^9
// long longの最大値9223372036854775807 ≒ 9×10^18
//'0'+=16; で大文字に
//'大文字'+=32; で小文字に
// s[i]-'0'でchar文字→int数に;
// string s = to_string(int数);
// int n = stoi(string文字列)
//実行時間制約2秒では2×10^8回くらいまで計算できる
int main() {
ld n, m, x, y;
cin >> n >> m >> x >> y;
cout << (n / 2) * m << " ";
cout << (2 * x == n && 2 * y == m ? "1" : "0") << endl;
}
| [
"variable_declaration.type.change",
"call.remove"
] | 815,196 | 815,197 | u604329931 | cpp |
p03001 | // #include <bits/stdc++.h>
#include <algorithm>
#include <cmath>
#include <iostream>
#include <map>
#include <numeric>
#include <string>
#include <tuple>
#include <vector>
using namespace std;
typedef long long ll;
#define rep(i, n) for (ll i = 0; i < (ll)(n); i++)
#define repd(i, a, b) for (ll i = (ll)(a); i < (ll)(b); i++)
#define repdm(i, a, b) for (ll i = (ll)(a); i > (ll)(b); i--)
const ll INF = 1LL << 60;
const ll MOD = 1000000007;
int main() {
double W, H, x, y;
cin >> W >> H >> x >> y;
printf("%.12f", (W / 2) * H);
// center
if (x == (W / 2) && y == (H / 2))
cout << " 1" << endl;
// not center
else
cout << "0" << endl;
} | // #include <bits/stdc++.h>
#include <algorithm>
#include <cmath>
#include <iostream>
#include <map>
#include <numeric>
#include <string>
#include <tuple>
#include <vector>
using namespace std;
typedef long long ll;
#define rep(i, n) for (ll i = 0; i < (ll)(n); i++)
#define repd(i, a, b) for (ll i = (ll)(a); i < (ll)(b); i++)
#define repdm(i, a, b) for (ll i = (ll)(a); i > (ll)(b); i--)
const ll INF = 1LL << 60;
const ll MOD = 1000000007;
int main() {
double W, H, x, y;
cin >> W >> H >> x >> y;
printf("%.12f", (W / 2) * H);
// center
if (x == (W / 2) && y == (H / 2))
cout << " 1" << endl;
// not center
else
cout << " 0" << endl;
} | [
"literal.string.change",
"io.output.change"
] | 815,203 | 815,204 | u879674287 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int mod = 1000000007;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
double ans = (double)w * y / 2;
int num = (w == x * 2 && h == y * 2) ? 1 : 0;
cout << ans << " " << num << endl;
}
| #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int mod = 1000000007;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
double ans = (double)w * h / 2;
int num = (w == x * 2 && h == y * 2) ? 1 : 0;
cout << ans << " " << num << endl;
}
| [
"identifier.change",
"expression.operation.binary.change"
] | 815,205 | 815,206 | u999989620 | cpp |
p03001 | #include <algorithm>
#include <bitset>
#include <climits>
#include <cmath>
#include <cstdint>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <set>
#include <string>
#include <vector>
using namespace std;
typedef long long ll;
typedef vector<int> VI;
typedef vector<ll> VL;
const double PI = 3.14159265358979323846;
#define REP(i, n) for (int i = 0; i < (int)(n); i++)
#define REP1(i, n) for (int i = 1; i <= (int)(n); i++)
#define REPLL(i, n) for (ll i = 0; i < (ll)(n); i++)
#define REPLL1(i, n) for (ll i = 1; i <= (ll)(n); i++)
#define ALL(x) (x).begin(), (x).end()
#define SZ(x) ((int)(x).size())
#define LEN(x) ((int)(x).length())
#define ZERO(a) memset(a, 0, sizeof(a))
#define RAD(d) (PI * (d) / 180)
#define DEG(r) (180.0 * (r) / PI)
template <class T> bool chmax(T &a, const T &b) {
if (a < b) {
a = b;
return true;
}
return false;
}
template <class T> bool chmin(T &a, const T &b) {
if (b < a) {
a = b;
return true;
}
return false;
}
template <class T> void dump(const vector<T> &v) {
REP(i, SZ(v) - 1) { cout << v[i] << " "; }
cout << v[SZ(v) - 1] << endl;
}
template <class T> void dump(int w, int h, const vector<T> &v) {
REP(j, h) {
REP(i, w - 1) { cout << v[j * w + i] << " "; }
cout << v[j * w + w - 1] << endl;
}
}
// 和
template <class T> T accumulate(const vector<T> &v) {
T sum = 0;
REP(i, SZ(v)) { sum += v[i]; }
return sum;
}
// 和(範囲指定)
template <class T> T accumulate(const vector<T> &v, int start, int length) {
T sum = 0;
REP(i, length) { sum += v[start + i]; }
return sum;
}
// 平均
template <class T> T average(const vector<T> &v) {
return accumulate(v) / SZ(v);
}
// 行列
template <class T> struct Matrix {
T w, h;
vector<T> A;
Matrix(T w_, T h_) : w(w_), h(h_), A(w * h) {}
T get(T x, T y) const { return A[y * w + x]; }
};
template <class T> void input(Matrix<T> &m) {
REP(j, m.h) {
REP(i, m.w) { cin >> m.A[j * m.w + i]; }
}
}
template <class T> Matrix<T> prod(const Matrix<T> &a, const Matrix<T> &b) {
Matrix<T> m(b.w, a.h);
REP(j, m.h) {
REP(i, m.w) {
ll c = 0;
REP(k, a.w) { c += a.A[j * a.w + k] * b.A[k * b.w + i]; }
m.A[j * m.w + i] = c;
}
}
return m;
}
void dump(const Matrix<ll> &m) {
REP(j, m.h) {
REP(i, m.w - 1) { printf("%lld ", m.A[j * m.w + i]); }
printf("%lld\n", m.A[j * m.w + m.w - 1]);
}
}
void dump(const Matrix<double> &m) {
REP(j, m.h) {
REP(i, m.w - 1) { printf("%f ", m.A[j * m.w + i]); }
printf("%f\n", m.A[j * m.w + m.w - 1]);
}
}
// 文字列の大文字化
string &to_upper(string &s) {
REP(i, s.length()) {
if ('a' <= s[i] && s[i] <= 'z') {
s[i] -= 32;
}
}
return s;
}
// 文字列の小文字化
string &to_lower(string &s) {
REP(i, s.length()) {
if ('A' <= s[i] && s[i] <= 'Z') {
s[i] += 32;
}
}
return s;
}
// すべての約数を列挙する
template <class T> vector<T> get_divisors(T n) {
vector<T> ret;
for (T i = 1; i * i <= n; i++) {
if (n % i == 0) {
ret.push_back(i);
if (i * i != n)
ret.push_back(n / i);
}
}
sort(ALL(ret));
return ret;
}
// 1-sqrt(N)までの約数を列挙する
template <class T> vector<T> get_divisors2(T n) {
vector<T> ret;
for (T i = 1; i * i <= n; i++) {
if (n % i == 0) {
ret.push_back(i);
}
}
return ret;
}
// 最大公約数(※ユークリッドの互除法)
template <class T> T gcd(T a, T b) {
if (a < b)
return gcd(b, a);
ll r;
while ((r = a % b)) {
a = b;
b = r;
}
return b;
}
// 3数の最大公約数(※ユークリッドの互除法)
template <class T> T gcd(T a, T b, T c) { return gcd(gcd(a, b), c); }
// 3数以上の最大公約数
template <class T> T gcd(const vector<T> v) {
if (SZ(v) == 0)
return 0;
if (SZ(v) == 1)
return v[0];
if (SZ(v) == 2)
return gcd(v[0], v[1]);
T g = v[0];
for (int i = 1; i < SZ(v); i++) {
g = gcd(g, v[i]);
}
return g;
}
// MOD計算
//
// modint 構造体を使ってみませんか? (C++) - noshi91のメモ
// https://noshi91.hatenablog.com/entry/2019/03/31/174006
//
// 使い方:
// const int MOD = 1000000007;
// using mint = modint<MOD>;
// mint a = 1234;
//
template <std::uint_fast64_t Modulus> class modint {
using u64 = std::uint_fast64_t;
public:
u64 a;
constexpr modint(const u64 x = 0) noexcept : a(x % Modulus) {}
constexpr u64 &value() noexcept { return a; }
constexpr const u64 &value() const noexcept { return a; }
constexpr modint operator+(const modint rhs) const noexcept {
return modint(*this) += rhs;
}
constexpr modint operator-(const modint rhs) const noexcept {
return modint(*this) -= rhs;
}
constexpr modint operator*(const modint rhs) const noexcept {
return modint(*this) *= rhs;
}
constexpr modint operator/(const modint rhs) const noexcept {
return modint(*this) /= rhs;
}
constexpr modint &operator+=(const modint rhs) noexcept {
a += rhs.a;
if (a >= Modulus) {
a -= Modulus;
}
return *this;
}
constexpr modint &operator-=(const modint rhs) noexcept {
if (a < rhs.a) {
a += Modulus;
}
a -= rhs.a;
return *this;
}
constexpr modint &operator*=(const modint rhs) noexcept {
a = a * rhs.a % Modulus;
return *this;
}
constexpr modint &operator/=(modint rhs) noexcept {
u64 exp = Modulus - 2;
while (exp) {
if (exp % 2) {
*this *= rhs;
}
rhs *= rhs;
exp /= 2;
}
return *this;
}
};
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
double S = W * H / 2;
bool flag = x * 2 == W && y * 2 == H;
printf("%.10f %d\n", S, flag);
return 0;
}
| #include <algorithm>
#include <bitset>
#include <climits>
#include <cmath>
#include <cstdint>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <set>
#include <string>
#include <vector>
using namespace std;
typedef long long ll;
typedef vector<int> VI;
typedef vector<ll> VL;
const double PI = 3.14159265358979323846;
#define REP(i, n) for (int i = 0; i < (int)(n); i++)
#define REP1(i, n) for (int i = 1; i <= (int)(n); i++)
#define REPLL(i, n) for (ll i = 0; i < (ll)(n); i++)
#define REPLL1(i, n) for (ll i = 1; i <= (ll)(n); i++)
#define ALL(x) (x).begin(), (x).end()
#define SZ(x) ((int)(x).size())
#define LEN(x) ((int)(x).length())
#define ZERO(a) memset(a, 0, sizeof(a))
#define RAD(d) (PI * (d) / 180)
#define DEG(r) (180.0 * (r) / PI)
template <class T> bool chmax(T &a, const T &b) {
if (a < b) {
a = b;
return true;
}
return false;
}
template <class T> bool chmin(T &a, const T &b) {
if (b < a) {
a = b;
return true;
}
return false;
}
template <class T> void dump(const vector<T> &v) {
REP(i, SZ(v) - 1) { cout << v[i] << " "; }
cout << v[SZ(v) - 1] << endl;
}
template <class T> void dump(int w, int h, const vector<T> &v) {
REP(j, h) {
REP(i, w - 1) { cout << v[j * w + i] << " "; }
cout << v[j * w + w - 1] << endl;
}
}
// 和
template <class T> T accumulate(const vector<T> &v) {
T sum = 0;
REP(i, SZ(v)) { sum += v[i]; }
return sum;
}
// 和(範囲指定)
template <class T> T accumulate(const vector<T> &v, int start, int length) {
T sum = 0;
REP(i, length) { sum += v[start + i]; }
return sum;
}
// 平均
template <class T> T average(const vector<T> &v) {
return accumulate(v) / SZ(v);
}
// 行列
template <class T> struct Matrix {
T w, h;
vector<T> A;
Matrix(T w_, T h_) : w(w_), h(h_), A(w * h) {}
T get(T x, T y) const { return A[y * w + x]; }
};
template <class T> void input(Matrix<T> &m) {
REP(j, m.h) {
REP(i, m.w) { cin >> m.A[j * m.w + i]; }
}
}
template <class T> Matrix<T> prod(const Matrix<T> &a, const Matrix<T> &b) {
Matrix<T> m(b.w, a.h);
REP(j, m.h) {
REP(i, m.w) {
ll c = 0;
REP(k, a.w) { c += a.A[j * a.w + k] * b.A[k * b.w + i]; }
m.A[j * m.w + i] = c;
}
}
return m;
}
void dump(const Matrix<ll> &m) {
REP(j, m.h) {
REP(i, m.w - 1) { printf("%lld ", m.A[j * m.w + i]); }
printf("%lld\n", m.A[j * m.w + m.w - 1]);
}
}
void dump(const Matrix<double> &m) {
REP(j, m.h) {
REP(i, m.w - 1) { printf("%f ", m.A[j * m.w + i]); }
printf("%f\n", m.A[j * m.w + m.w - 1]);
}
}
// 文字列の大文字化
string &to_upper(string &s) {
REP(i, s.length()) {
if ('a' <= s[i] && s[i] <= 'z') {
s[i] -= 32;
}
}
return s;
}
// 文字列の小文字化
string &to_lower(string &s) {
REP(i, s.length()) {
if ('A' <= s[i] && s[i] <= 'Z') {
s[i] += 32;
}
}
return s;
}
// すべての約数を列挙する
template <class T> vector<T> get_divisors(T n) {
vector<T> ret;
for (T i = 1; i * i <= n; i++) {
if (n % i == 0) {
ret.push_back(i);
if (i * i != n)
ret.push_back(n / i);
}
}
sort(ALL(ret));
return ret;
}
// 1-sqrt(N)までの約数を列挙する
template <class T> vector<T> get_divisors2(T n) {
vector<T> ret;
for (T i = 1; i * i <= n; i++) {
if (n % i == 0) {
ret.push_back(i);
}
}
return ret;
}
// 最大公約数(※ユークリッドの互除法)
template <class T> T gcd(T a, T b) {
if (a < b)
return gcd(b, a);
ll r;
while ((r = a % b)) {
a = b;
b = r;
}
return b;
}
// 3数の最大公約数(※ユークリッドの互除法)
template <class T> T gcd(T a, T b, T c) { return gcd(gcd(a, b), c); }
// 3数以上の最大公約数
template <class T> T gcd(const vector<T> v) {
if (SZ(v) == 0)
return 0;
if (SZ(v) == 1)
return v[0];
if (SZ(v) == 2)
return gcd(v[0], v[1]);
T g = v[0];
for (int i = 1; i < SZ(v); i++) {
g = gcd(g, v[i]);
}
return g;
}
// MOD計算
//
// modint 構造体を使ってみませんか? (C++) - noshi91のメモ
// https://noshi91.hatenablog.com/entry/2019/03/31/174006
//
// 使い方:
// const int MOD = 1000000007;
// using mint = modint<MOD>;
// mint a = 1234;
//
template <std::uint_fast64_t Modulus> class modint {
using u64 = std::uint_fast64_t;
public:
u64 a;
constexpr modint(const u64 x = 0) noexcept : a(x % Modulus) {}
constexpr u64 &value() noexcept { return a; }
constexpr const u64 &value() const noexcept { return a; }
constexpr modint operator+(const modint rhs) const noexcept {
return modint(*this) += rhs;
}
constexpr modint operator-(const modint rhs) const noexcept {
return modint(*this) -= rhs;
}
constexpr modint operator*(const modint rhs) const noexcept {
return modint(*this) *= rhs;
}
constexpr modint operator/(const modint rhs) const noexcept {
return modint(*this) /= rhs;
}
constexpr modint &operator+=(const modint rhs) noexcept {
a += rhs.a;
if (a >= Modulus) {
a -= Modulus;
}
return *this;
}
constexpr modint &operator-=(const modint rhs) noexcept {
if (a < rhs.a) {
a += Modulus;
}
a -= rhs.a;
return *this;
}
constexpr modint &operator*=(const modint rhs) noexcept {
a = a * rhs.a % Modulus;
return *this;
}
constexpr modint &operator/=(modint rhs) noexcept {
u64 exp = Modulus - 2;
while (exp) {
if (exp % 2) {
*this *= rhs;
}
rhs *= rhs;
exp /= 2;
}
return *this;
}
};
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
double S = W * H / 2.0;
bool flag = x * 2 == W && y * 2 == H;
printf("%.10f %d\n", S, flag);
return 0;
}
| [
"literal.number.change",
"expression.operation.binary.change"
] | 815,217 | 815,218 | u081029414 | cpp |
p03001 | #include <algorithm>
#include <bitset>
#include <climits>
#include <cmath>
#include <cstdint>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <set>
#include <string>
#include <vector>
using namespace std;
typedef long long ll;
typedef vector<int> VI;
typedef vector<ll> VL;
const double PI = 3.14159265358979323846;
#define REP(i, n) for (int i = 0; i < (int)(n); i++)
#define REP1(i, n) for (int i = 1; i <= (int)(n); i++)
#define REPLL(i, n) for (ll i = 0; i < (ll)(n); i++)
#define REPLL1(i, n) for (ll i = 1; i <= (ll)(n); i++)
#define ALL(x) (x).begin(), (x).end()
#define SZ(x) ((int)(x).size())
#define LEN(x) ((int)(x).length())
#define ZERO(a) memset(a, 0, sizeof(a))
#define RAD(d) (PI * (d) / 180)
#define DEG(r) (180.0 * (r) / PI)
template <class T> bool chmax(T &a, const T &b) {
if (a < b) {
a = b;
return true;
}
return false;
}
template <class T> bool chmin(T &a, const T &b) {
if (b < a) {
a = b;
return true;
}
return false;
}
template <class T> void dump(const vector<T> &v) {
REP(i, SZ(v) - 1) { cout << v[i] << " "; }
cout << v[SZ(v) - 1] << endl;
}
template <class T> void dump(int w, int h, const vector<T> &v) {
REP(j, h) {
REP(i, w - 1) { cout << v[j * w + i] << " "; }
cout << v[j * w + w - 1] << endl;
}
}
// 和
template <class T> T accumulate(const vector<T> &v) {
T sum = 0;
REP(i, SZ(v)) { sum += v[i]; }
return sum;
}
// 和(範囲指定)
template <class T> T accumulate(const vector<T> &v, int start, int length) {
T sum = 0;
REP(i, length) { sum += v[start + i]; }
return sum;
}
// 平均
template <class T> T average(const vector<T> &v) {
return accumulate(v) / SZ(v);
}
// 行列
template <class T> struct Matrix {
T w, h;
vector<T> A;
Matrix(T w_, T h_) : w(w_), h(h_), A(w * h) {}
T get(T x, T y) const { return A[y * w + x]; }
};
template <class T> void input(Matrix<T> &m) {
REP(j, m.h) {
REP(i, m.w) { cin >> m.A[j * m.w + i]; }
}
}
template <class T> Matrix<T> prod(const Matrix<T> &a, const Matrix<T> &b) {
Matrix<T> m(b.w, a.h);
REP(j, m.h) {
REP(i, m.w) {
ll c = 0;
REP(k, a.w) { c += a.A[j * a.w + k] * b.A[k * b.w + i]; }
m.A[j * m.w + i] = c;
}
}
return m;
}
void dump(const Matrix<ll> &m) {
REP(j, m.h) {
REP(i, m.w - 1) { printf("%lld ", m.A[j * m.w + i]); }
printf("%lld\n", m.A[j * m.w + m.w - 1]);
}
}
void dump(const Matrix<double> &m) {
REP(j, m.h) {
REP(i, m.w - 1) { printf("%f ", m.A[j * m.w + i]); }
printf("%f\n", m.A[j * m.w + m.w - 1]);
}
}
// 文字列の大文字化
string &to_upper(string &s) {
REP(i, s.length()) {
if ('a' <= s[i] && s[i] <= 'z') {
s[i] -= 32;
}
}
return s;
}
// 文字列の小文字化
string &to_lower(string &s) {
REP(i, s.length()) {
if ('A' <= s[i] && s[i] <= 'Z') {
s[i] += 32;
}
}
return s;
}
// すべての約数を列挙する
template <class T> vector<T> get_divisors(T n) {
vector<T> ret;
for (T i = 1; i * i <= n; i++) {
if (n % i == 0) {
ret.push_back(i);
if (i * i != n)
ret.push_back(n / i);
}
}
sort(ALL(ret));
return ret;
}
// 1-sqrt(N)までの約数を列挙する
template <class T> vector<T> get_divisors2(T n) {
vector<T> ret;
for (T i = 1; i * i <= n; i++) {
if (n % i == 0) {
ret.push_back(i);
}
}
return ret;
}
// 最大公約数(※ユークリッドの互除法)
template <class T> T gcd(T a, T b) {
if (a < b)
return gcd(b, a);
ll r;
while ((r = a % b)) {
a = b;
b = r;
}
return b;
}
// 3数の最大公約数(※ユークリッドの互除法)
template <class T> T gcd(T a, T b, T c) { return gcd(gcd(a, b), c); }
// 3数以上の最大公約数
template <class T> T gcd(const vector<T> v) {
if (SZ(v) == 0)
return 0;
if (SZ(v) == 1)
return v[0];
if (SZ(v) == 2)
return gcd(v[0], v[1]);
T g = v[0];
for (int i = 1; i < SZ(v); i++) {
g = gcd(g, v[i]);
}
return g;
}
// MOD計算
//
// modint 構造体を使ってみませんか? (C++) - noshi91のメモ
// https://noshi91.hatenablog.com/entry/2019/03/31/174006
//
// 使い方:
// const int MOD = 1000000007;
// using mint = modint<MOD>;
// mint a = 1234;
//
template <std::uint_fast64_t Modulus> class modint {
using u64 = std::uint_fast64_t;
public:
u64 a;
constexpr modint(const u64 x = 0) noexcept : a(x % Modulus) {}
constexpr u64 &value() noexcept { return a; }
constexpr const u64 &value() const noexcept { return a; }
constexpr modint operator+(const modint rhs) const noexcept {
return modint(*this) += rhs;
}
constexpr modint operator-(const modint rhs) const noexcept {
return modint(*this) -= rhs;
}
constexpr modint operator*(const modint rhs) const noexcept {
return modint(*this) *= rhs;
}
constexpr modint operator/(const modint rhs) const noexcept {
return modint(*this) /= rhs;
}
constexpr modint &operator+=(const modint rhs) noexcept {
a += rhs.a;
if (a >= Modulus) {
a -= Modulus;
}
return *this;
}
constexpr modint &operator-=(const modint rhs) noexcept {
if (a < rhs.a) {
a += Modulus;
}
a -= rhs.a;
return *this;
}
constexpr modint &operator*=(const modint rhs) noexcept {
a = a * rhs.a % Modulus;
return *this;
}
constexpr modint &operator/=(modint rhs) noexcept {
u64 exp = Modulus - 2;
while (exp) {
if (exp % 2) {
*this *= rhs;
}
rhs *= rhs;
exp /= 2;
}
return *this;
}
};
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double S = W * H / 2;
bool flag = x * 2 == W && y * 2 == H;
printf("%.10f %d\n", S, flag);
return 0;
}
| #include <algorithm>
#include <bitset>
#include <climits>
#include <cmath>
#include <cstdint>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <set>
#include <string>
#include <vector>
using namespace std;
typedef long long ll;
typedef vector<int> VI;
typedef vector<ll> VL;
const double PI = 3.14159265358979323846;
#define REP(i, n) for (int i = 0; i < (int)(n); i++)
#define REP1(i, n) for (int i = 1; i <= (int)(n); i++)
#define REPLL(i, n) for (ll i = 0; i < (ll)(n); i++)
#define REPLL1(i, n) for (ll i = 1; i <= (ll)(n); i++)
#define ALL(x) (x).begin(), (x).end()
#define SZ(x) ((int)(x).size())
#define LEN(x) ((int)(x).length())
#define ZERO(a) memset(a, 0, sizeof(a))
#define RAD(d) (PI * (d) / 180)
#define DEG(r) (180.0 * (r) / PI)
template <class T> bool chmax(T &a, const T &b) {
if (a < b) {
a = b;
return true;
}
return false;
}
template <class T> bool chmin(T &a, const T &b) {
if (b < a) {
a = b;
return true;
}
return false;
}
template <class T> void dump(const vector<T> &v) {
REP(i, SZ(v) - 1) { cout << v[i] << " "; }
cout << v[SZ(v) - 1] << endl;
}
template <class T> void dump(int w, int h, const vector<T> &v) {
REP(j, h) {
REP(i, w - 1) { cout << v[j * w + i] << " "; }
cout << v[j * w + w - 1] << endl;
}
}
// 和
template <class T> T accumulate(const vector<T> &v) {
T sum = 0;
REP(i, SZ(v)) { sum += v[i]; }
return sum;
}
// 和(範囲指定)
template <class T> T accumulate(const vector<T> &v, int start, int length) {
T sum = 0;
REP(i, length) { sum += v[start + i]; }
return sum;
}
// 平均
template <class T> T average(const vector<T> &v) {
return accumulate(v) / SZ(v);
}
// 行列
template <class T> struct Matrix {
T w, h;
vector<T> A;
Matrix(T w_, T h_) : w(w_), h(h_), A(w * h) {}
T get(T x, T y) const { return A[y * w + x]; }
};
template <class T> void input(Matrix<T> &m) {
REP(j, m.h) {
REP(i, m.w) { cin >> m.A[j * m.w + i]; }
}
}
template <class T> Matrix<T> prod(const Matrix<T> &a, const Matrix<T> &b) {
Matrix<T> m(b.w, a.h);
REP(j, m.h) {
REP(i, m.w) {
ll c = 0;
REP(k, a.w) { c += a.A[j * a.w + k] * b.A[k * b.w + i]; }
m.A[j * m.w + i] = c;
}
}
return m;
}
void dump(const Matrix<ll> &m) {
REP(j, m.h) {
REP(i, m.w - 1) { printf("%lld ", m.A[j * m.w + i]); }
printf("%lld\n", m.A[j * m.w + m.w - 1]);
}
}
void dump(const Matrix<double> &m) {
REP(j, m.h) {
REP(i, m.w - 1) { printf("%f ", m.A[j * m.w + i]); }
printf("%f\n", m.A[j * m.w + m.w - 1]);
}
}
// 文字列の大文字化
string &to_upper(string &s) {
REP(i, s.length()) {
if ('a' <= s[i] && s[i] <= 'z') {
s[i] -= 32;
}
}
return s;
}
// 文字列の小文字化
string &to_lower(string &s) {
REP(i, s.length()) {
if ('A' <= s[i] && s[i] <= 'Z') {
s[i] += 32;
}
}
return s;
}
// すべての約数を列挙する
template <class T> vector<T> get_divisors(T n) {
vector<T> ret;
for (T i = 1; i * i <= n; i++) {
if (n % i == 0) {
ret.push_back(i);
if (i * i != n)
ret.push_back(n / i);
}
}
sort(ALL(ret));
return ret;
}
// 1-sqrt(N)までの約数を列挙する
template <class T> vector<T> get_divisors2(T n) {
vector<T> ret;
for (T i = 1; i * i <= n; i++) {
if (n % i == 0) {
ret.push_back(i);
}
}
return ret;
}
// 最大公約数(※ユークリッドの互除法)
template <class T> T gcd(T a, T b) {
if (a < b)
return gcd(b, a);
ll r;
while ((r = a % b)) {
a = b;
b = r;
}
return b;
}
// 3数の最大公約数(※ユークリッドの互除法)
template <class T> T gcd(T a, T b, T c) { return gcd(gcd(a, b), c); }
// 3数以上の最大公約数
template <class T> T gcd(const vector<T> v) {
if (SZ(v) == 0)
return 0;
if (SZ(v) == 1)
return v[0];
if (SZ(v) == 2)
return gcd(v[0], v[1]);
T g = v[0];
for (int i = 1; i < SZ(v); i++) {
g = gcd(g, v[i]);
}
return g;
}
// MOD計算
//
// modint 構造体を使ってみませんか? (C++) - noshi91のメモ
// https://noshi91.hatenablog.com/entry/2019/03/31/174006
//
// 使い方:
// const int MOD = 1000000007;
// using mint = modint<MOD>;
// mint a = 1234;
//
template <std::uint_fast64_t Modulus> class modint {
using u64 = std::uint_fast64_t;
public:
u64 a;
constexpr modint(const u64 x = 0) noexcept : a(x % Modulus) {}
constexpr u64 &value() noexcept { return a; }
constexpr const u64 &value() const noexcept { return a; }
constexpr modint operator+(const modint rhs) const noexcept {
return modint(*this) += rhs;
}
constexpr modint operator-(const modint rhs) const noexcept {
return modint(*this) -= rhs;
}
constexpr modint operator*(const modint rhs) const noexcept {
return modint(*this) *= rhs;
}
constexpr modint operator/(const modint rhs) const noexcept {
return modint(*this) /= rhs;
}
constexpr modint &operator+=(const modint rhs) noexcept {
a += rhs.a;
if (a >= Modulus) {
a -= Modulus;
}
return *this;
}
constexpr modint &operator-=(const modint rhs) noexcept {
if (a < rhs.a) {
a += Modulus;
}
a -= rhs.a;
return *this;
}
constexpr modint &operator*=(const modint rhs) noexcept {
a = a * rhs.a % Modulus;
return *this;
}
constexpr modint &operator/=(modint rhs) noexcept {
u64 exp = Modulus - 2;
while (exp) {
if (exp % 2) {
*this *= rhs;
}
rhs *= rhs;
exp /= 2;
}
return *this;
}
};
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
double S = W * H / 2.0;
bool flag = x * 2 == W && y * 2 == H;
printf("%.10f %d\n", S, flag);
return 0;
}
| [
"variable_declaration.type.change",
"literal.number.change",
"expression.operation.binary.change"
] | 815,219 | 815,218 | u081029414 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
typedef pair<ll, ll> pll;
#define FOR(i, n, m) for (ll(i) = (m); (i) < (n); ++(i))
#define REP(i, n) FOR(i, n, 0)
#define OF64 std::setprecision(10)
const ll MOD = 1000000007;
const ll INF = (ll)1e15;
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
double s = (double)H * (double)y / 2.0;
int t = 0;
if (x + x == W && y + y == H)
t = 1;
cout << OF64 << s << " " << t << endl;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
typedef pair<ll, ll> pll;
#define FOR(i, n, m) for (ll(i) = (m); (i) < (n); ++(i))
#define REP(i, n) FOR(i, n, 0)
#define OF64 std::setprecision(10)
const ll MOD = 1000000007;
const ll INF = (ll)1e15;
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
double s = (double)H * (double)W / 2.0;
int t = 0;
if (x + x == W && y + y == H)
t = 1;
cout << OF64 << s << " " << t << endl;
return 0;
} | [
"identifier.change",
"expression.operation.binary.change"
] | 815,220 | 815,221 | u340980616 | cpp |
p03001 | #ifndef _GLIBCXX_NO_ASSERT
#include <cassert>
#endif
#include <cctype>
#include <cerrno>
#include <cfloat>
#include <ciso646>
#include <climits>
#include <clocale>
#include <cmath>
#include <csetjmp>
#include <csignal>
#include <cstdarg>
#include <cstddef>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#if __cplusplus >= 201103L
#include <ccomplex>
#include <cfenv>
#include <cinttypes>
#include <cstdbool>
#include <cstdint>
#include <ctgmath>
#include <cwchar>
#include <cwctype>
#endif
// C++
#include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <exception>
#include <fstream>
#include <functional>
#include <iomanip>
#include <ios>
#include <iosfwd>
#include <iostream>
#include <istream>
#include <iterator>
#include <limits>
#include <list>
#include <locale>
#include <map>
#include <memory>
#include <new>
#include <numeric>
#include <ostream>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <stdexcept>
#include <streambuf>
#include <string>
#include <typeinfo>
#include <utility>
#include <valarray>
#include <vector>
#if __cplusplus >= 201103L
#include <array>
#include <atomic>
#include <chrono>
#include <condition_variable>
#include <forward_list>
#include <future>
#include <initializer_list>
#include <mutex>
#include <random>
#include <ratio>
#include <regex>
#include <scoped_allocator>
#include <system_error>
#include <thread>
#include <tuple>
#include <type_traits>
#include <typeindex>
#include <unordered_map>
#include <unordered_set>
#endif
#define int long long
#define rng(i, l, r) for (size_t i = (l); i < (r); ++i)
#define rep(i, n) rng(i, 0, n)
#define gnr(i, l, r) for (size_t i = (r)-1; i >= (l); i--)
#define per(i, b) gnr(i, 0, b)
#define ALL(obj) (obj).begin(), (obj).end() // 1,2,3,...
#define rALL(obj) (obj).rbegin(), (obj).rend() //...,3,2,1
using namespace std;
// using ll = long long;
const int MOD = 1000000007;
const int INF = 1e18;
const int dx4[4] = {1, 0, -1, 0};
const int dy4[4] = {0, 1, 0, -1};
const int dx8[8] = {1, 1, 0, -1, -1, -1, 0, 1};
const int dy8[8] = {0, 1, 1, 1, 0, -1, -1, -1};
const double pi = acos(-1);
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
using Graph = vector<vector<int>>;
int gcd(int a, int b) { return b ? gcd(b, a % b) : a; }
//*max_element(ALL(vector))
// count(ALL(vector),num) -> n
void solve() {
// remove the bottom 3 lines when you submit this code.
std::ifstream in("sample.txt");
std::cin.rdbuf(in.rdbuf());
cin.tie(0);
ios::sync_with_stdio(false);
double w, h, x, y;
cin >> w >> h >> x >> y;
int halfs = w * h / 2;
double cx = w / 2;
double cy = h / 2;
bool isPcenter = (cx == x && cy == y);
int num = 0;
if (isPcenter)
num = 1;
cout << setprecision(10) << halfs << " " << num << endl;
}
signed main() {
solve();
return 0;
}
| #ifndef _GLIBCXX_NO_ASSERT
#include <cassert>
#endif
#include <cctype>
#include <cerrno>
#include <cfloat>
#include <ciso646>
#include <climits>
#include <clocale>
#include <cmath>
#include <csetjmp>
#include <csignal>
#include <cstdarg>
#include <cstddef>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#if __cplusplus >= 201103L
#include <ccomplex>
#include <cfenv>
#include <cinttypes>
#include <cstdbool>
#include <cstdint>
#include <ctgmath>
#include <cwchar>
#include <cwctype>
#endif
// C++
#include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <exception>
#include <fstream>
#include <functional>
#include <iomanip>
#include <ios>
#include <iosfwd>
#include <iostream>
#include <istream>
#include <iterator>
#include <limits>
#include <list>
#include <locale>
#include <map>
#include <memory>
#include <new>
#include <numeric>
#include <ostream>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <stdexcept>
#include <streambuf>
#include <string>
#include <typeinfo>
#include <utility>
#include <valarray>
#include <vector>
#if __cplusplus >= 201103L
#include <array>
#include <atomic>
#include <chrono>
#include <condition_variable>
#include <forward_list>
#include <future>
#include <initializer_list>
#include <mutex>
#include <random>
#include <ratio>
#include <regex>
#include <scoped_allocator>
#include <system_error>
#include <thread>
#include <tuple>
#include <type_traits>
#include <typeindex>
#include <unordered_map>
#include <unordered_set>
#endif
#define int long long
#define rng(i, l, r) for (size_t i = (l); i < (r); ++i)
#define rep(i, n) rng(i, 0, n)
#define gnr(i, l, r) for (size_t i = (r)-1; i >= (l); i--)
#define per(i, b) gnr(i, 0, b)
#define ALL(obj) (obj).begin(), (obj).end() // 1,2,3,...
#define rALL(obj) (obj).rbegin(), (obj).rend() //...,3,2,1
using namespace std;
// using ll = long long;
const int MOD = 1000000007;
const int INF = 1e18;
const int dx4[4] = {1, 0, -1, 0};
const int dy4[4] = {0, 1, 0, -1};
const int dx8[8] = {1, 1, 0, -1, -1, -1, 0, 1};
const int dy8[8] = {0, 1, 1, 1, 0, -1, -1, -1};
const double pi = acos(-1);
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
using Graph = vector<vector<int>>;
int gcd(int a, int b) { return b ? gcd(b, a % b) : a; }
//*max_element(ALL(vector))
// count(ALL(vector),num) -> n
void solve() {
// remove the bottom 3 lines when you submit this code.
std::ifstream in("sample.txt");
std::cin.rdbuf(in.rdbuf());
cin.tie(0);
ios::sync_with_stdio(false);
double w, h, x, y;
cin >> w >> h >> x >> y;
double halfs = w * h / 2;
double cx = w / 2;
double cy = h / 2;
bool isPcenter = (cx == x && cy == y);
int num = 0;
if (isPcenter)
num = 1;
cout << setprecision(10) << halfs << " " << num << endl;
}
signed main() {
solve();
return 0;
}
| [
"variable_declaration.type.primitive.change"
] | 815,225 | 815,226 | u914047482 | cpp |
p03001 | #ifndef _GLIBCXX_NO_ASSERT
#include <cassert>
#endif
#include <cctype>
#include <cerrno>
#include <cfloat>
#include <ciso646>
#include <climits>
#include <clocale>
#include <cmath>
#include <csetjmp>
#include <csignal>
#include <cstdarg>
#include <cstddef>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#if __cplusplus >= 201103L
#include <ccomplex>
#include <cfenv>
#include <cinttypes>
#include <cstdbool>
#include <cstdint>
#include <ctgmath>
#include <cwchar>
#include <cwctype>
#endif
// C++
#include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <exception>
#include <fstream>
#include <functional>
#include <iomanip>
#include <ios>
#include <iosfwd>
#include <iostream>
#include <istream>
#include <iterator>
#include <limits>
#include <list>
#include <locale>
#include <map>
#include <memory>
#include <new>
#include <numeric>
#include <ostream>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <stdexcept>
#include <streambuf>
#include <string>
#include <typeinfo>
#include <utility>
#include <valarray>
#include <vector>
#if __cplusplus >= 201103L
#include <array>
#include <atomic>
#include <chrono>
#include <condition_variable>
#include <forward_list>
#include <future>
#include <initializer_list>
#include <mutex>
#include <random>
#include <ratio>
#include <regex>
#include <scoped_allocator>
#include <system_error>
#include <thread>
#include <tuple>
#include <type_traits>
#include <typeindex>
#include <unordered_map>
#include <unordered_set>
#endif
#define int long long
#define rng(i, l, r) for (size_t i = (l); i < (r); ++i)
#define rep(i, n) rng(i, 0, n)
#define gnr(i, l, r) for (size_t i = (r)-1; i >= (l); i--)
#define per(i, b) gnr(i, 0, b)
#define ALL(obj) (obj).begin(), (obj).end() // 1,2,3,...
#define rALL(obj) (obj).rbegin(), (obj).rend() //...,3,2,1
using namespace std;
// using ll = long long;
const int MOD = 1000000007;
const int INF = 1e18;
const int dx4[4] = {1, 0, -1, 0};
const int dy4[4] = {0, 1, 0, -1};
const int dx8[8] = {1, 1, 0, -1, -1, -1, 0, 1};
const int dy8[8] = {0, 1, 1, 1, 0, -1, -1, -1};
const double pi = acos(-1);
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
using Graph = vector<vector<int>>;
int gcd(int a, int b) { return b ? gcd(b, a % b) : a; }
//*max_element(ALL(vector))
// count(ALL(vector),num) -> n
void solve() {
// remove the bottom 3 lines when you submit this code.
std::ifstream in("sample.txt");
std::cin.rdbuf(in.rdbuf());
cin.tie(0);
ios::sync_with_stdio(false);
double w, h, x, y;
cin >> w >> h >> x >> y;
int halfs = w * h / 2;
int cx = w / 2;
int cy = h / 2;
bool isPcenter = (cx == x && cy == y);
int num = 0;
if (isPcenter)
num = 1;
cout << setprecision(10) << halfs << " " << num << endl;
}
signed main() {
solve();
return 0;
}
| #ifndef _GLIBCXX_NO_ASSERT
#include <cassert>
#endif
#include <cctype>
#include <cerrno>
#include <cfloat>
#include <ciso646>
#include <climits>
#include <clocale>
#include <cmath>
#include <csetjmp>
#include <csignal>
#include <cstdarg>
#include <cstddef>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#if __cplusplus >= 201103L
#include <ccomplex>
#include <cfenv>
#include <cinttypes>
#include <cstdbool>
#include <cstdint>
#include <ctgmath>
#include <cwchar>
#include <cwctype>
#endif
// C++
#include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <exception>
#include <fstream>
#include <functional>
#include <iomanip>
#include <ios>
#include <iosfwd>
#include <iostream>
#include <istream>
#include <iterator>
#include <limits>
#include <list>
#include <locale>
#include <map>
#include <memory>
#include <new>
#include <numeric>
#include <ostream>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <stdexcept>
#include <streambuf>
#include <string>
#include <typeinfo>
#include <utility>
#include <valarray>
#include <vector>
#if __cplusplus >= 201103L
#include <array>
#include <atomic>
#include <chrono>
#include <condition_variable>
#include <forward_list>
#include <future>
#include <initializer_list>
#include <mutex>
#include <random>
#include <ratio>
#include <regex>
#include <scoped_allocator>
#include <system_error>
#include <thread>
#include <tuple>
#include <type_traits>
#include <typeindex>
#include <unordered_map>
#include <unordered_set>
#endif
#define int long long
#define rng(i, l, r) for (size_t i = (l); i < (r); ++i)
#define rep(i, n) rng(i, 0, n)
#define gnr(i, l, r) for (size_t i = (r)-1; i >= (l); i--)
#define per(i, b) gnr(i, 0, b)
#define ALL(obj) (obj).begin(), (obj).end() // 1,2,3,...
#define rALL(obj) (obj).rbegin(), (obj).rend() //...,3,2,1
using namespace std;
// using ll = long long;
const int MOD = 1000000007;
const int INF = 1e18;
const int dx4[4] = {1, 0, -1, 0};
const int dy4[4] = {0, 1, 0, -1};
const int dx8[8] = {1, 1, 0, -1, -1, -1, 0, 1};
const int dy8[8] = {0, 1, 1, 1, 0, -1, -1, -1};
const double pi = acos(-1);
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
using Graph = vector<vector<int>>;
int gcd(int a, int b) { return b ? gcd(b, a % b) : a; }
//*max_element(ALL(vector))
// count(ALL(vector),num) -> n
void solve() {
// remove the bottom 3 lines when you submit this code.
std::ifstream in("sample.txt");
std::cin.rdbuf(in.rdbuf());
cin.tie(0);
ios::sync_with_stdio(false);
double w, h, x, y;
cin >> w >> h >> x >> y;
double halfs = w * h / 2;
double cx = w / 2;
double cy = h / 2;
bool isPcenter = (cx == x && cy == y);
int num = 0;
if (isPcenter)
num = 1;
cout << setprecision(10) << halfs << " " << num << endl;
}
signed main() {
solve();
return 0;
}
| [
"variable_declaration.type.primitive.change"
] | 815,227 | 815,226 | u914047482 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
using ll = long long int;
using ld = long double;
using VI = vector<ll>;
using VD = vector<ld>;
using VVI = vector<VI>;
using VC = vector<char>;
using VVC = vector<VC>;
using VS = vector<string>;
using PLL = pair<ll, ll>;
using PLD = pair<ld, ld>;
using VPLL = vector<PLL>;
#define REP(i, n) for (ll i = 0; i < (ll)(n); i++)
#define REPD(i, n) for (ll i = (ll)(n)-1; i >= 0; i--)
#define ALL(x) (x).begin(), (x).end()
#define ALLR(x) (x).rbegin(), (x).rend()
#define SIZE(x) ((ll)(x).size())
#define MAX(x) *max_element((x).begin(), (x).end())
#define MIN(x) *min_element((x).begin(), (x).end())
#define SORTR(x) sort((x).rbegin(), (x).rend())
#define SORT(x) sort((x).begin(), (x).end())
#define SUM(x) accumulate((x).begin(), (x).end(), 0)
#define FILL(x, a) fill(x.begin(), x.end(), a)
#define EACH(i, x) \
for (typeof((x).begin()) i = (x).begin(); i != (x).end(); ++i)
const long long int INF = 1e18;
const ld EPS = 1e-10;
const int MOD = int(1e9) + 7;
template <class T> bool chmax(T &a, const T &b) {
if (a < b) {
a = b;
return 1;
}
return 0;
}
template <class T> bool chmin(T &a, const T &b) {
if (b < a) {
a = b;
return 1;
}
return 0;
}
template <class BidirectionalIterator>
bool next_partial_permutation(BidirectionalIterator first,
BidirectionalIterator middle,
BidirectionalIterator last) {
reverse(middle, last);
return next_permutation(first, last);
}
#define COUT(x) cout << x << "\n"
void Main() {
ll w, h, x, y;
ll result = 0;
cin >> w >> h >> x >> y;
printf("%lf%d\n", double(w) * double(h) / 2, x + x == w && y + y == h);
return;
}
int main() {
std::cin.tie(0);
std::ios_base::sync_with_stdio(false);
std::cout << std::fixed << std::setprecision(15);
Main();
}
| #include <bits/stdc++.h>
using namespace std;
using ll = long long int;
using ld = long double;
using VI = vector<ll>;
using VD = vector<ld>;
using VVI = vector<VI>;
using VC = vector<char>;
using VVC = vector<VC>;
using VS = vector<string>;
using PLL = pair<ll, ll>;
using PLD = pair<ld, ld>;
using VPLL = vector<PLL>;
#define REP(i, n) for (ll i = 0; i < (ll)(n); i++)
#define REPD(i, n) for (ll i = (ll)(n)-1; i >= 0; i--)
#define ALL(x) (x).begin(), (x).end()
#define ALLR(x) (x).rbegin(), (x).rend()
#define SIZE(x) ((ll)(x).size())
#define MAX(x) *max_element((x).begin(), (x).end())
#define MIN(x) *min_element((x).begin(), (x).end())
#define SORTR(x) sort((x).rbegin(), (x).rend())
#define SORT(x) sort((x).begin(), (x).end())
#define SUM(x) accumulate((x).begin(), (x).end(), 0)
#define FILL(x, a) fill(x.begin(), x.end(), a)
#define EACH(i, x) \
for (typeof((x).begin()) i = (x).begin(); i != (x).end(); ++i)
const long long int INF = 1e18;
const ld EPS = 1e-10;
const int MOD = int(1e9) + 7;
template <class T> bool chmax(T &a, const T &b) {
if (a < b) {
a = b;
return 1;
}
return 0;
}
template <class T> bool chmin(T &a, const T &b) {
if (b < a) {
a = b;
return 1;
}
return 0;
}
template <class BidirectionalIterator>
bool next_partial_permutation(BidirectionalIterator first,
BidirectionalIterator middle,
BidirectionalIterator last) {
reverse(middle, last);
return next_permutation(first, last);
}
#define COUT(x) cout << x << "\n"
void Main() {
ll w, h, x, y;
ll result = 0;
cin >> w >> h >> x >> y;
printf("%lf %d\n", double(w) * double(h) / 2, x + x == w && y + y == h);
return;
}
int main() {
std::cin.tie(0);
std::ios_base::sync_with_stdio(false);
std::cout << std::fixed << std::setprecision(15);
Main();
}
| [
"literal.string.change",
"call.arguments.change",
"io.output.change"
] | 815,228 | 815,229 | u170054586 | cpp |
p03001 | #include <algorithm>
#include <climits>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <utility>
#include <vector>
#define rep(i, n) for (int i = 0; i < (n); ++i)
using namespace std;
using ll = long long int;
template <class T> ostream &operator<<(ostream &os, vector<T> &v) {
for (auto i = v.begin(); i != v.end(); i++) {
os << *i << " ";
}
return os;
}
const long long MOD = 1000000007;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
double ans = (double)(w * h) / (double)2;
if (x == w / 2 and y == h / 2)
std::cout << setprecision(15) << ans << " " << '1' << std::endl;
else
std::cout << setprecision(15) << ans << " " << '0' << std::endl;
return 0;
}
| #include <algorithm>
#include <climits>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <utility>
#include <vector>
#define rep(i, n) for (int i = 0; i < (n); ++i)
using namespace std;
using ll = long long int;
template <class T> ostream &operator<<(ostream &os, vector<T> &v) {
for (auto i = v.begin(); i != v.end(); i++) {
os << *i << " ";
}
return os;
}
const long long MOD = 1000000007;
int main() {
double w, h, x, y;
cin >> w >> h >> x >> y;
double ans = (double)(w * h) / (double)2;
if (x == w / 2. and y == h / 2.)
std::cout << setprecision(15) << ans << " " << '1' << std::endl;
else
std::cout << setprecision(15) << ans << " " << '0' << std::endl;
return 0;
}
| [
"variable_declaration.type.primitive.change",
"control_flow.branch.if.condition.change"
] | 815,233 | 815,234 | u131340563 | cpp |
p03001 | #include <algorithm>
#include <cstdlib>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <string>
#include <typeinfo>
#include <unordered_map>
#include <vector>
using namespace std;
using ll = long long int;
const int mod = 1e9 + 7;
#define rep(i, a, b) for (ll i = a; i < b; i++)
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
unsigned long long ans = w * h / 2;
if (x + x == w && y + y == h) {
cout << fixed << setprecision(6) << ans;
cout << " " << 1 << endl;
} else {
cout << fixed << setprecision(6) << ans;
cout << " " << 0 << endl;
}
return 0;
} | #include <algorithm>
#include <cstdlib>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <string>
#include <typeinfo>
#include <unordered_map>
#include <vector>
using namespace std;
using ll = long long int;
const int mod = 1e9 + 7;
#define rep(i, a, b) for (ll i = a; i < b; i++)
int main() {
double w, h, x, y;
cin >> w >> h >> x >> y;
double ans = w * h / 2;
if (x + x == w && y + y == h) {
cout << fixed << setprecision(6) << ans;
cout << " " << 1 << endl;
} else {
cout << fixed << setprecision(6) << ans;
cout << " " << 0 << endl;
}
return 0;
} | [
"variable_declaration.type.change",
"variable_declaration.type.primitive.change"
] | 815,261 | 815,262 | u870074807 | cpp |
p03001 | #include <algorithm>
#include <cstdlib>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <string>
#include <typeinfo>
#include <unordered_map>
#include <vector>
using namespace std;
using ll = long long int;
const int mod = 1e9 + 7;
#define rep(i, a, b) for (ll i = a; i < b; i++)
int main() {
float w, h, x, y;
cin >> w >> h >> x >> y;
ll ans = w * h / 2;
if (x + x == w && y + y == h) {
cout << fixed << setprecision(6) << ans;
cout << " " << 1 << endl;
} else {
cout << fixed << setprecision(6) << ans;
cout << " " << 0 << endl;
}
return 0;
} | #include <algorithm>
#include <cstdlib>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <string>
#include <typeinfo>
#include <unordered_map>
#include <vector>
using namespace std;
using ll = long long int;
const int mod = 1e9 + 7;
#define rep(i, a, b) for (ll i = a; i < b; i++)
int main() {
double w, h, x, y;
cin >> w >> h >> x >> y;
double ans = w * h / 2;
if (x + x == w && y + y == h) {
cout << fixed << setprecision(6) << ans;
cout << " " << 1 << endl;
} else {
cout << fixed << setprecision(6) << ans;
cout << " " << 0 << endl;
}
return 0;
} | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.change"
] | 815,263 | 815,262 | u870074807 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ull = unsigned long long;
using st = string;
using ch = char;
using db = double;
using bl = bool;
using vll = vector<long long>;
using vdb = vector<db>;
using vvll = vector<vll>;
using vst = vector<st>;
using vch = vector<char>;
using pll = pair<ll, ll>;
using vpll = vector<pll>;
using vvpll = vector<vpll>;
#define rep(i, m, n) for (ll i = (ll)(m); i < (ll)(n); i++)
#define vrep(i, vec) for (auto &i : vec)
#define vin(vec) \
for (auto &i : vec) \
cin >> i
#define all(v) v.begin(), v.end()
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
const ll mod = 1000000007;
const ll inf = 1LL << 60;
int main() {
db w, h, x, y;
cin >> w >> h >> x >> y;
cout << fixed << setprecision(2);
cout << w * h / 2 << " " << (w / 2 == x, h / 2 == y ? 1 : 0) << endl;
} | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ull = unsigned long long;
using st = string;
using ch = char;
using db = double;
using bl = bool;
using vll = vector<long long>;
using vdb = vector<db>;
using vvll = vector<vll>;
using vst = vector<st>;
using vch = vector<char>;
using pll = pair<ll, ll>;
using vpll = vector<pll>;
using vvpll = vector<vpll>;
#define rep(i, m, n) for (ll i = (ll)(m); i < (ll)(n); i++)
#define vrep(i, vec) for (auto &i : vec)
#define vin(vec) \
for (auto &i : vec) \
cin >> i
#define all(v) v.begin(), v.end()
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
const ll mod = 1000000007;
const ll inf = 1LL << 60;
int main() {
db w, h, x, y;
cin >> w >> h >> x >> y;
cout << fixed << setprecision(2);
cout << w * h / 2 << " " << (w / 2 == x && h / 2 == y ? 1 : 0) << endl;
} | [
"io.output.change"
] | 815,268 | 815,269 | u729173935 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
int a, b, x, y;
cin >> a >> b >> x >> y;
printf("%.12f", a * b / 2);
if (2 * x == a && 2 * y == b) {
cout << " " << 1 << endl;
} else {
cout << " " << 0 << endl;
}
} | #include <bits/stdc++.h>
using namespace std;
int main() {
double a, b, x, y;
cin >> a >> b >> x >> y;
printf("%.12f", a * b / 2);
if (2 * x == a && 2 * y == b) {
cout << " " << 1 << endl;
} else {
cout << " " << 0 << endl;
}
}
| [
"variable_declaration.type.primitive.change"
] | 815,270 | 815,271 | u488207046 | cpp |
p03001 | #include <algorithm>
#include <climits>
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <fstream>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
#define MOD (1000000007)
using namespace std;
typedef long long int Int;
constexpr Int TEN(int n) { return n == 0 ? 1 : 10 * TEN(n - 1); }
int W, H, x, y;
int main(void) {
cin >> W >> H >> x >> y;
double area;
area = (1.0 * W * 1.0 * H) / 2.0;
if (x == W / 2 && y == H / 2) {
cout << area << " " << 1 << endl;
} else {
cout << area << " " << 0 << endl;
}
return 0;
}
| #include <algorithm>
#include <climits>
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <fstream>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
#define MOD (1000000007)
using namespace std;
typedef long long int Int;
constexpr Int TEN(int n) { return n == 0 ? 1 : 10 * TEN(n - 1); }
double W, H, x, y;
int main(void) {
cin >> W >> H >> x >> y;
double area;
area = (1.0 * W * 1.0 * H) / 2.0;
if (x == W / 2 && y == H / 2) {
cout << area << " " << 1 << endl;
} else {
cout << area << " " << 0 << endl;
}
return 0;
}
| [
"variable_declaration.type.primitive.change"
] | 815,280 | 815,281 | u498141549 | cpp |
p03001 | #include <bits/stdc++.h>
#define rep(i, n) for (int(i) = 0; (i) < (n); (i)++)
using namespace std;
int main() {
int w, h;
cin >> w >> h;
{
cout << fixed << setprecision(6);
double sq = w * h / 2;
cout << sq;
cout << " ";
}
int y, x;
cin >> x >> y;
if (x == w / 2 && y == h / 2) {
cout << 1 << endl;
} else {
cout << 0 << endl;
}
return 0;
} | #include <bits/stdc++.h>
#define rep(i, n) for (int(i) = 0; (i) < (n); (i)++)
using namespace std;
int main() {
double w, h;
cin >> w >> h;
{
cout << fixed << setprecision(6);
double sq = w * h / 2;
cout << sq;
cout << " ";
}
int y, x;
cin >> x >> y;
if (x == w / 2 && y == h / 2) {
cout << 1 << endl;
} else {
cout << 0 << endl;
}
return 0;
} | [
"variable_declaration.type.primitive.change"
] | 815,286 | 815,287 | u264405855 | cpp |
p03001 | #include <bits/stdc++.h>
#define rep(i, n) for (int(i) = 0; (i) < (n); (i)++)
using namespace std;
int main() {
int w, h;
cin >> w >> h;
{
cout << fixed << setprecision(20);
double sq = w * h / 2;
cout << sq;
cout << " ";
}
int y, x;
cin >> x >> y;
if (x == w / 2 && y == h / 2) {
cout << 1 << endl;
} else {
cout << 0 << endl;
}
return 0;
} | #include <bits/stdc++.h>
#define rep(i, n) for (int(i) = 0; (i) < (n); (i)++)
using namespace std;
int main() {
double w, h;
cin >> w >> h;
{
cout << fixed << setprecision(6);
double sq = w * h / 2;
cout << sq;
cout << " ";
}
int y, x;
cin >> x >> y;
if (x == w / 2 && y == h / 2) {
cout << 1 << endl;
} else {
cout << 0 << endl;
}
return 0;
} | [
"variable_declaration.type.primitive.change",
"literal.number.change",
"io.output.change"
] | 815,288 | 815,287 | u264405855 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
cout << (double)(w * h / 2) << " "
<< ((w % 2 == 0 and w / 2 == x) and (h % 2 == 0 and h / 2 == y) ? 1 : 0)
<< "\n";
} | #include <bits/stdc++.h>
using namespace std;
int main() {
long long w, h, x, y;
cin >> w >> h >> x >> y;
cout << (double)(w * h / 2.0) << " "
<< ((w % 2 == 0 and w / 2 == x) and (h % 2 == 0 and h / 2 == y) ? 1 : 0)
<< "\n";
} | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change",
"literal.number.change",
"io.output.change"
] | 815,304 | 815,303 | u672611103 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
cout << (double)(w * h / 2) << " "
<< ((w % 2 == 0 and w / 2 == x) and (h % 2 == 0 and h / 2 == y) ? 1 : 0)
<< "\n";
} | #include <bits/stdc++.h>
using namespace std;
int main() {
long long w, h, x, y;
cin >> w >> h >> x >> y;
cout << (long double)(w * h / 2.0) << " "
<< ((w % 2 == 0 and w / 2 == x) and (h % 2 == 0 and h / 2 == y) ? 1 : 0)
<< "\n";
} | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change",
"literal.number.change",
"io.output.change"
] | 815,304 | 815,305 | u672611103 | cpp |
p03001 | // url:
// problem name:
#include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < (n); ++i)
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
using namespace std;
using ll = long long;
using P = pair<int, int>;
using Pl = pair<long long, long long>;
using veci = vector<int>;
using vecl = vector<long>;
using vecveci = vector<vector<int>>;
using vecvecl = vector<vector<long long>>;
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
double ans1 = W * H / 2;
int ans2 = 0;
if (2 * x == W && 2 * y == H)
ans2 = 1;
printf("%.10f", ans1);
cout << " " << ans2 << endl;
} | // url:
// problem name:
#include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < (n); ++i)
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
using namespace std;
using ll = long long;
using P = pair<int, int>;
using Pl = pair<long long, long long>;
using veci = vector<int>;
using vecl = vector<long>;
using vecveci = vector<vector<int>>;
using vecvecl = vector<vector<long long>>;
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
double ans1 = (double)(W * H) / 2;
int ans2 = 0;
if (2 * x == W && 2 * y == H)
ans2 = 1;
printf("%.10f", ans1);
cout << " " << ans2 << endl;
} | [
"type_conversion.add"
] | 815,306 | 815,307 | u446371873 | cpp |
p03001 | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); i++)
#define rep2(i, x, n) for (int i = x; i < (n); i++)
#define ALL(n) begin(n), end(n)
using namespace std;
using ll = long long;
int main() {
int w, h, x, y;
float area;
cin >> w >> h >> x >> y;
int ans = 0;
if (x == w / 2 && y == h / 2)
ans = 1;
cout << fixed << setprecision(10);
cout << (w * h) / 2 << " " << ans << endl;
return 0;
} | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); i++)
#define rep2(i, x, n) for (int i = x; i < (n); i++)
#define ALL(n) begin(n), end(n)
using namespace std;
using ll = long long;
int main() {
double w, h, x, y;
cin >> w >> h >> x >> y;
int ans = 0;
if (x == w / 2 && y == h / 2)
ans = 1;
cout << fixed << setprecision(10);
cout << (w * h) / 2 << " " << ans << endl;
return 0;
} | [
"variable_declaration.type.primitive.change",
"variable_declaration.remove"
] | 815,327 | 815,328 | u058958514 | cpp |
p03001 | #include <bits/stdc++.h>
#define rep(i, n) for (int(i) = 0; (i) < (n); (i)++)
#define rep2(i, a, n) for (int i = a; i < n; i++)
#define been(ix) (ix).begin(), (ix).end()
using namespace std;
typedef long long ll;
typedef vector<int> vi;
typedef vector<long long> vl;
const ll INFL = 1e18;
const int INF = 1001001001;
typedef pair<int, int> P;
#define foreach(ix, i) for (auto &(ix) : (i))
typedef long double ld;
const int mod = 1000000007;
int main() {
std::cout << std::fixed << std::setprecision(10);
int n, k, x, y;
cin >> n >> k >> x >> y;
ld ans = ((ld)n * (ld)k) / 2;
cout << ans << " ";
if (n / 2 == x && k / 2 == y)
cout << 1 << endl;
else
cout << 0 << endl;
}
| #include <bits/stdc++.h>
#define rep(i, n) for (int(i) = 0; (i) < (n); (i)++)
#define rep2(i, a, n) for (int i = a; i < n; i++)
#define been(ix) (ix).begin(), (ix).end()
using namespace std;
typedef long long ll;
typedef vector<int> vi;
typedef vector<long long> vl;
const ll INFL = 1e18;
const int INF = 1001001001;
typedef pair<int, int> P;
#define foreach(ix, i) for (auto &(ix) : (i))
typedef long double ld;
const int mod = 1000000007;
int main() {
std::cout << std::fixed << std::setprecision(10);
double n, k, x, y;
cin >> n >> k >> x >> y;
ld ans = ((ld)n * (ld)k) / 2;
cout << ans << " ";
if (n / 2 == x && k / 2 == y)
cout << 1 << endl;
else
cout << 0 << endl;
}
| [
"variable_declaration.type.primitive.change"
] | 815,335 | 815,336 | u495881622 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ios::sync_with_stdio(0);
cin.tie(0);
ll w, h, x, y;
cin >> w >> h >> x >> y;
double tot = w * h / 2;
cout << tot << " ";
if (x * 2 == w && y * 2 == h)
cout << 1;
else
cout << 0;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ios::sync_with_stdio(0);
cin.tie(0);
ll w, h, x, y;
cin >> w >> h >> x >> y;
double tot = w * h;
tot /= 2;
cout << tot << " ";
if (x * 2 == w && y * 2 == h)
cout << 1;
else
cout << 0;
return 0;
} | [
"expression.operation.binary.change",
"assignment.change"
] | 815,344 | 815,345 | u859436937 | cpp |
p03001 | #include <algorithm>
#include <cmath>
#include <cstdlib>
#include <iomanip>
#include <iostream>
#include <map>
#include <numeric>
#include <string>
#include <utility>
#include <vector>
using namespace std;
using ll = long long;
int main() {
long double W, H;
long double x, y;
cin >> W >> H >> x >> y;
W / 2 == x &&H / 2 == y
? cout << fixed << setprecision(9) << W * H / 2 << " " << 1
: cout << W * H / 2 << " " << 1;
}
| #include <algorithm>
#include <cmath>
#include <cstdlib>
#include <iomanip>
#include <iostream>
#include <map>
#include <numeric>
#include <string>
#include <utility>
#include <vector>
using namespace std;
using ll = long long;
int main() {
long double W, H;
long double x, y;
cin >> W >> H >> x >> y;
W / 2 == x &&H / 2 == y
? cout << fixed << setprecision(9) << W * H / 2 << " " << 1
: cout << W * H / 2 << " " << 0;
} | [
"literal.number.change",
"expression.operation.binary.change"
] | 815,346 | 815,347 | u272628953 | cpp |
p03001 | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)n; i++)
#define rep1(i, n) for (int i = 1; i <= (int)n; i++)
#define rep2(i, j, n) for (int j = i; j < n; j++)
#define rep3(i, j, n) for (int j = i; j <= n; j++)
#define rrep(i, n) for (int i = n - 1; i >= 0; i--)
#define sp(n) cout << fixed << setprecision(n)
typedef long long ll;
using namespace std;
int main(void) {
ll w, h, x, y;
cin >> w >> h >> x >> y;
double res = w * h / 2;
int jud = x * 2 == w && y * 2 == h ? 1 : 0;
cout << res << " " << jud << endl;
}
| #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)n; i++)
#define rep1(i, n) for (int i = 1; i <= (int)n; i++)
#define rep2(i, j, n) for (int j = i; j < n; j++)
#define rep3(i, j, n) for (int j = i; j <= n; j++)
#define rrep(i, n) for (int i = n - 1; i >= 0; i--)
#define sp(n) cout << fixed << setprecision(n)
typedef long long ll;
using namespace std;
int main(void) {
ll w, h, x, y;
cin >> w >> h >> x >> y;
double res = (double)(w * h) / 2;
int jud = x * 2 == w && y * 2 == h ? 1 : 0;
cout << res << " " << jud << endl;
}
| [
"type_conversion.add"
] | 815,348 | 815,349 | u222866518 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); i++)
typedef long long ll;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
double f = (double)w * h / 2;
int cnt = 1;
if (w % 2 != 0 || h % 2 != 0) {
cnt = 0;
} else {
if (x != w / 2 && y != h / 2)
cnt = 0;
}
printf("%.9f %d", f, cnt);
} | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); i++)
typedef long long ll;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
double f = (double)w * h / 2;
int cnt = 1;
if (w % 2 != 0 || h % 2 != 0) {
cnt = 0;
} else {
if (x != w / 2 || y != h / 2)
cnt = 0;
}
printf("%.9f %d", f, cnt);
} | [
"misc.opposites",
"control_flow.branch.if.condition.change"
] | 815,350 | 815,351 | u726957641 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); i++)
typedef long long ll;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
ll f = w * h / 2;
int cnt = 1;
if (w % 2 != 0 || h % 2 != 0) {
cnt = 0;
} else {
if (x != w / 2 || y != h / 2)
cnt = 0;
}
printf("%.9f %d", f, cnt);
} | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); i++)
typedef long long ll;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
double f = (double)w * h / 2;
int cnt = 1;
if (w % 2 != 0 || h % 2 != 0) {
cnt = 0;
} else {
if (x != w / 2 || y != h / 2)
cnt = 0;
}
printf("%.9f %d", f, cnt);
} | [
"variable_declaration.type.change"
] | 815,352 | 815,351 | u726957641 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); i++)
typedef long long ll;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
ll f = w * h / 2;
int cnt = 1;
if (w % 2 != 0 || h % 2 != 0) {
cnt = 0;
} else {
if (x != w / 2 && y != h / 2)
cnt = 0;
}
printf("%.9f %d", f, cnt);
} | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); i++)
typedef long long ll;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
double f = (double)w * h / 2;
int cnt = 1;
if (w % 2 != 0 || h % 2 != 0) {
cnt = 0;
} else {
if (x != w / 2 || y != h / 2)
cnt = 0;
}
printf("%.9f %d", f, cnt);
} | [
"variable_declaration.type.change",
"misc.opposites",
"control_flow.branch.if.condition.change"
] | 815,353 | 815,351 | u726957641 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < n; i++)
#define rep1(i, n) for (int i = 1; i < n + 1; i++)
#define sort(A) sort(A.begin(), A.end())
#define reverse(A) reverse(A.begin(), A.end());
#define vecmin(A) *min_element(A.begin(), A.end());
#define vecmax(A) *max_element(A.begin(), A.end());
typedef long long ll;
int main() {
int w, h;
cin >> w >> h;
int x, y;
cin >> x >> y;
float ans = (float)w * h / 2;
cout << ans << " ";
if (x == w / 2 && y == h / 2)
cout << 1 << endl;
else
cout << 0 << endl;
} | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < n; i++)
#define rep1(i, n) for (int i = 1; i < n + 1; i++)
#define sort(A) sort(A.begin(), A.end())
#define reverse(A) reverse(A.begin(), A.end());
#define vecmin(A) *min_element(A.begin(), A.end());
#define vecmax(A) *max_element(A.begin(), A.end());
typedef long long ll;
int main() {
double w, h;
cin >> w >> h;
double x, y;
cin >> x >> y;
double ans = (w * h) / 2;
cout << ans << " ";
if (x == w / 2 && y == h / 2)
cout << 1 << endl;
else
cout << 0 << endl;
} | [
"variable_declaration.type.primitive.change"
] | 815,354 | 815,355 | u132364782 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
using vi = vector<int>; // intの1次元の型に vi という別名をつける
using vvi = vector<vi>; // intの2次元の型に vvi という別名をつける
using vvvi = vector<vvi>;
using ll = long long; // long longをllだけにした
using vll = vector<ll>;
using vvll = vector<vll>;
using vvvll = vector<vvll>;
using vb = vector<bool>;
using vvb = vector<vb>;
using mii = map<int, int>;
long long divup(long long a, long long b);
long long kaijou(long long i);
long long P(long long n, long long k);
long long C(long long n, long long k);
long long GCD(long long a, long long b);
long long LCM(long long a, long long b);
bool prime(long long N);
double distance(vector<long long> p, vector<long long> q, long long n);
void press(vector<long long> &v);
void ranking(vector<long long> &v);
void erase(vector<long long> &v, long long i);
void unique(vector<long long> &v);
void printv(vector<long long> v);
//端数繰りあがり割り算(検証済)
// a÷bの端数繰り上げ
// b!=0のデバグはしてないので分母に0を入れないように
//負数対応
long long divup(long long a, long long b) {
long long x = abs(a);
long long y = abs(b);
long long z = (x + y - 1) / y;
if (b * a < 0)
return -z;
else
return z;
}
//階乗
//検証済み
long long kaijou(long long i) {
if (i == 0)
return 1;
long long j = 1;
for (long long k = 1; k <= i; k++) {
j *= k;
}
return j;
}
//順列nPk(完成)
// n個の異なる要素から、取り出す順序を区別してk個取り出す場合の数
// n<kなら0を返す
//敢えて負数時のデバグはしてない
long long P(long long n, long long k) {
if (n < k)
return 0;
long long y = 1;
for (long long i = 0; i < k; i++) {
y *= (n - i);
}
return y;
}
//組み合わせnCk(検証済み)
// P,kaijouと併用
long long C(long long n, long long k) {
if (n < k)
return 0;
return P(n, k) / kaijou(k);
}
// nHk
//区別しないn個の要素を、区別するk個のグループに分ける
// 0個のグループがあっ
//て良い
// C必須
//最大公約数GCD,最小公倍数LCM
// LCMを使うときはGCDをセットで
//検証済み
long long GCD(long long a, long long b) {
if (a < b)
swap(a, b);
long long d = a % b;
if (d == 0) {
return b;
}
return GCD(b, d);
}
long long LCM(long long a, long long b) { return (a / GCD(a, b)) * b; }
//素数判定
//素数ならばtrue、素数以外の整数にはfalse
//負数は全てfalse
//検証済み
bool prime(long long N) {
if (N == 1) {
return false;
}
if (N < 0)
return false;
long long p = sqrt(N);
for (long long i = 2; i <= p; i++) {
if (N % i == 0) {
return false;
}
}
return true;
}
//ユークリッド距離
//検証済み
//位置ベクトル1,位置ベクトル2,ベクトルの次元(2または3が一般的)
double distance(vector<long long> p, vector<long long> q, long long n) {
double x = 0;
for (long long i = 0; i < n; i++) {
x += pow((p.at(i) - q.at(i)), 2);
}
return sqrt(x);
}
//配列圧縮(検証済)
//{1,36,1,3,8,-2,-92}を
//{2, 5,2,3,4, 1, 0}にする
void press(vector<long long> &v) {
long long n = v.size();
vector<long long> w(n);
map<long long, long long> m;
for (auto &p : v) {
m[p] = 0;
}
long long i = 0;
for (auto &p : m) {
p.second = i;
i++;
}
for (long long i = 0; i < n; i++) {
w.at(i) = m[v.at(i)];
}
v = w;
return;
}
//配列のi番目の要素がj番目に小さいとき、j番目の数がiであるベクトルを返す関数
//配列の要素が全て異なるときにしか正常に動作しない
//配列の要素に同じものが含まれても見かけ上動作はするが意味のない値を戻し、
//エラーも起きないので注意
//検証済
//{2,4,1,6,0,3,8,9,5}を
//{4,2,0,5,1,8,3,6,7}にして返す
//"rank"という名前にするとSTLの関数(配列の次元を返す関数)になるので注意
void ranking(vector<long long> &v) {
long long n = v.size();
map<long long, long long> m;
long long i;
for (i = 0; i < n; i++) {
m[v.at(i)] = i;
}
vector<long long> w(n);
i = 0;
for (auto &p : m) {
v.at(i) = p.second;
i++;
}
return;
}
//部分削除(未検証)
//ベクトルのi番目(i=0,1,2,...,n-1)の要素を削除し、
//以降の要素を全て前に1ずらして参照返し
//ベクトル長は1小さくなって返る
// i>n-1の時は変化しない
void erase(vector<long long> &v, long long i) {
long long n = v.size();
if (i > n - 1)
return;
for (long long j = i; j < n - 1; j++) {
v.at(j) = v.at(j + 1);
}
v.pop_back();
return;
}
//重複削除(未完成)
//引数ベクトルに同一要素が複数あるとき、先頭を残し他は削除
//参照返し
//ベクトル長も変化する
// O(logn)くらい
void unique(vector<long long> &v) {
long long n = v.size();
set<long long> s;
long long i = 0;
while (i < n) {
if (s.count(v.at(i))) {
erase(v, i);
n--;
} else {
s.insert(v.at(i));
i++;
}
}
return;
}
//ベクトルの出力(検証済)
// debug用にvectorの中身を出力する
void printv(vector<long long> v) {
cout << "{ ";
for (auto &p : v) {
cout << p << ",";
}
cout << "}" << endl;
}
int main() {
// cout << std:://3.141; // "3.1"
double w, h, x, y;
cin >> w >> h >> x >> y;
double s = w * h / 2;
cout << setprecision(2) << s << " ";
if (x * 2 == w && y * 2 == h)
cout << 1;
else
cout << 0;
}
| #include <bits/stdc++.h>
using namespace std;
using vi = vector<int>; // intの1次元の型に vi という別名をつける
using vvi = vector<vi>; // intの2次元の型に vvi という別名をつける
using vvvi = vector<vvi>;
using ll = long long; // long longをllだけにした
using vll = vector<ll>;
using vvll = vector<vll>;
using vvvll = vector<vvll>;
using vb = vector<bool>;
using vvb = vector<vb>;
using mii = map<int, int>;
long long divup(long long a, long long b);
long long kaijou(long long i);
long long P(long long n, long long k);
long long C(long long n, long long k);
long long GCD(long long a, long long b);
long long LCM(long long a, long long b);
bool prime(long long N);
double distance(vector<long long> p, vector<long long> q, long long n);
void press(vector<long long> &v);
void ranking(vector<long long> &v);
void erase(vector<long long> &v, long long i);
void unique(vector<long long> &v);
void printv(vector<long long> v);
//端数繰りあがり割り算(検証済)
// a÷bの端数繰り上げ
// b!=0のデバグはしてないので分母に0を入れないように
//負数対応
long long divup(long long a, long long b) {
long long x = abs(a);
long long y = abs(b);
long long z = (x + y - 1) / y;
if (b * a < 0)
return -z;
else
return z;
}
//階乗
//検証済み
long long kaijou(long long i) {
if (i == 0)
return 1;
long long j = 1;
for (long long k = 1; k <= i; k++) {
j *= k;
}
return j;
}
//順列nPk(完成)
// n個の異なる要素から、取り出す順序を区別してk個取り出す場合の数
// n<kなら0を返す
//敢えて負数時のデバグはしてない
long long P(long long n, long long k) {
if (n < k)
return 0;
long long y = 1;
for (long long i = 0; i < k; i++) {
y *= (n - i);
}
return y;
}
//組み合わせnCk(検証済み)
// P,kaijouと併用
long long C(long long n, long long k) {
if (n < k)
return 0;
return P(n, k) / kaijou(k);
}
// nHk
//区別しないn個の要素を、区別するk個のグループに分ける
// 0個のグループがあっ
//て良い
// C必須
//最大公約数GCD,最小公倍数LCM
// LCMを使うときはGCDをセットで
//検証済み
long long GCD(long long a, long long b) {
if (a < b)
swap(a, b);
long long d = a % b;
if (d == 0) {
return b;
}
return GCD(b, d);
}
long long LCM(long long a, long long b) { return (a / GCD(a, b)) * b; }
//素数判定
//素数ならばtrue、素数以外の整数にはfalse
//負数は全てfalse
//検証済み
bool prime(long long N) {
if (N == 1) {
return false;
}
if (N < 0)
return false;
long long p = sqrt(N);
for (long long i = 2; i <= p; i++) {
if (N % i == 0) {
return false;
}
}
return true;
}
//ユークリッド距離
//検証済み
//位置ベクトル1,位置ベクトル2,ベクトルの次元(2または3が一般的)
double distance(vector<long long> p, vector<long long> q, long long n) {
double x = 0;
for (long long i = 0; i < n; i++) {
x += pow((p.at(i) - q.at(i)), 2);
}
return sqrt(x);
}
//配列圧縮(検証済)
//{1,36,1,3,8,-2,-92}を
//{2, 5,2,3,4, 1, 0}にする
void press(vector<long long> &v) {
long long n = v.size();
vector<long long> w(n);
map<long long, long long> m;
for (auto &p : v) {
m[p] = 0;
}
long long i = 0;
for (auto &p : m) {
p.second = i;
i++;
}
for (long long i = 0; i < n; i++) {
w.at(i) = m[v.at(i)];
}
v = w;
return;
}
//配列のi番目の要素がj番目に小さいとき、j番目の数がiであるベクトルを返す関数
//配列の要素が全て異なるときにしか正常に動作しない
//配列の要素に同じものが含まれても見かけ上動作はするが意味のない値を戻し、
//エラーも起きないので注意
//検証済
//{2,4,1,6,0,3,8,9,5}を
//{4,2,0,5,1,8,3,6,7}にして返す
//"rank"という名前にするとSTLの関数(配列の次元を返す関数)になるので注意
void ranking(vector<long long> &v) {
long long n = v.size();
map<long long, long long> m;
long long i;
for (i = 0; i < n; i++) {
m[v.at(i)] = i;
}
vector<long long> w(n);
i = 0;
for (auto &p : m) {
v.at(i) = p.second;
i++;
}
return;
}
//部分削除(未検証)
//ベクトルのi番目(i=0,1,2,...,n-1)の要素を削除し、
//以降の要素を全て前に1ずらして参照返し
//ベクトル長は1小さくなって返る
// i>n-1の時は変化しない
void erase(vector<long long> &v, long long i) {
long long n = v.size();
if (i > n - 1)
return;
for (long long j = i; j < n - 1; j++) {
v.at(j) = v.at(j + 1);
}
v.pop_back();
return;
}
//重複削除(未完成)
//引数ベクトルに同一要素が複数あるとき、先頭を残し他は削除
//参照返し
//ベクトル長も変化する
// O(logn)くらい
void unique(vector<long long> &v) {
long long n = v.size();
set<long long> s;
long long i = 0;
while (i < n) {
if (s.count(v.at(i))) {
erase(v, i);
n--;
} else {
s.insert(v.at(i));
i++;
}
}
return;
}
//ベクトルの出力(検証済)
// debug用にvectorの中身を出力する
void printv(vector<long long> v) {
cout << "{ ";
for (auto &p : v) {
cout << p << ",";
}
cout << "}" << endl;
}
int main() {
// cout << std:://3.141; // "3.1"
cout << fixed;
double w, h, x, y;
cin >> w >> h >> x >> y;
double s = w * h / 2;
cout << setprecision(18) << s << " ";
if (x * 2 == w && y * 2 == h)
cout << 1;
else
cout << 0;
}
| [
"literal.number.change",
"io.output.change"
] | 815,368 | 815,369 | u513211419 | cpp |
p03001 | #define _CRT_SECURE_NO_WARNINGS
#define _USE_MATH_DEFINES
#pragma warning(disable : 4996)
#include <algorithm>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <functional>
#include <iomanip>
#include <iostream>
#include <list>
#include <map>
#include <math.h>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include <stdio.h>
#include <stdlib.h>
#include <string>
#include <vector>
#define rep(i, n) for (int i = 0; i < (n); ++i)
using namespace std;
typedef long long ll;
const double PI = 3.14159265358979323846;
const int MAX = 1e7;
const int MOD = 1e9 + 7;
int main(int argc, char *args[]) {
int w, h, x, y;
cin >> w >> h >> x >> y;
double ans = w * h / 2;
int num = 0;
if (w == x * 2 && h == y * 2)
num = 1;
printf("%.10f %d\n", ans, num);
return 0;
} | #define _CRT_SECURE_NO_WARNINGS
#define _USE_MATH_DEFINES
#pragma warning(disable : 4996)
#include <algorithm>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <functional>
#include <iomanip>
#include <iostream>
#include <list>
#include <map>
#include <math.h>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include <stdio.h>
#include <stdlib.h>
#include <string>
#include <vector>
#define rep(i, n) for (int i = 0; i < (n); ++i)
using namespace std;
typedef long long ll;
const double PI = 3.14159265358979323846;
const int MAX = 1e7;
const int MOD = 1e9 + 7;
int main(int argc, char *args[]) {
int w, h, x, y;
cin >> w >> h >> x >> y;
double ans = (double)w * h / 2;
int num = 0;
if (w == x * 2 && h == y * 2)
num = 1;
printf("%.10f %d\n", ans, num);
return 0;
} | [
"type_conversion.add"
] | 815,372 | 815,373 | u455067221 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
#define ll long long int
#define vi vector<int>
#define prec fixed << setprecision(10)
#define mod 1000000007
#define set(x) __builtin_popcount(x)
#define ffs(x) __builtin_ffs(x)
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
cout << prec << w * h / 2;
if (w == 2 * x && h == 2 * y)
cout << ' ' << 1;
else
cout << ' ' << 0;
}
| #include <bits/stdc++.h>
using namespace std;
#define ll long long int
#define vi vector<int>
#define prec fixed << setprecision(15)
#define mod 1000000007
#define set(x) __builtin_popcount(x)
#define ffs(x) __builtin_ffs(x)
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
cout << prec << (double)w * h / 2;
if (w == 2 * x && h == 2 * y)
cout << ' ' << 1;
else
cout << ' ' << 0;
}
| [
"preprocessor.define.value.change",
"literal.integer.change"
] | 815,381 | 815,382 | u232462132 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
#define ll long long int
#define vi vector<int>
#define prec fixed << setprecision(10)
#define mod 1000000007
#define set(x) __builtin_popcount(x)
#define ffs(x) __builtin_ffs(x)
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
cout << prec << w * h / 2;
if (w == 2 * x && h == 2 * y)
cout << ' ' << 1;
else
cout << ' ' << 0;
}
| #include <bits/stdc++.h>
using namespace std;
#define ll long long int
#define vi vector<int>
#define prec fixed << setprecision(15)
#define mod 1000000007
#define set(x) __builtin_popcount(x)
#define ffs(x) __builtin_ffs(x)
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
cout << prec << (double)w * h / 2;
if (w == 2 * x && h == 2 * y)
cout << ' ' << 1;
else
cout << ' ' << 0;
}
| [
"preprocessor.define.value.change",
"literal.integer.change",
"variable_declaration.type.change"
] | 815,383 | 815,382 | u232462132 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
long long w, h, x, y;
cin >> w >> h >> x >> y;
cout << fixed << setprecision(12) << w * h / 2 << " "
<< (w == x * 2 && h == y * 2 ? 1 : 0) << endl;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
double w, h, x, y;
cin >> w >> h >> x >> y;
cout << fixed << setprecision(12) << w * h / 2 << " "
<< (w == x * 2 && h == y * 2 ? 1 : 0) << endl;
return 0;
}
| [
"variable_declaration.type.primitive.change",
"variable_declaration.type.narrow.change"
] | 815,387 | 815,388 | u587366956 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
long long w, h, x, y;
cin >> w >> h >> x >> y;
cout << fixed << setprecision(12) << w * h / 2 << " "
<< (w == x * 2 && h == y * 2 ? 1 : 0) << endl;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
long long w, h, x, y;
cin >> w >> h >> x >> y;
cout << fixed << setprecision(12) << w * h / 2.0 << " "
<< (w == x * 2 && h == y * 2 ? 1 : 0) << endl;
return 0;
}
| [
"literal.number.change",
"io.output.change"
] | 815,387 | 815,389 | u587366956 | cpp |
p03001 | #pragma region include
#include <algorithm>
#include <bitset>
#include <cmath>
#include <cstdlib>
#include <iostream>
#include <map>
#include <set>
#include <stdio.h>
#include <string>
#include <tuple>
#include <vector>
#pragma endregion
using namespace std;
#pragma region 定数
#define INF_VAL (2147483647 - 1)
#define INF_VAL_MINUS -INFVAL
#pragma endregion
#pragma region マクロ
// 型
#define ll long long
// 配列の長さを取得する(ただし関数内ではポインタサイズに注意)
#define SIZE_OF_ARRAY(array) sizeof(array) / sizeof(*array)
// for文
#define forn(i, size) for (long long(i) = 0; (i) < (size); (i)++)
#define for0(size) for (long(i) = 0; (i) < (size); (i)++)
// ソート
#define Sort(array, length) sort(array, array + length)
#define SortDESC(array, length, type_name) \
sort(array, array + length, std::greater<type_name>())
// 配列の最大値、最小値取得
#define MAX_OF_ARRAY(array, length) *max_element(array, array + length)
#define MIN_OF_ARRAY(array, length) *min_element(array, array + length)
// 結果出力系
#define YES \
{ \
cout << "YES" << endl; \
return 0; \
}
#define NO \
{ \
cout << "NO" << endl; \
return 0; \
}
#define Yes \
{ \
cout << "Yes" << endl; \
return 0; \
}
#define No \
{ \
cout << "No" << endl; \
return 0; \
}
#define println(str) cout << str << endl;
#define print(str) cout << str;
#pragma endregion
#pragma region Utility
#pragma region 最大公約数
ll gcd(ll a, ll b) {
if (a % b == 0) {
return (b);
} else {
return (gcd(b, a % b));
}
}
#pragma endregion
#pragma region 最小公倍数
ll lcm(ll a, ll b) { return a * b / gcd(a, b); }
#pragma endregion
#pragma region 配列要素の合計値を取得
template <typename T> T getSum(T array[], int length) {
T sum = 0;
for (int i = 0; i < length; i++) {
sum += array[i];
}
return sum;
}
#pragma endregion
#pragma region ToString(int)
string ToString(int i) {
char buffer[1000];
sprintf(buffer, "%d", i);
return string(buffer);
}
#pragma endregion
#pragma region 10進数からN進数(<= 10) へ変換
string convertToN(long n, int base) {
string ans = "";
while (n != 0) {
int temp = n % base; // 1桁取得
ans = ToString(temp) + ans;
n /= base;
}
return ans;
}
#pragma endregion
#pragma region 連想配列のkeyが存在するか
template <typename T> bool containsKey(map<string, T> map, string key) {
if (map.count(key) == 0) {
return false;
}
return true;
}
#pragma endregion
#pragma region 素数判定
bool isPrime(ll num) {
if (num <= 1) {
return false;
}
for (int i = 2; i < num / 2 + 1; i++) {
if (num % i == 0) {
return false;
}
}
return true;
}
#pragma endregion
#pragma region 二分探索
bool question(ll middle) {
// 問題に応じて書き換えること
// int N_length = ToString(middle).size();
// return A * middle + B * N_length <= X;
return false;
}
ll binarySearch(ll left, ll right) {
while (right - left > 1) {
ll middle = (right + left) / 2;
if (question(middle)) {
left = middle;
} else {
right = middle;
}
}
return left;
}
#pragma endregion
#pragma endregion
int main() {
// 標準入力から値を取得
ll W, H, x, y;
cin >> W >> H >> x >> y;
printf("%f ", (double)W * H / 2);
if (x == W / 2 && y == H / 2) {
println(1);
} else {
println(0);
}
}
| #pragma region include
#include <algorithm>
#include <bitset>
#include <cmath>
#include <cstdlib>
#include <iostream>
#include <map>
#include <set>
#include <stdio.h>
#include <string>
#include <tuple>
#include <vector>
#pragma endregion
using namespace std;
#pragma region 定数
#define INF_VAL (2147483647 - 1)
#define INF_VAL_MINUS -INFVAL
#pragma endregion
#pragma region マクロ
// 型
#define ll long long
// 配列の長さを取得する(ただし関数内ではポインタサイズに注意)
#define SIZE_OF_ARRAY(array) sizeof(array) / sizeof(*array)
// for文
#define forn(i, size) for (long long(i) = 0; (i) < (size); (i)++)
#define for0(size) for (long(i) = 0; (i) < (size); (i)++)
// ソート
#define Sort(array, length) sort(array, array + length)
#define SortDESC(array, length, type_name) \
sort(array, array + length, std::greater<type_name>())
// 配列の最大値、最小値取得
#define MAX_OF_ARRAY(array, length) *max_element(array, array + length)
#define MIN_OF_ARRAY(array, length) *min_element(array, array + length)
// 結果出力系
#define YES \
{ \
cout << "YES" << endl; \
return 0; \
}
#define NO \
{ \
cout << "NO" << endl; \
return 0; \
}
#define Yes \
{ \
cout << "Yes" << endl; \
return 0; \
}
#define No \
{ \
cout << "No" << endl; \
return 0; \
}
#define println(str) cout << str << endl;
#define print(str) cout << str;
#pragma endregion
#pragma region Utility
#pragma region 最大公約数
ll gcd(ll a, ll b) {
if (a % b == 0) {
return (b);
} else {
return (gcd(b, a % b));
}
}
#pragma endregion
#pragma region 最小公倍数
ll lcm(ll a, ll b) { return a * b / gcd(a, b); }
#pragma endregion
#pragma region 配列要素の合計値を取得
template <typename T> T getSum(T array[], int length) {
T sum = 0;
for (int i = 0; i < length; i++) {
sum += array[i];
}
return sum;
}
#pragma endregion
#pragma region ToString(int)
string ToString(int i) {
char buffer[1000];
sprintf(buffer, "%d", i);
return string(buffer);
}
#pragma endregion
#pragma region 10進数からN進数(<= 10) へ変換
string convertToN(long n, int base) {
string ans = "";
while (n != 0) {
int temp = n % base; // 1桁取得
ans = ToString(temp) + ans;
n /= base;
}
return ans;
}
#pragma endregion
#pragma region 連想配列のkeyが存在するか
template <typename T> bool containsKey(map<string, T> map, string key) {
if (map.count(key) == 0) {
return false;
}
return true;
}
#pragma endregion
#pragma region 素数判定
bool isPrime(ll num) {
if (num <= 1) {
return false;
}
for (int i = 2; i < num / 2 + 1; i++) {
if (num % i == 0) {
return false;
}
}
return true;
}
#pragma endregion
#pragma region 二分探索
bool question(ll middle) {
// 問題に応じて書き換えること
// int N_length = ToString(middle).size();
// return A * middle + B * N_length <= X;
return false;
}
ll binarySearch(ll left, ll right) {
while (right - left > 1) {
ll middle = (right + left) / 2;
if (question(middle)) {
left = middle;
} else {
right = middle;
}
}
return left;
}
#pragma endregion
#pragma endregion
int main() {
// 標準入力から値を取得
ll W, H, x, y;
cin >> W >> H >> x >> y;
printf("%f ", (double)W * H / 2);
if (x == (double)W / 2 && y == (double)H / 2) {
println(1);
} else {
println(0);
}
}
| [
"control_flow.branch.if.condition.change"
] | 815,415 | 815,416 | u550949279 | cpp |
p03001 | #define _USE_MATH_DEFINES
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define rep(i, n) for (int i = 0; i < (int)(n); ++i)
#define rep1(i, n) for (int i = 1; i < (int)(n); ++i)
#define repeq(i, n) for (int i = 0; i <= (int)(n); ++i)
#define rep1eq(i, n) for (int i = 1; i <= (int)(n); ++i)
#define rrep(i, n) for (int i = (int)(n)-1; i >= 0; --i)
#define rrep1(i, n) for (int i = (int)(n)-1; i > 0; --i)
#define rrepeq(i, n) for (int i = (int)(n); i >= 0; --i)
#define rrep1eq(i, n) for (int i = (int)(n); i > 0; --i)
#define ALL(a) (a).begin(), (a).end()
#define RALL(a) (a).rbegin(), (a).rend()
using ll = long long;
using vi = vector<int>;
using vl = vector<ll>;
using vb = vector<bool>;
template <typename T> using Graph = vector<vector<T>>;
template <typename T> using Spacial = vector<vector<vector<T>>>;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
const int MOD = 1e9 + 7;
const int MOD2 = 998244353;
const double EPS = 1e-9;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
template <typename T> struct is_pair : false_type {};
template <typename T1, typename T2> struct is_pair<pair<T1, T2>> : true_type {};
template <typename T> struct is_vector : false_type {};
template <typename T> struct is_vector<vector<T>> : true_type {};
template <typename T1, typename T2>
istream &operator>>(istream &istr, pair<T1, T2> &p) {
istr >> p.first >> p.second;
return istr;
}
template <typename T1, typename T2>
ostream &operator<<(ostream &ostr, const pair<T1, T2> &p) {
ostr << p.first << " " << p.second;
return ostr;
}
template <typename T> istream &operator>>(istream &istr, vector<T> &vec) {
for (auto itr = vec.begin(); itr != vec.end(); ++itr) {
istr >> *itr;
}
return istr;
}
template <typename T> ostream &operator<<(ostream &ostr, const vector<T> &vec) {
if (vec.empty())
return ostr;
bool vp = is_vector<T>() || is_pair<T>();
ostr << vec.front();
for (auto itr = ++vec.begin(); itr != vec.end(); ++itr) {
ostr << (vp ? "\n" : " ") << *itr;
}
return ostr;
}
template <typename T1, typename T2> inline bool chmax(T1 &a, T2 b) {
return a < b && (a = b, true);
}
template <typename T1, typename T2> inline bool chmin(T1 &a, T2 b) {
return a > b && (a = b, true);
}
int modpow(int a, long long n, int mod = MOD) {
int ret = 1;
do {
if (n & 1)
ret = 1LL * ret * a % mod;
a = 1LL * a * a % mod;
} while (n >>= 1);
return ret;
}
template <typename T> T GCD(T a, T b) { return b ? GCD(b, a % b) : a; }
template <typename T> T LCM(T a, T b) { return a / GCD(a, b) * b; }
template <typename T1, typename T2>
bool CompareBySecond(pair<T1, T2> a, pair<T1, T2> b) {
return a.second != b.second ? a.second < b.second : a.first < b.first;
}
template <typename T> bool CompareBySlope(pair<T, T> a, pair<T, T> b) {
// counterclockwise from 12 o'clock direction
if (a.first * b.first < 0)
return a.first < b.first;
if (a.first == 0)
return a.second >= 0 || b.first > 0;
if (b.first == 0)
return b.second < 0 && a.first < 0;
return a.second * b.first < a.first * b.second;
}
/* -------- <templates end> -------- */
void solve() {
int w, h, x, y;
cin >> w >> h >> x >> y;
long double area = w * h;
cout << pii(area / 2, (2 * x == w && 2 * y == h)) << endl;
}
/* -------- <programs end> -------- */
signed main() {
cin.tie(nullptr);
ios::sync_with_stdio(false);
cout << fixed << setprecision(12);
solve();
return 0;
}
| #define _USE_MATH_DEFINES
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define rep(i, n) for (int i = 0; i < (int)(n); ++i)
#define rep1(i, n) for (int i = 1; i < (int)(n); ++i)
#define repeq(i, n) for (int i = 0; i <= (int)(n); ++i)
#define rep1eq(i, n) for (int i = 1; i <= (int)(n); ++i)
#define rrep(i, n) for (int i = (int)(n)-1; i >= 0; --i)
#define rrep1(i, n) for (int i = (int)(n)-1; i > 0; --i)
#define rrepeq(i, n) for (int i = (int)(n); i >= 0; --i)
#define rrep1eq(i, n) for (int i = (int)(n); i > 0; --i)
#define ALL(a) (a).begin(), (a).end()
#define RALL(a) (a).rbegin(), (a).rend()
using ll = long long;
using vi = vector<int>;
using vl = vector<ll>;
using vb = vector<bool>;
template <typename T> using Graph = vector<vector<T>>;
template <typename T> using Spacial = vector<vector<vector<T>>>;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
const int MOD = 1e9 + 7;
const int MOD2 = 998244353;
const double EPS = 1e-9;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
template <typename T> struct is_pair : false_type {};
template <typename T1, typename T2> struct is_pair<pair<T1, T2>> : true_type {};
template <typename T> struct is_vector : false_type {};
template <typename T> struct is_vector<vector<T>> : true_type {};
template <typename T1, typename T2>
istream &operator>>(istream &istr, pair<T1, T2> &p) {
istr >> p.first >> p.second;
return istr;
}
template <typename T1, typename T2>
ostream &operator<<(ostream &ostr, const pair<T1, T2> &p) {
ostr << p.first << " " << p.second;
return ostr;
}
template <typename T> istream &operator>>(istream &istr, vector<T> &vec) {
for (auto itr = vec.begin(); itr != vec.end(); ++itr) {
istr >> *itr;
}
return istr;
}
template <typename T> ostream &operator<<(ostream &ostr, const vector<T> &vec) {
if (vec.empty())
return ostr;
bool vp = is_vector<T>() || is_pair<T>();
ostr << vec.front();
for (auto itr = ++vec.begin(); itr != vec.end(); ++itr) {
ostr << (vp ? "\n" : " ") << *itr;
}
return ostr;
}
template <typename T1, typename T2> inline bool chmax(T1 &a, T2 b) {
return a < b && (a = b, true);
}
template <typename T1, typename T2> inline bool chmin(T1 &a, T2 b) {
return a > b && (a = b, true);
}
int modpow(int a, long long n, int mod = MOD) {
int ret = 1;
do {
if (n & 1)
ret = 1LL * ret * a % mod;
a = 1LL * a * a % mod;
} while (n >>= 1);
return ret;
}
template <typename T> T GCD(T a, T b) { return b ? GCD(b, a % b) : a; }
template <typename T> T LCM(T a, T b) { return a / GCD(a, b) * b; }
template <typename T1, typename T2>
bool CompareBySecond(pair<T1, T2> a, pair<T1, T2> b) {
return a.second != b.second ? a.second < b.second : a.first < b.first;
}
template <typename T> bool CompareBySlope(pair<T, T> a, pair<T, T> b) {
// counterclockwise from 12 o'clock direction
if (a.first * b.first < 0)
return a.first < b.first;
if (a.first == 0)
return a.second >= 0 || b.first > 0;
if (b.first == 0)
return b.second < 0 && a.first < 0;
return a.second * b.first < a.first * b.second;
}
/* -------- <templates end> -------- */
void solve() {
int w, h, x, y;
cin >> w >> h >> x >> y;
long double area = w * h;
cout << make_pair(area / 2, (2 * x == w && 2 * y == h)) << endl;
}
/* -------- <programs end> -------- */
signed main() {
cin.tie(nullptr);
ios::sync_with_stdio(false);
cout << fixed << setprecision(12);
solve();
return 0;
}
| [
"identifier.change",
"call.function.change",
"io.output.change"
] | 815,434 | 815,435 | u104057163 | cpp |
p03001 | #define _USE_MATH_DEFINES
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define rep(i, n) for (int i = 0; i < (int)(n); ++i)
#define rep1(i, n) for (int i = 1; i < (int)(n); ++i)
#define repeq(i, n) for (int i = 0; i <= (int)(n); ++i)
#define rep1eq(i, n) for (int i = 1; i <= (int)(n); ++i)
#define rrep(i, n) for (int i = (int)(n)-1; i >= 0; --i)
#define rrep1(i, n) for (int i = (int)(n)-1; i > 0; --i)
#define rrepeq(i, n) for (int i = (int)(n); i >= 0; --i)
#define rrep1eq(i, n) for (int i = (int)(n); i > 0; --i)
#define ALL(a) (a).begin(), (a).end()
#define RALL(a) (a).rbegin(), (a).rend()
using ll = long long;
using vi = vector<int>;
using vl = vector<ll>;
using vb = vector<bool>;
template <typename T> using Graph = vector<vector<T>>;
template <typename T> using Spacial = vector<vector<vector<T>>>;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
const int MOD = 1e9 + 7;
const int MOD2 = 998244353;
const double EPS = 1e-9;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
template <typename T> struct is_pair : false_type {};
template <typename T1, typename T2> struct is_pair<pair<T1, T2>> : true_type {};
template <typename T> struct is_vector : false_type {};
template <typename T> struct is_vector<vector<T>> : true_type {};
template <typename T1, typename T2>
istream &operator>>(istream &istr, pair<T1, T2> &p) {
istr >> p.first >> p.second;
return istr;
}
template <typename T1, typename T2>
ostream &operator<<(ostream &ostr, const pair<T1, T2> &p) {
ostr << p.first << " " << p.second;
return ostr;
}
template <typename T> istream &operator>>(istream &istr, vector<T> &vec) {
for (auto itr = vec.begin(); itr != vec.end(); ++itr) {
istr >> *itr;
}
return istr;
}
template <typename T> ostream &operator<<(ostream &ostr, const vector<T> &vec) {
if (vec.empty())
return ostr;
bool vp = is_vector<T>() || is_pair<T>();
ostr << vec.front();
for (auto itr = ++vec.begin(); itr != vec.end(); ++itr) {
ostr << (vp ? "\n" : " ") << *itr;
}
return ostr;
}
template <typename T1, typename T2> inline bool chmax(T1 &a, T2 b) {
return a < b && (a = b, true);
}
template <typename T1, typename T2> inline bool chmin(T1 &a, T2 b) {
return a > b && (a = b, true);
}
int modpow(int a, long long n, int mod = MOD) {
int ret = 1;
do {
if (n & 1)
ret = 1LL * ret * a % mod;
a = 1LL * a * a % mod;
} while (n >>= 1);
return ret;
}
template <typename T> T GCD(T a, T b) { return b ? GCD(b, a % b) : a; }
template <typename T> T LCM(T a, T b) { return a / GCD(a, b) * b; }
template <typename T1, typename T2>
bool CompareBySecond(pair<T1, T2> a, pair<T1, T2> b) {
return a.second != b.second ? a.second < b.second : a.first < b.first;
}
template <typename T> bool CompareBySlope(pair<T, T> a, pair<T, T> b) {
// counterclockwise from 12 o'clock direction
if (a.first * b.first < 0)
return a.first < b.first;
if (a.first == 0)
return a.second >= 0 || b.first > 0;
if (b.first == 0)
return b.second < 0 && a.first < 0;
return a.second * b.first < a.first * b.second;
}
/* -------- <templates end> -------- */
void solve() {
int w, h, x, y;
cin >> w >> h >> x >> y;
double area = w * h;
cout << pii(area / 2, (2 * x == w && 2 * y == h)) << endl;
}
/* -------- <programs end> -------- */
signed main() {
cin.tie(nullptr);
ios::sync_with_stdio(false);
cout << fixed << setprecision(12);
solve();
return 0;
}
| #define _USE_MATH_DEFINES
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define rep(i, n) for (int i = 0; i < (int)(n); ++i)
#define rep1(i, n) for (int i = 1; i < (int)(n); ++i)
#define repeq(i, n) for (int i = 0; i <= (int)(n); ++i)
#define rep1eq(i, n) for (int i = 1; i <= (int)(n); ++i)
#define rrep(i, n) for (int i = (int)(n)-1; i >= 0; --i)
#define rrep1(i, n) for (int i = (int)(n)-1; i > 0; --i)
#define rrepeq(i, n) for (int i = (int)(n); i >= 0; --i)
#define rrep1eq(i, n) for (int i = (int)(n); i > 0; --i)
#define ALL(a) (a).begin(), (a).end()
#define RALL(a) (a).rbegin(), (a).rend()
using ll = long long;
using vi = vector<int>;
using vl = vector<ll>;
using vb = vector<bool>;
template <typename T> using Graph = vector<vector<T>>;
template <typename T> using Spacial = vector<vector<vector<T>>>;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
const int MOD = 1e9 + 7;
const int MOD2 = 998244353;
const double EPS = 1e-9;
const int dx[4] = {1, 0, -1, 0};
const int dy[4] = {0, 1, 0, -1};
template <typename T> struct is_pair : false_type {};
template <typename T1, typename T2> struct is_pair<pair<T1, T2>> : true_type {};
template <typename T> struct is_vector : false_type {};
template <typename T> struct is_vector<vector<T>> : true_type {};
template <typename T1, typename T2>
istream &operator>>(istream &istr, pair<T1, T2> &p) {
istr >> p.first >> p.second;
return istr;
}
template <typename T1, typename T2>
ostream &operator<<(ostream &ostr, const pair<T1, T2> &p) {
ostr << p.first << " " << p.second;
return ostr;
}
template <typename T> istream &operator>>(istream &istr, vector<T> &vec) {
for (auto itr = vec.begin(); itr != vec.end(); ++itr) {
istr >> *itr;
}
return istr;
}
template <typename T> ostream &operator<<(ostream &ostr, const vector<T> &vec) {
if (vec.empty())
return ostr;
bool vp = is_vector<T>() || is_pair<T>();
ostr << vec.front();
for (auto itr = ++vec.begin(); itr != vec.end(); ++itr) {
ostr << (vp ? "\n" : " ") << *itr;
}
return ostr;
}
template <typename T1, typename T2> inline bool chmax(T1 &a, T2 b) {
return a < b && (a = b, true);
}
template <typename T1, typename T2> inline bool chmin(T1 &a, T2 b) {
return a > b && (a = b, true);
}
int modpow(int a, long long n, int mod = MOD) {
int ret = 1;
do {
if (n & 1)
ret = 1LL * ret * a % mod;
a = 1LL * a * a % mod;
} while (n >>= 1);
return ret;
}
template <typename T> T GCD(T a, T b) { return b ? GCD(b, a % b) : a; }
template <typename T> T LCM(T a, T b) { return a / GCD(a, b) * b; }
template <typename T1, typename T2>
bool CompareBySecond(pair<T1, T2> a, pair<T1, T2> b) {
return a.second != b.second ? a.second < b.second : a.first < b.first;
}
template <typename T> bool CompareBySlope(pair<T, T> a, pair<T, T> b) {
// counterclockwise from 12 o'clock direction
if (a.first * b.first < 0)
return a.first < b.first;
if (a.first == 0)
return a.second >= 0 || b.first > 0;
if (b.first == 0)
return b.second < 0 && a.first < 0;
return a.second * b.first < a.first * b.second;
}
/* -------- <templates end> -------- */
void solve() {
int w, h, x, y;
cin >> w >> h >> x >> y;
long double area = w * h;
cout << make_pair(area / 2, (2 * x == w && 2 * y == h)) << endl;
}
/* -------- <programs end> -------- */
signed main() {
cin.tie(nullptr);
ios::sync_with_stdio(false);
cout << fixed << setprecision(12);
solve();
return 0;
}
| [
"variable_declaration.type.widen.change",
"identifier.change",
"call.function.change",
"io.output.change"
] | 815,436 | 815,435 | u104057163 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
#define pb push_back
#define eb emplace_back
#define fi first
#define se second
#define endl '\n'
#define fcin \
ios::sync_with_stdio(false); \
cin.tie(nullptr);
#define INF 0x3f3f3f3f
#define all(x) x.begin(), x.end()
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
typedef long long ll;
typedef pair<int, int> pii;
template <typename A, typename B> string to_string(pair<A, B> p) {
return "(" + to_string(p.fi) + ", " + to_string(p.se) + ")";
}
template <typename T> string to_string(T v) {
string s = "{";
bool first = true;
for (const auto &x : v) {
if (!first)
s += ", ";
first = false;
s += to_string(x);
}
return s + "}";
}
void debug_out() { cerr << endl; }
template <typename First, typename... Next> void debug_out(First F, Next... N) {
cerr << " " << to_string(F);
debug_out(N...);
}
#ifdef LOCAL
#define debug(...) cerr << "[" << #__VA_ARGS__ << "]:", debug_out(__VA_ARGS__)
#else
#define debug(...) 1
#endif
int main() {
fcin;
int w, h, x, y;
cin >> w >> h >> x >> y;
ll a = ll(w) * h;
cout << fixed << setprecision(10) << a / 2.0 << " ";
if (x == w / 2 and y == h / 2)
cout << 1 << endl;
else
cout << 0 << endl;
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
#define pb push_back
#define eb emplace_back
#define fi first
#define se second
#define endl '\n'
#define fcin \
ios::sync_with_stdio(false); \
cin.tie(nullptr);
#define INF 0x3f3f3f3f
#define all(x) x.begin(), x.end()
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
typedef long long ll;
typedef pair<int, int> pii;
template <typename A, typename B> string to_string(pair<A, B> p) {
return "(" + to_string(p.fi) + ", " + to_string(p.se) + ")";
}
template <typename T> string to_string(T v) {
string s = "{";
bool first = true;
for (const auto &x : v) {
if (!first)
s += ", ";
first = false;
s += to_string(x);
}
return s + "}";
}
void debug_out() { cerr << endl; }
template <typename First, typename... Next> void debug_out(First F, Next... N) {
cerr << " " << to_string(F);
debug_out(N...);
}
#ifdef LOCAL
#define debug(...) cerr << "[" << #__VA_ARGS__ << "]:", debug_out(__VA_ARGS__)
#else
#define debug(...) 1
#endif
int main() {
fcin;
int w, h, x, y;
cin >> w >> h >> x >> y;
ll a = ll(w) * h;
cout << fixed << setprecision(10) << a / 2.0 << " ";
if (x == w / 2.0 and y == h / 2.0)
cout << 1 << endl;
else
cout << 0 << endl;
return 0;
}
| [
"literal.number.change",
"control_flow.branch.if.condition.change"
] | 815,446 | 815,447 | u189873906 | cpp |
p03001 | #include <algorithm>
#include <cmath>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <string>
#include <vector>
#define fi first
#define se second
#define rep(i, n) for (int i = 0; i < (n); ++i)
#define rrep(i, n) for (int i = 1; i < (n); ++i)
#define drep(i, n) for (int i = (n)-1; i >= 0; --i)
#define srep(i, s, t) for (int i = s; i < t; ++i)
#define all(x) (x).begin(), (x).end()
#define maxs(x, y) (x = max(x, y))
#define mins(x, y) (x = min(x, y))
#define pb push_back
#define sz(x) (int)(x).size()
#define PQ(T) priority_queue<T, v(T), greater<T>>
using namespace std;
using ll = long long;
using uint = unsigned;
using ull = unsigned long long;
using P = pair<int, int>;
const ll LINF = 1001002003004005006ll;
const int INF = 1001001001;
const int mod = 1000000007;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
double ans = (w * h) / 2;
int f = 0;
if (x * 2 == w && y * 2 == h)
f = 1;
printf("%.10lf %d\n", ans, f);
return 0;
}
| #include <algorithm>
#include <cmath>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <string>
#include <vector>
#define fi first
#define se second
#define rep(i, n) for (int i = 0; i < (n); ++i)
#define rrep(i, n) for (int i = 1; i < (n); ++i)
#define drep(i, n) for (int i = (n)-1; i >= 0; --i)
#define srep(i, s, t) for (int i = s; i < t; ++i)
#define all(x) (x).begin(), (x).end()
#define maxs(x, y) (x = max(x, y))
#define mins(x, y) (x = min(x, y))
#define pb push_back
#define sz(x) (int)(x).size()
#define PQ(T) priority_queue<T, v(T), greater<T>>
using namespace std;
using ll = long long;
using uint = unsigned;
using ull = unsigned long long;
using P = pair<int, int>;
const ll LINF = 1001002003004005006ll;
const int INF = 1001001001;
const int mod = 1000000007;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
double ans = (double)(w * h) / 2;
int f = 0;
if (x * 2 == w && y * 2 == h)
f = 1;
printf("%.10lf %d\n", ans, f);
return 0;
}
| [
"type_conversion.add"
] | 815,452 | 815,453 | u655777757 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
#define int long long int
signed main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
cout << fixed << setprecision(6) << (w * h) / (2 * 1.0) << " ";
if (x + x == w && y + y == h)
cout << 0 << endl;
else
cout << 1 << endl;
} | #include <bits/stdc++.h>
using namespace std;
#define int long long int
signed main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
cout << fixed << setprecision(6) << (w * h) / (2 * 1.0) << " ";
if (x + x == w && y + y == h)
cout << 1 << endl;
else
cout << 0 << endl;
} | [
"control_flow.branch.else.remove",
"control_flow.branch.else_if.replace.remove",
"control_flow.branch.if.replace.add"
] | 815,458 | 815,459 | u980161833 | cpp |
p03001 | #include <iostream>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
//長方形の中心にあると二つ存在。それ以外なら1つ
//面積は必ず等しくできる
cout << ((long long)H * W) / 2.0;
//長方形の中心にある
if (x == W / 2 && y == H / 2)
cout << ' ' << 1 << endl;
else
cout << ' ' << 0 << endl;
return 0;
} | #include <iostream>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
//長方形の中心にあると二つ存在。それ以外なら1つ
//面積は必ず等しくできる
cout << ((long long)H * W) / 2.0;
//長方形の中心にある
if (x == W / 2.0 && y == H / 2.0)
cout << ' ' << 1 << endl;
else
cout << ' ' << 0 << endl;
return 0;
} | [
"literal.number.change",
"control_flow.branch.if.condition.change"
] | 815,460 | 815,461 | u604023588 | cpp |
p03001 | #include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < (int)(n); i++)
#define REPS(i, n) for (int i = 1; i <= (int)(n); i++)
using namespace std;
using ll = long long;
using ld = long double;
int main(void) {
ll W, H, x, y;
cin >> W >> H >> x >> y;
cout << fixed << setprecision(10) << (ld)W * H / 2 << " ";
if (x == W / 2 && y == H / 2) {
cout << 1 << endl;
} else {
cout << 0 << endl;
}
} | #include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < (int)(n); i++)
#define REPS(i, n) for (int i = 1; i <= (int)(n); i++)
using namespace std;
using ll = long long;
using ld = long double;
int main(void) {
ll W, H, x, y;
cin >> W >> H >> x >> y;
cout << fixed << setprecision(10) << (ld)W * H / 2 << " ";
if (x == (ld)W / 2 && y == (ld)H / 2) {
cout << 1 << endl;
} else {
cout << 0 << endl;
}
} | [
"control_flow.branch.if.condition.change"
] | 815,462 | 815,463 | u986754154 | cpp |
p03001 | #include <algorithm>
#include <cstdint>
#include <cstdio>
#include <deque>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <string>
#include <tuple>
#include <utility>
#include <vector>
int main() {
intmax_t W, H, x, y;
scanf("%jd %jd %jd %jd", &W, &H, &x, &y);
double S = W * H / 2.0;
bool f = ((x * 2 == W) && (y * 2 == H));
printf("%.12fX %d\n", S, f);
}
| #include <algorithm>
#include <cstdint>
#include <cstdio>
#include <deque>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <string>
#include <tuple>
#include <utility>
#include <vector>
int main() {
intmax_t W, H, x, y;
scanf("%jd %jd %jd %jd", &W, &H, &x, &y);
double S = W * H / 2.0;
bool f = ((x * 2 == W) && (y * 2 == H));
printf("%.12f %d\n", S, f);
}
| [
"literal.string.change",
"call.arguments.change",
"io.output.change"
] | 815,489 | 815,490 | u352499693 | cpp |
p03001 | #include <algorithm>
#include <iostream>
using namespace std;
int main() {
long long W, H, x, y;
cin >> W >> H >> x >> y;
long long S = 0.50 * W * H;
bool deg = (2 * x == W) && (2 * y == H);
cout << S << " " << deg << endl;
return 0;
}
| #include <algorithm>
#include <iostream>
using namespace std;
int main() {
long long W, H, x, y;
cin >> W >> H >> x >> y;
double S = 0.50 * W * H;
bool deg = (2 * x == W) && (2 * y == H);
cout << S << " " << deg << endl;
return 0;
}
| [
"variable_declaration.type.primitive.change",
"variable_declaration.type.narrow.change"
] | 815,495 | 815,496 | u774438048 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
#define rep(i, n) for (int i = 0; i < (int)(n); ++i)
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
int main() {
std::cout << std::fixed << std::setprecision(10);
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans1 = W * H / 2;
int ans2 = 0;
if (x * 2 == W && y * 2 == H) {
ans2 = 1;
}
cout << ans1 << " " << ans2 << endl;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
#define rep(i, n) for (int i = 0; i < (int)(n); ++i)
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
int main() {
std::cout << std::fixed << std::setprecision(10);
double W, H, x, y;
cin >> W >> H >> x >> y;
double ans1 = W * H / 2;
int ans2 = 0;
if (x * 2 == W && y * 2 == H) {
ans2 = 1;
}
cout << ans1 << " " << ans2 << endl;
} | [
"variable_declaration.type.primitive.change"
] | 815,511 | 815,512 | u989306199 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define pa pair<int, int>
#define pal pair<long long, long long>
#define pali pair<long long, int>
#define pad pair<double, double>
#define pb push_back
#define mp make_pair
#define COUT(v) \
for (int64_t i = 0; i < (v).size(); ++i) { \
cout << v.at(i) << endl; \
}
#define REP(i, n) for (int64_t i = 0; i < n; ++i)
#define FOR(i, r, n) for (int64_t i = (r); i < n; ++i)
#define VIN(v) \
for (int64_t i = 0; i < (v).size(); ++i) { \
cin >> (v).at(i); \
}
typedef vector<bool> bvec;
typedef vector<int> ivec;
typedef vector<long long> lvec;
typedef vector<double> dvec;
typedef vector<pa> pavec;
typedef vector<pali> palivec;
typedef vector<pal> palvec;
typedef vector<vector<bool>> bmat;
typedef vector<vector<int>> imat;
typedef vector<vector<long long>> lmat;
typedef vector<string> svec;
typedef vector<vector<string>> smat;
const ll infll = (1LL << 60) - 1;
const int inf = (1 << 30) - 1;
const int MOD = 1000000007;
ll gcd(ll x, ll y) {
ll r = x % y;
if (r == 0)
return y;
else
return gcd(y, r);
}
ll lcm(ll x, ll y) { return x * y / gcd(x, y); }
lvec mfactor(ll n) {
bvec ip(n, true);
lvec mf(n, -1);
ip[0] = false;
ip[1] = false;
mf[0] = 0;
mf[1] = 1;
REP(i, n) {
if (ip[i]) {
mf[i] = i;
for (ll j = i * i; j < n; j += i) {
ip[j] = false;
if (mf[j] == -1)
mf[j] = i;
}
}
}
return mf;
}
palivec get_prime(ll n, const lvec &mf) {
palivec plist;
while (n != 1) {
int cnt = 0;
ll m = mf[n];
while (mf[n] == m) {
cnt++;
n /= m;
}
plist.pb(pali(m, cnt));
}
return plist;
}
void COMinit(int m, lvec &fac, lvec &finv) {
lvec inv(m);
fac[0] = fac[1] = 1;
finv[0] = finv[1] = 1;
inv[1] = 1;
for (int i = 2; i < m; i++) {
fac[i] = fac[i - 1] * i % MOD;
inv[i] = MOD - inv[MOD % i] * (MOD / i) % MOD;
finv[i] = finv[i - 1] * inv[i] % MOD;
}
}
ll pow_mod(ll a, ll n) {
ll x = 1;
while (n > 0) {
if (n & 1) {
x = x * a % MOD;
}
a = a * a % MOD;
n >>= 1;
}
return x;
}
ll COM(int n, int k, const lvec &fac, const lvec &finv) {
if (n < k)
return 0;
if (n < 0 || k < 0)
return 0;
return fac[n] * (finv[k] * finv[n - k] % MOD) % MOD;
}
ll modinv(ll a, ll m) {
ll b = m, u = 1, v = 0;
while (b) {
ll t = a / b;
a -= t * b;
swap(a, b);
u -= t * v;
swap(u, v);
}
u %= m;
if (u < 0)
u += m;
return u;
}
ll P(ll n, ll m) {
ll s = 1;
ll cnt = n;
REP(i, n - m) {
s *= cnt % MOD;
s %= MOD;
--cnt;
}
return s;
}
void fac(int a, int b, bvec &fmap) {
for (int i = 2; i < b; i++) {
if (fmap[i])
continue;
else if (a % i == 0) {
fmap[i] = true;
int n = a / i, x = i;
while (n >= i) {
n /= i;
x += i;
fmap[x] = true;
}
}
}
}
int main() {
cin.tie(0);
ios::sync_with_stdio(false);
ll h, w, x, y;
cin >> w >> h >> x >> y;
cout << setprecision(19) << h * w / 2 << ' ';
if (x == w / 2 && y == h / 2)
cout << 1 << endl;
else
cout << 0 << endl;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define pa pair<int, int>
#define pal pair<long long, long long>
#define pali pair<long long, int>
#define pad pair<double, double>
#define pb push_back
#define mp make_pair
#define COUT(v) \
for (int64_t i = 0; i < (v).size(); ++i) { \
cout << v.at(i) << endl; \
}
#define REP(i, n) for (int64_t i = 0; i < n; ++i)
#define FOR(i, r, n) for (int64_t i = (r); i < n; ++i)
#define VIN(v) \
for (int64_t i = 0; i < (v).size(); ++i) { \
cin >> (v).at(i); \
}
typedef vector<bool> bvec;
typedef vector<int> ivec;
typedef vector<long long> lvec;
typedef vector<double> dvec;
typedef vector<pa> pavec;
typedef vector<pali> palivec;
typedef vector<pal> palvec;
typedef vector<vector<bool>> bmat;
typedef vector<vector<int>> imat;
typedef vector<vector<long long>> lmat;
typedef vector<string> svec;
typedef vector<vector<string>> smat;
const ll infll = (1LL << 60) - 1;
const int inf = (1 << 30) - 1;
const int MOD = 1000000007;
ll gcd(ll x, ll y) {
ll r = x % y;
if (r == 0)
return y;
else
return gcd(y, r);
}
ll lcm(ll x, ll y) { return x * y / gcd(x, y); }
lvec mfactor(ll n) {
bvec ip(n, true);
lvec mf(n, -1);
ip[0] = false;
ip[1] = false;
mf[0] = 0;
mf[1] = 1;
REP(i, n) {
if (ip[i]) {
mf[i] = i;
for (ll j = i * i; j < n; j += i) {
ip[j] = false;
if (mf[j] == -1)
mf[j] = i;
}
}
}
return mf;
}
palivec get_prime(ll n, const lvec &mf) {
palivec plist;
while (n != 1) {
int cnt = 0;
ll m = mf[n];
while (mf[n] == m) {
cnt++;
n /= m;
}
plist.pb(pali(m, cnt));
}
return plist;
}
void COMinit(int m, lvec &fac, lvec &finv) {
lvec inv(m);
fac[0] = fac[1] = 1;
finv[0] = finv[1] = 1;
inv[1] = 1;
for (int i = 2; i < m; i++) {
fac[i] = fac[i - 1] * i % MOD;
inv[i] = MOD - inv[MOD % i] * (MOD / i) % MOD;
finv[i] = finv[i - 1] * inv[i] % MOD;
}
}
ll pow_mod(ll a, ll n) {
ll x = 1;
while (n > 0) {
if (n & 1) {
x = x * a % MOD;
}
a = a * a % MOD;
n >>= 1;
}
return x;
}
ll COM(int n, int k, const lvec &fac, const lvec &finv) {
if (n < k)
return 0;
if (n < 0 || k < 0)
return 0;
return fac[n] * (finv[k] * finv[n - k] % MOD) % MOD;
}
ll modinv(ll a, ll m) {
ll b = m, u = 1, v = 0;
while (b) {
ll t = a / b;
a -= t * b;
swap(a, b);
u -= t * v;
swap(u, v);
}
u %= m;
if (u < 0)
u += m;
return u;
}
ll P(ll n, ll m) {
ll s = 1;
ll cnt = n;
REP(i, n - m) {
s *= cnt % MOD;
s %= MOD;
--cnt;
}
return s;
}
void fac(int a, int b, bvec &fmap) {
for (int i = 2; i < b; i++) {
if (fmap[i])
continue;
else if (a % i == 0) {
fmap[i] = true;
int n = a / i, x = i;
while (n >= i) {
n /= i;
x += i;
fmap[x] = true;
}
}
}
}
int main() {
cin.tie(0);
ios::sync_with_stdio(false);
double w, h, x, y;
cin >> w >> h >> x >> y;
cout << setprecision(19) << h * w / 2 << ' ';
if (x == w / 2 && y == h / 2)
cout << 1 << endl;
else
cout << 0 << endl;
} | [
"variable_declaration.type.change",
"variable_declaration.remove",
"variable_declaration.add"
] | 815,515 | 815,516 | u842917248 | cpp |
p03001 | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); ++i)
using namespace std;
using ll = long long;
using P = pair<int, int>;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
cout << fixed << setprecision(6) << 1. * w * h / 2 << " ";
if (x == w / 2 && y == h / 2)
cout << 1;
else
cout << 0;
return 0;
} | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); ++i)
using namespace std;
using ll = long long;
using P = pair<int, int>;
int main() {
double w, h, x, y;
cin >> w >> h >> x >> y;
cout << fixed << setprecision(6) << 1. * w * h / 2 << " ";
if (x == w / 2 && y == h / 2)
cout << 1;
else
cout << 0;
return 0;
} | [
"variable_declaration.type.primitive.change"
] | 815,522 | 815,523 | u915689660 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
long long w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w && 2 * y == h)
cout << w * (h / 2.0) << " " << 1 << endl;
else
cout << w * (h / 2.0) << " " << 1 << endl;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
double w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w && 2 * y == h)
cout << w * (h / 2.0) << " " << 1 << endl;
else
cout << w * (h / 2.0) << " " << 0 << endl;
} | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.narrow.change",
"literal.number.change",
"io.output.change"
] | 815,526 | 815,527 | u459105164 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int w, h, x, y;
int main() {
cin >> w >> h >> x >> y;
printf("%7.5f", w * h / 2);
if (w / 2 == x && h / 2 == y)
cout << " " << 1;
else
cout << " " << 0;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
double w, h, x, y;
int main() {
cin >> w >> h >> x >> y;
printf("%7.5f", w * h / 2);
if (w / 2 == x && h / 2 == y)
cout << " " << 1;
else
cout << " " << 0;
return 0;
} | [
"variable_declaration.type.primitive.change"
] | 815,543 | 815,544 | u469639111 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
cout << (W * H) / 2 << " ";
if (x == W / 2 && y == H / 2)
cout << 1 << endl;
else
cout << 0 << endl;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
/*ll S; cin >> S;
ll h = 1;
ll w = S;
if(S > 1000000000){
for(ll i = 5000000000; i > 0; i--){
//cout << i << endl;
if(S % i == 0) {h = i; w = S/i; break;}
}
}
cout << 0 << " " << 0 << " " << w << " " << 0 << " " << 0 << " " << h <<
endl;
*/
double W, H, x, y;
cin >> W >> H >> x >> y;
cout << (W * H) / 2 << " ";
if (x == W / 2 && y == H / 2)
cout << 1 << endl;
else
cout << 0 << endl;
} | [
"variable_declaration.type.change"
] | 815,545 | 815,546 | u521973174 | cpp |
p03001 | #include <algorithm>
#include <iostream>
#include <vector>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
typedef long long ll;
using namespace std;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w && 2 * y == h) {
cout << double(w) * double(h) / 2 << " " << '1' << endl;
} else {
cout << double(w) * double(h) / 2 << " " << '1' << endl;
}
return 0;
} | #include <algorithm>
#include <iostream>
#include <vector>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
typedef long long ll;
using namespace std;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
if (2 * x == w && 2 * y == h) {
cout << double(w) * double(h) / 2 << " " << '1' << endl;
} else {
cout << double(w) * double(h) / 2 << " " << '0' << endl;
}
return 0;
} | [
"literal.string.change",
"io.output.change"
] | 815,547 | 815,548 | u745267317 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
#define REP(i, n) for (int i = 0; i < (n); i++)
#define REP2(i, x, n) for (int i = x; i < (n); i++)
#define ALL(n) begin(n), end(n)
struct cww {
cww() {
ios::sync_with_stdio(false);
cin.tie(0);
}
} star;
const long long INF = numeric_limits<long long>::max();
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
double ans = w * h / 2;
int cnt = 0;
if (2 * x == w && 2 * y == h)
cnt = 1;
cout << fixed << setprecision(4) << ans << " " << cnt << endl;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
#define REP(i, n) for (int i = 0; i < (n); i++)
#define REP2(i, x, n) for (int i = x; i < (n); i++)
#define ALL(n) begin(n), end(n)
struct cww {
cww() {
ios::sync_with_stdio(false);
cin.tie(0);
}
} star;
const long long INF = numeric_limits<long long>::max();
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
double ans = double(w) * double(h) / 2;
int cnt = 0;
if (2 * x == w && 2 * y == h)
cnt = 1;
cout << fixed << setprecision(4) << ans << " " << cnt << endl;
return 0;
} | [
"call.add",
"call.arguments.change"
] | 815,549 | 815,550 | u823722490 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
double half = (W * H) / 2;
bool can = false;
if (W % 2 == 0 && H % 2 == 0) {
if (x == W / 2 && y == H / 2)
can = true;
}
cout << fixed << setprecision(12);
if (can)
cout << half << " " << 1 << endl;
else
cout << half << " " << 0 << endl;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
double half = (double)W * H / 2;
bool can = false;
if (W % 2 == 0 && H % 2 == 0) {
if (x == W / 2 && y == H / 2)
can = true;
}
cout << fixed << setprecision(12);
if (can)
cout << half << " " << 1 << endl;
else
cout << half << " " << 0 << endl;
} | [
"type_conversion.add"
] | 815,551 | 815,552 | u241312295 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
double w, h;
int x, y;
cin >> w >> h >> x >> y;
double maxSize = (w / 2) * h;
bool multipleWaysPossible = (((x == w / 2) || (y == h / 2)) ? true : false);
cout << fixed << setprecision(9);
cout << maxSize << " " << (multipleWaysPossible ? 1 : 0) << endl;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
double w, h;
int x, y;
cin >> w >> h >> x >> y;
double maxSize = (w / 2) * h;
bool multipleWaysPossible = (((x == w / 2) && (y == h / 2)) ? true : false);
cout << fixed << setprecision(9);
cout << maxSize << " " << (multipleWaysPossible ? 1 : 0) << endl;
} | [
"misc.opposites",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change"
] | 815,560 | 815,561 | u584797714 | cpp |
p03001 | #include <iostream>
using namespace std;
int main() {
long long W, H, x, y;
cin >> W >> H >> x >> y;
cout << W * H / 2 << " ";
if (x * 2 == W && y * 2 == H) {
cout << 1 << endl;
} else {
cout << 0 << endl;
}
return 0;
}
| #include <iostream>
using namespace std;
int main() {
long long W, H, x, y;
cin >> W >> H >> x >> y;
cout << W * H / 2.0 << " ";
if (x * 2 == W && y * 2 == H) {
cout << 1 << endl;
} else {
cout << 0 << endl;
}
return 0;
}
| [
"literal.number.change",
"io.output.change"
] | 815,564 | 815,565 | u016119075 | cpp |
p03001 | #include <iostream>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
cout << W * H / 2 << " ";
if (x * 2 == W && y * 2 == H) {
cout << 1 << endl;
} else {
cout << 0 << endl;
}
return 0;
}
| #include <iostream>
using namespace std;
int main() {
long long W, H, x, y;
cin >> W >> H >> x >> y;
cout << W * H / 2.0 << " ";
if (x * 2 == W && y * 2 == H) {
cout << 1 << endl;
} else {
cout << 0 << endl;
}
return 0;
}
| [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change",
"literal.number.change",
"io.output.change"
] | 815,566 | 815,565 | u016119075 | cpp |
p03001 | #include <iostream>
#include <vector>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = (double)W * H / 2;
int num = (W == x * 2 && H == y * 2) ? 1 : 0;
printf("%.10f%d\n", ans, num);
}
| #include <iostream>
#include <vector>
using namespace std;
int main() {
double W, H, x, y;
cin >> W >> H >> x >> y;
double ans = W * H / 2;
int num = (W == x * 2 && H == y * 2) ? 1 : 0;
printf("%.10f %d\n", ans, num);
}
| [
"variable_declaration.type.primitive.change",
"literal.string.change",
"call.arguments.change",
"io.output.change"
] | 815,570 | 815,571 | u147556624 | cpp |
p03001 | #include <iostream>
#include <vector>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = (double)W * H / 2;
int num = (W == x * 2 || H == y * 2) ? 1 : 0;
printf("%.10f%d\n", ans, num);
}
| #include <iostream>
#include <vector>
using namespace std;
int main() {
double W, H, x, y;
cin >> W >> H >> x >> y;
double ans = W * H / 2;
int num = (W == x * 2 && H == y * 2) ? 1 : 0;
printf("%.10f %d\n", ans, num);
}
| [
"variable_declaration.type.primitive.change",
"misc.opposites",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change",
"literal.string.change",
"call.arguments.change",
"io.output.change"
] | 815,572 | 815,571 | u147556624 | cpp |
p03001 | #include <iostream>
#include <vector>
using namespace std;
int main() {
double W, H, x, y;
cin >> W >> H >> x >> y;
double ans;
ans = W * H / 2;
int num = (W == x * 2 || H == y * 2) ? 1 : 0;
printf("%.10f%d\n", ans, num);
}
| #include <iostream>
#include <vector>
using namespace std;
int main() {
double W, H, x, y;
cin >> W >> H >> x >> y;
double ans = W * H / 2;
int num = (W == x * 2 && H == y * 2) ? 1 : 0;
printf("%.10f %d\n", ans, num);
}
| [
"variable_declaration.remove",
"misc.opposites",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change",
"literal.string.change",
"call.arguments.change",
"io.output.change"
] | 815,573 | 815,571 | u147556624 | cpp |
p03001 | #include <iostream>
#include <vector>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = (double)W * H / 2;
int num = (W == x * 2 && H == y * 2) ? 1 : 0;
printf("%.10f%d\n", ans, num);
}
| #include <iostream>
#include <vector>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = (double)W * H / 2;
int num = (W == x * 2 && H == y * 2) ? 1 : 0;
printf("%.10f %d\n", ans, num);
}
| [
"literal.string.change",
"call.arguments.change",
"io.output.change"
] | 815,570 | 815,575 | u147556624 | cpp |
p03001 | #include <iostream>
#include <vector>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = (double)W * H / 2;
int num = (W == x * 2 || H == y * 2) ? 1 : 0;
printf("%.10f%d\n", ans, num);
}
| #include <iostream>
#include <vector>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = (double)W * H / 2;
int num = (W == x * 2 && H == y * 2) ? 1 : 0;
printf("%.10f %d\n", ans, num);
}
| [
"misc.opposites",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change",
"literal.string.change",
"call.arguments.change",
"io.output.change"
] | 815,572 | 815,575 | u147556624 | cpp |
p03001 | #include <iostream>
#include <vector>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans;
ans = (double)W * H / 2;
int num = (W == x * 2 || H == y * 2) ? 1 : 0;
printf("%.10f%d\n", ans, num);
}
| #include <iostream>
#include <vector>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = (double)W * H / 2;
int num = (W == x * 2 && H == y * 2) ? 1 : 0;
printf("%.10f %d\n", ans, num);
}
| [
"variable_declaration.remove",
"misc.opposites",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change",
"literal.string.change",
"call.arguments.change",
"io.output.change"
] | 815,576 | 815,575 | u147556624 | cpp |
p03001 | #include <iostream>
#include <vector>
using namespace std;
int main() {
double W, H, x, y;
cin >> W >> H >> x >> y;
double ans;
ans = (double)W * H / 2;
int num = (W == x * 2 || H == y * 2) ? 1 : 0;
printf("%.10f%d\n", ans, num);
}
| #include <iostream>
#include <vector>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = (double)W * H / 2;
int num = (W == x * 2 && H == y * 2) ? 1 : 0;
printf("%.10f %d\n", ans, num);
}
| [
"variable_declaration.type.primitive.change",
"misc.opposites",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change",
"literal.string.change",
"call.arguments.change",
"io.output.change"
] | 815,577 | 815,575 | u147556624 | cpp |
p03001 | #include <algorithm>
#include <cmath>
#include <cstdio>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
using namespace std;
#define rep(i, n) for (int(i) = 0; (i) < (n); (i)++)
#define FOR(i, m, n) for (int(i) = (m); (i) < (n); (i)++)
#define All(v) (v).begin(), (v).end()
typedef long long ll;
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
int flag = 0;
double res = H * W / 2.0;
if (x == W / 2 && y == H / 2)
flag = 1;
cout << fixed << setprecision(10) << (double)res;
cout << " " << flag << endl;
return 0;
} | #include <algorithm>
#include <cmath>
#include <cstdio>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
using namespace std;
#define rep(i, n) for (int(i) = 0; (i) < (n); (i)++)
#define FOR(i, m, n) for (int(i) = (m); (i) < (n); (i)++)
#define All(v) (v).begin(), (v).end()
typedef long long ll;
int main() {
ll W, H, x, y;
cin >> W >> H >> x >> y;
int flag = 0;
double res = H * W / 2.0;
if (x == W / 2.0 && y == H / 2.0)
flag = 1;
cout << fixed << setprecision(10) << (double)res;
cout << " " << flag << endl;
return 0;
} | [
"literal.number.change",
"control_flow.branch.if.condition.change"
] | 815,580 | 815,581 | u917282863 | cpp |
p03001 | #include <bits/stdc++.h>
#define ford(i, a, b) for (int i = (a); i >= b; i--)
#define rep(i, a, b) for (int i = (a); (i) <= (b); (i)++)
#define ll long long
#define re return
#define mp map<int, int>
using namespace std;
int main() {
int w, h, x, y;
cin >> w >> h >> x >> y;
if (w / 2 == x && h / 2 == y)
cout << fixed << setprecision(6) << w * h / 2 << "1";
else
cout << fixed << setprecision(6) << w * h / 2 << "0";
re 0;
}
| #include <bits/stdc++.h>
#define ford(i, a, b) for (int i = (a); i >= b; i--)
#define rep(i, a, b) for (int i = (a); (i) <= (b); (i)++)
#define ll long long
#define re return
#define mp map<int, int>
using namespace std;
int main() {
double w, h, x, y;
cin >> w >> h >> x >> y;
if (w / 2 == x && h / 2 == y)
cout << fixed << setprecision(6) << w * h / 2 << " 1";
else
cout << fixed << setprecision(6) << w * h / 2 << " 0";
re 0;
}
| [
"variable_declaration.type.primitive.change",
"literal.string.change",
"io.output.change"
] | 815,584 | 815,585 | u796123030 | cpp |
p03001 | #include <algorithm>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <map>
#include <vector>
#define endl "\n"
#define ll long long int
using namespace std;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
double area = (double)(w * h) / 2;
ll flag = 0;
if (x == w / 2 && y == h / 2)
flag = 1;
cout << fixed << setprecision(9) << area << " " << flag << endl;
} | #include <algorithm>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <map>
#include <vector>
#define endl "\n"
#define ll long long int
using namespace std;
int main() {
double w, h, x, y;
cin >> w >> h >> x >> y;
double area = (double)(w * h) / 2;
ll flag = 0;
if (x == w / 2 && y == h / 2)
flag = 1;
cout << fixed << setprecision(9) << area << " " << flag << endl;
} | [
"variable_declaration.type.change"
] | 815,586 | 815,587 | u345207975 | cpp |
p03001 | #include <algorithm>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <map>
#include <vector>
#define endl "\n"
#define ll long long int
using namespace std;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
double area = (w * h) / 2;
ll flag = 0;
if (x == w / 2 && y == h / 2)
flag = 1;
cout << fixed << setprecision(9) << area << " " << flag << endl;
} | #include <algorithm>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <map>
#include <vector>
#define endl "\n"
#define ll long long int
using namespace std;
int main() {
double w, h, x, y;
cin >> w >> h >> x >> y;
double area = (double)(w * h) / 2;
ll flag = 0;
if (x == w / 2 && y == h / 2)
flag = 1;
cout << fixed << setprecision(9) << area << " " << flag << endl;
} | [
"variable_declaration.type.change"
] | 815,588 | 815,587 | u345207975 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
double w, h, x, y, answer;
cin >> w >> h >> x >> y;
answer = h * w * 0.5;
if (x == w * 0.5 || y == h * 0.5) {
cout << answer << " 1" << endl;
} else {
cout << answer << " 0" << endl;
}
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
double w, h, x, y, answer;
cin >> w >> h >> x >> y;
answer = (h * w) * 0.5;
if (x == w * 0.5 && y == h * 0.5) {
cout << answer << " 1" << endl;
} else {
cout << answer << " 0" << endl;
}
}
| [
"misc.opposites",
"control_flow.branch.if.condition.change"
] | 815,600 | 815,601 | u931071094 | cpp |
p03001 | #include <iomanip>
#include <iostream>
#include <iterator>
#include <map>
using namespace std;
int main() {
long long w, h, x, y, r;
int poss = 0;
cin >> w >> h >> x >> y;
if ((x == w / 2) && (y == h / 2)) {
poss += 1;
}
cout << fixed << setprecision(10) << double((w * h) / 2.0) << " " << poss;
}
| #include <iomanip>
#include <iostream>
#include <iterator>
#include <map>
using namespace std;
int main() {
double w, h, x, y;
int poss = 0;
cin >> w >> h >> x >> y;
if ((x == w / 2) && (y == h / 2)) {
poss = 1;
}
cout << fixed << setprecision(10) << double((w * h) / 2.0) << " " << poss;
} | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.narrow.change",
"variable_declaration.remove",
"assignment.value.change"
] | 815,616 | 815,617 | u554529201 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int INF = 1e9;
const int MOD = 1e9 + 7;
const ll LINF = 1e18;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
ll m = 0;
if (w == 2 * x && h == 2 * y) {
m = 1;
}
cout << fixed << setprecision(15) << (double)(w * h / 2) << ' ' << m << endl;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int INF = 1e9;
const int MOD = 1e9 + 7;
const ll LINF = 1e18;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
ll m = 0;
if (w == 2 * x && h == 2 * y) {
m = 1;
}
cout << fixed << setprecision(10) << (double)(w * h) / 2.0 << ' ' << m
<< endl;
} | [
"literal.number.change",
"io.output.change",
"expression.operation.binary.remove"
] | 815,636 | 815,635 | u701556979 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int INF = 1e9;
const int MOD = 1e9 + 7;
const ll LINF = 1e18;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
ll m = 0;
if (w == 2 * x && h == 2 * y) {
m = 1;
}
cout << fixed << setprecision(10) << (double)(w * h / 2) << ' ' << m << endl;
} | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int INF = 1e9;
const int MOD = 1e9 + 7;
const ll LINF = 1e18;
int main() {
ll w, h, x, y;
cin >> w >> h >> x >> y;
ll m = 0;
if (w == 2 * x && h == 2 * y) {
m = 1;
}
cout << fixed << setprecision(10) << (double)(w * h) / 2.0 << ' ' << m
<< endl;
} | [
"expression.operation.binary.remove"
] | 815,637 | 815,635 | u701556979 | cpp |
p03001 |
// C - Rectangle Cutting
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
// const int INF = 2147483647;
// const ll INF = 9223372036854775807;
// const int MOD = 1e9 + 7;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
float A = W * H / 2.0;
int multi;
if (x == W / 2 && y == H / 2)
multi = 1;
else
multi = 0;
cout << A << " " << multi << endl;
return 0;
} |
// C - Rectangle Cutting
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
// const int INF = 2147483647;
// const ll INF = 9223372036854775807;
// const int MOD = 1e9 + 7;
int main() {
double W, H, x, y;
cin >> W >> H >> x >> y;
float A = W * H / 2.0;
int multi;
if (x == W / 2.0 && y == H / 2.0)
multi = 1;
else
multi = 0;
cout << A << " " << multi << endl;
return 0;
} | [
"variable_declaration.type.primitive.change",
"literal.number.change",
"control_flow.branch.if.condition.change"
] | 815,642 | 815,641 | u790272146 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
int ans = 0;
int64_t b = (double)W * (double)H / 2;
if ((double)W / 2 == x || (double)H / 2 == y) {
ans++;
}
cout << fixed << setprecision(10);
cout << b << " " << ans << endl;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
int ans = 0;
double b = (double)W * (double)H / 2;
if ((double)W / 2 == x && (double)H / 2 == y) {
ans++;
}
cout << fixed << setprecision(10);
cout << b << " " << ans << endl;
}
| [
"variable_declaration.type.primitive.change",
"misc.opposites",
"control_flow.branch.if.condition.change"
] | 815,663 | 815,662 | u387371565 | cpp |
p03001 | #include <iostream>
#include <vector>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = W * H / 2;
int ptn = 0;
if (W == x * 2 && H == y * 2)
ptn = 1;
printf("%10f %d\n", ans, ptn);
return 0;
} | #include <iostream>
#include <vector>
using namespace std;
int main() {
int W, H, x, y;
cin >> W >> H >> x >> y;
double ans = (double)W * (double)H / 2;
int ptn = 0;
if (W == x * 2 && H == y * 2)
ptn = 1;
printf("%10f %d\n", ans, ptn);
return 0;
} | [
"type_conversion.add"
] | 815,666 | 815,667 | u807028974 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
int x, y, a, b;
cin >> x >> y >> a >> b;
double q = x * y / 2;
if (x == a * 2 && y == b * 2) {
cout << q << " " << 1;
} else {
cout << q << " " << 0;
}
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int x, y, a, b;
cin >> x >> y >> a >> b;
double q = (double)x * y / 2;
if (x == a * 2 && y == b * 2) {
cout << q << " " << 1;
} else {
cout << q << " " << 0;
}
} | [
"type_conversion.add"
] | 815,676 | 815,677 | u167245594 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
long long W, H, x, y;
cin >> W >> H >> x >> y;
cout << W * H / 2 << " " << (W == x * 2 && H == y * 2 ? 1 : 0) << endl;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
long long W, H, x, y;
cin >> W >> H >> x >> y;
cout << (double)W * H / 2 << " " << (W == x * 2 && H == y * 2 ? 1 : 0)
<< endl;
} | [
"type_conversion.add"
] | 815,690 | 815,691 | u816742421 | cpp |
p03001 | #include "bits/stdc++.h"
using namespace std;
int main() {
double w, h;
int x, y;
cin >> w >> h >> x >> y;
char mode;
if (x == w / 2 && y == h / 2) {
mode = '0';
} else {
mode = '1';
}
double area = w * h / 2;
cout << fixed << setprecision(9) << area << " " << mode << endl;
}
| #include "bits/stdc++.h"
using namespace std;
int main() {
double w, h;
int x, y;
cin >> w >> h >> x >> y;
char mode;
if (x == w / 2 && y == h / 2) {
mode = '1';
} else {
mode = '0';
}
double area = w * h / 2;
cout << fixed << setprecision(9) << area << " " << mode << endl;
}
| [
"literal.string.change",
"assignment.value.change"
] | 815,694 | 815,695 | u418785081 | cpp |
p03001 | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define FOR(i, n, m) for (int i = (int)(n); i <= (int)(m); i++)
#define ITR(x, c) for (__typeof(c.begin()) x = c.begin(); x != c.end(); x++)
#define RITR(x, c) for (__typeof(c.rbegin()) x = c.rbegin(); x != c.rend(); x++)
#define setp(n) fixed << setprecision(n)
#define ld long double
#define ll long long
#define vll vector<ll>
#define vi vector<int>
#define pll pair<ll, ll>
#define pi pair<int, int>
#define all(a) (a.begin()), (a.end())
#define rall(a) (a.rbegin()), (a.rend())
#define fi first
#define se second
#define pb push_back
#define mp make_pair
#define ins insert
using namespace std;
/* Some Libraries */
//-------------------------------------------------
int main(void) {
cin.tie(0);
ios::sync_with_stdio(false);
ll h, w, x, y;
cin >> w >> h >> x >> y;
double ans = h * w / 2;
cout << setp(12) << ans << " " << (2 * x == w && 2 * y == h) << endl;
return 0;
}
| #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define FOR(i, n, m) for (int i = (int)(n); i <= (int)(m); i++)
#define ITR(x, c) for (__typeof(c.begin()) x = c.begin(); x != c.end(); x++)
#define RITR(x, c) for (__typeof(c.rbegin()) x = c.rbegin(); x != c.rend(); x++)
#define setp(n) fixed << setprecision(n)
#define ld long double
#define ll long long
#define vll vector<ll>
#define vi vector<int>
#define pll pair<ll, ll>
#define pi pair<int, int>
#define all(a) (a.begin()), (a.end())
#define rall(a) (a.rbegin()), (a.rend())
#define fi first
#define se second
#define pb push_back
#define mp make_pair
#define ins insert
using namespace std;
/* Some Libraries */
//-------------------------------------------------
int main(void) {
cin.tie(0);
ios::sync_with_stdio(false);
ll h, w, x, y;
cin >> w >> h >> x >> y;
double ans = (double)h * w / 2;
cout << setp(12) << ans << " " << (2 * x == w && 2 * y == h) << endl;
return 0;
}
| [
"type_conversion.add"
] | 815,702 | 815,703 | u682686221 | cpp |
p03001 | #include <bits/stdc++.h>
#include <iomanip>
#include <iostream>
#include <math.h>
using namespace std;
int main() {
double W, H, x, y;
int center;
cin >> W >> H >> x >> y;
;
if (x == W / 2 && y == H / 2)
center = 0;
else
center = 1;
cout << fixed << std::setprecision(6) << (W * H) / 2 << ' ' << center << endl;
return 0;
}
| #include <bits/stdc++.h>
#include <iomanip>
#include <iostream>
#include <math.h>
using namespace std;
int main() {
double W, H, x, y;
int center;
cin >> W >> H >> x >> y;
;
if (x == W / 2 && y == H / 2)
center = 1;
else
center = 0;
cout << fixed << std::setprecision(6) << (W * H) / 2 << ' ' << center << endl;
return 0;
}
| [
"control_flow.branch.else.remove",
"control_flow.branch.else_if.replace.remove",
"control_flow.branch.if.replace.add",
"assignment.add"
] | 815,704 | 815,705 | u913852240 | cpp |
p03001 | #include <algorithm>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <limits>
#include <map>
#include <numeric>
#include <vector>
using namespace std;
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
const long long INF = 1LL << 60;
long long gcd(long long a, long long b) {
if (a % b == 0) {
return (b);
} else {
return (gcd(b, a % b));
}
}
long long lcm(long long a, long long b) { return a * b / gcd(a, b); }
int main() {
long long W, H, X, Y;
cin >> W >> H >> X >> Y;
double area = W * H;
printf("%.9f", area / 2);
if (X == W / 2 && Y == H / 2) {
cout << " " << 1 << endl;
} else {
cout << " " << 0 << endl;
}
} | #include <algorithm>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <limits>
#include <map>
#include <numeric>
#include <vector>
using namespace std;
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
const long long INF = 1LL << 60;
long long gcd(long long a, long long b) {
if (a % b == 0) {
return (b);
} else {
return (gcd(b, a % b));
}
}
long long lcm(long long a, long long b) { return a * b / gcd(a, b); }
int main() {
double W, H, X, Y;
cin >> W >> H >> X >> Y;
double area = W * H;
printf("%.9f", area / 2);
if (X == W / 2 && Y == H / 2) {
cout << " " << 1 << endl;
} else {
cout << " " << 0 << endl;
}
} | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.narrow.change"
] | 815,721 | 815,722 | u999904282 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
long long w, h, x, y;
cin >> w >> h >> x >> y;
double area = (w * h) / 2;
printf("%.12f ", area);
if (x * 2 == w && y * 2 == h)
cout << 1 << " ";
else
cout << 0 << " ";
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
long long w, h, x, y;
cin >> w >> h >> x >> y;
double area = double(w) * double(h) / 2;
printf("%.12f ", area);
if (x * 2 == w && y * 2 == h)
cout << 1 << " ";
else
cout << 0 << " ";
return 0;
} | [
"call.add",
"call.arguments.change"
] | 815,723 | 815,724 | u866310595 | cpp |
p03001 | #include <bits/stdc++.h>
using namespace std;
int main() {
long long w, h, x, y;
cin >> w >> h >> x >> y;
double area = (w * h) / 2;
printf("%.9f ", area);
if (x * 2 == w && y * 2 == h)
cout << 1 << " ";
else
cout << 0 << " ";
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
long long w, h, x, y;
cin >> w >> h >> x >> y;
double area = double(w) * double(h) / 2;
printf("%.12f ", area);
if (x * 2 == w && y * 2 == h)
cout << 1 << " ";
else
cout << 0 << " ";
return 0;
} | [
"call.add",
"call.arguments.change",
"literal.string.change",
"io.output.change"
] | 815,725 | 815,724 | u866310595 | cpp |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.