buggy_code stringlengths 11 625k | fixed_code stringlengths 17 625k | bug_type stringlengths 2 4.45k | language int64 0 8 | token_count int64 5 200k |
|---|---|---|---|---|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, k;
cin >> n >> k;
vector<int> inp(n + 1, 0);
for (int i = 1; i <= n; i++) {
// cin >> inp.at(i);
inp.at(i) = 0;
}
vector<int> data(n + 2, 0);
if (k >= 2000) {
k = 2000;
}
for (int j = 0; j < k; j++) {
for (int i = 1... | #include <bits/stdc++.h>
using namespace std;
int main() {
int n, k;
cin >> n >> k;
vector<int> inp(n + 1, 0);
for (int i = 1; i <= n; i++) {
cin >> inp.at(i);
// inp.at(i) = 0;
}
vector<int> data(n + 2, 0);
if (k >= 2000) {
k = 2000;
}
for (int j = 0; j < k; j++) {
for (int i = 1... | [["+", 0, 7, 8, 9, 0, 1, 0, 16, 31, 22], ["+", 0, 7, 8, 9, 0, 1, 0, 16, 17, 152], ["-", 0, 7, 8, 9, 0, 1, 0, 11, 17, 32], ["-", 0, 7, 8, 9, 0, 1, 0, 11, 12, 13]] | 1 | 266 |
import itertools
N, K = map(int,input().split())
A = list(map(int,input().split()))
B = [0] * (N+1)
chk = [N] *N
for k in range(K):
if A == chk:
break
for i in range(N):
if A[i] == 0:
B[i] += 1
B[i+1] -= 1
continue
l = i - A[i]
r = i + A[i]
... | import itertools
N, K = map(int,input().split())
A = list(map(int,input().split()))
B = [0] * (N+1)
chk = [N] *N
for k in range(K):
if A == chk:
break
for i in range(N):
if A[i] == 0:
B[i] += 1
B[i+1] -= 1
continue
l = i - A[i]
r = i + A[i]
... | [["+", 0, 1, 0, 652, 3, 4, 0, 661, 0, 48]] | 5 | 188 |
#include <bits/stdc++.h>
using namespace std;
int a[200005], c[200005], n, k;
int main() {
scanf("%d%d", &n, &k);
register int i, j, t, s, f;
for (i = 1; i <= n; i++)
scanf("%d", &a[i]);
for (j = 1; j <= k; j++) {
memset(c, 0, sizeof(c));
for (i = 1; i <= n; ++i) {
++c[max(1, i - a[i])];
... | #include <bits/stdc++.h>
using namespace std;
int a[200005], c[200005], n, k;
int main() {
scanf("%d%d", &n, &k);
register int i, j, t, s, f;
for (i = 1; i <= n; i++)
scanf("%d", &a[i]);
for (j = 1; j <= k; j++) {
memset(c, 0, sizeof(c));
for (i = 1; i <= n; ++i) {
++c[max(1, i - a[i])];
... | [["-", 0, 27, 28, 69, 341, 342, 0, 2, 63, 22], ["+", 0, 27, 28, 69, 341, 342, 0, 2, 63, 22], ["-", 0, 7, 8, 9, 0, 7, 10, 43, 39, 40]] | 1 | 243 |
#include <bits/stdc++.h>
using namespace std;
int a[200001], c[200002], n, k;
int main() {
cin >> n >> k;
register int i, j, t, s, f;
for (i = 1; i <= n; ++i) {
cin >> a[i];
}
for (j = 1; j <= k; ++j) {
memset(c, 0, sizeof(c));
for (i = 1; i <= n; ++i) {
++c[max(1, i - a[i])];
--c[min(... | #include <bits/stdc++.h>
using namespace std;
int a[200001], c[200002], n, k;
int main() {
cin >> n >> k;
register int i, j, t, s, f;
for (i = 1; i <= n; ++i) {
cin >> a[i];
}
for (j = 1; j <= k; ++j) {
memset(c, 0, sizeof(c));
for (i = 1; i <= n; ++i) {
++c[max(1, i - a[i])];
--c[min(... | [["+", 0, 7, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 0, 7, 8, 9, 0, 7, 8, 9, 0, 46]] | 1 | 225 |
#include <algorithm>
#include <deque>
#include <iomanip>
#include <iostream>
#include <map>
#include <math.h>
#include <queue>
#include <stack>
#include <string>
#include <vector>
const int MOD = 1e9 + 7;
#define PI 3.14159265359
typedef long long ll;
using namespace std;
int main() {
int n, k;
cin >> n >> k;
ve... | #include <algorithm>
#include <deque>
#include <iomanip>
#include <iostream>
#include <map>
#include <math.h>
#include <queue>
#include <stack>
#include <string>
#include <vector>
const int MOD = 1e9 + 7;
#define PI 3.14159265359
typedef long long ll;
using namespace std;
int main() {
int n, k;
cin >> n >> k;
ve... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 19], ["-", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 47], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13]] | 1 | 295 |
N, K = map(int, input().split())
A = list(map(int, input().split()))
b = [0 for i in range(N+2)]
if K > 70:
ans = [N for i in range(N)]
print(*ans)
else:
for _ in range(K):
for i in range(N+2):
b[i] = 0
for i in range(N):
b[max(0, i+1-a[i])] += 1
b[min(N+1... | N, K = map(int, input().split())
A = list(map(int, input().split()))
b = [0 for i in range(N+2)]
if K > 70:
ans = [N for i in range(N)]
print(*ans)
else:
for _ in range(K):
for i in range(N+2):
b[i] = 0
for i in range(N):
b[max(0, i+1-A[i])] += 1
b[min(N+1... | [["-", 206, 652, 3, 4, 0, 657, 12, 206, 51, 22], ["+", 206, 652, 3, 4, 0, 657, 12, 206, 51, 22], ["-", 3, 4, 0, 657, 31, 657, 12, 206, 51, 22], ["+", 3, 4, 0, 657, 31, 657, 12, 206, 51, 22], ["-", 8, 196, 0, 1, 0, 662, 31, 206, 51, 22], ["+", 8, 196, 0, 1, 0, 662, 31, 206, 51, 22], ["-", 0, 1, 0, 652, 3, 4, 0, 661, 0, ... | 5 | 182 |
#include "bits/stdc++.h"
using namespace std;
typedef long long int lint;
typedef pair<lint, lint> plint;
typedef pair<double long, double long> pld;
#define ALL(x) (x).begin(), (x).end()
#define SZ(x) ((lint)(x).size())
#define POW2(n) (1LL << (n))
#define FOR(i, begin, end) ... | #include "bits/stdc++.h"
using namespace std;
typedef long long int lint;
typedef pair<lint, lint> plint;
typedef pair<double long, double long> pld;
#define ALL(x) (x).begin(), (x).end()
#define SZ(x) ((lint)(x).size())
#define POW2(n) (1LL << (n))
#define FOR(i, begin, end) ... | [["-", 15, 339, 51, 16, 31, 69, 341, 342, 0, 22], ["+", 15, 339, 51, 16, 31, 69, 341, 342, 0, 22]] | 1 | 525 |
#include <bits/stdc++.h>
using namespace std;
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
#define ll long long
#define REP(i, a, b) for (ll i = a; i < b; i++)
#define REPI(i, a, b) for (ll i = b - 1; i >= a; i--)
#define i_os ... | #include <bits/stdc++.h>
using namespace std;
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
#define ll long long
#define REP(i, a, b) for (ll i = a; i < b; i++)
#define REPI(i, a, b) for (ll i = b - 1; i >= a; i--)
#define i_os ... | [["-", 0, 57, 15, 339, 51, 16, 12, 16, 17, 72], ["-", 0, 57, 15, 339, 51, 16, 12, 16, 12, 13]] | 1 | 476 |
#include <algorithm>
#include <cassert>
#include <cstdio>
#include <cstdlib>
#include <functional>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
#define repi(i, a, b) for (ll i = (a); i < (b); ++i)
#define rep(i, a) repi(i, 0, ... | #include <algorithm>
#include <cassert>
#include <cstdio>
#include <cstdlib>
#include <functional>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
#define repi(i, a, b) for (ll i = (a); i < (b); ++i)
#define rep(i, a) repi(i, 0, ... | [["-", 0, 1, 0, 11, 12, 16, 12, 69, 28, 22], ["-", 0, 11, 12, 16, 12, 69, 341, 342, 0, 70], ["-", 0, 11, 12, 16, 12, 69, 341, 342, 0, 13], ["-", 0, 11, 12, 16, 12, 69, 341, 342, 0, 73], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 12, 22]] | 1 | 571 |
#include <algorithm>
#include <bitset>
#include <cmath>
#include <cstring>
#include <iomanip>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <regex>
#include <string>
#include <tuple>
#include <vector>
using namespace std;
template <typename T> bool chmax(T &a, const T b) {
if (a <=... | #include <algorithm>
#include <bitset>
#include <cmath>
#include <cstring>
#include <iomanip>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <regex>
#include <string>
#include <tuple>
#include <vector>
using namespace std;
template <typename T> bool chmax(T &a, const T b) {
if (a <=... | [["-", 8, 9, 0, 1, 0, 11, 12, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 11, 12, 2, 63, 22]] | 1 | 2,359 |
#include <bits/stdc++.h>
using namespace std;
int a[200010], b[200010], n, k;
int main() {
int i, j, k, l;
scanf("%d%d", &n, &k);
for (i = 1; i <= n; i++)
scanf("%d", &a[i]);
while (k--) {
for (i = 1; i <= n; i++)
b[i] = 0;
for (i = 1; i <= n; i++) {
j = max(i - a[i], 1);
l = min(i... | #include <bits/stdc++.h>
using namespace std;
int a[200010], b[200010], n, k;
int main() {
int i, j, k, l;
scanf("%d%d", &n, &k);
for (i = 1; i <= n; i++)
scanf("%d", &a[i]);
while (k--) {
for (i = 1; i <= n; i++)
b[i] = 0;
for (i = 1; i <= n; i++) {
j = max(i - a[i], 1);
l = min(i... | [["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 98], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 31, 22], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 17, 20], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 12, 13]] | 1 | 310 |
#include <bits/stdc++.h>
#define all(x) (x).begin(), (x).end()
typedef long long ll;
#define MOD 1000000007
using namespace std;
vector<ll> imos(vector<ll> &a) {
ll n = a.size();
vector<ll> ims(n + 1, 0);
for (int i = 0; i < n; i++) {
ims[max(0LL, i - a[i])]++;
ims[min(n, i + a[i] + 1)]--;
}
for (int ... | #include <bits/stdc++.h>
#define all(x) (x).begin(), (x).end()
typedef long long ll;
#define MOD 1000000007
using namespace std;
vector<ll> imos(vector<ll> &a) {
ll n = a.size();
vector<ll> ims(n + 1, 0);
for (int i = 0; i < n; i++) {
ims[max(0LL, i - a[i])]++;
ims[min(n, i + a[i] + 1)]--;
}
for (int ... | [["+", 49, 50, 51, 2, 3, 4, 0, 16, 17, 72], ["+", 49, 50, 51, 2, 3, 4, 0, 16, 12, 13]] | 1 | 278 |
#include <bits/stdc++.h>
#define rep(i, a, b) for (int i = (a); i < (b); ++i)
#define per(i, a, b) for (int i = (b)-1; i >= (a); --i)
#define fi first
#define se second
#define all(x) (x).begin(), (x).end()
#define sz(x) (int)(x).size()
#define mp make_pair
#define pb push_back
using namespace std;
typedef long long ll... | #include <bits/stdc++.h>
#define rep(i, a, b) for (int i = (a); i < (b); ++i)
#define per(i, a, b) for (int i = (b)-1; i >= (a); --i)
#define fi first
#define se second
#define all(x) (x).begin(), (x).end()
#define sz(x) (int)(x).size()
#define mp make_pair
#define pb push_back
using namespace std;
typedef long long ll... | [["+", 0, 14, 8, 9, 0, 1, 0, 16, 17, 151], ["+", 8, 9, 0, 1, 0, 16, 12, 103, 0, 104], ["+", 8, 9, 0, 1, 0, 16, 12, 103, 0, 125]] | 1 | 305 |
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ull = unsigned long long;
using ld = long double;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
using pli = pair<ll, int>;
using pil = pair<int, ll>;
using uint = unsigned int;
template <typename T> using Graph = vector<vector<T>>;
const ... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ull = unsigned long long;
using ld = long double;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
using pli = pair<ll, int>;
using pil = pair<int, ll>;
using uint = unsigned int;
template <typename T> using Graph = vector<vector<T>>;
const ... | [["-", 51, 218, 8, 9, 0, 1, 0, 27, 28, 22], ["-", 51, 218, 8, 9, 0, 1, 0, 27, 17, 68], ["-", 49, 50, 51, 218, 8, 9, 0, 1, 0, 35]] | 1 | 341 |
from heapq import heappush, heappop
N, K = map(int, input().split())
A = [int(i) for i in input().split()]
while K and sum(A) < N * N :
l = [0] * N
h = []
for i in range(N) :
while h and h[0] < i :
heappop(h)
l[i] = len(h)
heappush(h, (i + A[i]))
r = [0] * N
h = []
for i in range(N ... | from heapq import heappush, heappop
N, K = map(int, input().split())
A = [int(i) for i in input().split()]
while K and sum(A) < N * N :
l = [0] * N
h = []
for i in range(N) :
while h and h[0] < i :
heappop(h)
l[i] = len(h)
heappush(h, (i + A[i]))
r = [0] * N
h = []
for i in range(N ... | [["-", 8, 196, 0, 52, 15, 679, 12, 666, 667, 47], ["+", 8, 196, 0, 52, 15, 679, 12, 666, 667, 18], ["+", 0, 52, 15, 679, 12, 666, 0, 664, 17, 33], ["+", 0, 1, 0, 652, 3, 4, 0, 23, 0, 24], ["+", 0, 652, 3, 4, 0, 23, 0, 664, 17, 33], ["+", 3, 4, 0, 23, 0, 664, 28, 23, 0, 25]] | 5 | 202 |
/*
AuThOr Gwj
*/
#include <bits/stdc++.h>
#define rb(a, b, c) for (int a = b; a <= c; ++a)
#define rl(a, b, c) for (int a = b; a >= c; --a)
#define LL long long
#define IT iterator
#define PB push_back
#define II(a, b) make_pair(a, b)
#define FIR first
#define SEC second
#define FREO freopen("check.out", "w", stdout)
#... | /*
AuThOr Gwj
*/
#include <bits/stdc++.h>
#define rb(a, b, c) for (int a = b; a <= c; ++a)
#define rl(a, b, c) for (int a = b; a >= c; --a)
#define LL long long
#define IT iterator
#define PB push_back
#define II(a, b) make_pair(a, b)
#define FIR first
#define SEC second
#define FREO freopen("check.out", "w", stdout)
#... | [["-", 15, 339, 51, 16, 31, 69, 341, 342, 0, 22], ["+", 15, 339, 51, 16, 31, 69, 341, 342, 0, 22]] | 1 | 352 |
#include <bits/stdc++.h>
using namespace std;
#define LL long long
#define ULL unsigned long long
#define mp make_pair
#define pb push_back
#define pii pair<int, int>
#define pll pair<LL, LL>
#define x first
#define y second
#define pi acosl(-1)
#define sqr(x) ((x) * (x))
#define pdd pair<double, double>
#define MEMS(x... | #include <bits/stdc++.h>
using namespace std;
#define LL long long
#define ULL unsigned long long
#define mp make_pair
#define pb push_back
#define pii pair<int, int>
#define pll pair<LL, LL>
#define x first
#define y second
#define pi acosl(-1)
#define sqr(x) ((x) * (x))
#define pdd pair<double, double>
#define MEMS(x... | [["-", 64, 9, 0, 7, 10, 43, 49, 50, 51, 13], ["+", 64, 9, 0, 7, 10, 43, 49, 50, 51, 13], ["-", 0, 57, 64, 9, 0, 7, 15, 16, 17, 18], ["+", 0, 57, 64, 9, 0, 7, 15, 16, 17, 19], ["-", 8, 9, 0, 1, 0, 11, 12, 16, 31, 13], ["-", 8, 9, 0, 1, 0, 11, 12, 16, 17, 48]] | 1 | 368 |
#include <cmath>
#include <iostream>
#include <vector>
using namespace std;
int main() {
int N, K;
cin >> N >> K;
vector<int> a(N);
for (int i = 0; i < N; ++i) {
cin >> a[i];
}
int trial_num;
if (K >= 41)
trial_num = 41;
else
K = N;
for (int n = 0; n <= trial_num; ++n) {
vector<in... | #include <cmath>
#include <iostream>
#include <vector>
using namespace std;
int main() {
int N, K;
cin >> N >> K;
vector<int> a(N);
for (int i = 0; i < N; ++i) {
cin >> a[i];
}
int trial_num;
if (K >= 41)
trial_num = 41;
else
trial_num = K;
for (int n = 0; n < trial_num; ++n) {
ve... | [["-", 0, 57, 75, 76, 0, 1, 0, 11, 31, 22], ["+", 0, 57, 75, 76, 0, 1, 0, 11, 31, 22], ["-", 0, 57, 75, 76, 0, 1, 0, 11, 12, 22], ["+", 0, 57, 75, 76, 0, 1, 0, 11, 12, 22], ["-", 0, 14, 8, 9, 0, 7, 15, 16, 17, 19], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 17, 18]] | 1 | 258 |
package main
import (
"bufio"
"fmt"
"log"
"os"
"reflect"
"strconv"
)
func main() {
n := readInt64()
k := int(readInt64())
a := readInt64Slice(n)
for i := 0; i < k; i++ {
b := make([]int64, n+1)
for j := int64(0); j < n; j++ {
l := max(0, j-a[j])
r := min(n, j+a[j]+1)
b[l]++
b[r]--
}
f... | package main
import (
"bufio"
"fmt"
"log"
"os"
"reflect"
"strconv"
)
func main() {
n := readInt64()
k := int(readInt64())
a := readInt64Slice(n)
for i := 0; i < k; i++ {
b := make([]int64, n+1)
for j := int64(0); j < n; j++ {
l := max(0, j-a[j])
r := min(n, j+a[j]+1)
b[l]++
b[r]--
}
f... | [["-", 8, 196, 0, 1, 0, 2, 63, 438, 439, 22], ["-", 8, 196, 0, 1, 0, 2, 63, 438, 0, 131], ["-", 8, 196, 0, 1, 0, 2, 63, 438, 119, 120], ["-", 8, 196, 0, 1, 0, 2, 3, 4, 0, 24], ["-", 8, 196, 0, 1, 0, 2, 3, 4, 0, 22], ["-", 8, 196, 0, 1, 0, 2, 3, 4, 0, 25], ["-", 36, 36, 0, 434, 0, 435, 8, 196, 0, 165], ["+", 36, 36, 0, ... | 7 | 501 |
import math
N,K = map(int,input().split())
A = list(map(int,input().split()))
for j in range(min(K,int(math.log2(N)))):
B = [0]*N
for i in range(N):
l = max(0,i-A[i])
r = min(N-1,i+A[i])
B[l] += 1
if r < N-1:
B[r+1] -= 1
for i in range(1,N):
B[i] += B[i-1]
A = B
print(' '.join(map(str,A)))
| import math
N,K = map(int,input().split())
A = list(map(int,input().split()))
for j in range(min(K,int(2*(math.log2(N)))+10)):
B = [0]*N
for i in range(N):
l = max(0,i-A[i])
r = min(N-1,i+A[i])
B[l] += 1
if r < N-1:
B[r+1] -= 1
for i in range(1,N):
B[i] += B[i-1]
A = B
print(' '.join(map(str,A)))
| [["+", 0, 657, 31, 652, 3, 4, 0, 657, 31, 612], ["+", 0, 657, 31, 652, 3, 4, 0, 657, 17, 48], ["+", 31, 652, 3, 4, 0, 657, 12, 23, 0, 24], ["+", 0, 657, 12, 23, 0, 652, 3, 4, 0, 25], ["+", 3, 4, 0, 652, 3, 4, 0, 657, 17, 72], ["+", 3, 4, 0, 652, 3, 4, 0, 657, 12, 612]] | 5 | 160 |
def main():
N, K = map(int, input().split())
A = list(map(int, input().split())) # 整数のリスト
B = [0] * N
for j in range(K, 41):
for i in range(N):
l = max(0, i-A[i])
r = min(N-1, i+A[i])
B[l] += 1
if r+1 < N: B[r+1] -= 1
for i in range(1,N):... | def main():
N, K = map(int, input().split())
A = list(map(int, input().split())) # 整数のリスト
B = [0] * N
for j in range(min(K, 41)):
for i in range(N):
l = max(0, i-A[i])
r = min(N-1, i+A[i])
B[l] += 1
if r+1 < N: B[r+1] -= 1
for i in range(... | [["+", 0, 7, 12, 652, 3, 4, 0, 652, 63, 22], ["+", 12, 652, 3, 4, 0, 652, 3, 4, 0, 24], ["+", 12, 652, 3, 4, 0, 652, 3, 4, 0, 25]] | 5 | 169 |
#include <algorithm>
#include <iostream>
#include <math.h>
#include <vector>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
int main() {
int N, K;
cin >> N >> K;
vector<int> A(N);
for (int i = 0; i < N; i++) {
cin >> A[i];
}
rep(k, K) {
vector<int> B(N, 0);
rep(i,... | #include <algorithm>
#include <iostream>
#include <math.h>
#include <vector>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
int main() {
int N, K;
cin >> N >> K;
vector<int> A(N);
for (int i = 0; i < N; i++) {
cin >> A[i];
}
rep(k, K) {
vector<int> B(N, 0);
rep(i,... | [["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 72], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13]] | 1 | 244 |
((stdin) => {
let [l1, l2] = stdin.split('\n');
let [n, k] = l1.split(' ');
[n, k] = [ +n, +k ];
let a = l2.split(' ');
for (let i = 0; i < n; i++) {
a[i] = +a[i];
}
for (let j = 0; j < k && j < 41; j++) {
let b = new Array(n).fill(0);
for (let i = 0; i < n; i++) {
let l = Math.max(0, ... | ((stdin) => {
let [l1, l2] = stdin.split('\n');
let [n, k] = l1.split(' ');
[n, k] = [ +n, +k ];
let a = l2.split(' ');
for (let i = 0; i < n; i++) {
a[i] = +a[i];
}
for (let j = 0; j < k && j < 41; j++) {
let b = new Array(n).fill(0);
for (let i = 0; i < n; i++) {
let l = Math.max(0, ... | [["-", 0, 2, 3, 3, 0, 2, 63, 558, 500, 22], ["+", 0, 2, 3, 3, 0, 2, 63, 558, 500, 22]] | 2 | 273 |
#include <bits/stdc++.h>
using namespace std;
#define all(n) begin(n), end(n)
const long long INF = numeric_limits<long long>::max();
typedef long long ll;
typedef vector<int> vint;
typedef vector<vector<int>> vvint;
typedef vector<ll> vll;
typedef vector<vector<ll>> vvll;
typedef unsigned long long ull;
template <clas... | #include <bits/stdc++.h>
using namespace std;
#define all(n) begin(n), end(n)
const long long INF = numeric_limits<long long>::max();
typedef long long ll;
typedef vector<int> vint;
typedef vector<vector<int>> vvint;
typedef vector<ll> vll;
typedef vector<vector<ll>> vvll;
typedef unsigned long long ull;
template <clas... | [["-", 0, 14, 8, 9, 0, 7, 15, 16, 12, 22], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 12, 22]] | 1 | 544 |
#include <bits/stdc++.h>
using namespace std;
#define REP(i, n) for (int i = 0; i < (n); i++)
#define REAP(i, a, n) for (int i = (a); i < (n); i++)
#define YES cout << "Yes" << endl
#define NO cout << "No" << endl
#define fr first
#define sc second
#define pb push_back
#define All(v) v.begin(), v.end()
typedef long lo... | #include <bits/stdc++.h>
using namespace std;
#define REP(i, n) for (int i = 0; i < (n); i++)
#define REAP(i, a, n) for (int i = (a); i < (n); i++)
#define YES cout << "Yes" << endl
#define NO cout << "No" << endl
#define fr first
#define sc second
#define pb push_back
#define All(v) v.begin(), v.end()
typedef long lo... | [["-", 15, 339, 51, 16, 31, 69, 341, 342, 0, 22], ["+", 15, 339, 51, 16, 31, 69, 341, 342, 0, 22]] | 1 | 281 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int N, K;
cin >> N >> K;
vector<int> A(N), B(N), C(N);
vector<int> D(N, N);
for (int i = 0; i < N; i++) {
cin >> A.at(i);
}
for (int a = 0; a < K; a++) {
if (A == D)
break;
for (int i = 0; i < N; i++) {
int j = max(0, i -... | #include <bits/stdc++.h>
using namespace std;
int main() {
int N, K;
cin >> N >> K;
vector<int> A(N), B(N), C(N);
vector<int> D(N, N);
for (int i = 0; i < N; i++) {
cin >> A.at(i);
}
for (int a = 0; a < K; a++) {
if (A == D)
break;
for (int i = 0; i < N; i++) {
int j = max(0, i -... | [["+", 0, 27, 28, 2, 3, 4, 0, 16, 17, 72], ["+", 0, 27, 28, 2, 3, 4, 0, 16, 12, 13]] | 1 | 256 |
N, K=map(int, input().split())
A=list(map(int, input().split()))
for i in range(K):
p=[0]*N
n=[0]*N
for i in range(N):
if i-A[i]>0:
p[i-A[i]]+=1
else:
p[0]+=1
if i+A[i]<N-1:
n[i+A[i]+1]+=1
light=0
Ncount=0
for i in range(N):
light=light+p[i]-n[i]
A[i]=light
if light... | N, K=map(int, input().split())
A=list(map(int, input().split()))
for i in range(K):
p=[0]*N
n=[0]*N
for i in range(N):
if i-A[i]>0:
p[i-A[i]]+=1
else:
p[0]+=1
if i+A[i]<N-1:
n[i+A[i]+1]+=1
light=0
Ncount=0
for i in range(N):
light=light+p[i]-n[i]
A[i]=light
if light... | [["+", 0, 57, 64, 196, 0, 1, 0, 652, 63, 22], ["+", 64, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 64, 196, 0, 1, 0, 652, 3, 4, 0, 25]] | 5 | 192 |
# coding: utf-8
# Your code here!
import time
t1=time.time()
def LI():return list(map(int,input().split()))
n,k=LI()
a=LI()
for _ in range(k):
tab=[0]*(n)
for i in range(n):
q=a[i]
if 0<=i-q:
tab[i-q]+=1
else:
tab[0]+=1
if i+q+1<=n-1:
tab[i+q+... | # coding: utf-8
# Your code here!
import time
t1=time.time()
def LI():return list(map(int,input().split()))
n,k=LI()
a=LI()
for _ in range(k):
tab=[0]*(n)
for i in range(n):
q=a[i]
if 0<=i-q:
tab[i-q]+=1
else:
tab[0]+=1
if i+q+1<=n-1:
tab[i+q+... | [["-", 8, 196, 0, 57, 64, 196, 0, 93, 0, 94], ["+", 0, 57, 64, 196, 0, 1, 0, 652, 63, 22], ["+", 64, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 64, 196, 0, 1, 0, 652, 3, 4, 0, 25]] | 5 | 198 |
from math import log2
n,k = map(int,input().split())
a = list(map(int,input().split()))
b = [0]*n
if(k > log2(n)):
for i in range(n):
print(n,end=" ")
else:
for j in range(k):
b = [0]*n
for i in range(n):
l = max(0,i-a[i])
r = min(n-1,a[i]+i)
b[l] +=... | from math import log2
n,k = map(int,input().split())
a = list(map(int,input().split()))
b = [0]*n
if(k > 10*log2(n) + 1):
for i in range(n):
print(n,end=" ")
else:
for j in range(k):
b = [0]*n
for i in range(n):
l = max(0,i-a[i])
r = min(n-1,a[i]+i)
... | [["+", 15, 23, 0, 666, 0, 657, 31, 657, 31, 612], ["+", 15, 23, 0, 666, 0, 657, 31, 657, 17, 48], ["+", 0, 57, 15, 23, 0, 666, 0, 657, 17, 72], ["+", 0, 57, 15, 23, 0, 666, 0, 657, 12, 612]] | 5 | 187 |
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define ALL(obj) (obj).begin, (obj).end()
int main() {
ll N, K;
cin >> N >> K;
vector<ll> A(N);
ll minA = N + 1;
for (int i = 0; i < N; i++) {
cin >> A[i];
}
while (K > 0) {
minA = N + 1;
vector<ll> B(N, 0);
for (int ... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define ALL(obj) (obj).begin, (obj).end()
int main() {
ll N, K;
cin >> N >> K;
vector<ll> A(N);
ll minA = N + 1;
for (int i = 0; i < N; i++) {
cin >> A[i];
}
while (K > 0) {
minA = N + 1;
vector<ll> B(N, 0);
for (int ... | [["+", 0, 57, 64, 9, 0, 7, 8, 9, 0, 46], ["-", 0, 57, 64, 9, 0, 7, 8, 9, 0, 46]] | 1 | 311 |
#include <bits/stdc++.h>
typedef long long int ll;
typedef long double ld;
using namespace std;
const long long int INF = 1e18;
const long long int mod = 1e9 + 7;
typedef pair<ll, ll> pairs;
typedef vector<pairs> p;
struct Edge {
ll to, weight;
Edge(ll t, ll w) : to(t), weight(w) {}
};
using graph = vector<vector... | #include <bits/stdc++.h>
typedef long long int ll;
typedef long double ld;
using namespace std;
const long long int INF = 1e18;
const long long int mod = 1e9 + 7;
typedef pair<ll, ll> pairs;
typedef vector<pairs> p;
struct Edge {
ll to, weight;
Edge(ll t, ll w) : to(t), weight(w) {}
};
using graph = vector<vector... | [["+", 0, 7, 8, 9, 0, 1, 0, 16, 17, 151], ["+", 8, 9, 0, 1, 0, 16, 12, 103, 0, 104], ["+", 8, 9, 0, 1, 0, 16, 12, 103, 0, 125]] | 1 | 521 |
#!/usr/bin python3
# -*- coding: utf-8 -*-
def main():
N, K = map(int, input().split())
A = list(map(int, input().split()))
for i in range(min(K,100)):
dm = [0]*N
for x in range(N):
dm[max(x - A[x],0)]+=1
if x+A[i]+1<N:
dm[x+A[x]+1]+=-1
for j... | #!/usr/bin python3
# -*- coding: utf-8 -*-
def main():
N, K = map(int, input().split())
A = list(map(int, input().split()))
for i in range(min(K,50)):
dm = [0]*N
for x in range(N):
dm[max(x - A[x],0)]+=1
if x+A[x]+1<N:
dm[x+A[x]+1]+=-1
for j ... | [["-", 12, 652, 3, 4, 0, 652, 3, 4, 0, 612], ["+", 12, 652, 3, 4, 0, 652, 3, 4, 0, 612], ["-", 15, 666, 0, 657, 31, 657, 12, 206, 206, 22], ["+", 15, 666, 0, 657, 31, 657, 12, 206, 206, 22]] | 5 | 160 |
#include <bits/stdc++.h>
#include <cctype>
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); i++)
#define all(v) (v).begin(), (v).end()
typedef long long int ll;
#define pi 3.1415926535897932384
#define E9 1000000000
#define eps 1e-4
#define pii pair<int, int>
int main() {
int N, K;
cin >> N >> K;
... | #include <bits/stdc++.h>
#include <cctype>
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); i++)
#define all(v) (v).begin(), (v).end()
typedef long long int ll;
#define pi 3.1415926535897932384
#define E9 1000000000
#define eps 1e-4
#define pii pair<int, int>
int main() {
int N, K;
cin >> N >> K;
... | [["-", 3, 4, 0, 2, 3, 4, 0, 16, 31, 22], ["-", 3, 4, 0, 2, 3, 4, 0, 16, 17, 85], ["-", 3, 4, 0, 2, 3, 4, 0, 16, 12, 13], ["+", 0, 2, 3, 4, 0, 2, 3, 4, 0, 13]] | 1 | 253 |
#include <bits/stdc++.h>
#if ONLINE_JUDGE
#define DEBUG false
#else
#define DEBUG true
#endif
#define REP(i, k, n) \
for (signed long long int i = (signed long long int)(k); \
i < (signed long long int)(n); i++)
#define rep(i, n) REP... | #include <bits/stdc++.h>
#if ONLINE_JUDGE
#define DEBUG false
#else
#define DEBUG true
#endif
#define REP(i, k, n) \
for (signed long long int i = (signed long long int)(k); \
i < (signed long long int)(n); i++)
#define rep(i, n) REP... | [["-", 49, 50, 51, 2, 3, 4, 0, 16, 31, 22], ["+", 49, 50, 51, 2, 3, 4, 0, 16, 31, 22], ["+", 0, 27, 28, 69, 341, 342, 0, 16, 17, 72], ["+", 0, 27, 28, 69, 341, 342, 0, 16, 12, 13]] | 1 | 771 |
#!/usr/bin/env python3
import sys
def solve(N: int, K: int, A: "List[int]"):
for k in range(K):
B = [0] * N
for i in range(N):
l = max(0, i - A[i])
r = i + A[i]
B[l] += 1
if r + 1 < N:
B[r + 1] -= 1
for i in range(1, N):
... | #!/usr/bin/env python3
import sys
def solve(N: int, K: int, A: "List[int]"):
for k in range(K):
B = [0] * N
for i in range(N):
l = max(0, i - A[i])
r = i + A[i]
B[l] += 1
if r + 1 < N:
B[r + 1] -= 1
for i in range(1, N):
... | [["-", 8, 196, 0, 57, 15, 666, 0, 657, 12, 22], ["+", 8, 196, 0, 57, 15, 666, 0, 657, 12, 22]] | 5 | 222 |
//
#include <bits/stdc++.h>
using namespace std;
#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, start, end) for (int i = (int)start; i <= (int)end; i++)
#define vrep(i, n) for (int i = (int)n - 1; i >= 0; i--)
#define vrep1(i, n) for (int i ... | //
#include <bits/stdc++.h>
using namespace std;
#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, start, end) for (int i = (int)start; i <= (int)end; i++)
#define vrep(i, n) for (int i = (int)n - 1; i >= 0; i--)
#define vrep1(i, n) for (int i ... | [["-", 0, 1, 0, 2, 3, 4, 0, 16, 17, 33], ["-", 0, 1, 0, 2, 3, 4, 0, 16, 12, 13], ["-", 0, 1, 0, 2, 3, 4, 0, 25, 0, 35]] | 1 | 1,231 |
n, k = map(int, input().split())
A = list(map(int, input().split()))
for i in range(k):
B = [0] * (n+1)
for j in range(n):
B[max(0, j-A[j])] += 1
B[min(n, j+A[j])] -= 1
A[0] = B[0]
for j in range(1, n):
A[j] = A[j-1]+B[j]
if A == [n]*n:
print(*A)
exit()
print(... | n, k = map(int, input().split())
A = list(map(int, input().split()))
for i in range(k):
B = [0] * (n+1)
for j in range(n):
B[max(0, j-A[j])] += 1
B[min(n, j+A[j]+1)] -= 1
A[0] = B[0]
for j in range(1, n):
A[j] = A[j-1]+B[j]
if A == [n]*n:
print(*A)
exit()
prin... | [["+", 31, 206, 206, 652, 3, 4, 0, 657, 17, 72], ["+", 31, 206, 206, 652, 3, 4, 0, 657, 12, 612]] | 5 | 149 |
#include <bits/stdc++.h>
#include <stdlib.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
typedef pair<ll, ll> llP;
ll mod(ll a, ll b) {
ll ret = a % b;
if (ret < 0)
ret += b;
return ret;
}
ll modpow(ll a, ll b, ll c) {
ll res = 1;
while (b > 0) {
if (b & 1)
res = mod(r... | #include <bits/stdc++.h>
#include <stdlib.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
typedef pair<ll, ll> llP;
ll mod(ll a, ll b) {
ll ret = a % b;
if (ret < 0)
ret += b;
return ret;
}
ll modpow(ll a, ll b, ll c) {
ll res = 1;
while (b > 0) {
if (b & 1)
res = mod(r... | [["+", 0, 27, 28, 69, 341, 342, 0, 16, 17, 72], ["+", 0, 27, 28, 69, 341, 342, 0, 16, 12, 13]] | 1 | 435 |
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp> // Common file
#include <ext/pb_ds/tree_policy.hpp>
#define ll long long
#define pb push_back
#define vi vector<long long>
#include <ext/pb_ds/assoc_container.hpp> // Common file
#include <ext/pb_ds/tree_policy.hpp>
#include <functional> // for less
usin... | #include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp> // Common file
#include <ext/pb_ds/tree_policy.hpp>
#define ll long long
#define pb push_back
#define vi vector<long long>
#include <ext/pb_ds/assoc_container.hpp> // Common file
#include <ext/pb_ds/tree_policy.hpp>
#include <functional> // for less
usin... | [["-", 15, 339, 51, 16, 31, 69, 341, 342, 0, 22], ["+", 15, 339, 51, 16, 31, 69, 341, 342, 0, 22]] | 1 | 1,206 |
// include
//------------------------------------------
#include <bits/stdc++.h>
using namespace std;
// typedef
//------------------------------------------
using LL = int64_t;
using VL = vector<LL>;
using VVL = vector<VL>;
using VS = vector<string>;
using PLL = pair<LL, LL>;
// container util
//--------------------... | // include
//------------------------------------------
#include <bits/stdc++.h>
using namespace std;
// typedef
//------------------------------------------
using LL = int64_t;
using VL = vector<LL>;
using VVL = vector<VL>;
using VS = vector<string>;
using PLL = pair<LL, LL>;
// container util
//--------------------... | [["-", 0, 57, 15, 339, 51, 16, 12, 69, 28, 22], ["-", 15, 339, 51, 16, 12, 69, 341, 342, 0, 70], ["-", 51, 16, 12, 69, 341, 342, 0, 16, 31, 22], ["-", 51, 16, 12, 69, 341, 342, 0, 16, 17, 72], ["-", 51, 16, 12, 69, 341, 342, 0, 16, 12, 13], ["-", 15, 339, 51, 16, 12, 69, 341, 342, 0, 73], ["+", 8, 9, 0, 57, 15, 339, 51... | 1 | 1,205 |
N,K=map(int,input().split())
ls=list(map(int,input().split()))
for _ in range(K):
if ls==[N]*N:
break
else:
R=[0]*(N)
for i in range(N):
R[max([0,i-ls[i]])]+=1
if i+ls[i]+1<N:
R[i+ls[i]+1]-=1
ls[0]=R[0]
for i in range(N-1):
ls[i+1]=ls[i]+R[i+1]
for i in range(N)... | N,K=map(int,input().split())
ls=list(map(int,input().split()))
for _ in range(K):
if ls==[N]*N:
break
else:
R=[0]*(N)
for i in range(N):
R[max([0,i-ls[i]])]+=1
if i+ls[i]+1<N:
R[i+ls[i]+1]-=1
ls[0]=R[0]
for i in range(N-1):
ls[i+1]=ls[i]+R[i+1]
for i in range(N)... | [["+", 0, 652, 3, 4, 0, 653, 51, 557, 0, 6]] | 5 | 170 |
//#include <tourist>
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<ll, ll> p;
const int INF = 1e9;
const ll LINF = ll(1e18);
const int MOD = 1000000007;
const int dx[4] = {0, 1, 0, -1}, dy[4] = {-1, 0, 1, 0};
const int Dx[8] = {0, 1, 1, 1, 0, -1, -1, -1},
Dy[8] = {-1, -1, 0,... | //#include <tourist>
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<ll, ll> p;
const int INF = 1e9;
const ll LINF = ll(1e18);
const int MOD = 1000000007;
const int dx[4] = {0, 1, 0, -1}, dy[4] = {-1, 0, 1, 0};
const int Dx[8] = {0, 1, 1, 1, 0, -1, -1, -1},
Dy[8] = {-1, -1, 0,... | [["-", 31, 16, 31, 16, 12, 69, 341, 342, 0, 22], ["+", 31, 16, 31, 16, 12, 69, 341, 342, 0, 22]] | 1 | 485 |
from math import log2
def main():
N,K = map(int,input().split())
A = list(map(int,input().split()))
if K > log2(N):
return print(*[N]*N,sep = " ")
for _ in range(K):
imos = [0]*(N + 1)
for i in range(N):
imos[max(0,i - A[i])] += 1
imos[min(N,i + 1 + A[i]... | from math import log2
def main():
N,K = map(int,input().split())
A = list(map(int,input().split()))
if K > log2(N)+ 50:
return print(*[N]*N,sep = " ")
for _ in range(K):
imos = [0]*(N + 1)
for i in range(N):
imos[max(0,i - A[i])] += 1
imos[min(N,i + 1 + ... | [["+", 8, 196, 0, 57, 15, 666, 0, 657, 17, 72], ["+", 8, 196, 0, 57, 15, 666, 0, 657, 12, 612]] | 5 | 179 |
#pragma region template 2.4
#include <bits/stdc++.h>
using namespace std;
template <typename T> using pq_asc = priority_queue<T, vector<T>, greater<T>>;
typedef long long ll;
typedef vector<ll> vi;
typedef vector<vi> vvi;
typedef pair<ll, ll> ii;
typedef vector<ii> vii;
typedef vector<string> vs;
#define REP(i, n) for ... | #pragma region template 2.4
#include <bits/stdc++.h>
using namespace std;
template <typename T> using pq_asc = priority_queue<T, vector<T>, greater<T>>;
typedef long long ll;
typedef vector<ll> vi;
typedef vector<vi> vvi;
typedef pair<ll, ll> ii;
typedef vector<ii> vii;
typedef vector<string> vs;
#define REP(i, n) for ... | [["-", 8, 9, 0, 1, 0, 2, 3, 4, 0, 13], ["+", 0, 1, 0, 2, 3, 4, 0, 2, 63, 22], ["+", 0, 2, 3, 4, 0, 2, 3, 4, 0, 24], ["+", 0, 2, 3, 4, 0, 2, 3, 4, 0, 22], ["+", 0, 2, 3, 4, 0, 2, 3, 4, 0, 21], ["+", 0, 2, 3, 4, 0, 2, 3, 4, 0, 13], ["+", 0, 2, 3, 4, 0, 2, 3, 4, 0, 25]] | 1 | 552 |
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); ++i)
#define all(v) v.begin(), v.end()
using namespace std;
typedef long long ll;
int main() {
ll a, v, b, w, t;
cin >> a >> v >> b >> w >> t;
string ans = "NO";
ll axmin = a - v * t;
ll axmax = a + v * t;
ll bxmin = b - w * t;
ll bxmax ... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); ++i)
#define all(v) v.begin(), v.end()
using namespace std;
typedef long long ll;
int main() {
ll a, v, b, w, t;
cin >> a >> v >> b >> w >> t;
string ans = "NO";
ll axmin = a - v * t;
ll axmax = a + v * t;
ll bxmin = b - w * t;
ll bxmax ... | [["-", 0, 57, 15, 339, 51, 16, 31, 16, 17, 18], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 19], ["-", 0, 57, 15, 339, 51, 16, 12, 16, 17, 47], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 17, 20]] | 1 | 122 |
a, v = gets.split.map(&:to_i)
b, w = gets.split.map(&:to_i)
t = gets.to_i
puts v * t - w * t > (a - b).abs ? 'YES' : 'NO' | a, v = gets.split.map(&:to_i)
b, w = gets.split.map(&:to_i)
t = gets.to_i
puts v * t - w * t >= (a - b).abs ? 'YES' : 'NO' | [["-", 0, 652, 3, 4, 0, 754, 15, 738, 17, 47], ["+", 0, 652, 3, 4, 0, 754, 15, 738, 17, 20]] | 4 | 55 |
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())
d = abs(a - b)
if v * t > w * t + d:
print('YES')
else:
print('NO') | a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())
d = abs(a - b)
if v * t >= w * t + d:
print('YES')
else:
print('NO') | [["-", 36, 36, 0, 656, 0, 57, 15, 666, 667, 47], ["+", 36, 36, 0, 656, 0, 57, 15, 666, 667, 20]] | 5 | 73 |
#include <bits/stdc++.h>
#define fasterthanlight \
ios_base::sync_with_stdio(false); \
cin.tie(NULL); \
cout.tie(NULL)
#define test ... | #include <bits/stdc++.h>
#define fasterthanlight \
ios_base::sync_with_stdio(false); \
cin.tie(NULL); \
cout.tie(NULL)
#define test ... | [["-", 8, 9, 0, 43, 49, 50, 51, 2, 63, 22], ["-", 0, 43, 49, 50, 51, 2, 3, 4, 0, 24], ["-", 0, 43, 49, 50, 51, 2, 3, 4, 0, 25]] | 1 | 114 |
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
constexpr int di[] = {0, 1, 0, -1}, dj[] = {1, 0, -1, 0};
#define rep(i, n) for (int i = 0; i < n; i++)
#define repr(i, n) for (int i = n; i >= 0; i--)
#define SORT(v) sort((v).begin(), (v).end())
#define SORTR(v) sort((v).rbe... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
constexpr int di[] = {0, 1, 0, -1}, dj[] = {1, 0, -1, 0};
#define rep(i, n) for (int i = 0; i < n; i++)
#define repr(i, n) for (int i = n; i >= 0; i--)
#define SORT(v) sort((v).begin(), (v).end())
#define SORTR(v) sort((v).rbe... | [["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 842 |
A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())
kyori = B-A
tikaduki = V-W
if T*tikaduki <kyori:
print("NO")
else:
print("YES")
| A, V = map(int, input().split())
B, W = map(int, input().split())
T = int(input())
kyori = abs(B-A)
tikaduki = V-W
if T*tikaduki <kyori:
print("NO")
else:
print("YES")
| [["+", 0, 656, 0, 1, 0, 662, 12, 652, 63, 22], ["+", 0, 1, 0, 662, 12, 652, 3, 4, 0, 24], ["+", 0, 1, 0, 662, 12, 652, 3, 4, 0, 25]] | 5 | 71 |
#include <bits/stdc++.h>
#define ll long long
#define pb push_back
#define mp make_pair
using namespace std;
const int MOD = 1000000007;
const ll INF = 1LL << 60;
int main() {
cin.tie(0);
ios::sync_with_stdio(false);
ll a, v, b, w, t;
cin >> a >> v >> b >> w >> t;
if (w >= v) {
cout << "NO" << endl;
} e... | #include <bits/stdc++.h>
#define ll long long
#define pb push_back
#define mp make_pair
using namespace std;
const int MOD = 1000000007;
const ll INF = 1LL << 60;
int main() {
cin.tie(0);
ios::sync_with_stdio(false);
ll a, v, b, w, t;
cin >> a >> v >> b >> w >> t;
if (w >= v) {
cout << "NO" << endl;
} e... | [["-", 0, 9, 0, 57, 15, 339, 51, 16, 17, 18], ["+", 0, 9, 0, 57, 15, 339, 51, 16, 17, 19]] | 1 | 132 |
import sys
from collections import defaultdict, Counter, namedtuple, deque
import itertools
import functools
import bisect
import heapq
# import math
from math import gcd
MOD = 10 ** 9 + 7
# MOD = 998244353
# sys.setrecursionlimit(10**8)
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input(... | import sys
from collections import defaultdict, Counter, namedtuple, deque
import itertools
import functools
import bisect
import heapq
# import math
from math import gcd
MOD = 10 ** 9 + 7
# MOD = 998244353
# sys.setrecursionlimit(10**8)
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input(... | [["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 121 |
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())
if w >= v:
print('NO')
elif abs(b - a) / (w - v) > t:
print('NO')
else:
print('YES') | a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())
if w >= v:
print('NO')
elif abs(b - a) / (v - w) > t:
print('NO')
else:
print('YES') | [["-", 15, 666, 0, 657, 12, 23, 0, 657, 31, 22], ["-", 15, 666, 0, 657, 12, 23, 0, 657, 17, 33], ["+", 15, 666, 0, 657, 12, 23, 0, 657, 17, 33], ["+", 15, 666, 0, 657, 12, 23, 0, 657, 12, 22]] | 5 | 81 |
#include <stdio.h>
#include <stdlib.h>
int main() {
long long a, b, v, w, t;
scanf("%lld%lld%lld%lld%lld", &a, &v, &b, &w, &t);
if (abs(b - a) > (v - w) * t)
puts("No");
else
puts("Yes");
return 0;
}
| #include <stdio.h>
#include <stdlib.h>
int main() {
long long a, b, v, w, t;
scanf("%lld%lld%lld%lld%lld", &a, &v, &b, &w, &t);
if (abs(b - a) > (v - w) * t)
puts("NO");
else
puts("YES");
return 0;
}
| [["-", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 0 | 79 |
#include <bits/stdc++.h>
using namespace std;
int main() {
long long a, b, v, w, t;
cin >> a >> v >> b >> w >> t;
cout << (abs(a - b) + w * t - v * t >= 0 ? "NO" : "YES") << endl;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
long long a, b, v, w, t;
cin >> a >> v >> b >> w >> t;
cout << (abs(a - b) + w * t - v * t > 0 ? "NO" : "YES") << endl;
}
| [["-", 31, 16, 12, 23, 0, 41, 15, 16, 17, 20], ["+", 31, 16, 12, 23, 0, 41, 15, 16, 17, 47]] | 1 | 67 |
#!/usr/bin/env python
# coding: utf-8
def ri():
return int(input())
def rl():
return list(input().split())
def rli():
return list(map(int, input().split()))
def main():
a, v = rli()
b, w = rli()
t = ri()
if t*(v-w) >= abs(a-b):
print("Yes")
else:
print("No")
if __n... | #!/usr/bin/env python
# coding: utf-8
def ri():
return int(input())
def rl():
return list(input().split())
def rli():
return list(map(int, input().split()))
def main():
a, v = rli()
b, w = rli()
t = ri()
if t*(v-w) >= abs(a-b):
print("YES")
else:
print("NO")
if __n... | [["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 115 |
import sys
from copy import deepcopy
from collections import deque
sys.setrecursionlimit(10**6)
def S(): return sys.stdin.readline().rstrip()
def I(): return int(sys.stdin.readline().rstrip())
def LS(): return list(sys.stdin.readline().rstrip().split())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split... | import sys
from copy import deepcopy
from collections import deque
sys.setrecursionlimit(10**6)
def S(): return sys.stdin.readline().rstrip()
def I(): return int(sys.stdin.readline().rstrip())
def LS(): return list(sys.stdin.readline().rstrip().split())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split... | [["-", 75, 76, 8, 196, 0, 57, 15, 666, 667, 18], ["+", 75, 76, 8, 196, 0, 57, 15, 666, 667, 19]] | 5 | 261 |
#include <algorithm>
#include <cmath>
#include <deque>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <random>
#include <set>
#include <stack>
#include <string>
#include <utility>
#include <vector>
using namespace std;
#define rep(i, n) for (int i = 0; i < n; ++i)
#define REP(i, n) for... | #include <algorithm>
#include <cmath>
#include <deque>
#include <iomanip>
#include <iostream>
#include <map>
#include <queue>
#include <random>
#include <set>
#include <stack>
#include <string>
#include <utility>
#include <vector>
using namespace std;
#define rep(i, n) for (int i = 0; i < n; ++i)
#define REP(i, n) for... | [["-", 12, 23, 0, 41, 15, 23, 0, 16, 17, 18], ["+", 12, 23, 0, 41, 15, 23, 0, 16, 17, 19]] | 1 | 161 |
#include <bits/stdc++.h>
#include <stdio.h>
using namespace std;
#define inputInt(a) \
int a; \
cin >> a;
#define inputInt2(a, b) \... | #include <bits/stdc++.h>
#include <stdio.h>
using namespace std;
#define inputInt(a) \
int a; \
cin >> a;
#define inputInt2(a, b) \... | [["-", 8, 9, 0, 43, 49, 50, 51, 5, 0, 6], ["+", 8, 9, 0, 43, 49, 50, 51, 5, 0, 6]] | 1 | 1,339 |
#include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
typedef pair<ll, ll> P;
typedef vector<ll> VI;
typedef vector<VI> VVI;
const ll MOD = 1000000007;
const ll INF = 4611686018427387903;
#define REP(i, n) for (int i = 0; i < n; i++)
#define ALL(v) v.begin(), v.end()
int main() {
ll a, b, v, w;
c... | #include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
typedef pair<ll, ll> P;
typedef vector<ll> VI;
typedef vector<VI> VVI;
const ll MOD = 1000000007;
const ll INF = 4611686018427387903;
#define REP(i, n) for (int i = 0; i < n; i++)
#define ALL(v) v.begin(), v.end()
int main() {
ll a, b, v, w;
c... | [["-", 0, 9, 0, 57, 15, 339, 51, 16, 17, 20], ["+", 0, 9, 0, 57, 15, 339, 51, 16, 17, 19]] | 1 | 169 |
#include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < n; i++)
#define REPR(i, n) for (int i = n; i >= 0; i--)
#define FOR(i, m, n) for (int i = m; i < n; i++)
#define ALL(v) v.begin(), v.end()
using namespace std;
typedef long long ll;
int main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
ll a, b,... | #include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < n; i++)
#define REPR(i, n) for (int i = n; i >= 0; i--)
#define FOR(i, m, n) for (int i = m; i < n; i++)
#define ALL(v) v.begin(), v.end()
using namespace std;
typedef long long ll;
int main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
ll a, b,... | [["-", 15, 16, 31, 16, 31, 23, 0, 16, 31, 22], ["-", 15, 16, 31, 16, 31, 23, 0, 16, 17, 33], ["+", 15, 16, 31, 16, 31, 23, 0, 16, 17, 33], ["+", 15, 16, 31, 16, 31, 23, 0, 16, 12, 22]] | 1 | 156 |
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#define x first
#define y second
#define pb push_back
#define mp make_pair
#define all(v) v.begin(), v.end()
#define sz(v) (int)v.size()
#define up_b upper_bound
#define low_b lower_bound
#define nl '\n'
using namespace std;
using namespace __gnu_pbds;
... | #include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#define x first
#define y second
#define pb push_back
#define mp make_pair
#define all(v) v.begin(), v.end()
#define sz(v) (int)v.size()
#define up_b upper_bound
#define low_b lower_bound
#define nl '\n'
using namespace std;
using namespace __gnu_pbds;
... | [["-", 8, 9, 0, 1, 0, 11, 12, 16, 31, 22], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 31, 22]] | 1 | 240 |
#include <algorithm>
#include <array>
#include <iostream>
#include <limits>
#include <list>
#include <map>
#include <math.h>
#include <memory>
#include <queue>
#include <set>
#include <stdio.h>
#include <string>
#include <unordered_map>
#include <vector>
using namespace std;
using ll = long long;
using vec = vector<ll... | #include <algorithm>
#include <array>
#include <iostream>
#include <limits>
#include <list>
#include <map>
#include <math.h>
#include <memory>
#include <queue>
#include <set>
#include <stdio.h>
#include <string>
#include <unordered_map>
#include <vector>
using namespace std;
using ll = long long;
using vec = vector<ll... | [["-", 12, 23, 0, 41, 64, 23, 0, 5, 0, 6], ["+", 12, 23, 0, 41, 64, 23, 0, 5, 0, 6], ["-", 12, 23, 0, 41, 75, 23, 0, 5, 0, 6], ["+", 12, 23, 0, 41, 75, 23, 0, 5, 0, 6]] | 1 | 158 |
a, v = map(int,input().split())
b, w = map(int,input().split())
t=int(input())
if v<=w:
print("NO")
else:
time=abs(a-b)/(v-w)
print(time)
if time<=t:
print("YES")
else:
print("NO") | a, v = map(int,input().split())
b, w = map(int,input().split())
t=int(input())
if v<=w:
print("NO")
else:
time=abs(a-b)/(v-w)
#print(time)
if time<=t:
print("YES")
else:
print("NO") | [["-", 75, 76, 8, 196, 0, 1, 0, 652, 63, 22], ["-", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["-", 8, 196, 0, 1, 0, 652, 3, 4, 0, 22], ["-", 8, 196, 0, 1, 0, 652, 3, 4, 0, 25]] | 5 | 90 |
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ull = unsigned long long;
#define rep(i, n) for (ll i = 0; i < n; ++i)
#define ocut cout
#define ouct cout
#define itn int
struct Union {
vector<ll> par;
Union(ll a) { par = vector<ll>(a, -1); }
ll find(ll a) {
if (par[a] < 0) {
... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ull = unsigned long long;
#define rep(i, n) for (ll i = 0; i < n; ++i)
#define ocut cout
#define ouct cout
#define itn int
struct Union {
vector<ll> par;
Union(ll a) { par = vector<ll>(a, -1); }
ll find(ll a) {
if (par[a] < 0) {
... | [["-", 64, 9, 0, 57, 15, 339, 51, 16, 17, 20], ["+", 64, 9, 0, 57, 15, 339, 51, 16, 17, 19]] | 1 | 400 |
A,V = list(map(int,input().split()))
B,W = list(map(int,input().split()))
T = int(input())
if abs(A-B)- (V-W)*T < 0:
print("YES")
else:
print("NO") | A,V = list(map(int,input().split()))
B,W = list(map(int,input().split()))
T = int(input())
if abs(A-B)- (V-W)*T <= 0:
print("YES")
else:
print("NO") | [["-", 36, 36, 0, 656, 0, 57, 15, 666, 667, 18], ["+", 36, 36, 0, 656, 0, 57, 15, 666, 667, 19]] | 5 | 78 |
A,V=map(int,input().split())
B,W=map(int,input().split())
T=int(input())
if(A<=B and A+V*T>=B+W*T):
print("YES")
elif(A>=B and A+V*T<=B+W*T):
print("YES")
else:
print("NO") | A,V=map(int,input().split())
B,W=map(int,input().split())
T=int(input())
if(A<=B and A+V*T>=B+W*T):
print("YES")
elif(A>=B and A-V*T<=B-W*T):
print("YES")
else:
print("NO") | [["-", 15, 23, 0, 679, 12, 666, 0, 657, 17, 72], ["+", 15, 23, 0, 679, 12, 666, 0, 657, 17, 33]] | 5 | 98 |
#include <cmath>
#include <iostream>
using namespace std;
int main() {
double A, V, B, W, T;
cin >> A >> V >> B >> W >> T;
if (V - W <= 0)
cout << "NO" << endl;
cout << (abs(A - B) / (V - W) <= T ? "YES" : "NO") << endl;
} | #include <cmath>
#include <iostream>
using namespace std;
int main() {
double A, V, B, W, T;
cin >> A >> V >> B >> W >> T;
if (V - W <= 0)
cout << "NO" << endl;
else
cout << (abs(A - B) / (V - W) <= T ? "YES" : "NO") << endl;
} | [["+", 0, 14, 8, 9, 0, 57, 75, 76, 0, 95]] | 1 | 82 |
a,v = map(int,input().split())
b,w = map(int,input().split())
t = int(input())
b -= a
if b < 0:
b = -b
b += t*w
a += t*v
if b > a:
print("NO")
else:
print("YES") | a,v = map(int,input().split())
b,w = map(int,input().split())
t = int(input())
b -= a
a = 0
if b < 0:
b = -b
b += t*w
a += t*v
if b > a:
print("NO")
else:
print("YES") | [["+", 36, 36, 0, 656, 0, 1, 0, 662, 31, 22], ["+", 36, 36, 0, 656, 0, 1, 0, 662, 0, 32], ["+", 36, 36, 0, 656, 0, 1, 0, 662, 12, 612]] | 5 | 81 |
def mi():
return map(int, input().split())
def main():
A, V = mi()
B, W = mi()
T = int(input())
if abs(A-B) >= T*(V-W):
print('NO')
else:
print('YES')
if __name__ == '__main__':
main() | def mi():
return map(int, input().split())
def main():
A, V = mi()
B, W = mi()
T = int(input())
if abs(A-B) > T*(V-W):
print('NO')
else:
print('YES')
if __name__ == '__main__':
main() | [["-", 0, 14, 8, 196, 0, 57, 15, 666, 667, 20], ["+", 0, 14, 8, 196, 0, 57, 15, 666, 667, 47]] | 5 | 85 |
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, tan, asin, acos, atan, radians, degrees, log2, gcd, floor
from itertools import accumulate, permutations, combinations, combinations_with_replacement, product, groupby
from operator import ite... | import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, tan, asin, acos, atan, radians, degrees, log2, gcd, floor
from itertools import accumulate, permutations, combinations, combinations_with_replacement, product, groupby
from operator import ite... | [["-", 36, 36, 0, 656, 0, 57, 15, 666, 667, 47], ["+", 36, 36, 0, 656, 0, 57, 15, 666, 667, 20], ["+", 0, 656, 0, 57, 15, 666, 0, 652, 63, 22], ["+", 0, 57, 15, 666, 0, 652, 3, 4, 0, 24], ["+", 0, 57, 15, 666, 0, 652, 3, 4, 0, 25]] | 5 | 273 |
#include <bits/stdc++.h>
using namespace std;
#define MOD 1000000007
//#define MOD 998244353
#define INF 1000000010
#define EPS 1e-9
#define F first
#define S second
#define debug(x) cout << x << endl;
#define repi(i, x, n) for (int i = x; i < n; i++)
#define rep(i, n) repi(i, 0, n)
#define lp(i, n) repi(i, 0, n)
#def... | #include <bits/stdc++.h>
using namespace std;
#define MOD 1000000007
//#define MOD 998244353
#define INF 1000000010
#define EPS 1e-9
#define F first
#define S second
#define debug(x) cout << x << endl;
#define repi(i, x, n) for (int i = x; i < n; i++)
#define rep(i, n) repi(i, 0, n)
#define lp(i, n) repi(i, 0, n)
#def... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 47], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 20]] | 1 | 187 |
a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())
la, ra = a - t * v, a + t * v + 1
lb, rb = b + t * w, b + t * w + 1
l, r = min(la, lb), max(ra, rb)
if l == la and r == ra:
print("YES")
else:
print("NO") | a, v = map(int, input().split())
b, w = map(int, input().split())
t = int(input())
la, ra = a - t * v, a + t * v + 1
lb, rb = b - t * w, b + t * w + 1
l, r = min(la, lb), max(ra, rb)
if l == la and r == ra:
print("YES")
else:
print("NO") | [["-", 0, 1, 0, 662, 12, 432, 0, 657, 17, 72], ["+", 0, 1, 0, 662, 12, 432, 0, 657, 17, 33]] | 5 | 114 |
#include <algorithm>
#include <stdio.h>
using namespace std;
using ll = long long;
ll a, b, v, w, t;
int main() {
scanf("%lld %lld %lld %lld %lld", &a, &v, &b, &w, &t);
printf(abs(a - b) < (v - w) * t ? "YES\n" : "NO\n");
} | #include <algorithm>
#include <stdio.h>
using namespace std;
using ll = long long;
ll a, b, v, w, t;
int main() {
scanf("%lld %lld %lld %lld %lld", &a, &v, &b, &w, &t);
printf(abs(a - b) <= (v - w) * t ? "YES\n" : "NO\n");
} | [["-", 0, 2, 3, 4, 0, 41, 15, 16, 17, 18], ["+", 0, 2, 3, 4, 0, 41, 15, 16, 17, 19]] | 1 | 81 |
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ull = unsigned long long;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
using pull = pair<ull, ll>;
#define INF 1000000000
#define LLINF 10000000000000000ll
#define MOD 1000000007LL
bool dbgflag = false;
int main() {
cin.tie(0);
ios... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ull = unsigned long long;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
using pull = pair<ull, ll>;
#define INF 1000000000
#define LLINF 10000000000000000ll
#define MOD 1000000007LL
bool dbgflag = false;
int main() {
cin.tie(0);
ios... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 18], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 19]] | 1 | 140 |
A,V=map(int,input().split())
B,W=map(int,input().split())
T=int(input())
if V<=W:
print('NO')
exit()
n=abs(A-B)//(V-W)
if n<=T:
print('YES')
else:
print('NO') | A,V=map(int,input().split())
B,W=map(int,input().split())
T=int(input())
if V<=W:
print('NO')
exit()
n=-(-abs(A-B)//(V-W))
if n<=T:
print('YES')
else:
print('NO') | [["+", 0, 656, 0, 1, 0, 662, 12, 664, 17, 33], ["+", 0, 1, 0, 662, 12, 664, 28, 23, 0, 24], ["+", 12, 664, 28, 23, 0, 657, 31, 664, 17, 33], ["+", 12, 664, 28, 23, 0, 657, 12, 23, 0, 25]] | 5 | 87 |
#include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for (int i = a; i < (b); ++i)
#define trav(a, x) for (auto &a : (x))
#define all(x) x.begin(), x.end() // sort(all(x))
#define sz(x) (int)(x).size()
#define mp(x, y) make_pair((x), (y))
typedef long long ll;
typedef double T;
typedef pair<int, int> p... | #include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for (int i = a; i < (b); ++i)
#define trav(a, x) for (auto &a : (x))
#define all(x) x.begin(), x.end() // sort(all(x))
#define sz(x) (int)(x).size()
#define mp(x, y) make_pair((x), (y))
typedef long long ll;
typedef double T;
typedef pair<int, int> p... | [["-", 8, 9, 0, 43, 49, 50, 51, 16, 31, 22], ["-", 8, 9, 0, 43, 49, 50, 51, 16, 17, 33], ["+", 8, 9, 0, 43, 49, 50, 51, 16, 17, 33], ["+", 8, 9, 0, 43, 49, 50, 51, 16, 12, 22]] | 1 | 799 |
#exec({'RUBY_THREAD_VM_STACK_SIZE'=>'100000000'},'/usr/bin/ruby', $0) if !ENV['RUBY_THREAD_VM_STACK_SIZE']
require 'prime'
def inpf() a=gets.chomp.split(" ").map(&:to_f)end
def inps() a=gets.chomp.split(" ")end
def copy(a) Marshal.load(Marshal.dump(a)) end
def kaijo(n,r = 10**9+7)(n < 2)? 1 : (2..n).inject{|memo,u|... | #exec({'RUBY_THREAD_VM_STACK_SIZE'=>'100000000'},'/usr/bin/ruby', $0) if !ENV['RUBY_THREAD_VM_STACK_SIZE']
require 'prime'
def inpf() a=gets.chomp.split(" ").map(&:to_f)end
def inps() a=gets.chomp.split(" ")end
def copy(a) Marshal.load(Marshal.dump(a)) end
def kaijo(n,r = 10**9+7)(n < 2)? 1 : (2..n).inject{|memo,u|... | [["-", 15, 739, 0, 738, 31, 738, 31, 652, 17, 131], ["-", 15, 739, 0, 738, 31, 738, 31, 652, 735, 22]] | 4 | 326 |
#include <bits/stdc++.h>
using ll = long long;
using namespace std;
int main(void) {
ll a, v;
ll b, w;
ll t;
cin >> a >> v;
cin >> b >> w;
cin >> t;
int spd = v - w;
int dist = (ll)abs(a - b);
if (spd < 0) {
puts("NO");
} else if (dist >= spd * t) {
puts("NO");
} else {
puts("YES");
... | #include <bits/stdc++.h>
using ll = long long;
using namespace std;
int main(void) {
ll a, v;
ll b, w;
ll t;
cin >> a >> v;
cin >> b >> w;
cin >> t;
int spd = v - w;
int dist = (ll)abs(a - b);
if (spd < 0) {
puts("NO");
} else if (dist > spd * t) {
puts("NO");
} else {
puts("YES");
... | [["-", 75, 76, 0, 57, 15, 339, 51, 16, 17, 20], ["+", 75, 76, 0, 57, 15, 339, 51, 16, 17, 47]] | 1 | 114 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int a, v, b, w, t;
cin >> a >> v >> b >> w >> t;
int s = v - w, p = abs(a - b);
if (s <= 0) {
cout << "NO";
} else if (p / s <= t) {
cout << "YES";
} else
cout << "NO";
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int a, v, b, w, t;
cin >> a >> v >> b >> w >> t;
double s = v - w, p = abs(a - b);
if (s <= 0) {
cout << "NO";
} else if (p / s - t <= 0) {
cout << "YES";
} else
cout << "NO";
}
| [["-", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40], ["+", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40], ["-", 75, 76, 0, 57, 15, 339, 51, 16, 17, 19], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 33], ["+", 75, 76, 0, 57, 15, 339, 51, 16, 17, 19], ["+", 75, 76, 0, 57, 15, 339, 51, 16, 12, 13]] | 1 | 89 |
#include <bits/stdc++.h>
#define ll long long
using namespace std;
const int MAXN = 51;
const int MAXV = 1 << 18;
int a[MAXN], b[MAXN];
int cnt[MAXV];
ll dp[MAXV], C[MAXN][MAXN];
int main() {
for (int i = 0; i <= 50; i++) {
C[i][0] = 1;
for (int j = 1; j <= i; j++)
C[i][j] = C[i - 1][j] + C[i - 1][j - 1... | #include <bits/stdc++.h>
#define ll long long
using namespace std;
const int MAXN = 51;
const int MAXV = 1 << 18;
int a[MAXN], b[MAXN];
int cnt[MAXV];
ll dp[MAXV], C[MAXN][MAXN];
int main() {
for (int i = 0; i <= 50; i++) {
C[i][0] = 1;
for (int j = 1; j <= i; j++)
C[i][j] = C[i - 1][j] + C[i - 1][j - 1... | [["+", 0, 57, 64, 9, 0, 1, 0, 27, 28, 22], ["+", 0, 57, 64, 9, 0, 1, 0, 27, 17, 68], ["+", 8, 9, 0, 57, 64, 9, 0, 1, 0, 35]] | 1 | 606 |
#include <bits/stdc++.h>
#define debug(...) fprintf(stderr, __VA_ARGS__)
#ifndef AT_HOME
#define getchar() IO::myGetchar()
#define putchar(x) IO::myPutchar(x)
#endif
namespace IO {
static const int IN_BUF = 1 << 23, OUT_BUF = 1 << 23;
inline char myGetchar() {
static char buf[IN_BUF], *ps = buf, *pt = buf;
if (... | #include <bits/stdc++.h>
#define debug(...) fprintf(stderr, __VA_ARGS__)
#ifndef AT_HOME
#define getchar() IO::myGetchar()
#define putchar(x) IO::myPutchar(x)
#endif
namespace IO {
static const int IN_BUF = 1 << 23, OUT_BUF = 1 << 23;
inline char myGetchar() {
static char buf[IN_BUF], *ps = buf, *pt = buf;
if (... | [["-", 0, 7, 8, 9, 0, 7, 15, 16, 12, 22], ["+", 0, 7, 8, 9, 0, 7, 15, 16, 12, 22]] | 1 | 1,098 |
//#pragma GCC optimize("Ofast,no-stack-protector,unroll-loops")
//#pragma GCC target("avx,avx2")
//#pragma GCC target("avx2")
//#pragma GCC optimize("O3")
//# include <x86intrin.h>
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
using... | //#pragma GCC optimize("Ofast,no-stack-protector,unroll-loops")
//#pragma GCC target("avx,avx2")
//#pragma GCC target("avx2")
//#pragma GCC optimize("O3")
//# include <x86intrin.h>
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
using... | [["-", 8, 9, 0, 1, 0, 2, 3, 4, 0, 13], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 22]] | 1 | 789 |
#include <bits/stdc++.h>
typedef long long ll;
typedef long double ld;
using namespace std;
#define F first
#define S second
#define pb push_back
#define all(x) (x).begin(), (x).end()
#define SZ(x) (int)(x).size()
#define int ll
bool sub(int a, int b) { return (a | b) == b; }
const int N = 55;
const int M = (1 << 18)... | #include <bits/stdc++.h>
typedef long long ll;
typedef long double ld;
using namespace std;
#define F first
#define S second
#define pb push_back
#define all(x) (x).begin(), (x).end()
#define SZ(x) (int)(x).size()
#define int ll
bool sub(int a, int b) { return (a | b) == b; }
const int N = 55;
const int M = (1 << 18)... | [["-", 64, 9, 0, 1, 0, 16, 31, 16, 12, 13], ["+", 64, 9, 0, 1, 0, 16, 31, 16, 12, 13]] | 1 | 814 |
import sys
readline = sys.stdin.readline
readall = sys.stdin.read
ns = lambda: readline().rstrip()
ni = lambda: int(readline().rstrip())
nm = lambda: map(int, readline().split())
nl = lambda: list(map(int, readline().split()))
prn = lambda x: print(*x, sep='\n')
def popcount(x):
x = x - ((x >> 1) & 0x55555555)
... | import sys
readline = sys.stdin.readline
readall = sys.stdin.read
ns = lambda: readline().rstrip()
ni = lambda: int(readline().rstrip())
nm = lambda: map(int, readline().split())
nl = lambda: list(map(int, readline().split()))
prn = lambda x: print(*x, sep='\n')
def popcount(x):
x = x - ((x >> 1) & 0x55555555)
... | [["-", 0, 656, 0, 14, 8, 196, 0, 37, 0, 38]] | 5 | 561 |
#include <bits/stdc++.h>
using namespace std;
int n, k, s, t, a[55], b[55], cnt, ct, cc, ka[333333], kb[333333], kc[333333],
pop[333333], rt;
long long c[55][55], fuck[55], ans;
void FWT_or(int a[], int flg) {
for (int i = 2; i <= (1 << rt); i <<= 1) {
for (int p = i >> 1, j = 0; j < (1 << rt); j += i) {
... | #include <bits/stdc++.h>
using namespace std;
int n, k, s, t, a[55], b[55], cnt, ct, cc, ka[333333], kb[333333], kc[333333],
pop[333333], rt;
long long c[55][55], fuck[55], ans;
void FWT_or(int a[], int flg) {
for (int i = 2; i <= (1 << rt); i <<= 1) {
for (int p = i >> 1, j = 0; j < (1 << rt); j += i) {
... | [["-", 8, 9, 0, 7, 10, 43, 49, 50, 51, 13], ["+", 8, 9, 0, 7, 10, 43, 49, 50, 51, 13], ["-", 0, 1, 0, 2, 3, 4, 0, 16, 17, 33], ["-", 0, 1, 0, 2, 3, 4, 0, 16, 12, 13]] | 1 | 811 |
#include <iostream>
#include <map>
#include <utility>
#include <vector>
using namespace std;
int main() {
int N, K, S, T;
cin >> N >> K >> S >> T;
vector<int> A(N);
for (int &a : A)
cin >> a;
vector<map<pair<int, int>, long long>> X(K + 1);
X[0][make_pair(0, 0x3ffff)] = 1;
for (int &a : A) {
if ... | #include <iostream>
#include <map>
#include <utility>
#include <vector>
using namespace std;
int main() {
int N, K, S, T;
cin >> N >> K >> S >> T;
vector<int> A(N);
for (int &a : A)
cin >> a;
vector<map<pair<int, int>, long long>> X(K + 1);
X[0][make_pair(0x3ffff, 0)] = 1;
for (int &a : A) {
if ... | [["-", 31, 69, 341, 342, 0, 2, 3, 4, 0, 13], ["-", 31, 69, 341, 342, 0, 2, 3, 4, 0, 21], ["+", 31, 69, 341, 342, 0, 2, 3, 4, 0, 21], ["+", 31, 69, 341, 342, 0, 2, 3, 4, 0, 13]] | 1 | 221 |
#include <bits/stdc++.h>
using namespace std;
const int K = 18, N = 55;
long long C[N][N];
int cnt[1 << K];
void pre() {
for (int i = 0; i < N; i++)
C[i][0] = 1;
for (int i = 1; i < N; i++)
for (int j = 1; j < N; j++)
C[i][j] = C[i - 1][j - 1] + C[i - 1][j];
for (int i = 0; i < N; i++)
for (i... | #include <bits/stdc++.h>
using namespace std;
const int K = 18, N = 55;
long long C[N][N];
int cnt[1 << K];
void pre() {
for (int i = 0; i < N; i++)
C[i][0] = 1;
for (int i = 1; i < N; i++)
for (int j = 1; j < N; j++)
C[i][j] = C[i - 1][j - 1] + C[i - 1][j];
for (int i = 0; i < N; i++)
for (i... | [["-", 0, 57, 15, 339, 51, 16, 12, 16, 12, 22], ["+", 15, 339, 51, 16, 12, 16, 12, 69, 28, 22], ["+", 51, 16, 12, 16, 12, 69, 341, 342, 0, 70], ["+", 51, 16, 12, 16, 12, 69, 341, 342, 0, 22], ["+", 51, 16, 12, 16, 12, 69, 341, 342, 0, 73]] | 1 | 430 |
/*
Though leaves are many , the root is one.
Through all the lying days of my youth
I swayed my leaves and flowers in the sun.
Now I may wither long longo the truth.
- William Butler Yeats
*/
//#pragma GCC optimize("Ofast,no-stack-protector")
//#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt... | /*
Though leaves are many , the root is one.
Through all the lying days of my youth
I swayed my leaves and flowers in the sun.
Now I may wither long longo the truth.
- William Butler Yeats
*/
//#pragma GCC optimize("Ofast,no-stack-protector")
//#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt... | [["+", 8, 9, 0, 1, 0, 11, 12, 16, 17, 33], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 12, 13]] | 1 | 902 |
#include <algorithm>
#include <iostream>
#include <unordered_map>
#include <vector>
using namespace std;
typedef long long ll;
typedef pair<ll, ll> pll;
#define rep(i, n) for (int i = 0; i < n; i++)
#define all(x) x.begin(), x.end()
#define chmin(a, b) a = min(a, b)
#define chmax(a, b) a = max(a, b)
ll dp[55][400000];... | #include <algorithm>
#include <iostream>
#include <unordered_map>
#include <vector>
using namespace std;
typedef long long ll;
typedef pair<ll, ll> pll;
#define rep(i, n) for (int i = 0; i < n; i++)
#define all(x) x.begin(), x.end()
#define chmin(a, b) a = min(a, b)
#define chmax(a, b) a = max(a, b)
ll dp[55][400000];... | [["-", 64, 1, 0, 11, 31, 69, 341, 342, 0, 22], ["+", 64, 1, 0, 11, 31, 69, 341, 342, 0, 22]] | 1 | 692 |
#include <bits/stdc++.h>
using namespace std;
int n, m, k;
long long ans = 0ll;
int gcd(int x, int y) {
if (x < 0)
x = -x;
if (y < 0)
y = -y;
if (x < y)
swap(x, y);
while (y) {
int r = x % y;
x = y, y = r;
}
return x;
}
long long solve(int w, int h, int s) {
long long res = 0ll;
fo... | #include <bits/stdc++.h>
using namespace std;
int n, m, k;
long long ans = 0ll;
int gcd(int x, int y) {
if (x < 0)
x = -x;
if (y < 0)
y = -y;
if (x < y)
swap(x, y);
while (y) {
int r = x % y;
x = y, y = r;
}
return x;
}
long long solve(int w, int h, int s) {
long long res = 0ll;
fo... | [["-", 8, 9, 0, 7, 15, 16, 31, 16, 12, 22], ["+", 8, 9, 0, 7, 15, 16, 31, 16, 12, 22]] | 1 | 380 |
#include <bits/stdc++.h>
using namespace std;
#define ll long long
#define sd(x) scanf("%d", &(x))
#define pii pair<int, int>
#define F first
#define S second
#define all(c) ((c).begin()), ((c).end())
#define sz(x) ((int)(x).size())
#define ld long double
template <class T, class U>
ostream &operator<<(ostream &os, c... | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define sd(x) scanf("%d", &(x))
#define pii pair<int, int>
#define F first
#define S second
#define all(c) ((c).begin()), ((c).end())
#define sz(x) ((int)(x).size())
#define ld long double
template <class T, class U>
ostream &operator<<(ostream &os, c... | [["-", 31, 16, 31, 16, 12, 16, 12, 2, 63, 22], ["+", 31, 16, 31, 16, 12, 16, 12, 2, 63, 22]] | 1 | 548 |
//#pragma GCC optimize("Ofast")
//#pragma GCC target("avx")
//#undef LOCAL
#include <algorithm>
#include <array>
#include <bitset>
#include <cassert>
#include <complex>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <strin... | //#pragma GCC optimize("Ofast")
//#pragma GCC target("avx")
//#undef LOCAL
#include <algorithm>
#include <array>
#include <bitset>
#include <cassert>
#include <complex>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <strin... | [["-", 51, 16, 31, 16, 31, 16, 12, 16, 31, 13], ["-", 51, 16, 31, 16, 31, 16, 12, 16, 17, 48], ["+", 15, 339, 51, 16, 31, 16, 31, 16, 17, 33], ["+", 15, 339, 51, 16, 31, 16, 31, 16, 12, 22]] | 1 | 2,107 |
#include <cstdio>
#include <cstring>
#include <iostream>
using namespace std;
const int N = 205;
int T;
int n;
long long a[N];
char s[N];
struct Basis {
static const int M = 60;
long long d[N];
void clear() {
memset(d, 0, sizeof(d));
return;
}
void insert(long long t) {
for (int i = M; i >= 0; i--... | #include <cstdio>
#include <cstring>
#include <iostream>
using namespace std;
const int N = 205;
int T;
int n;
long long a[N];
char s[N];
struct Basis {
static const int M = 60;
long long d[N];
void clear() {
memset(d, 0, sizeof(d));
return;
}
void insert(long long t) {
for (int i = M; i >= 0; i--... | [["-", 64, 9, 0, 57, 64, 9, 0, 93, 0, 94], ["+", 64, 9, 0, 57, 64, 9, 0, 37, 0, 38]] | 1 | 433 |
#include <algorithm>
#include <bitset>
#include <cmath>
#include <complex>
#include <cstring>
#include <deque>
#include <iomanip>
#include <iostream>
#include <limits>
#include <list>
#include <map>
#include <numeric>
#include <queue>
#include <random>
#include <regex>
#include <set>
#include <stack>
#include <string>
... | #include <algorithm>
#include <bitset>
#include <cmath>
#include <complex>
#include <cstring>
#include <deque>
#include <iomanip>
#include <iostream>
#include <limits>
#include <list>
#include <map>
#include <numeric>
#include <queue>
#include <random>
#include <regex>
#include <set>
#include <stack>
#include <string>
... | [["-", 64, 9, 0, 1, 0, 16, 31, 16, 12, 13], ["+", 64, 9, 0, 1, 0, 16, 31, 16, 12, 13]] | 1 | 1,662 |
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < n; ++i)
using namespace std;
using ll = long long;
constexpr ll mod = 998244353;
constexpr int inf = 1000000000;
constexpr ll linf = 1000000000000000000;
template <int COL = 60> struct bitmat {
private:
vector<bitset<COL>> mat;
int rank;
public:
int... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < n; ++i)
using namespace std;
using ll = long long;
constexpr ll mod = 998244353;
constexpr int inf = 1000000000;
constexpr ll linf = 1000000000000000000;
template <int COL = 60> struct bitmat {
private:
vector<bitset<COL>> mat;
int rank = 0;
public:
... | [["+", 0, 359, 0, 122, 8, 123, 0, 124, 0, 32], ["+", 0, 359, 0, 122, 8, 123, 0, 124, 365, 13]] | 1 | 427 |
#include <bits/stdc++.h>
#define mk make_pair
#define fs first
#define sc second
using namespace std;
typedef long long ll;
typedef long double ld;
ll a[100010];
const ll d = 63;
ll basis[63]; // basis[i] keeps the mask of the vector whose f value is i
ll sz; // Current size of the basis
void insertVector(ll mask) {
... | #include <bits/stdc++.h>
#define mk make_pair
#define fs first
#define sc second
using namespace std;
typedef long long ll;
typedef long double ld;
ll a[100010];
const ll d = 63;
ll basis[63]; // basis[i] keeps the mask of the vector whose f value is i
ll sz; // Current size of the basis
void insertVector(ll mask) {
... | [["-", 0, 52, 8, 9, 0, 7, 15, 16, 12, 13], ["+", 0, 52, 8, 9, 0, 7, 15, 16, 12, 13]] | 1 | 399 |
#include <algorithm>
#include <cstdio>
#include <cstring>
#include <iostream>
using namespace std;
struct L_B {
long long d[61], p[61];
int cnt;
L_B() {
memset(d, 0, sizeof(d));
memset(p, 0, sizeof(p));
cnt = 0;
}
bool insert(long long val) {
for (int i = 60; i >= 0; i--)
if (val & (1LL ... | #include <algorithm>
#include <cstdio>
#include <cstring>
#include <iostream>
using namespace std;
struct L_B {
long long d[61], p[61];
int cnt;
L_B() {
memset(d, 0, sizeof(d));
memset(p, 0, sizeof(p));
cnt = 0;
}
bool insert(long long val) {
for (int i = 60; i >= 0; i--)
if (val & (1LL ... | [["-", 0, 9, 0, 57, 15, 339, 51, 16, 12, 147], ["+", 0, 9, 0, 57, 15, 339, 51, 16, 12, 146], ["-", 0, 1, 0, 2, 3, 4, 0, 16, 31, 13], ["-", 0, 1, 0, 2, 3, 4, 0, 16, 17, 33]] | 1 | 306 |
#include <bits/stdc++.h>
#define int long long
#define pb push_back
#define pii pair<int, int>
#define vi vector<int>
#define vii vector<pii>
#define mi map<int, int>
#define mii map<pii, int>
#define all(a) (a).begin(), (a).end()
#define x first
#define y second
#define sz(x) (int)x.size()
#define endl '\n'
#define h... | #include <bits/stdc++.h>
#define int long long
#define pb push_back
#define pii pair<int, int>
#define vi vector<int>
#define vii vector<pii>
#define mi map<int, int>
#define mii map<pii, int>
#define all(a) (a).begin(), (a).end()
#define x first
#define y second
#define sz(x) (int)x.size()
#define endl '\n'
#define h... | [["+", 8, 9, 0, 1, 0, 2, 63, 118, 28, 22], ["+", 8, 9, 0, 1, 0, 2, 63, 118, 17, 131], ["+", 8, 9, 0, 1, 0, 2, 63, 118, 119, 120], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 0, 30, 0, 14, 8, 9, 0, 1, 0, 35]] | 1 | 293 |
/* Aa^~ kokoro ga pyonpyon suru n jaa^~
// ZZZXXkXkkkZ!``` ``` ``` ``` ``` ``` ``` ``` ``` ``` ```
```?Wfpppbpbbpbbpbbbkbkk
// ppbbbpbbpVr`` `` ` ` ` ` ```` `` ` ` `` ` ` ` ` ` ` ` ` `
dppbbkkkkkkkkkkqkqkk
// HkqqqqqkkWr`` ` ` ``` ``` `?G, ` ` ``.JC!```` ` ` `` ``
````(Wpbkkkkkkkkqkkkkkqk
// mmmmmqqqqpr` `` `` ```````... | /* Aa^~ kokoro ga pyonpyon suru n jaa^~
// ZZZXXkXkkkZ!``` ``` ``` ``` ``` ``` ``` ``` ``` ``` ```
```?Wfpppbpbbpbbpbbbkbkk
// ppbbbpbbpVr`` `` ` ` ` ` ```` `` ` ` `` ` ` ` ` ` ` ` ` `
dppbbkkkkkkkkkkqkqkk
// HkqqqqqkkWr`` ` ` ``` ``` `?G, ` ` ``.JC!```` ` ` `` ``
````(Wpbkkkkkkkkqkkkkkqk
// mmmmmqqqqpr` `` `` ```````... | [["-", 8, 9, 0, 43, 39, 344, 3, 347, 0, 13], ["+", 8, 9, 0, 43, 39, 344, 3, 347, 0, 13], ["-", 75, 76, 0, 9, 0, 57, 64, 1, 0, 35], ["-", 75, 76, 0, 9, 0, 57, 75, 76, 0, 95], ["-", 0, 9, 0, 57, 75, 76, 0, 93, 0, 94]] | 1 | 679 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.