| # | Time | Username | Problem | Language | Result | Execution time | Memory |
|---|---|---|---|---|---|---|---|
| 1335768 | monaxia | Languages (IOI10_languages) | C++20 | 0 ms | 0 KiB |
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
// #pragma GCC optimize("O3,unroll-loops")
// #pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt")
#define pb push_back
#define ppb pop_back
#define fr first
#define sc second
#define all(v) v.begin(), v.end()
#define vektor vector
#define ordered_set tree<pair <ll, ll>, null_type, less<pair <ll, ll>>, rb_tree_tag, tree_order_statistics_node_update>
using namespace std;
using namespace __gnu_pbds;
using ll = long long;
using ull = unsigned long long;
using ld = long double;
constexpr ull Mod = 1e9 + 7;
constexpr ull sqr = 708;
constexpr ld EPS = 1e-12L;
mt19937_64 rng(chrono::steady_clock::now().time_since_epoch().count());
ll random(ll l, ll r) {if (l > r) return -1; return uniform_int_distribution<ll>(l, r)(rng);}
int a[101][101], mark[100];
// int language(int L){return random(0, 55);}
void exerpt(int e[100]){
sort(e, e + 100);
for(int i = 0; i < 56; i ++){
int cnt = 0;
for(int j = 0; j < 100; j ++){
if(a[i][j] == e[j]) cnt ++;
}
if(cnt == 100){
language(i);
return;
}
}
int num = 0;
mark[0] = 1;
while(mark[num]) num = random(0, 55);
int ans = language(num);
mark[ans] = 1;
for(int j = 0; j < 100; j ++) a[ans][j] = e[j];
}