uuid
stringlengths
36
36
repo_name
stringlengths
5
123
relative_path
stringlengths
5
4k
content
stringlengths
33
2.85M
category
stringclasses
6 values
algo_rel_score
float64
0.85
1
quality_score
float64
3
8.76
67b475bd-c572-4108-a8a4-abc03cc81377
raincross7/code-similarity
codes/train_code/problem368/problem368_364.cpp
#include <bits/stdc++.h> using namespace std; using ll = long long; int main(){ ll A,B,K; cin >> A >> B >> K; if(K<A){ A-=K; } else{ if(K-A<B){ B-=K-A; } else{ B=0; } A=0; } cout << A << " " << B << endl; }
ALGO
0.999964
3.9486
a3d03495-a3fa-4190-8550-2094f72285c5
kunal26das/codes
Data-Structures/Graphs/1. Trees/Binary Search Tree/Backup/3 pointer vertex binary search tree/10.3.cpp
#include<iostream> #include<stdlib.h> #include<conio.h> using namespace std; class vertex { public: int value; vertex *up; vertex *left; vertex *right; vertex() { up=NULL; left=NULL; right=NULL; } }; class binary { void place(vertex **ptr,vertex *x) { ...
ALGO
0.999891
3.867726
976e14f7-c6d5-4894-9b85-d1a4a13d11bc
MrE2ooo/SecureLoginDisplay
windows/runner/utils.cpp
#include "utils.h" #include <flutter_windows.h> #include <io.h> #include <stdio.h> #include <windows.h> #include <iostream> void CreateAndAttachConsole() { if (::AllocConsole()) { FILE *unused; if (freopen_s(&unused, "CONOUT$", "w", stdout)) { _dup2(_fileno(stdout), 1); } if (freopen_s(&unuse...
TOOL
0.998757
6.771107
812e2558-bd28-44ce-a5c6-8c1522729979
Deeptig9138/DSA-in-CPP
Basics/Patterns/Square Pattern/solid_square1.cpp
#include <iostream> using namespace std; int main(){ int n; cout<<"Enter number of rows: "; cin >> n; for(int i = 0; i < n; i++){ int num = 1; for(int j = 0; j < n; j++){ cout<<num; num = num + 1; } cout<<endl; } return 0; }
ALGO
0.999818
4.2193
bb043860-86b2-46ce-b9c5-6ce11c8923f3
SolveGuys/AlgorithmStudy
Problems_Archives/113week/ChopangE/7579.cpp
#include<iostream> #include<vector> using namespace std; int main() { ios_base::sync_with_stdio(0); cin.tie(NULL); cout.tie(NULL); int N, M; cin >> N >> M; vector<int> bite(N+1); vector<int> cost(N + 1); for ( int i = 1; i < N + 1; i++ ) { cin >> bite[i]; } for ( int i = 1; i < N + 1; i++ ) { cin >> cost[...
ALGO
0.999998
3.963108
3810f594-9c38-47c8-ad2c-661a1d27f0f4
binchengecon/TwoCapital_Final
src/cppcore/eigen3/bench/sparse_cholesky.cpp
// #define EIGEN_TAUCS_SUPPORT // #define EIGEN_CHOLMOD_SUPPORT #include <iostream> #include <Eigen/Sparse> // g++ -DSIZE=10000 -DDENSITY=0.001 sparse_cholesky.cpp -I.. -DDENSEMATRI -O3 -g0 -DNDEBUG -DNBTRIES=1 -I /home/gael/Coding/LinearAlgebra/taucs_full/src/ -I/home/gael/Coding/LinearAlgebra/taucs_full/build/lin...
ALGO
0.99709
4.157064
f1ce0efd-9767-4358-89d4-17ba08372597
omkaranu04/CP_DSA
AtCoder/abc373/B.cpp
#include <bits/stdc++.h> using namespace std; int main(int argc, char const *argv[]) { ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); vector<int> a(26); int ans = 0; string s; cin >> s; for (int i = 0; i < s.length(); i++) a[s[i] - 'A'] = i + 1; for (int i =...
ALGO
0.999906
4.042934
ef7d87f3-c2b8-4148-b7db-c21cbfcd15d1
mamichr/oop-vjezbe
3.vjezba/3.cpp
#include <iostream> #include <vector> using namespace std; void urediVektor(vector<int>& v) { int maxElement = v[0]; int maxIndex = 0; for (int i = 1; i < v.size(); ++i) { if (v[i] > maxElement) { maxElement = v[i]; maxIndex = i; } } int suma = 0; for ...
ALGO
0.999887
5.579568
2dc11369-c78b-419d-9c71-72354ca74040
PranxXxD/DSA-Problems
C++/Functions/areacircle.cpp
#include<iostream> using namespace std; int area(float n){ float pie = 3.14; float Area = pie * n*n; return Area; } int main(){ float AreaCircle = area(15); cout<< "Area of circle is :- " << AreaCircle << endl; }
ALGO
0.997238
3.840889
3788413c-c420-432f-8852-44f48d53f094
risehyun/Cplusplus-Practice
Charpter01 연산자 오버로딩/EX6_12.cpp
/* vector front() back() ̳ʴ ġ() Ƿ, ̳ vector, list, deque ù ° front(), back() Լ Ѵ. */ #include <iostream> #include <vector> using namespace std; int main() { vector<int> v; v.push_back(10); v.push_back(20); v.push_back(30); v.push_back(40); v.push_back(50); for (size_t i = 0; i < v.size(); ++i...
TOOL
0.986411
4.135431
133b3b48-36fb-4e49-b0b6-f857beae73a8
ashish-17/SoftBoundCETS-4.0
llvm-4.0.0/lib/Transforms/Utils/LoopUnrollRuntime.cpp
#include "llvm/Transforms/Utils/UnrollLoop.h" #include "llvm/ADT/Statistic.h" #include "llvm/Analysis/AliasAnalysis.h" #include "llvm/Analysis/LoopIterator.h" #include "llvm/Analysis/LoopPass.h" #include "llvm/Analysis/ScalarEvolution.h" #include "llvm/Analysis/ScalarEvolutionExpander.h" #include "llvm/IR/BasicBlock.h"...
ALGO
0.987522
7.904688
92012b46-875d-4781-9023-dd12e2209866
openharmony/third_party_skia
docs/examples/SkPath_cubicTo_example.cpp
REG_FIDDLE(SkPath_cubicTo_example, 512, 512, false, 0) { /* If the starting point is (x0, y0), then this curve is defined as the paramentric curve as `t` goes from 0 to 1: s := 1 - t x := (s * s * s * x0) + (3 * s * s * t * x1) + (3 * s * t * t * x2) + ...
ALGO
0.991087
4.208977
de561368-d33f-4f53-8e48-4a26c3408508
tongdaxu/ECE-9343-Exercise
3-11-2.Hash_Table/main.cpp
/* 11.1 Direct Hashing 11.2 Hash Table with LinkNode 11.3 Hash Function */ #include <stdlib.h> #include <stdio.h> #include <vector> #include <iostream> #include <stack> #include <math.h> #include <random> #define HASH 2 template<class T> class Bucket{ public: int aRecord = -1; int bRecord = -1; int key; ...
ALGO
0.997813
4.478495
965ff196-5401-41eb-b166-7447014f8e31
Rupali-Ilish/XPSC
week 7/Day 3/Two Array.cpp
#include<bits/stdc++.h> using namespace std; #define ll long long int #define endl "\n" #define pi acos(-1) #define pb push_back #define pll pair<ll,ll> #define NO cout<<"NO"<<endl #define YES cout<<"YES"<<endl #define choto(x) sort((x).begin(), (x).end()) #define boro(x) sort((x).rbegin(), (x).rend()) #define ff first...
ALGO
0.999962
3.773704
296538a6-8310-44b4-b763-c179fae76f5b
ishandutta2007/codeforces
latte0119/normal/710/C.cpp
#include<bits/stdc++.h> using namespace std; #define int long long #define rep(i,n) for(int i=0;i<(n);i++) #define pb push_back #define eb emplace_back #define all(v) (v).begin(),(v).end() #define fi first #define se second using vint=vector<int>; using pint=pair<int,int>; using vpint=vector<pint>; template<typenam...
ALGO
0.999977
3.309273
8ad712e5-2697-4491-81ed-a497f943bc00
RickSchanze/AlgorithmExercise
138.M.2.cpp
/* * @lc app=leetcode.cn id=138 lang=cpp * * [138] 随机链表的复制 */ #include <bits/stdc++.h> #include <unordered_map> using namespace std; class Node { public: int val; Node* next; Node* random; Node(int _val) { val = _val; next = NULL; random = NULL; } }; // @lc code=star...
ALGO
0.999172
5.33405
c139c837-f877-4a4f-ae0c-92e072f55c6f
Intermodalics/pcl-debian
doc/tutorials/content/sources/greedy_projection/greedy_projection.cpp
#include <pcl/point_types.h> #include <pcl/io/pcd_io.h> #include <pcl/kdtree/kdtree_flann.h> #include <pcl/features/normal_3d.h> #include <pcl/surface/gp3.h> int main (int argc, char** argv) { // Load input file into a PointCloud<T> with an appropriate type pcl::PointCloud<pcl::PointXYZ>::Ptr cloud (new pcl::Point...
TOOL
0.940682
6.099657
d9d6cd31-2e6d-41ec-ad12-68fb8027d277
heavenMOJANG/ICPC
.history/programmes_C_Cpp/network_20250423191601.cpp
#pragma GCC optimize(1) #pragma GCC optimize(2) #pragma GCC optimize(3, "Ofast", "inline") #include <bits/stdc++.h> #define int long long using namespace std; constexpr int INF = 0x7fffffff; int a[3], g[16][16], dp[16]; int get(int x) { return 15 - x; } void solve() { int n; cin >> n; for (int i{}; i < 16; ...
ALGO
0.999062
4.434881
d22c5787-adc2-45a3-bf28-55c43a24bc31
ellenzinc/practiceProgramming_cpp
Ch 10. Solutions to Sorting and Searching/5.SparseSearch/sparseSearch.cpp
#include <iostream> #include <string> #include <vector> using namespace std; int sparseSearch(const vector<string> &strs, const string &target) { if (strs.empty() || target.empty()) return -1; int left = 0, right = (int)strs.size()-1; while(left <= right) { int mid= left + ((right - left)>>1); ...
ALGO
0.998442
5.131781
87b0c491-915a-479d-8c1d-9ccdd5e263d8
aryanharitsh123/Competitive-Programming-
A_Digital_Counter.cpp
#include<bits/stdc++.h> using namespace std; typedef long long int lli; #define all(arr) arr.begin(),arr.end() #define f first #define s second #define debug1(x) cout<<x<<"\n" #define debug2(x,y) cout<<x<<" "<<y<<"\n" #define debug3(x,y,z) cout<<x<<" "<<y<<" "<<z<<"\n" #define nl cout<<"\n"; #define pq priority_queue...
ALGO
0.99978
3.484127
a7d91b9d-6eb0-4a2b-b731-730efe9e1ef3
eulivre/lumen
src/instantx.cpp
#include "activemasternode.h" #include "darksend.h" #include "instantx.h" #include "key.h" #include "main.h" #include "masternode-sync.h" #include "masternodeman.h" #include "net.h" #include "protocol.h" #include "spork.h" #include "sync.h" #include "txmempool.h" #include "util.h" #include "consensus/validation.h" #in...
TOOL
0.983746
3.187586
ea795f9a-b2c0-414f-899c-927eb8aac072
pravin435916/Cpp-DSA
heap/topKFrequentElements.cpp
// according to higher frequency,store highest frequency elements to add first k highest frequency elements to the heap class Solution { public: vector<int> topKFrequent(vector<int>& nums, int k) { priority_queue<pair<int,int>> pq; map<int,int> mp; for(int i=0;i<nums.size();i++){ ...
ALGO
0.999989
5.97002
1065af6a-05dd-40a1-b71e-3d82cde751a4
DavidZyy/test
src/oj/2/J.cpp
#include <string> #include <iostream> #include <cmath> #include <iomanip> #include <cstdio> #include <algorithm> #include <vector> #include <climits> #include <set> #include <queue> #include <cstring> #include <queue> using namespace std; int main() { int n; cin>>n; while(n--){ int a, b; ci...
ALGO
0.999675
3.665802
9bff17fa-dcc3-4eaf-92ae-649acf1666d5
AnasAbdullh/Soultions_Problems_Solving_Level2
018DecryptText.cpp
#include <iostream> #include <string> using namespace std; string ReadText() { string txt = ""; cout << " Enter Text " << endl; cin >> txt; return txt; } string Encrypt(string txt) { short length = txt.length() - 1; string sum = " "; for (short i = 0; i <= length; i++) { char...
ALGO
0.986498
3.771625
911832ac-df65-44bf-82d0-5db09b1fe19a
kangsw1025/TIL
SolveProblem/20/20.06/20_06_19/200619_15686_치킨 배달.cpp
#include<iostream> #include<vector> #include<cmath> #include<algorithm> using namespace std; #define INF 987654231 vector<pair<int, int>> p, ch; int n, m, ans = INF; bool on[14]; int arr[51][51]; int find(pair<int, int> pa) { int sum = INF; int w = pa.first; int h = pa.second; for (int i = 0; i < 14; i++) { if...
ALGO
0.999716
3.670123
95353dee-52f7-4cc0-829a-bf914c7a1210
113bommy/deepmind_codecontests_refine
cpp_source_filter_file/cpp_train_13138_9.cpp
#include <bits/stdc++.h> using namespace std; const int MN = 1e6 + 44; const int mod = 1e8 + 9, b = 7; long long rcshnt[MN]; int n; char a[MN]; bool check(int len) { ; long long curr = 0; for (int i = 0; i < len; ++i) curr = (curr * b + a[i]) % mod; long long pre = curr; ; for (int i = len; i < n - 1; ++i) ...
ALGO
0.999986
3.478724
f5c20fea-49bf-49fa-9c6f-91c044a3d569
Jianxff/pyslam
3rd/g2o/g2o/solvers/slam2d_linear/slam2d_linear.cpp
#include "solver_slam2d_linear.h" #include "g2o/solvers/csparse/linear_solver_csparse.h" #include "g2o/core/block_solver.h" #include "g2o/core/solver.h" #include "g2o/core/optimization_algorithm_factory.h" #include "g2o/core/sparse_optimizer.h" #include "g2o/core/optimization_algorithm.h" #include "g2o/stuff/macros....
TOOL
0.983632
7.460847
66e4b4e3-21f9-498e-8a9a-3e04ad371076
raincross7/code-similarity
codes/train_code/problem159/problem159_2.cpp
#include <bits/stdc++.h> #include <iostream> using namespace std; int main() { int x; cin >> x; int t = x; int k = 1; while( t % 360 != 0 ) { k++; t += x; } cout << k; }
ALGO
0.999749
3.293093
3365e78d-72c2-4399-b71a-c62e455090c6
OsmarGHz/Algorithms
AtCoder/June 2025/Knapsack2/Knapsack2AErroneo.cpp
//Here, i tried to do a value-based dp, but first, iterating every posible value capacity, and inside of that, iterating by every element. This solves the unbounded knapsack, NOT the 0/1 knapsack #include <bits/stdc++.h> using namespace std; using ll = long long; const ll INF = 1e18; int main(){ int n,w; ll m...
ALGO
0.999994
4.760008
b45d07ba-5bc0-40a6-8fac-6013444fff5b
heqikun85/Code_Note
C++/210课件/8. Searching, Sorting, and Algorithm Efficiency/Selection Sort.cpp
void SelectSort(int DataArray[]) { int NextIdx; /* Next open position in sorted section */ int LargestKey; /* INdex of largest key in unsorted section */ int i; int temp; NextIdx = SIZE - 1; while(NextIdx > 0) { LargestKey = NextIdx; /* Ini...
ALGO
0.99997
4.348572
4343010a-f7d5-4a5b-9917-578d62d0ed02
likethestarsF/Backjun-Saves
Class_3/11286.cpp
// 240305 4 #11286 // 240306 1 #11286 #include <algorithm> #include <iostream> #include <vector> #define MAX_COMMAND 1000000 using namespace std; class heap_ABS { struct abs { bool isPos; unsigned int value; }; vector<abs> heap; public: heap_ABS() { heap.reserve(MAX_COMMAND + 1); heap.push_bac...
ALGO
0.999894
4.272183
398e84b9-643b-49fb-ad22-83b048eb0b93
wns5255/2020STD_C_1
20181025_LYH/백준_/3단계_/11021.cpp
// A+B (7) #include <iostream> using namespace std; int main(void) { int t; cin >> t; int a, b; for (int i = 1; i <= t; i++) { cin >> a >> b; cout << "Case #" << i << ": " << a + b << endl; } return 0; }
ALGO
0.997354
6.078169
c5443905-b2ec-4204-afdc-34566aed11c6
divyarochani/Leetcode_Question
136-single-number/single-number.cpp
class Solution { public: int singleNumber(vector<int>& nums) { int ans = 0; for(auto it: nums){ ans^= it; } return ans; } };
ALGO
0.999957
5.565799
2473a680-4299-4fab-ba9c-861233eb8008
sknabil/graph_codes
Graph_Sampling_updated.cpp
//#define __STDC_FORMAT_MACROS #define N 65000 #include <stdio.h> #include <string.h> #include <stdlib.h> #include <stdint.h> #include <time.h> #include <math.h> #include <map> uint64_t total_edges; struct Graph { struct Node* head[N]; struct Edge* edges; uint64_t numberOfEdges; }; struct Node { uint64_t dest;...
DATA
0.955631
3.836994
c5a953e1-bd31-494f-bd2b-cbbb494937f7
hyakukyojin/link382010
C++/souoc/souoc.cpp
#include <bits/stdc++.h> using namespace std; int main() { freopen ("souoc.inp","r",stdin); freopen ("souoc.out","w",stdout); int n; cin>>n; int souoc=0; for (int i=1;i<=n;i++) if (n%i==0)souoc++; cout<<souoc; return 0; }
ALGO
0.999433
4.460721
3d1662de-cca9-4203-89dc-2a3cfe7bc8d8
alexfreud/winamp
Src/external_dependencies/openmpt-trunk/include/unrar/model.cpp
/**************************************************************************** * This file is part of PPMd project * * Written and distributed to public domain by Dmitry Shkarin 1997, * * 1999-2000 * * Cont...
ALGO
0.999024
4.825659
35038ff1-00c7-43e7-aedc-e7bd57b37775
GeraldCrnj/Tareas_INF221_2024-2
Tarea1/Algoritmos de Ordenamiento/MergeSort.cpp
#include <iostream> #include <algorithm> #include <vector> #include <chrono> #include <fstream> using namespace std; vector<int> mergeSort(vector<int> v){ int n = v.size(); if (n <= 1) return v; int mid = n / 2; vector<int> v1(v.begin(), v.begin() + mid); vector<int> v2(v.begin() + mid, v.end()); v1 = mer...
ALGO
0.971364
5.124145
c10521be-ff88-4ef2-9cf4-63035009570d
godely/Problems
Spoj/PRHYME.cpp
#include <cstdio> #include <algorithm> #include <cstring> #include <utility> #include <vector> #include <queue> #include <stack> #include <map> #include <iostream> #include <set> #include <cmath> #include <cassert> #include <ctime> #include <string> using namespace std; #define db(x) cout << #x " == " << x << endl //...
ALGO
0.999785
3.547256
0b36ae82-b574-49d9-b196-666444d900e7
wfxedu/CRF-BLSTMParser
eigen/doc/examples/Tutorial_PartialLU_solve.cpp
#include <Eigen/Core> #include <Eigen/LU> #include <iostream> using namespace std; using namespace Eigen; int main() { Matrix3f A; Vector3f b; A << 1,2,3, 4,5,6, 7,8,10; b << 3, 3, 4; cout << "Here is the matrix A:" << endl << A << endl; cout << "Here is the vector b:" << endl << b << endl; Vec...
ALGO
0.999882
3.142567
e364a812-7d56-4b4e-88a0-7785ee63dfc8
zhe0328/leetcode
61-rotate-list/61-rotate-list.cpp
/** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode() : val(0), next(nullptr) {} * ListNode(int x) : val(x), next(nullptr) {} * ListNode(int x, ListNode *next) : val(x), next(next) {} * }; */ class Solution { public: ListNode* rotateRight...
ALGO
0.999978
5.806971
a9543c92-a720-423e-b9cf-6c581aff6dbe
akash13s/Scheduler
Scheduler.cpp
#include <iostream> #include <stdio.h> #include "set" #include <algorithm> #include "map" #include "string" #include "iostream" #include "list" #include "queue" #include "stack" #include <ctype.h> #include <stdio.h> #include <stdlib.h> #include <unistd.h> #include "vector" #include "fstream" #include <regex> using nam...
ALGO
0.999534
3.47205
bdd9c9ec-2b3b-465b-a0ae-6c136f88f482
trdln/ADS-Autumn-2021
Additional/History/ADS2020-main/!Quizes/AlgoFinal2/D.cpp
#include <bits/stdc++.h> #define ll long long #define sep " " using namespace std; int cnt = 0; bool isTop(string s) { stack<char> st; for (auto it : s) { if (!st.empty()) { if (st.top() == it) st.pop(); else st.push(it); } ...
ALGO
0.99985
4.390917
a85cd01e-31ce-497d-a9c9-5b77f3ac0ccd
Bouya12/self-study
AlgoAndDSfromPGC/Chapter4/Chapter4_2/Stack.cpp
#include <bits/stdc++.h> #define rep(i, n) for(int i = 0; i < (int)(n); i++) using namespace std; int top, S[1000]; void push(int x) { S[++top] = x; } int pop() { top--; return S[top+1]; } int main() { string in; int a, b; top = 0; while (cin >> in) { if (in[0] == '+') { a = pop(); b...
ALGO
0.999857
4.345216
44576f5a-a599-466e-87f5-9bf48f1230a7
websopon24/19701073_Md_Sopon_Abdullah
158b.cpp
#include<bits/stdc++.h> using namespace std; int main() { int n; cin>>n; int s; int i; int c=0; int m[5]= {0}; for( i=0; i<n; i++) { cin>>s; m[s]++; } c = m[4]+m[3]+m[2]/2; m[1] -=m[3]; if(m[2]%2) { c++; m[1]-=2; } if(m[1]>...
ALGO
0.999928
3.674809
7206f7a2-bcf3-4e53-b78a-beddf9cbb4d7
cezime/mina
reference-07-groth16-prover/depends/libff/libff/algebra/curves/edwards/edwards_pp.cpp
/** @file ***************************************************************************** * @author This file is part of libff, developed by SCIPR Lab * and contributors (see AUTHORS). * @copyright MIT license (see LICENSE file) ***********************************************************************...
ALGO
0.975448
6.806217
5a5726ee-c7bd-47f7-be6b-7b7ecb3d5916
mayank7jha1/ISA_22A
Lecture 26/Credit_Card.cpp
#include<bits/stdc++.h> using namespace std; // const int N = 0; #define int long long int n, d; int a[100005] = {0}; void Solve() { int amount = 0; /*By default aisa toh nahi hain ki mera answer -1 aajaye: By default aisa to nahi hain ki irrespective of what i add or deposit and make my account balaance as the mi...
ALGO
0.999954
3.943964
518b8892-0fb6-4844-b7a8-29a7bc97044a
xjtuAccel999/ConSci-v1.0
src/layer/sigmoid.cpp
#include "sigmoid.h" #include <math.h> #include "assert.h" #ifndef NCNN_TOOLS #include "../hw/hw_act.h" #endif #include "../hw/accel_params.h" namespace ncnn { Sigmoid::Sigmoid() { one_blob_only = true; support_inplace = true; } int Sigmoid::forward_inplace(Mat& bottom_top_blob, const Option& opt) const { ...
ALGO
0.972062
6.175563
2fb387f2-64a6-47cd-beee-05f77790947c
malasiot/clopema_certh_ros
certh_libs/src/image/cvblob/cvBlob/cvcolor.cpp
#include <cmath> #include <iostream> using namespace std; #if (defined(_WIN32) || defined(__WIN32__) || defined(__TOS_WIN__) || defined(__WINDOWS__) || (defined(__APPLE__) & defined(__MACH__))) #include <cv.h> #else #include <opencv/cv.h> #endif #include "cvblob.h" namespace cvb { CvScalar cvBlobMeanColor(CvBlob ...
ALGO
0.931672
5.72576
d1cd12c2-8bb5-4da2-b11f-25b747fd261b
SaurabhYadav45/DSA-POTD
3864-count-the-number-of-computer-unlocking-permutations/count-the-number-of-computer-unlocking-permutations.cpp
class Solution { public: const int MOD = 1e9 + 7; int countPermutations(vector<int>& complexity) { int n = complexity.size(); for(int i=1; i<n; i++){ if(complexity[0] >= complexity[i]) return 0; } long long result = 1; for(int i=2; i<n; i++){ res...
ALGO
0.99999
5.200691
52762e53-2196-4f68-b386-19470f9e46e5
Zoibderg/CS131_CPP
CS_textbook_files/Chapter17/ReliableNumberList.cpp
#include "reliablenumberlist.h" //*************************************************** // Copy constructor * //*************************************************** ReliableNumberList:: ReliableNumberList(const ReliableNumberList& original) { head = copyList(original.head); } //****...
TOOL
0.905588
5.116342
770c1053-2df7-42ff-b80d-9d92171f9558
michaelcdevin/ActiveHybridMooring
cpp/ahm_6dof.cpp
#include <iostream> #include <cmath> #include "Config.h" #include "MoorDyn2.hpp" double amp = 5.0; double per = 20; inline constexpr double pi = 3.14159265358979323846; int main(int, char**) { // define system auto system = new moordyn::MoorDyn("../../MoorDyn/ahm_6dof.txt"); //("../../MoorDyn/oc3.txt"); i...
ALGO
0.985178
4.541886
a68f8559-528a-428f-bb17-ce17933302db
Danacus/llvm-project-ami-cfl
libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/push.heap/ranges_push_heap.pass.cpp
// UNSUPPORTED: c++03, c++11, c++14, c++17 // <algorithm> // template<random_access_iterator I, sentinel_for<I> S, class Comp = ranges::less, // class Proj = identity> // requires sortable<I, Comp, Proj> // constexpr I // ranges::push_heap(I first, S last, Comp comp = {}, Proj proj = {}); ...
TEST
0.986777
7.630742
eaeda35a-9b5e-4a35-97cd-064a39ea384b
FanniBelics/Spline-surfaces
Spline-surfaces/spline.cpp
#include "spline.h" // Calculate the B-spline basis function value N_{i,p}(u) float BSplineBasis(int i, int p, float u, const std::vector<float>& knotVector) { if (p == 0) { return (u >= knotVector[i] && u <= knotVector[i + 1]) ? 1.0f : 0.0f; } float leftTerm = 0.0f; if (knotVector[i + p] != k...
ALGO
0.998732
6.518964
73cf90bf-70cd-4f37-bf62-889e32bafb60
marauwu777/Test
Source.cpp
#include <iostream> #include <cmath> #include <iomanip> #include "Header.h" using namespace std; // template<typename Type> void input_vector(Type* vector, int size) { for (int i = 0; i < size; i++) { cout << "Enter the vector element" << endl; cin >> vector[i]; } } // template<typename...
TOOL
0.961195
3.062556
b99970d5-c5d4-4ba9-9812-1282b48d6d33
heysujal/Problem-Solving-in-cpp
Array/sorting/merge_two_sorted_arrays.cpp
#include <bits/stdc++.h> using namespace std; void print_array(int arr[], int n) { for (int i = 0; i < n; i++) { cout << arr[i] << ' '; } cout << endl; } void merge_sort(int a[], int m, int b[], int n) { int i = 0; int j = 0; while (i < m && j < n) { // this is not st...
ALGO
0.999918
4.848436
073ff457-891c-424d-9853-346d2b99d7b9
Mocknbrd/Codeforces_solutions
Code/C_Discrete_Acceleration.cpp
#include <bits/stdc++.h> using namespace std; #define cin std::cin #define cout std::cout #define ios \ ios_base::sync_with_stdio(0); \ cin.tie(0); \ cout.tie(0); #define see(statement) cout<<statement<<endl #define YY see("YES") #define NN see("NO") #define yy se...
ALGO
0.99985
4.30222
a668f82e-6741-4461-b0ca-f144dc10c069
Eremeir/csci401
Assign1/dfa.cpp
/* Assignment #1 AUTHOR: Matt Borek */ #include <iostream> #include <vector> #include <string> /** * @brief Main function to test DFA Simulator * * Process standard input to simualte a DFA and test words to check if they exist in the language of the DFA. * * @return int indicating program's exit statu...
ALGO
0.999655
6.638076
084b085f-ce76-4cb2-af61-5e2e8d619d90
irfan5d7/Mission-R-nD-C-Programming
C-BinarySearchTree-Worksheet/BSTTransversals.cpp
/* Given a Binary Search Tree ,Calculate its Inorder ,Postorder and PreOrder Input : A BST Output : Copy Inorder/Postorder/Preorder into the array specified . Note : Memory for the Array is already allocated ,Dont allocate it again using malloc ->Take help of helper functions which are actually solving the problem ....
ALGO
0.999829
5.311193
58068cc6-0bad-455b-995d-ad9038399eec
everx-labs/TVM-Compiler
llvm/lib/DebugInfo/CodeView/TypeIndexDiscovery.cpp
#include "llvm/ADT/ArrayRef.h" #include "llvm/Support/Endian.h" using namespace llvm; using namespace llvm::codeview; static inline MethodKind getMethodKind(uint16_t Attrs) { Attrs &= uint16_t(MethodOptions::MethodKindMask); Attrs >>= 2; return MethodKind(Attrs); } static inline bool isIntroVirtual(uint16_t At...
TOOL
0.87599
6.886866
610d573e-0f49-4617-9f89-4e5959dd728e
zyin422/CPGrind
Codeforces/Codeforces Round 971 (Div. 4)/D_SatyamAndCounting.cpp
//#pragma GCC optimize ("trapv") #include <bits/stdc++.h> using namespace std; typedef long long ll; typedef unsigned long long ull; #define IOS ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0); #define endl "\n" ll INF, MOD; signed main() { IOS; ll t; cin >> t; while (t--) { ll n; cin >> ...
ALGO
0.999928
4.490811
075cadaa-05c1-4a87-b728-f141b83df226
Kaushal-11/LeetCode-Problem-Solutions
703.cpp
#include<bits/stdc++.h> using namespace std; class KthLargest { public: priority_queue<int, vector<int>, greater<int>> pq; int k; KthLargest(int k, vector<int>& nums) { for(int x : nums){ pq.push(x); if(pq.size() > k) pq.pop(); } } ...
ALGO
0.99992
5.55671
cd9cc71f-290c-48ff-9f3c-224cf0752275
mushfiq-906/cp__training
Codeforces__Problems/contest/743/b/65619111.cpp
// Author : Abdallah Hemdan #ifdef _MSC_VER #define _CRT_SECURE_NO_WARNINGS #endif #include <bits\stdc++.h> #define vll vector<ll> #define vi vector<int> #define sz size() #define pii pair<int,int> #define IO ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0) #define all(v) ((v).begin()), ((v).end()) #define rall(v)...
ALGO
0.999865
4.276955
cc359a54-e15f-4c19-92c5-4568e052bfe3
202010800LJH/Study_Cpp
백준4470_otherex.cpp
#include<iostream> using namespace std; int main(void) { int N; cin >> N; char str[50][50]; for (int i = 0; i < N; i++) { cin.getline(str[i], 50); } for (int i = 0; i < N; i++) { cout << i + 1 << ". " << str[i] << endl; } return 0; }
ALGO
0.975624
3.071219
1e95c5b2-0008-4044-8a40-a258d8aababd
Bravvel/hse-algorithms
6 contest/I.cpp
#include <iostream> #include <vector> #include <algorithm> #include <set> #include <cmath> using namespace std; bool comp(int a, int b) { return a > b; } void solve() { long long n; cin >> n; vector<long long> a(n); vector<long long> b(n); for (int i = 0; i < n; i++) { cin >> a[i];...
ALGO
0.999987
3.261633
3176e52d-be25-4884-830e-32394bc29346
trinhminhtriet/leetcode
solutions/0200-0299/0248.strobogrammatic-number-iii/Solution.cpp
using ll = long long; class Solution { public: const vector<pair<char, char>> pairs = {{'1', '1'}, {'8', '8'}, {'6', '9'}, {'9', '6'}}; int strobogrammaticInRange(string low, string high) { int n; function<vector<string>(int)> dfs = [&](int u) { if (u == 0) return vector<string>{""...
ALGO
0.999832
5.730862
0f531fe2-4db2-454f-a8ba-5cc6892c8d67
enochjung/acmicpc_net
07/7578.cpp
#include <cstdio> #define N 500010 int n, a[N*2], b[N], t[N]; void add(int idx) { while(idx <= n) { ++t[idx]; idx += idx&-idx; } } int get(int idx) { int sum = 0; while(idx) { sum += t[idx]; idx -= idx&-idx; } return sum; } int main() { scanf("%d", &n); for(int i=0; i<n; ++i) { int v; scanf("...
ALGO
0.999765
3.428127
6ae4974f-c528-4caa-b963-c8cf78b2b438
javi9davi/IDSProject
src/core/config.cpp
// config.cpp #include "config.h" #include <iostream> #include <fstream> #include <regex> Config::Config() = default; Config::Config(const int update_interval, const int monitoring_interval, const int process_interval, const bool monitor_files, const bool mo...
CONFIG
0.9409
6.141457
4773d2ce-8cd9-49c8-96ea-9efe7618d088
Shaunmak1214/C-plusplus-Tutorials
Lab12/Q2.cpp
#include <iostream> #include <iomanip> using namespace std; class BasicShape { private: double area; public: //setter function double getArea() { return area; } virtual void calcArea() { cout << "Not possible to calculate the area of a basic shape" << endl; ...
TOOL
0.959316
3.967099
890fad47-5a52-4b80-bee3-a8b4cc74084f
muhammadhasan01/cp
Online Judge/TLX/Pemrograman Kompetitif Dasar/07-dynamic-programming/G.cpp
#include <bits/stdc++.h> using namespace std; int main() { ios_base::sync_with_stdio(0); cin.tie(0); int n; cin >> n; if (n % 2 == 1) { cout << 0 << '\n'; return 0; } vector<long long> dp(n + 1); dp[0] = 1; for (int i = 2; i <= n; i += 2) { for (int j =...
ALGO
0.999988
4.740124
a52e25ed-51d9-4623-b33f-5aecedf6c5da
tanziyamansuri8/leetcode-solution
0389-find-the-difference/0389-find-the-difference.cpp
class Solution { public: char findTheDifference(string s, string t) { char result = 0; for(char c:s){ result ^= c; } for(char c : t){ result ^= c; } return result; } };
ALGO
0.999918
6.408112
216022fe-dc97-4903-90a0-4fc0ac53757d
uwoobeat/baekjoon
cpp/9663.cpp
#include <bits/stdc++.h> #define FASTIO \ ios::sync_with_stdio(false); \ cin.tie(0); \ cout.tie(0); using namespace std; int n, ans; bool check1[14], check2[27], check3[27]; void solve(int idx) { if (idx == n) { ans++; return; } for (int ...
ALGO
0.999953
4.820941
8dd7129f-855f-4560-ac70-fd5ecbd090ff
LadderLay/Data-Structure
cpp_classExercise/11/11-3.cpp
#include <iostream> #include <algorithm> #include <set> #include <fstream> using namespace std; int main() { multiset<int> st; set<int> se; int n,i; ifstream file; file.open("example.txt"); file >> n; for(int j=0; j<n; j++){ string s; file >> s; if(s == "add") { file >> i; st.insert(i); se.ins...
ALGO
0.992108
3.966859
c19e0073-7f32-47e1-a1ca-18958d743971
Cyb3r-0/Face-Recognition
opencv-master/modules/features2d/src/evaluation.cpp
/ #include "precomp.hpp" #include <limits> using namespace cv; template<typename _Tp> static int solveQuadratic(_Tp a, _Tp b, _Tp c, _Tp& x1, _Tp& x2) { if( a == 0 ) { if( b == 0 ) { x1 = x2 = 0; return c == 0; } x1 = x2 = -c/b; return 1; } ...
ALGO
0.99986
4.992169
4b1a0a69-c272-4153-8812-27054fee01d2
codingNoob12/algorithm-study
cpp/백준/2023-11-06/swea1238.cpp
#include <bits/stdc++.h> using namespace std; int g[101][101]; int visited[101]; void initGraph(); int setGraph(); int main() { ios::sync_with_stdio(0); cin.tie(0); int tc = 10; for (int i = 1; i <= tc; i++) { initGraph(); int start = setGraph(); int node = start; q...
ALGO
0.999497
3.967877
ebbc9ef5-12b4-4a41-ba0c-8cc90106692e
JohnItoo/Solvay
codeforces/rounds/CF-1447D.cpp
#include <bits/stdc++.h> using namespace std; #define _CRT_SECURE_NO_DEPRECATE // suppress some compilation warning messages (for VC++ users) // Shortcuts for "common" data types in contests typedef long long ll; typedef vector<int> vi; typedef pair<int, int> ii; typedef vector<ii> vii; typedef set<int> si; typedef map...
ALGO
0.999958
3.462789
43daafa5-0db3-4d4f-b5b5-de6734846835
vitoria/CompetitiveProgramming
leetcode/hamming-distance.cpp
#include <bits/stdc++.h> using namespace std; int hammingDistance(int x, int y) { unsigned int diff = x ^ y, ans = 0; while (diff) { if (diff % 2 == 1) ans++; diff = diff>>1; } return ans; } int main() { int x, y; while (cin >> x >> y) { int result = hammingDistance(x, y); cout << "Res...
ALGO
0.999843
4.477607
2bcb8fb6-3041-44fc-843a-f4efa72f4659
chayanika840/Project
First negative integer in every window of size k.cpp
#include <bits/stdc++.h> using namespace std; vector<long long> printFirstNegativeInteger(long long int arr[], long long int n, long long int k); int main() { long long int t, i; cin >> t; while (t--) { long long int n; cin >> n; long...
ALGO
0.999933
4.454761
1e4b20a0-376b-4e5a-8fee-c5eb95ac847a
magyarakoos/contest-prog
njudge/nemes/2-3/NT20/halozat/main.cpp
#include <bits/stdc++.h> #define speed cin.tie(0); ios::sync_with_stdio(0) #define cinv(v) for (auto& e : v) cin >> e; #define all(v) v.begin(), v.end() #define has(s, e) s.count(e) using namespace std; using ll = long long; using point = array<int, 2>; int main() { speed; int N, M, K; cin >> N >> M >> ...
ALGO
0.999987
4.748696
a3a84973-88ad-4e14-a0ad-b13b271e3ea7
SteveFauci/Learn_c_again
202505/leetcode/1-linked_list/1-单链表.cpp
class MyLinkedList { public: // 类里面用struct构建node struct node { int val; node* next; node(int x) : val{x}, next{nullptr} {}; }; // 构造函数初始化链表 MyLinkedList() { head = nullptr; size = 0; } int get(int index) { if (index >= size || index < 0) ...
ALGO
0.998185
4.662137
ab6d6118-5495-4010-9d27-db518d5dacd5
Dialpuri/privateer_dependencies
ccp4srs/trunk/srsrem.cpp
// // ================================================================= // // CCP4 Storage, Retrieval and Searches System (SRS) // // File srsrem.cpp // // SRS-based PDB remediator. // // Eugene Krissinel (2011) // // ================================================================= // #include <string.h> #inclu...
TOOL
0.865099
4.037211
3cc68b01-6ee5-4389-956f-f39776720715
Vaibhav14102006/ACC45DAYSOFCODE-2024
DAY 30 TRUESCORE.cpp
#include <bits/stdc++.h> using namespace std; int main() { int T; cin >> T; // Number of test cases while (T--) { int A, B, C, D; cin >> A >> B >> C >> D; // Read the current and desired scores // Check if it's possible for the score to change from A:B to C:D if (C >= A && ...
ALGO
0.999451
5.535235
7e616b9c-9ade-427f-956f-fd89953b54af
dheeraj-2000/dsalgo
DP/Coin_game_winner_where_every_player_has_three_choices.cpp
// C++ program to find winner of game // if player can pick 1, x, y coins #include <bits/stdc++.h> using namespace std; // To find winner of game bool findWinner(int x, int y, int n) { // To store results int dp[n + 1]; // Initial values dp[0] = false; dp[1] = true; // Computing other values. for (int i = 2; ...
ALGO
0.999991
5.278984
62fd8d4c-2099-40a9-a90c-1768331eaa0a
piyushsonawane07/striver-dsa
Tree & BST/tree_height.cpp
#include<iostream> #include<bits/stdc++.h> using namespace std; class Node{ public: int data; Node *left; Node *right; Node(int data) { this->data = data; left = right = NULL; } }; int heightIterative(Node* root){ if(root==NULL) return 0; queue<Node*> q; q.pus...
ALGO
0.999944
5.728977
af6fda99-1754-4ee6-b803-4f45fd14b550
scarsty/lammps_m
src/USER-OMP/angle_fourier_omp.cpp
/* ---------------------------------------------------------------------- Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ #include "angle_fourier_omp.h" #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" #include "...
ALGO
0.999826
6.037185
7c25e1a6-95f8-46fd-9ded-8a653c2b089d
grtushar/LightOJ
loj1000.cpp
using namespace std; #include<iostream> int main() { int a,b,T,Case=1; cin>>T; while(T--) { cin>>a>>b; cout<<"Case "<<Case++<<": "<<a+b<<endl; } return 0; }
ALGO
0.992924
5.449837
22538675-2a0b-4bae-b285-911598afbbf5
FlexShashlik/Cpp-Lafore
res/Progs/Ch02/Circarea.cpp
// circarea.cpp // demonstrates floating point variables #include <iostream> //for cout, etc. using namespace std; int main() { float rad; //variable of type float const float PI = 3.14159F; //type const float cout << "Enter radius of circle: "; //p...
ALGO
0.989795
3.901098
55fed468-e4d6-403d-a0c4-dba972fe31ad
liliumproject/llvm-project
libc/src/math/nvptx/truncf.cpp
#include "src/math/truncf.h" #include "src/__support/common.h" #include "src/__support/macros/config.h" namespace LIBC_NAMESPACE_DECL { LLVM_LIBC_FUNCTION(float, truncf, (float x)) { return __builtin_truncf(x); } } // namespace LIBC_NAMESPACE_DECL
ALGO
0.92668
6.378159
c16f13d6-b508-4065-83b2-1dc368b5aba4
cbkpar/BOJ
boj_2830.cpp
#include <iostream> #include <vector> #include <algorithm> using namespace std; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); int iN; cin >> iN; vector<long long> vecNum(iN, 0); for (int i = 0; i < iN; ++i) cin >> vecNum[i]; vector<long long> vecCount(20, 0); for (int i = 0;...
ALGO
0.999957
4.479885
3eac6c7c-a884-4ca3-88e0-0b340e4a58e8
ingenieursaurav/Platform_External_Skia
src/core/SkRasterClip.cpp
#include "SkRasterClip.h" #include "SkPath.h" #include "SkRegionPriv.h" enum MutateResult { kDoNothing_MutateResult, kReplaceClippedAgainstGlobalBounds_MutateResult, kContinue_MutateResult, }; static MutateResult mutate_conservative_op(SkRegion::Op* op, bool inverseFilled) { if (inverseFilled) { ...
TOOL
0.942328
7.563821
30e89b8f-2109-43ad-b02e-edae55336399
smhx/dmoj
sheep_and_coyotes/main.cpp
#include <cstdio> #include <iostream> #include <cmath> #include <iomanip> #include <vector> using namespace std; double x[100]; double y[100]; bool reachable[100]; inline double distance(double x1, double y1, double x2, double y2) { return sqrt( (x1-x2)*(x1-x2) + (y1-y2)*(y1-y2) ); } inline double round(double x) {...
ALGO
0.999846
4.372983
deaaa444-02a9-4263-b33e-a843d0f53bbe
tienvuiet/tienvuviet_C_session16
gioi7.cpp
#include<stdio.h> void xapxep(int *arr, int size){ for(int i=0;i<size-1;i++){ int min=i; for(int j=i+1;j<size;j++){ if(*(arr+j)<*(arr+min)){ min=j; } } int temp=*(arr+min); *(arr+min)=*(arr+i); *(arr+i)=temp; } for(int i=0;i<size;i++){ printf("%d ",*(arr+i)); } } int main (){ int a[...
ALGO
0.999932
3.519515
bec22a80-b11a-4623-bc80-98d01ccbef18
a1024/MCalc2
src/mc2.cpp
#define _CRT_SECURE_NO_WARNINGS #include <stdio.h> #include <string> #include <iostream> #ifndef __linux__ #include <conio.h> #endif #include "mc2.h" const char file[]=__FILE__; extern const int g_buf_size=G_BUF_SIZE; char g_buf[G_BUF_SIZE]={0}; char gfmode=0;//later void print_help() { printf( // "0123456789012...
TOOL
0.942454
3.525038
1d829000-8ee9-4a34-ae85-8ad10dfbdde6
Junak12/Codeforces_solution
D_Sakurako_s_Hobby.cpp
#include <bits/stdc++.h> using namespace std; #define opt() ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0); #define endl '\n' #define ll long long #define ld long double #define ull unsigned long long int main(){ opt(); int t; //cin>>t; t = 1; while(t--){ for (int i = 0; i < 1e4; ++i...
ALGO
0.988419
3.213573
e0a3b5cb-aec3-4190-ae7d-1e405174c53d
DuanYaQi/leetcode
DS_Tree/449. Serialize and Deserialize BST.cpp
/** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x), left(NULL), right(NULL) {} * }; */ class Codec { public: string s = ""; void serDfs(TreeNode* root) { if (root == nullptr) return; s ...
ALGO
0.99996
5.933599
3ddb2060-1549-4778-9a66-544628d6ffda
jh9amn/Master-DSA
STACK/Basic/postFixEvaluation.cpp
#include<iostream> #include<stack> using namespace std; int operation(int val1,int val2,char s){ if(s == '+') return val1+val2; else if(s == '-') return val1-val2; else if(s == '*') return val1*val2; else return val1/val2; } int main(){ string s = "79+4*8/3-"; stack<int>val; for(int i=0; ...
ALGO
0.999731
4.087887
ff996690-6ed3-441d-a4c3-837db26da500
hjiang13/LLMs-in-IR
POJ-104/37/1693.cpp
#include <iostream> using namespace std; int main() { int i,j,k,t,n,a[100000]; char str[100000]; cin >> "%d",&t); for(i=0; i<t; i++) { //gets(str); cin >> "%s",str); n=strlen(str); for(j=0; j<n; j++)a[j]=0; for(j=0; j<n; j++) for(k=0; k<n; k++) if(str[j]==str[k])a[j]++; for(j=0; j<n; j++)if(a[j]==1)break; if(j==n)cout ...
ALGO
0.999834
3.132063
b16e16cf-2bf0-4037-b5d1-5c986d00869c
AntonioTri/Cpp
while.cpp
#include <iostream> using namespace std; int main (){ int somma = 0; int i = 0; int a = 1; while (a) { somma = somma + i; i++; cout << somma << "\n"; } cout << "ho fatto la somma dei primi dieci numeri naturali!\n"; }
ALGO
0.99351
3.621181
5f51424c-8243-4fe9-8567-f276e6b04fb3
MarineRoboticsGroup/cora
examples/cora_vis_test.cpp
// // Created by tim on 11/13/23. // #include <CORA/CORA.h> #include <CORA/CORA_vis.h> #include <thread> // NOLINT [build/c++11] int main() { CORA::Problem problem = CORA::parsePyfgTextToProblem("./bin/data/factor_graph_small.pyfg"); // "./bin/data/plaza2.pyfg"); problem.updateProblemData(); CORA::Matr...
ALGO
0.999039
4.421908
db5b765f-a721-4134-8353-86a5c4018562
jinglinliang/CS368
p2/trim.cpp
//////////////////////////////////////////////////////////////////////////////// // File Name: trim.cpp // // Author: Gerald // CS email: <EMAIL> // // Description: The source file for trimming a string. // // IMPORTANT NOTE: THIS FILE SHOULD NOT BE MODIFIED. // // Code Source: The following 3 fun...
TOOL
0.885354
7.275289
ccadb518-1c3e-477a-93fa-af9d94a2c868
Vegetog/Competitive-Programming
ONLINE_JUDGE/洛谷/P_2602_ZJOI_2010_数字计数.cpp
#include <bits/stdc++.h> #ifndef ONLINE_JUDGE #include "_my_utils.h" #endif #define int long long using namespace std; using ll = long long; using PII = std::pair<int, int>; constexpr ll INF = 2E18 + 10; constexpr int N = 2E6 + 10; void SINGLE_TEST() { ll l,r; cin>>l>>r; vector<int> dp(15); for(int...
ALGO
0.999835
3.780608