source_code stringlengths 26 62k | lang_cluster stringclasses 11
values | src_uid stringlengths 32 32 | code_uid stringlengths 32 32 | difficulty int32 -1 3.5k ⌀ | exec_outcome stringclasses 1
value |
|---|---|---|---|---|---|
#include <bits/stdc++.h>
using namespace std;
int t, n, a[45], b[45], dem[2000005];
void solve(){
for(int i = 0; i <= 2e6; i++) dem[i] = 0;
map<int, int> mp;
for(int i = 1; i <= n; i++){
b[i] = a[i];
mp[a[i]]++;
}
bool ans = 0;
for(int i = 1; i <= n; i++){
if(mp... | C++ | 432411e161af5ef14803e946e2f7fbc3 | 6b606ef3ecba62c87268787e163dcf54 | 1,900 | PASSED |
#include <bits/stdc++.h>
using namespace std;
int t, n, a[45], b[45], dem[2000005];
void solve(){
for(int i = 0; i <= 2e6; i++) dem[i] = 0;
map<int, int> mp;
for(int i = 1; i <= n; i++){
b[i] = a[i];
mp[a[i]]++;
}
bool ans = 0;
for(int i = 1; i <= n; i++){
if(mp... | C++ | 432411e161af5ef14803e946e2f7fbc3 | 3b924075434b6e58beec33721a9bdc0d | 1,900 | PASSED |
#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma,sse2")
#pragma GCC optimization ("unroll-loops")
#include <bits/stdc++.h>
using namespace std;
//#define int long long
int t, n, a[45], b[45], dem[2000005];
void solve(){
for(int i = 0; i <= 2e6; i++) dem[i] = 0;
map<int, int> mp;
... | C++ | 432411e161af5ef14803e946e2f7fbc3 | 61c43535ac4fc2213a3b3e1983781c57 | 1,900 | PASSED |
// #pragma GCC optimize("Ofast")
// #pragma GCC target("avx,avx2,fma,sse2")
// #pragma GCC optimization ("unroll-loops")
#include <bits/stdc++.h>
using namespace std;
//#define int long long
int t, n, a[45], b[45], dem[2000005];
void solve(){
for(int i = 0; i <= 2e6; i++) dem[i] = 0;
map<int, i... | C++ | 432411e161af5ef14803e946e2f7fbc3 | dbe8a4af7dcf92a9b8a39da76226d6ac | 1,900 | PASSED |
#include<bits/stdc++.h>
#define forn(i, n) for (int i = 0; i < int(n); i++)
using namespace std;
set<int> find_divisors(int n){
// vector<int> divisors;
// for(int i=2; i<=n; i++){
// // if i is a divisor
// if(n%i == 0){
// divisors.push_back(i);
// }
// }
... | C++ | 432411e161af5ef14803e946e2f7fbc3 | 0ca744dd5e39e39be2b1bb8b3e154bb0 | 1,900 | PASSED |
#include <bits/stdc++.h>
using namespace std;
#define forn(i, n) for (int i = 0; i < int(n); i++)
set<int> divs(int n) {
set<int> d;
for (int dd = 1; dd * dd <= n; dd++)
if (n % dd == 0) {
d.insert(n / dd);
d.insert(dd);
}
return d;
}
int main() ... | C++ | 432411e161af5ef14803e946e2f7fbc3 | fa265b03d3d1afca41b8379dd98fecfd | 1,900 | PASSED |
#include<bits/stdc++.h>
using namespace std;
int main(){
ios_base::sync_with_stdio(false);
cin.tie(NULL);
int t;cin>>t;
while(t--){
int n;cin>>n;
vector<int> v(n);
map<int, int> m2;
int vmax = 0;
int vmin = INT_MAX;
for(au... | C++ | 432411e161af5ef14803e946e2f7fbc3 | 30995f58b5d3ac25f0111a12148fed3d | 1,900 | PASSED |
#include<bits/stdc++.h>
using namespace std;
int main(){
ios_base::sync_with_stdio(false);
cin.tie(NULL);
int t;cin>>t;
while(t--){
int n;cin>>n;
vector<int> v(n);
map<int, int> m2;
int vmax = 0;
int vmin = INT_MAX;
for(au... | C++ | 432411e161af5ef14803e946e2f7fbc3 | 669d53d72d668f99d5d4bb607f89143a | 1,900 | PASSED |
import java.math.BigInteger;
import java.sql.Array;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collection;
import java.util.Collections;
import java.util.Comparator;
import java.util.Deque;
import java.uti... | Java | 322792a11d3eb1df6b54e8f89c9a0490 | 3e15294c3489c763c14010de21a09052 | 800 | PASSED |
import java.io.*;
import java.util.*;
import java.math.BigInteger;
public class Sol {
public void run(long n)
{
long sum = n;
int length = 0;
length = 0;
int i = 1;
while(sum > 0) {
sum -= i;
length +=1;
... | Java | 322792a11d3eb1df6b54e8f89c9a0490 | 9f5bae050a70bf4236d36ce47df087b1 | 800 | PASSED |
import java.io.*;
import java.util.*;
import java.math.BigInteger;
public class Sol {
public void run(long n)
{
long sum = n;
int length = 0;
if(n<=2) System.out.println(n);
else if(n==3) { System.out.println(2); }
else {
System.out.println... | Java | 322792a11d3eb1df6b54e8f89c9a0490 | dd9ea5d9ca38551e441c7b3a162bf7e8 | 800 | PASSED |
import java.io.*;
import java.util.*;
import java.math.BigInteger;
public class Sol {
public void run(long n)
{
long sum = n;
int length = 0;
if(n<=2) System.out.println(n);
else if(n==3) { System.out.println(2); }
else {
System.out.println(... | Java | 322792a11d3eb1df6b54e8f89c9a0490 | 49a846d1cc72a120675493083bd1ee26 | 800 | PASSED |
import java.util.Scanner;
public class solution {
public static void main(String[] args) {
Scanner sc=new Scanner(System.in);
int t=sc.nextInt();
while(t-->0)
{
int n=sc.nextInt();
solve(n-1,1,1);
}
}
public static void solve(int sum ,int val,int count) {
if(sum<=0)
... | Java | 322792a11d3eb1df6b54e8f89c9a0490 | e9d022fdf2b3b10b7e2af9467e460af7 | 800 | PASSED |
import java.util.ArrayList;
import java.util.Scanner;
public class solution {
public static void main(String[] args) {
Scanner sc=new Scanner(System.in);
int t=sc.nextInt();
while(t-->0)
{ ArrayList<Integer> A=new ArrayList<>();
A.add(1);
int n=sc.nextInt();
solve(n-1,1,A);
S... | Java | 322792a11d3eb1df6b54e8f89c9a0490 | 4ce75c0445874b9378e454f4e9df4cb5 | 800 | PASSED |
import java.util.*;
public class MyClass {
public static void main(String args[]) {
Scanner sc=new Scanner(System.in);
int t=sc.nextInt();
while(t--!=0){
int s=sc.nextInt();
int i=0;
while(i*i<s){
i++;
}
System.out.println(i);
}... | Java | 322792a11d3eb1df6b54e8f89c9a0490 | 1cccf9315a2beb845fe26195e2808aed | 800 | PASSED |
import java.util.*;
public class Solution {
public static void main(String[] args) {
new Solution();
}
public Solution() {
Scanner scanner = new Scanner(System.in);
int cases = scanner.nextInt();
for (int i = 0; i < cases; i++) {
System.out.println((int) Math.c... | Java | 322792a11d3eb1df6b54e8f89c9a0490 | 6a771c999b701c5929d416845d6f1314 | 800 | PASSED |
import java.util.Scanner;
public class Test3 {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int time = scanner.nextInt();
int[] times = new int[time];
for (int i = 0; i < time; i++) {
times[i] = scanner.nextInt();
}
i... | Java | 322792a11d3eb1df6b54e8f89c9a0490 | 030ed7c3e7c7a41acd5f7da900b4a26f | 800 | PASSED |
import java.util.Scanner;
public class Main
{
public static void main (String[] args){
Scanner scanner = new Scanner(System.in);
int times = scanner.nextInt();
while(times-- > 0) {
int s = scanner.nextInt();
int t = (int)Math.sqrt(s);
if(t * t == s) {
System.out.println(t);
}els... | Java | 322792a11d3eb1df6b54e8f89c9a0490 | 50650829eb3eb6169f34b6c8e43ae03e | 800 | PASSED |
#include<bits/stdc++.h>
#define int long long int
#define double double_t
#define INF 1e18
using namespace std;
int GCD(int a, int b) {
if (b == 0) {
return a;
}
return GCD(b, a % b);
}
int power(int x, int y, int MOD = INF) {
if (y == 0) {
return 1;
}
if (y % 2 == 0) {
... | C++ | 93fb13c40ab03700ef9a827796bd3d9d | dde46343fa59a4245582373007486713 | 1,000 | PASSED |
#include<iostream>
#include<iomanip>
#include<cstdio>
#include<vector>
#include<algorithm>
#include<string>
#include<cmath>
#include<math.h>
#include<stdio.h>
#include<map>
#include<set>
#include<deque>
#include<queue>
#include<stack>
#include<unordered_set>
#include<bits/stdc++.h>
using namespace std;
#define ll long ... | C++ | 93fb13c40ab03700ef9a827796bd3d9d | 887a95c3e23abe26eb802623d95d9185 | 1,000 | PASSED |
//"Perhaps..,we 're asking the wrong questions .." -Agent Brown
#include <iostream>
#include <bits/stdc++.h>
#include <string>
#include <iomanip>
#include <unordered_map>
#define sz(s) (int(s.size()))
#define MemS(s, x) memset(s, x, sizeof(s))
#define PI acos(-1)
typedef long long ll;
using namespace std;
const ll Mod ... | C++ | 93fb13c40ab03700ef9a827796bd3d9d | c9dd08aa2b76322f7dae4dc2b77c57a3 | 1,000 | PASSED |
#include <iostream>
#include <bits/stdc++.h>
using namespace std;
#define FIO ios_base::sync_with_stdio(false);cin.tie(NULL);
# pragma GCC optimize "trapv"
const int INF = 100 ;
#define ll long long
#define f(m,n) for(int i = m ; i < n ; i++)
#define l '\n'
const int N = 100007;
void Fady_Malek() {
ios_base::syn... | C++ | 93fb13c40ab03700ef9a827796bd3d9d | 7c88c2071bc6b4b120ec6770bb42eede | 1,000 | PASSED |
#include <bits/stdc++.h>
using namespace std;
int main()
{
std::ios_base::sync_with_stdio(0);
cin.tie(NULL);
cout.tie(NULL);
int t;
cin >> t;
while (t--)
{
int n, a, b;
cin >> n >> a >> b;
string s;
cin >> s;
if (b >= 0)
{
cout <<... | C++ | 93fb13c40ab03700ef9a827796bd3d9d | 3eb88c5bb65323882681851406e78e44 | 1,000 | PASSED |
#include<cmath>
#include<map>
#include<vector>
#include<math.h>
#include <algorithm>
#include <string>
#include<iostream>
using namespace std;
typedef long long ll;
const int N = 1e5 + 5;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
int t; cin >> t;
while (t--) {
int n, a, b; ... | C++ | 93fb13c40ab03700ef9a827796bd3d9d | e67512ba1b57f8ceb2e514a665d2f359 | 1,000 | PASSED |
#pragma GCC optimize "trapv"
#include <iostream>
#include <vector>
#include <cmath>
#include <algorithm>
#define FIO ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);
#define ll long long
#define el "\n"
using namespace std;
int main()
{
FIO
int t;
cin >> t;
while (t--)
{
int a,n,b,m,... | C++ | 93fb13c40ab03700ef9a827796bd3d9d | f42bd59b00e05a7728b5a78f2b052c60 | 1,000 | PASSED |
#include <bits/stdc++.h>
using namespace std;
#define ll long long
int main()
{
ll t;
cin>>t;
while(t--){
ll n,a,b;
cin>>n>>a>>b;
string s;
cin>>s;
vector<pair<ll,ll>>v;
if(s[n-1]=='0'){
s.push_back('1');
}
e... | C++ | 93fb13c40ab03700ef9a827796bd3d9d | cc905adcff158afd4f91a60fa789614b | 1,000 | PASSED |
#include<iostream>
#include<cstdio>
#include<bitset>
#include<vector>
#include<math.h>
#include<algorithm>
#include<stack>
#include<set>
#include<map>
#include<queue>
#define BATSY ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0);
#define ll long long
#define ld long double
#define endl '\n'
#define DEC(n) cout<<fix... | C++ | 93fb13c40ab03700ef9a827796bd3d9d | e40ce4b4604eaef04cf2d437ed90447d | 1,000 | PASSED |
#include <bits/stdc++.h>
using namespace std;
#define _3en_7oras_ ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0);
#define el '\n'
using ll = long long ;
const int N = 5e3/2;
//sequence of solving [J,H,I,K,E,F,B,D,C]
int main() {
_3en_7oras_
int t;
cin>>t;
while(t--) {
int n, a, b;
... | C++ | 93fb13c40ab03700ef9a827796bd3d9d | f34beac41ac193f4961e99796d2d626a | 1,000 | PASSED |
// Created by KHALED MOSHARRAF PARVEZ
#include <bits/stdc++.h>
#define whatis1(x) cout<<#x<<"="<<x<<'\n'
#define whatis2(x,y) cout<<#x<<"="<<x<<","<<#y<<"="<<y<<'\n'
#define whatis3(x,y,z) cout<<#x<<"="<<x<<","<<#y<<"="<<y<<","<<#z<<"="<<z<<'\n'
#define whatisArray(arr,n) cout<<#arr<<", Size: "<<n<<'\n';for(int ... | C++ | e87ff02ce425fc3e96c09a15679aa656 | 737d5c127371b4b3dbe2cb413330c6f4 | 1,700 | PASSED |
# include<iostream>
# include<bits/stdc++.h>
using namespace std;
using ll = long long;
bool good(int l,int r,vector<ll> &a){
for(int i = l;i<=r;i++){
for(int j = i+1;j<=r;j++){
for(int k = j+1;k<=r;k++){
ll d1 = abs(a[j]-a[i]) + abs(j-i);
ll d2 = a... | C++ | e87ff02ce425fc3e96c09a15679aa656 | 32b9433ed2ba83e251c469d3a493f0a3 | 1,700 | PASSED |
# include<iostream>
# include<bits/stdc++.h>
using namespace std;
using ll = long long;
bool good(int l,int r,vector<ll> &a){
for(int i = l;i<=r;i++){
for(int j = i+1;j<=r;j++){
for(int k = j+1;k<=r;k++){
ll d1 = abs(a[j]-a[i]) + abs(j-i);
ll d2 = a... | C++ | e87ff02ce425fc3e96c09a15679aa656 | 3a531fb7d9bf8039e63e7799f15abfcb | 1,700 | PASSED |
# include<iostream>
# include<bits/stdc++.h>
using namespace std;
using ll = long long;
bool good(int l,int r,vector<ll> a){
for(int i = l;i<=r;i++){
for(int j = i+1;j<=r;j++){
for(int k = j+1;k<=r;k++){
ll d1 = abs(a[j]-a[i]) + abs(j-i);
ll d2 = ab... | C++ | e87ff02ce425fc3e96c09a15679aa656 | b4033dd41b49e0473ebc679e0c0fbed0 | 1,700 | PASSED |
# include<iostream>
# include<bits/stdc++.h>
using namespace std;
using ll = long long;
int main(){
ios :: sync_with_stdio(false);
cin.tie(NULL);
int T;
cin>>T;
while(T--){
int n;
cin>>n;
vector<ll> a(n);
for(int i = 0;i<n;i++){
cin>>a[i]... | C++ | e87ff02ce425fc3e96c09a15679aa656 | 78ffe81a7f83f1bcd9ef1a3f8da8bfb9 | 1,700 | PASSED |
#include <bits/stdc++.h>
using namespace std;
// ______________
// _ _
// _ /*/* _
// _ */ /* _
// _ /* _
// _ /*/ _
// _ /* */ _
// ______________
bool is_sortd(int x1, int x2, int x3)
{
if ((x1 >= x2 && x2 >= x3)) return false;
if (x1 <= x2 && x2 <= x3) ... | C++ | e87ff02ce425fc3e96c09a15679aa656 | a2c39271618e41a7fd028a9bf2a4c189 | 1,700 | PASSED |
#include <bits/stdc++.h>
using namespace std;
// ______________
// _ _
// _ /*/* _
// _ */ /* _
// _ /* _
// _ /*/ _
// _ /* */ _
// ______________
bool is_sortd(int x1, int x2, int x3)
{
if ((x1 >= x2 && x2 >= x3)) return false;
if (x1 <= x2 && x2 <= x3) retur... | C++ | e87ff02ce425fc3e96c09a15679aa656 | cfbd6659993a2046b1804fec544a1b48 | 1,700 | PASSED |
#include <bits/stdc++.h>
using namespace std;
/*/*
*/ /*
/*
/*/
/* */
bool is_sortd(int x1, int x2, int x3)
{
if ((x1 >= x2 && x2 >= x3)) return false;
if (x1 <= x2 && x2 <= x3) return false;
return true;
}
int main()
{
ios::sync_with_stdio(false);
cin.tie(0);
... | C++ | e87ff02ce425fc3e96c09a15679aa656 | 80de4aa8d45892d9cb0bb06d1f380946 | 1,700 | PASSED |
#include <bits/stdc++.h>
using namespace std;
/*/*
*/ /*
/*
/*/
/* */
bool is_sortd(int x1, int x2, int x3)
{
if ((x1 >= x2 && x2 >= x3)) return false;
if (x1 <= x2 && x2 <= x3) return false;
return true;
}
int main()
{
ios::sync_with_stdio(false);
cin.tie(0);
in... | C++ | e87ff02ce425fc3e96c09a15679aa656 | d57e201dc11fc054b495f59a51e7d853 | 1,700 | PASSED |
#include <bits/stdc++.h>
using namespace std;
/*/*
*/ /*
/*
/*/
/* */
bool is_sortd(int x1, int x2, int x3)
{
if ((x1 >= x2 && x2 >= x3)) return false;
if (x1 <= x2 && x2 <= x3) return false;
return true;
}
int main()
{
ios::sync_with_stdio(false);
cin.tie(0);
... | C++ | e87ff02ce425fc3e96c09a15679aa656 | e307179f9dafb8578d683afc3ab83c1b | 1,700 | PASSED |
#include<bits/stdc++.h>
using namespace std;
const int N=(4e5+5);
const int mod=(1e9+7);
int n,L,R;
int l[N],r[N];
int q[N],p[N];
inline int qpow(int x,int y){
int sum=1,tmp=y;
while(tmp){
///////
if(tmp&1)sum=1ll*sum*x%mod;
x=1ll*x*x%mod;
tmp>>=1;
}
return sum;
}
inline void st(int n){
q[0... | C++ | d8066e517678dfd6a11f2bfa9e0faed0 | ab2f08c3879814a40902f3b16fce5747 | 2,300 | PASSED |
#include<bits/stdc++.h>
using namespace std;
const int N=(4e5+5);
const int mod=(1e9+7);
int n,L,R;
int l[N],r[N];
int q[N],p[N];
inline int qpow(int x,int y){
int sum=1,tmp=y;
while(tmp){
if(tmp&1)sum=1ll*sum*x%mod;
x=1ll*x*x%mod;
tmp>>=1;
}
return sum;
}
inline void st(int n){
q[0]=1;
fo... | C++ | d8066e517678dfd6a11f2bfa9e0faed0 | a57afd05be652a5f81a0e81efdbf7589 | 2,300 | PASSED |
#include <string.h>
#include <stdio.h>
#include <math.h>
#include <map>
#include <queue>
#include <vector>
#include <numeric>
#include <iostream>
#include <algorithm>
using namespace std;
typedef long long ll;
typedef pair<int, int> pi;
typedef vector<int> vi;
#define mp make_pair
#define pb p... | C++ | d8066e517678dfd6a11f2bfa9e0faed0 | a9ff9613aecc03b8660702d1c6de7136 | 2,300 | PASSED |
#include <string.h>
#include <stdio.h>
#include <math.h>
#include <map>
#include <queue>
#include <vector>
#include <numeric>
#include <iostream>
#include <algorithm>
using namespace std;
typedef unsigned long long ll;
typedef pair<int, int> pi;
typedef vector<int> vi;
#define mp make_pair
#defin... | C++ | d8066e517678dfd6a11f2bfa9e0faed0 | 8f98014e0ebe1e75a8fef40e86112a5d | 2,300 | PASSED |
#include <string.h>
#include <stdio.h>
#include <math.h>
#include <map>
#include <queue>
#include <vector>
#include <numeric>
#include <iostream>
#include <algorithm>
using namespace std;
typedef long long ll;
typedef pair<int, int> pi;
typedef vector<int> vi;
#define mp make_pair
#define pb p... | C++ | d8066e517678dfd6a11f2bfa9e0faed0 | 6d4a2a2a49f287a74ed81ab8522b8084 | 2,300 | PASSED |
// LUOGU_RID: 95121017
/*
name: Excellent Arrays
id: CF1550D
date: 2022/11/22
*/
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int N = 4e5 + 10;
const ll P = 1e9 + 7;
int t, n, l, r;
ll A[N], invA[N];
ll qp(ll a,ll b){
ll ans = 1;
while(b){
if(b & 1){
ans... | C++ | d8066e517678dfd6a11f2bfa9e0faed0 | 1d5076f5ba8305d0f8d4380ce59c9e08 | 2,300 | PASSED |
/*
name: Excellent Arrays
id: CF1550D
date: 2022/11/22
*/
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int N = 4e5 + 10;
const ll P = 1e9 + 7;
int t, n, l, r;
ll A[N], invA[N];
ll qp(ll a,ll b){
ll ans = 1;
while(b){
if(b & 1){
ans = ans * a % P;
}
... | C++ | d8066e517678dfd6a11f2bfa9e0faed0 | 4cbfb4e7a4abed44f6428e73b424b71d | 2,300 | PASSED |
/*
name: Excellent Arrays
id: CF1550D
date: 2022/11/22
*/
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int N = 4e5 + 10;
const ll P = 1e9 + 7;
int t, n, l, r;
ll A[N], invA[N];
ll qp(ll a,ll b){
ll ans = 1;
while(b){
if(b&1) ans=ans*a%P;
a=a*a%P;
b>>=1... | C++ | d8066e517678dfd6a11f2bfa9e0faed0 | 3f63c59751d33140d012de549d076f0f | 2,300 | PASSED |
#include<cstdio>
#include<cstring>
#include<algorithm>
using namespace std;
#define int long long
const int MAXN=400005,MOD=1000000007;
int F[MAXN],F_[MAXN],n,l,r,T,f[MAXN][2],cnt,x,y,z,ans;
struct str{
int id,x,type;
bool operator < (str a){
return x<a.x;
}
}num[MAXN];
int pow(int a,int b){
int ans=1;
while(b){... | C++ | d8066e517678dfd6a11f2bfa9e0faed0 | 31490b116dcfcd58ca95f175baedb34e | 2,300 | PASSED |
#include<bits/stdc++.h>
#define forn(i,a,b)for(int i=(a),_b=(b);i<=_b;i++)
#define fore(i,b,a)for(int i=(b),_a=(a);i>=_a;i--)
#define rep(i,n)for(int i=0,_n=n;i<n;i++)
#define ll long long
#define pii pair<int,int>
#define m_p make_pair
#define pb push_back
#define fi first
#define se second
#define foreach(i... | C++ | d8066e517678dfd6a11f2bfa9e0faed0 | f54db5fca0564b060fdfdf55fcac051e | 2,300 | PASSED |
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx2,bmi,bmi2,popcnt,lzcnt")
#include <bits/stdc++.h>
using namespace std;
using ll = int64_t;
template <class Integer, class F>
Integer find_first_false(Integer l, Integer r,
F&& f) requires(sizeof(Integer) == 8) {
if (l > r) r... | C++ | 87d3c1d8d3d1f34664ff32081222117d | 210cd1c3fd51422157028fb77f172611 | 2,500 | PASSED |
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx2,bmi,bmi2,popcnt,lzcnt")
#include <bits/stdc++.h>
using namespace std;
using ll = int64_t;
template <class Integer, class F>
Integer find_first_false(Integer l, Integer r,
F&& f) requires(sizeof(Integer) == 4) {
if (l > r) r... | C++ | 87d3c1d8d3d1f34664ff32081222117d | f7ceb387d4eee8a7d3d2e30f657e7ea5 | 2,500 | PASSED |
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx,avx2,sse,sse2,sse3,sse4,popcnt")
#include <bits/stdc++.h>
using namespace std;
using ll = int64_t;
int main() {
cin.tie(nullptr)->sync_with_stdio(false);
int t = 1;
// cin >> t;
for (int test = 1; test <= t; test++) {
// cout << ... | C++ | 87d3c1d8d3d1f34664ff32081222117d | d04da9534595d4d40b92c170522b137b | 2,500 | PASSED |
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx,avx2,sse,sse2,sse3,sse4,popcnt")
#include <bits/stdc++.h>
using namespace std;
using ll = int64_t;
template <bool b>
auto binsearch(auto l, auto r, const auto& pred) {
--l, ++r;
for (decltype(l) m; m = midpoint(l, r), r > l + 1;) (pred(m) ? l : ... | C++ | 87d3c1d8d3d1f34664ff32081222117d | 41582d7af4c4193e355db0484e4666e5 | 2,500 | PASSED |
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx,avx2,sse,sse2,sse3,sse4,popcnt")
#include <bits/stdc++.h>
using namespace std;
using ll = int64_t;
template <bool b>
auto binsearch(auto l, auto r, auto&& pred) {
--l, ++r;
for (decltype(l) m; m = std::midpoint(l, r), r > l + 1;)
(pred(m... | C++ | 87d3c1d8d3d1f34664ff32081222117d | 8b86a98dcb420a5be72bf70f5d829b63 | 2,500 | PASSED |
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx,avx2,sse,sse2,sse3,sse4,popcnt")
#include <bits/stdc++.h>
using namespace std;
using ll = int64_t;
struct IOPre {
static constexpr int TEN = 10, SZ = TEN * TEN * TEN * TEN;
std::array<char, 4 * SZ> num;
constexpr IOPre() : num{} {
fo... | C++ | 87d3c1d8d3d1f34664ff32081222117d | 2cb283cad7ff933ca0dd9a3f6118bd64 | 2,500 | PASSED |
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx,avx2,sse,sse2,sse3,sse4,popcnt")
#include <bits/stdc++.h>
using namespace std;
using ll = int64_t;
template <bool b>
auto bin_search_split(auto l, auto r, const auto& predicate) {
--l, ++r;
while (r - l > 1) {
auto mid = std::midpoint(l,... | C++ | 87d3c1d8d3d1f34664ff32081222117d | 6ee35ae0a129e56271e06c13ab408f72 | 2,500 | PASSED |
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx,avx2,sse,sse2,sse3,sse4,popcnt")
#include <bits/stdc++.h>
using namespace std;
using ll = int64_t;
template <typename I, typename P, bool b>
I bin_search_split(I l, I r, const P &predicate) {
--l, ++r;
while (r - l > 1) {
auto mid = std:... | C++ | 87d3c1d8d3d1f34664ff32081222117d | 48f08f4737ba8a04ce1034af2f858ffc | 2,500 | PASSED |
#include <bits/stdc++.h>
using namespace std;
namespace internal {
// @param n `0 <= n`
// @return minimum non-negative `x` s.t. `n <= 2**x`
int ceil_pow2(int n) {
int x = 0;
while ((1U << x) < (unsigned int)(n)) x++;
return x;
}
// @param n `1 <= n`
// @return minimum non-negative `x` s.t.... | C++ | 87d3c1d8d3d1f34664ff32081222117d | c328037ad0e66455f8d1172ccdca6a2f | 2,500 | PASSED |
#include <bits/stdc++.h>
using namespace std;
namespace internal {
// @param n `0 <= n`
// @return minimum non-negative `x` s.t. `n <= 2**x`
int ceil_pow2(int n) {
int x = 0;
while ((1U << x) < (unsigned int)(n)) x++;
return x;
}
// @param n `1 <= n`
// @return minimum non-negative `x` s.t.... | C++ | 87d3c1d8d3d1f34664ff32081222117d | 42fb4dd044ea94e5b0f4b14180d5d1aa | 2,500 | PASSED |
#include <bits/stdc++.h>
#define mp make_pair
using namespace std;
const int inf = 1e9;
const int N = 2e5 + 5;
const int M = 1e6 + 5;
vector<int> p[N]; set<int> S;
pair<int, int> kcn[N];
int n, q, s, d, a[N], b[M], fa[N], dx[N], cnt, head[N], ID[2][N];
int find(int x) {return fa[x] == x ? x : fa[x] = find(fa[x... | C++ | 7ef1aeb7d4649df98e47d2c26cff251c | 555cd2a8f6ebec921bbd56786fa06403 | 2,700 | PASSED |
#include <bits/stdc++.h>
#define mp make_pair
using namespace std;
const int inf = 1e9;
const int N = 2e5 + 5;
const int M = 1e6 + 5;
struct st {int bel, x;} p[N];
bool cmp(st a, st b) {return a.bel < b.bel;}
set<int> S; pair<int, pair<int, int> > kcn[N];
int n, q, s, d, a[N], b[M], fa[N], mn[N], id[N], dx[N],... | C++ | 7ef1aeb7d4649df98e47d2c26cff251c | 62cd5b5b714cc409f8be8b5414842488 | 2,700 | PASSED |
#include <bits/stdc++.h>
#define mp make_pair
using namespace std;
const int inf = 1e9;
const int N = 2e5 + 5;
const int M = 1e6 + 5;
vector<int> p[N]; set<int> S;
pair<int, int> kcn[N];
int n, q, s, d, a[N], b[M], fa[N], dx[N], cnt, head[N], ID[2][N];
int find(int x) {return fa[x] == x ? x : fa[x] = find(fa[x... | C++ | 7ef1aeb7d4649df98e47d2c26cff251c | 3d495af848d6e4099c17adcb6d4358f5 | 2,700 | PASSED |
#include <bits/stdc++.h>
#include <random>
#include <chrono>
#define INF (ll)(2e16)
#define MOD (ll)(1e9 + 7)
#define pb push_back
#define mp make_pair
#define ft first
#define sd second
using namespace std;
using ll = long long;
using cd = complex<double>;
using ul = unsigned long;
void f_io () { ios_base :: sync_w... | C++ | 7ef1aeb7d4649df98e47d2c26cff251c | cadf1fe48323f4611f9679f5d7eae911 | 2,700 | PASSED |
#include <bits/stdc++.h>
#define N 200005
#define fi first
#define sc second
using namespace std;
typedef pair<int, int> II;
int amount , query , start , base_jump;
int rock_pos[N];
int head[N];
vector<int> component_obj[N];
vector<II> graph_map[N];
set<II> cur_pos;
struct edge {
int from... | C++ | 7ef1aeb7d4649df98e47d2c26cff251c | bc9c5dd9b71d37f16bdff3e149f4b4f5 | 2,700 | PASSED |
//
// Created by MerCI on 2022/4/12.
//
#include <bits/stdc++.h>
#define all(a) a.begin(),a.end()
#define rall(a) a.rbegin(),a.rend()
#define endl '\n'
#define ls p << 1
#define rs p << 1 | 1
using namespace std;
const int N = 2e5 + 1009;
const int mod = 1e9 + 7;
//const int N = 5009;
//const int N =... | C++ | 7ef1aeb7d4649df98e47d2c26cff251c | 3d709ce452143efbee1e054ae5b0ff4b | 2,700 | PASSED |
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <cstdio>
#include <vector>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <algorithm>
using namespace std;
#define fi first
#define se second
#define db double
#define LL long long
#define int long long
#define ... | C++ | 7ef1aeb7d4649df98e47d2c26cff251c | d60ec275e5ca29d4c3b5824bca0a2d59 | 2,700 | PASSED |
#include <set>
#include <vector>
#include <iostream>
using namespace std;
namespace Math {
int Abs(int x) { return (x > 0) ? x : -x; }
int Max(int u, int v) { return (u > v) ? u : v; }
int Min(int u, int v) { return (u < v) ? u : v; }
} using namespace Math;
const int MAX_n = 2e5;
const int MAX_m = 2... | C++ | 7ef1aeb7d4649df98e47d2c26cff251c | 9d73e841e32f6f46df3f42adc11cabce | 2,700 | PASSED |
#include<bits/stdc++.h>
#define file(s) freopen(s".in","r",stdin),freopen(s".out","w",stdout)
#define mod 1000000007
#define ll long long
#define N 1000005
using namespace std;
template<class T>void read(T&x) {
T f=1;x=0;char c=getchar();
while(c<'0'||c>'9'){if(c=='-')f=-1;c=getchar();}
while('0'<=c&&c<='9'... | C++ | 7ef1aeb7d4649df98e47d2c26cff251c | fc71f8215425dd67536245ebd66265a6 | 2,700 | PASSED |
#include <cstdio>
#include <vector>
#include <algorithm>
const int maxn = 2e5+5;
int n,m,S,D,a[maxn],ans[maxn],ecnt;
struct E{int x,y,z;}e[maxn*25];
std :: vector <int> V;
void lnk(int p,int s,int l){
auto it = std::lower_bound(V.begin(),V.end(),p);int P = it-V.begin();
if(it != V.end())e[++ecnt] = (E){s,l+P,*... | C++ | 7ef1aeb7d4649df98e47d2c26cff251c | c3450369c5e56a4b0c72b1f14f6be190 | 2,700 | PASSED |
#include <bits/stdc++.h>
using namespace std;
int main()
{
long long int t;
cin >> t;
for (long long int i = 0; i < t; i++)
{
long long int n, x = 2, a = 0, y = 0;
cin >> n;
string s, s2;
string s1 = "abcdefghijklmnopqrstuvwxyz";
vector<string> v, v1... | C++ | 83a665723ca4e40c78fca20057a0dc99 | 1edaa12fa295600cccefd94fbf9f912e | 1,200 | PASSED |
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define x first
#define y second
#define for0(i,n) for(int i = 0; i<n; i++)
#define for1(i,n) for(int i = 1; i<=n; i++)
#define sz(a) a.size()
#define pb push_back
typedef long long ll;
typedef pair<int,int>pii;
void solve() {
... | C++ | 83a665723ca4e40c78fca20057a0dc99 | 7ed7fe9d9881363a1e59ad1414799a6f | 1,200 | PASSED |
/*████████████████████████████████████████████████████████████████████████████████████
██████████████████████████████████████████████████████████████████████████████████████
███████████████████████████▓▓▓▓▓▓▓▓▓╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬▓▓▓╬╬╬╬╬╬▓███████████████████████
███████████████████████████▓███████▓▓╬╬╬╬╬╬╬╬╬╬╬╬▓███▓▓▓... | C++ | 83a665723ca4e40c78fca20057a0dc99 | 81fe03d51915dce641d7d2631635bc19 | 1,200 | PASSED |
/*████████████████████████████████████████████████████████████████████████████████████
██████████████████████████████████████████████████████████████████████████████████████
███████████████████████████▓▓▓▓▓▓▓▓▓╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬▓▓▓╬╬╬╬╬╬▓███████████████████████
███████████████████████████▓███████▓▓╬╬╬╬╬╬╬╬╬╬╬╬▓███▓▓▓... | C++ | 83a665723ca4e40c78fca20057a0dc99 | 11face1c21bdc9df095ecfd64d259e0f | 1,200 | PASSED |
/*████████████████████████████████████████████████████████████████████████████████████
██████████████████████████████████████████████████████████████████████████████████████
███████████████████████████▓▓▓▓▓▓▓▓▓╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬╬▓▓▓╬╬╬╬╬╬▓███████████████████████
███████████████████████████▓███████▓▓╬╬╬╬╬╬╬╬╬╬╬╬▓███▓▓▓... | C++ | 83a665723ca4e40c78fca20057a0dc99 | 03165f57a84908f68a41e45399ad4173 | 1,200 | PASSED |
#include <bits/stdc++.h>
using namespace std;
bool cmp(string a, string b){
if (a.size() == b.size()){
return a < b;
}
return a.size() < b.size();
}
void solve()
{
int n;
cin >> n;
string s;
cin >> s;
vector<string> ans;
for (char i = 'a'; i <= 'z'; i++)
{
bool ok = false;
for (int j = 0; j ... | C++ | 83a665723ca4e40c78fca20057a0dc99 | 47bffe478ab125808d2f2f2f97d0f165 | 1,200 | PASSED |
#include <bits/stdc++.h>
using namespace std;
#define pb push_back
#define ll long long int
ll powe(ll n)
{
ll s=1;
for(int i=1;i<=n;i++)s*=10;
return s;
}
// bool isSubstring(string s1, string s2)
// {
// if (s2.find(s1) != string::npos)
// return s2.find(s1);
// retur... | C++ | 83a665723ca4e40c78fca20057a0dc99 | d7f6e1938fc176671c3b9c560c777b47 | 1,200 | PASSED |
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int maxn=2e4+5;
int a[maxn] ;
void solve() {
memset(a , 0 , sizeof(a)) ;
int n ;
cin >> n ;
string s ;
cin >> s ;
if(n == 1){
if(s == "a")
cout << "b" << endl ;
else
cout << "... | C++ | 83a665723ca4e40c78fca20057a0dc99 | 0a9ee2504bea67af8d5c7d52cca9e74c | 1,200 | PASSED |
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int maxn=1e1+5;
int a[20000] ;
void solve() {
memset(a , 0 , sizeof(a)) ;
int n ;
cin >> n ;
string s ;
cin >> s ;
for(int i = 0 ; i < n ; i++){
a[s[i] - 'a']++ ;
}
for(int i = 0 ; i < 26 ; i+... | C++ | 83a665723ca4e40c78fca20057a0dc99 | b5e1e8e22efc646e65a32971e51aff29 | 1,200 | PASSED |
#include<bits/stdc++.h>
using namespace std;
void ass(){
int flag=1;
set<string>q;
string s;
int n;
cin>>n;
cin>>s;
for(int i=0;i<n;i++){
string ss;
for(int j=0;j<5&&j+i<n;j++){
ss.push_back(s[j+i]);
q.insert(ss);
}
}
for(int len=1;len<=6;len++) {
string t(len,... | C++ | 83a665723ca4e40c78fca20057a0dc99 | 749a9097c590759d086bdac26f086f9d | 1,200 | PASSED |
#include <bits/stdc++.h>
typedef int ll;
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
ll t, n;
string s;
cin >> t;
for (ll iii = 0; iii < t; ++iii) {
cin >> n;
cin >> s;
unordered_map<double, ll> m;
m.reserve(n * 2);
double K = 0, D = 0;
for (auto&... | C++ | de2e2e12be4464306beb0217875f66c7 | f6e79a00b9c91e2ad43b0d1d9d440698 | 1,500 | PASSED |
#include <bits/stdc++.h>
typedef int ll;
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
ll t, n;
string s;
double KD;
cin >> t;
for (ll iii = 0; iii < t; ++iii) {
cin >> n;
cin >> s;
unordered_map<double, ll> m;
m.reserve(n*2);
double K = 0, D = 0;
... | C++ | de2e2e12be4464306beb0217875f66c7 | 4a8b749f50a93d5c87dbb36a4366c543 | 1,500 | PASSED |
#include <bits/stdc++.h>
typedef int ll;
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
ll t, n;
string s;
cin >> t;
for (ll iii = 0; iii < t; ++iii) {
cin >> n;
cin >> s;
unordered_map<double, ll> m;
m.reserve(n*2);
double K = 0, D = 0;
for (auto& i... | C++ | de2e2e12be4464306beb0217875f66c7 | 141a6b40bf6188df5ee2a0bf4f4bcbd1 | 1,500 | PASSED |
#pragma GCC optimize("Ofast")
#include <bits/stdc++.h>
typedef int ll;
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
ll t, n;
string s;
cin >> t;
for (ll iii = 0; iii < t; ++iii) {
cin >> n;
cin >> s;
unordered_map<double, ll> m;
m.reserve(n*2);
doubl... | C++ | de2e2e12be4464306beb0217875f66c7 | 5926070d18de3dbfad73b120a6f61208 | 1,500 | PASSED |
#include <bits/stdc++.h>
typedef int ll;
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
ll t, n;
string s;
cin >> t;
for (ll iii = 0; iii < t; ++iii) {
cin >> n;
cin >> s;
map<double, ll> m;
double K = 0, D = 0;
for (auto& i : s) {
K += i == 'K';
... | C++ | de2e2e12be4464306beb0217875f66c7 | c41856eee9e83870f7cc2487ec9bf5d0 | 1,500 | PASSED |
#include <bits/stdc++.h>
typedef int ll;
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
ll t, n;
string s;
cin >> t;
for (;t > 0; --t) {
cin >> n;
cin >> s;
unordered_map<double, ll> m;
m.reserve(n*2);
double K = 0, D = 0;
for (auto& i : s) {
K +=... | C++ | de2e2e12be4464306beb0217875f66c7 | c6eec4d1795390d234b5dd2d84d9e589 | 1,500 | PASSED |
#include <bits/stdc++.h>
typedef int ll;
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
ll t, n;
string s;
cin >> t;
for (ll iii = 0; iii < t; ++iii) {
cin >> n;
cin >> s;
string ans;
unordered_map<double, ll> m;
m.reserve(n*2);
double K = 0, D = 0;
... | C++ | de2e2e12be4464306beb0217875f66c7 | 0a3a61c3c621a90d8e7aa24a6053d72d | 1,500 | PASSED |
#include <bits/stdc++.h>
typedef int ll;
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
ll t, n;
string s;
cin >> t;
for (ll iii = 0; iii < t; ++iii) {
cin >> n;
cin >> s;
unordered_map<double, ll> m;
m.reserve(n*2);
double K = 0, D = 0;
for (auto& i... | C++ | de2e2e12be4464306beb0217875f66c7 | a6d42427388d1ad22d7ea1d384b6cf43 | 1,500 | PASSED |
#include <bits/stdc++.h>
typedef int ll;
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
ll t, n, now;
unordered_map<double, int>::iterator a;
string s;
cin >> t;
for (ll iii = 0; iii < t; ++iii) {
cin >> n;
cin >> s;
unordered_map<double, ll> m;
m.reser... | C++ | de2e2e12be4464306beb0217875f66c7 | 12534bc6e3212e0f960e5e1aeff94685 | 1,500 | PASSED |
#include <bits/stdc++.h>
typedef int ll;
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
ll t, n, now;
string s;
cin >> t;
for (ll iii = 0; iii < t; ++iii) {
cin >> n;
cin >> s;
unordered_map<double, ll> m;
auto a = m.begin();
m.reserve(n*2);
double K... | C++ | de2e2e12be4464306beb0217875f66c7 | 9f0fc6563bf0fb636738e4ac7803c316 | 1,500 | PASSED |
#include<bits/stdc++.h>
using namespace std;
int a[107];
void slov()
{
int n;
cin>>n;
for(int i=1;i<=n;i++)
{
cin>>a[i];
}
sort(a+1,a+1+n);
if(a[1]<0)
return void(puts("NO"));
puts("YES");
vector<int>G;
int len=0;
for(int i=2;i<=n;i++)
{
if(a[i]==a[i-1])
{
G.push_back(a[i]);
... | C++ | 5698e6fd934b9f6b847d7e30a3d06f2b | 52f724b5fb6f281c0936dfc2aa33289d | 800 | PASSED |
#include<iostream>
#include<algorithm>
using namespace std;
const int N=110;
int a[N];
int main()
{
int m;
cin>>m;
while(m--)
{
int n;
cin>>n;
int Max=-1e9,Min=1e9;
for(int i=0;i<n;i++)
{
cin>>a[i];
Max=max(Max,a[i]);
Min=min(Min,a[i]);
}
sort(a,a+n);
if(Min<0)
cout<<"NO"<<endl;
else... | C++ | 5698e6fd934b9f6b847d7e30a3d06f2b | 70171c7648d7b50ef43e94aff6518771 | 800 | PASSED |
#include "iostream"
#include "vector"
#include "cmath"
using namespace std;
const int N = 2e5+5;
int a[N];
int main() {
int t, n;
cin >> t;
while (t--) {
cin >> n;
vector<int>a;
int num, f = 1;
for (int i = 0; i < n; i++) {
cin >> num;
if (num < 0) { f = 0; }
a.push_back(num);
}
if (f) {
vec... | C++ | 5698e6fd934b9f6b847d7e30a3d06f2b | af15f13f87993733c856ee1644afcfee | 800 | PASSED |
#include <iostream>
#include <algorithm>
#include <cstring>
#include <cstdio>
#include <queue>
#include <map>
#include <vector>
#include <stack>
#include <set>
#include <sstream>
#include <fstream>
#include <cmath>
#include <iomanip>
#include <bitset>
#include <unordered_map>
#include <unordered_set>
#define x first
#... | C++ | 5698e6fd934b9f6b847d7e30a3d06f2b | 4c18feec2f8c6d0be38387288bde5fc5 | 800 | PASSED |
#include<iostream>
using namespace std;
const int N = 200010;
int a[N];
void solve()
{
int n;
int mi = 1e5;
int mx = -1e5;
cin>>n;
for(int i=0;i<n;i++)
{
cin>>a[i];
mi = min(mi,a[i]);
mx = max(mx,a[i]);
}
if(mi<0)
{
cout<<"NO"<<endl;
return ;
}
cout<<"YES"<<endl;
cout<<mx+1<<endl;
for(int i=0;i<=... | C++ | 5698e6fd934b9f6b847d7e30a3d06f2b | 52ba876bd2a1c723ed9c15c0871d13ac | 800 | PASSED |
#include<iostream>
#include<algorithm>
using namespace std;
int main(void)
{
int t;
cin>>t;
while(t--)
{
int n,a[101],maxx=-101,i,flag=1;
cin>>n;
for(i=1;i<=n;i++)
{
cin>>a[i];
maxx=max(a[i],maxx);
if(a[i]<0)
{
... | C++ | 5698e6fd934b9f6b847d7e30a3d06f2b | 8e8847c201ab2a356b2b9c22e2da7d1a | 800 | PASSED |
//g++ -std=c++17 -Wl,--stack,268435456 Ahoyy.cpp -o Ahoyy.exe
#include<bits/stdc++.h>
#pragma GCC optimize("Ofast")
#pragma GCC optimize("unroll-loops")
#pragma GCC target("sse4")
using namespace std;
typedef long double ld;
typedef long long ll;
typedef unsigned long long ull;
#define pii pair<int,int>
#define pll p... | C++ | 5698e6fd934b9f6b847d7e30a3d06f2b | 7af53bbd6e245adb374b3438f29ceba1 | 800 | PASSED |
#include<bits/stdc++.h>
using namespace std;
const int N = 300010;
int main()
{
int t;
cin >> t;
while(t--)
{
int a[N];
bool pd =1;
vector<int>vc;
int n;
cin >>n;
for(int i = 0 ;i <n; i ++)
{
int kk;
cin >>a[i];
... | C++ | 5698e6fd934b9f6b847d7e30a3d06f2b | 03712570c8df3e1bcf332472d75d7489 | 800 | PASSED |
#include <bits/stdc++.h>
using namespace std;
int a[300];
int main(){
ios::sync_with_stdio(false);
int t;
cin >> t;
while(t--){
int n;
cin >> n;
bool fu = false;
for (int i = 0; i < n;i++){
cin >> a[i];
if(a[i] < 0){
fu = true;
... | C++ | 5698e6fd934b9f6b847d7e30a3d06f2b | 31d1d44275d8473797dc882e740ac09d | 800 | PASSED |
#include <bits/stdc++.h>
#define int long long
#define IOS ios::sync_with_stdio(false), cin.tie(0)
#define ll long long
#define ull unsigned long long
#define PII pair<int, int>
#define PDI pair<double, int>
#define PDD pair<double, double>
#define debug(a) cout << #a << " = " << a << endl
#define all(x) (x).beg... | C++ | 5698e6fd934b9f6b847d7e30a3d06f2b | 460595cb6c56817530c659713c363223 | 800 | PASSED |
#include <iostream>
#include <vector>
#include <algorithm>
#include <assert.h>
using namespace std;
#define pb push_back
#define ii pair<int, int>
#define f1 first
#define s2 second
const int MAX = 2e5 + 69;
int bit[MAX] = {};
vector<ii> history;
inline void add(int x, int val)
{
for (int i = x; i ... | C++ | 6ed24fef3b7f0f0dc040fc5bed535209 | ffa1cf05767b117b126681479b63aafc | 2,000 | PASSED |
#include <iostream>
#include <vector>
#include <algorithm>
#include <assert.h>
using namespace std;
#define pb push_back
#define ii pair<int, int>
#define f1 first
#define s2 second
const int MAX = 2e5 + 69;
int bit[MAX] = {};
vector<ii> history;
inline void add(int x, int val)
{
history.pb({x, val... | C++ | 6ed24fef3b7f0f0dc040fc5bed535209 | 71fc568182c8e04bba51db7f9215cd51 | 2,000 | PASSED |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.