uuid
string
repo_name
string
relative_path
string
content
string
category
string
algo_rel_score
float64
quality_score
float64
dac4f8ab-fcd3-438c-befd-dbbd981581a5
WasimAlgahlani/Data-Structure
dataStructure.cpp
#include<iostream> #include<cstring> #include<conio.h> #include"array.h" #include"stack1.h" #include"queue.h" #include"circular queue.h" #include"SLL.h" #include"DLL.h" #include"linkedStack.h" #include"linkedQueue.h" using namespace std; int ch; void list(); //To choose from void array(); ...
ALGO
0.948808
3.030628
804a4100-31b1-40cc-8619-66cb7ab9851b
marcos1336/rob-tica
questão 17.cpp
#include <iostream> using namespace std; void troca (int a,int& b){ a = a * 3; b = b * 3; cout<< "valores alterados agora pricipal e "<<a<<", e o valor de referencia e "<<b<<endl; } int main() { int valor, referencia; cout<<"Informe o valor pricipal: "<<endl; cin>> valo...
ALGO
0.996199
3.686662
35baa043-ea58-436b-956a-4c3eeb3a1aca
Chandan07-lab/LEETCODE_PROBLEMS
3174-minimum-number-of-changes-to-make-binary-string-beautiful/minimum-number-of-changes-to-make-binary-string-beautiful.cpp
class Solution { public: int minChanges(string s) { int n=s.length(); int change=0; for(int i=0;i<n;i+=2){ if(s[i]!=s[i+1]){ change++; } } return change; } };
ALGO
0.999967
5.662785
96bb244c-772c-4ed2-9d55-14c13ad90873
abolinsky/mmapgetset
mmapgetb.cpp
#include <sys/mman.h> #include <sys/types.h> #include <fcntl.h> #include <unistd.h> #include <sys/stat.h> #include <assert.h> #include <iostream> #include <sstream> #include <string> struct Pair { uint32_t index[]; }; struct PairArray { uint64_t index[]; }; size_t getFilesize(const char* filename) { struct stat s...
TOOL
0.971239
5.158463
6dbde14c-bd57-4eb4-850a-775c38a6a026
helloworldpxy/lanqiao-CPP
2/1均衡之核心.cpp
#include<iostream> using namespace std ; int main() { int ans = 0 ; for( int a = -3 ; a <= 3 ; a ++ ) { for( int b = -3 ; b <= 3 ; b ++ ) { for( int c = -3 ; c <= 3 ; c ++ ) { if( a*a*a + b*b*b + c*c*c == 3*a*b*c ) ans ++ ; ...
ALGO
0.99878
4.060509
5600775e-5209-4737-8aec-84edad62e3c9
JiangWenqi/Algorithm-Questions
Leetcode-Solutions/33.search-in-rotated-sorted-array.cpp
// @before-stub-for-debug-begin #include <vector> #include <string> #include "commoncppproblem33.h" using namespace std; // @before-stub-for-debug-end /* * @lc app=leetcode id=33 lang=cpp * * [33] Search in Rotated Sorted Array * * https://leetcode.com/problems/search-in-rotated-sorted-array/description/ * * a...
ALGO
0.999991
6.814885
f5926065-7142-4676-b920-8d33622382f8
RajasekharMugada/cpp_exercise_problems
ril_prime_permutations.cpp
/* Problem statement: Prime permutations You are given a number N. Write a program to find all the arrangements of the natural numbers from 1 to N in which the indices (starting from 1) of prime numbers are also prime numbers modulo 1000000007. Ex: for N = 5, there can be 12 possible arrangements Solution : no_of_prim...
ALGO
0.999909
5.688602
eb71dd19-f6a5-4044-9a41-c2ce69d0e7d2
utmux/CPP_PRIM_PLUS
5_4_formore.cpp
#include <iostream> const int ArSize = 20; int main() { long long factorials[ArSize]; factorials[1] = factorials[0] = 1LL; for (int i = 2; i < ArSize; i++) factorials[i] = factorials[i - 1] * i; for (int i = 0; i < ArSize; i++) std::cout << i << "!= " << factorials[i] << std::endl; return 0; }
ALGO
0.998873
3.450528
8aedda20-bed6-49d2-ab0b-254b0bdc3209
muellertobias/GPU-Computing
VectorMulti/VectorAdd.cpp
#define CL_USE_DEPRECATED_OPENCL_1_0_APIS #include <CL/opencl.h> #include <CL/cl.h> #include <stdio.h> #include <stdlib.h> #include <math.h> #include <iostream> #include <iostream> #include <string> #include <sstream> // Kopiert von https://www.olcf.ornl.gov/tutorials/opencl-vector-addition/ // OpenCL kernel. Each w...
ALGO
0.853457
5.078807
204e4091-f6c6-4288-8647-f857901a3f8d
IanChen15/ClothSimulation
extern/libigl/tutorial/304_LinearEqualityConstraints/main.cpp
#include <igl/boundary_facets.h> #include <igl/cotmatrix.h> #include <igl/invert_diag.h> #include <igl/jet.h> #include <igl/massmatrix.h> #include <igl/min_quad_with_fixed.h> #include <igl/readOFF.h> #include <igl/opengl/glfw/Viewer.h> #include <Eigen/Sparse> #include <iostream> #include "tutorial_shared_path.h" int m...
ALGO
0.998738
5.849187
c31d4c19-a1de-4008-a033-922e00bc874e
alleycat1/WGoDot4_SDK
servers/physics_3d/joints/godot_pin_joint_3d.cpp
/**************************************************************************/ /* godot_pin_joint_3d.cpp */ /**************************************************************************/ /* This file is part of: */ /* ...
ALGO
0.975207
4.795869
908a0c42-8b17-4184-9642-3ac223b6779b
CJSBinder-User/CJSBinder
experiment/correctness_efficiency/groundtruth/cpp/NEWMAN_CONWAY_SEQUENCE_1.cpp
#include <iostream> #include <cstdlib> #include <string> #include <vector> #include <fstream> #include <iomanip> #include <bits/stdc++.h> using namespace std; int f_gold ( int n ) { int f [ n + 1 ]; int i; f [ 0 ] = 0; f [ 1 ] = 1; f [ 2 ] = 1; for ( i = 3; i <= n; i ++ ) f [ i ] = f [ f [ i - 1 ] ] + f...
ALGO
0.99981
4.719877
16898823-907d-49fe-8a56-b56c649f0a62
annikiforovaa/tasks_home_09-01
task9/main.cpp
#include "task9.h" int main() { //Entering an array consisting of 15 elements of an integer type int size = 15; int* arr = new int[size]; int* otr_a = new int[size]; std::cout << "Enter 15 elements of your array: " << std::endl; for (int i = 0; i < size; i++) std::cin >> arr[i]; concl(size, arr); }
TOOL
0.909164
3.076069
5fecaab7-b464-45e4-b9fe-c993953aebe2
rrampr-zz/codeforces
p_285a.cpp
#include <iostream> using namespace std; int main() { int n, k; cin >> n >> k; for (int i = 1; i <= n - k - 1; ++i) { cout << i << " "; } int t = n; for (int j = 0; j < k + 1; ++j) { cout << t << " "; t--; } cout << "\n"; return 0; }
ALGO
0.999979
3.227993
ac406427-a558-40a4-889a-ecf9b0142823
vintagetimepiececoin-project/vintagetimepiececoin
src/chainparams.cpp
#include "chainparams.h" #include "assert.h" #include "core.h" #include "protocol.h" #include "util.h" #include <boost/assign/list_of.hpp> using namespace boost::assign; // // Main network // unsigned int pnSeed[] = { //0xc6c74b0a, 0x6baafdeb, 0xa2f3d1bc, 0xbce287b5, 0xbce287b8, 0x688361e5, 0xb23e116a, 0x80c78...
CONFIG
0.94244
6.812902
7066401e-d9fa-4e41-973c-b2ac24faf158
md-shamim-ahmad/HackerRank-Online-Judge-Problems-Solutions
Practice/C++/Input and Output.cpp
#include <cmath> #include <cstdio> #include <vector> #include <iostream> #include <algorithm> using namespace std; int main() { int a,b,c; cin>>a>>b>>c; cout<<a+b+c<<endl; /* Enter your code here. Read input from STDIN. Print output to STDOUT */ return 0; }
ALGO
0.999732
3.674167
d09226d3-a9e2-4300-b9cb-96c91857dd3c
Vaibhav-srivastava-knit/compatative-programming
concept/graph theory/min_spanning_tree.cpp
#include <bits/stdc++.h> using namespace std; struct edge{ int a; int b; int wt; }; bool comp(edge a,edge b) { if(a.wt<b.wt) return true; return false; } edge ed[10001]; int par[10001]; int find(int a) { if(par[a]==-1)return a; else return par[a]=find(par[a]); } void uni(i...
ALGO
0.999928
4.396811
d927bceb-ac39-4000-9b3b-4a5440fc6d54
ssf-czh/university-
大二学校数据结构习题/第三章/station.cpp
//һmxa mxa[i]ʾi֮ #include <bits/stdc++.h> using namespace std; stack <int> s; int n; int a[100010]; int mxa[100010]; int main() { int n; cin>>n; for(int i=0;i<n;i++) cin>>a[i]; for(int i=n-1;i>=0;i--) { mxa[i]=a[i]; mxa[i]=max(mxa[i],mxa[i+1]); } for(int i=0;i<n;) { int mx=mxa[i]; //ҵ һֱջ while(s.e...
ALGO
0.999994
3.796233
cc4dcd37-a947-4876-949b-5d98585b3ecf
Sbugart/CEMCodes-365
Easy/AtCoder-ABC377A/A-Rearranging_ABC.cpp
#include <bits/stdc++.h> using namespace std; int main(){ string entrada; int possui = 0; cin >> entrada; for(int i = 0; i < 3; i++){ possui = possui | (1 << (entrada[i] - 'A')); } if(possui == 7) cout << "Yes" << endl; else cout << "No" << endl; return 0; }
ALGO
0.999899
4.06448
3a3c6455-e9ef-4b23-9c65-d868c7c3cea0
AyuTUL/AyushTuladhar2ndCSIT
DS/Lab/14.cpp
#include<iostream> #include<limits.h> #define MAX 52 using namespace std; int minKey(int key[],bool mstSet[],int V) { int min=INT_MAX,min_index; for(int v=0;v<V;v++) if(!mstSet[v] && key[v]<min) { min=key[v]; min_index=v; } return(min_index); } void printMST(int...
ALGO
0.999953
4.24825
e1fb540f-b497-4027-ba07-1a1ae819149f
FriskTheFallenHuman/source-sdk-2013-template
mp/src/mathlib/powsse.cpp
#include "mathlib/ssemath.h" // NOTE: This has to be the last file included! #include "tier0/memdbgon.h" fltx4 Pow_FixedPoint_Exponent_SIMD( const fltx4 & x, int exponent) { fltx4 rslt=Four_Ones; // x^0=1.0 int xp=abs(exponent); if (xp & 3) // fraction present? { fltx4 sq_rt=SqrtEstSIMD(x); ...
ALGO
0.997438
5.896356
34cc963f-5b34-4e39-9234-df08729b31f4
Chava-Sai/Unwind
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.998859
6.785645
8da5012d-5261-43a1-b895-2dff1b745c35
Nitin23123/CPPLEETCODE
palindrome.cpp
#include<bits/stdc++.h> using namespace std; int palindorme(int n ){ int digit= 0; int copy = n; // Store the original number for comparison while(n>0){ digit = digit*10 + n % 10; // Build the reversed number n /= 10; // Remove the last digit } if(copy == digit) { return 1; ...
ALGO
0.999829
4.185707
fc7f1ce3-dd14-4ec3-90c9-19f5bf0fcf48
krsheshu/hls_libs
libs/fir/loop_pipelining/src/loop_pipelining.cpp
#define N 11 #include "ap_int.h" #include "loop_pipelining.h" void loop_pipelining ( data_t *y, data_t x){ coef_t c[N] = { 53, 0, -91, 0, 313, 500, 313, 0, -91, 0, 53 }; static data_t shiftreg[N]; acc_t acc; int i; acc = 0; TAPPED_DELAY_LINE: for (i = N-1; i> 0; i--) { #pragma HLS pipeli...
ALGO
0.998787
3.567302
3e94aa56-bbc3-437f-b542-fb6be00a4e03
xavierolivenza/Nes_Pinball
Nes_Pinball/Box2D/Box2D/Dynamics/Contacts/b2ChainAndPolygonContact.cpp
#include <Box2D/Dynamics/Contacts/b2ChainAndPolygonContact.h> #include <Box2D/Common/b2BlockAllocator.h> #include <Box2D/Dynamics/b2Fixture.h> #include <Box2D/Collision/Shapes/b2ChainShape.h> #include <Box2D/Collision/Shapes/b2EdgeShape.h> #include <new> b2Contact* b2ChainAndPolygonContact::Create(b2Fixture* fixtureA...
ALGO
0.992604
6.405189
e36005ad-bae7-469d-ac99-c8b1430cdbb8
tal-tech/Solution_for_Classroom_Quality_Monitoring_of_English_Classroom_Teachers
offline-asr-sub-e2e-asr/chrome-base/third_party/icu/source/i18n/sortkey.cpp
//=============================================================================== // // File sortkey.cpp // // // // Created by: Helena Shih // // Modification History: // // Date Name Description // // 6/20/97 helena Java class name change. // 6/23/97 helena Added comments t...
TOOL
0.985914
6.212571
20adf185-ecc8-4d51-a87a-8a8b1908fa91
Yoochanhong/codetree-TILs
240516/규칙에 따라 밀기/push-by-the-rules.cpp
#include <iostream> #include <deque> using namespace std; int main() { deque<char> q; string a; cin >> a; for (auto i : a) q.emplace_back(i); cin >> a; for (auto i : a){ if (i == 'L') { q.emplace_back(q.front()); q.pop_front(); } else { q.empl...
ALGO
0.999972
3.382288
0feb3b00-ac3e-4f06-a84a-0495f9469c94
byzhang/blaze
blazemark/src/mtl/Mat3TMat3Mult.cpp
//================================================================================================= //================================================================================================= //************************************************************************************************* // Includes //****...
ALGO
0.997766
4.682436
de533dc8-41db-4a4f-80be-cce828d83881
arangodb/arangodb
3rdParty/boost/1.78.0/libs/compute/example/black_scholes.cpp
#include <cstdlib> #include <iostream> #include <boost/compute/command_queue.hpp> #include <boost/compute/system.hpp> #include <boost/compute/algorithm/copy_n.hpp> #include <boost/compute/container/vector.hpp> #include <boost/compute/utility/source.hpp> namespace compute = boost::compute; // return a random float be...
ALGO
0.996548
6.940489
dd9efb2d-fb93-48eb-881c-73278430ca55
imohammaadmin/ACM-solutions
Codeforces/426A.cpp
#include <iostream> #include <vector> #include <algorithm> using namespace std; int main(){ int m,v,n,flag=1; cin>>m>>v; vector<int> a; for (int i = 0; i < m; i++) { cin>>n; a.push_back(n); } sort(a.begin(),a.end()); n = 0; for (int i = 0; i < m; i++) { i...
ALGO
0.999985
4.294914
19fe7ac0-682f-442e-b2f4-81a3906d8a63
JoungJinwon/Algorithm_Problem
BOJ/1157/1157.cpp
#include <iostream> #include <vector> using namespace std; int main() { int largestIndex = 0; int alphabetVec[26] = {0}; vector<char> mostFrequentVec; string str; cin >> str; for (int i = 0; i < str.length(); i++) { if (str[i] >= 'a' && str[i] <= 'z') alphab...
ALGO
0.999992
4.004655
5f95f913-8fd9-4669-a85e-7c1171ce7913
ishandutta2007/codeforces
jdurie/normal/1311/B.cpp
#pragma GCC target ("avx2") #pragma GCC optimize ("O3") #pragma GCC optimize ("unroll-loops") #include <bits/stdc++.h> using namespace std; template<class T, class S> ostream& operator << (ostream &o, const pair<T, S> &p) { return o << '(' << p.first << ", " << p.second << ')'; } template<template<class, class...> ...
ALGO
0.999962
4.605456
d8bc5577-e568-4d8c-9f9d-e91254768905
ishandutta2007/codeforces
brobat/normal/1638/B.cpp
#include <bits/stdc++.h> using namespace std; #define int long long #define endl "\n" #define forn(i, a, n) for (int i = a; i < n; i++) const int MAXN = 200100; const int MOD = 1000000007; const int INF = 9100000000000000000; const double EPS = 1E-7; void solve() { int n; cin >> n; bool pos = true; i...
ALGO
0.999991
5.01769
b1761f48-ea93-4a01-8420-76c4f38ec2dd
ishandutta2007/codeforces
sonechko/normal/996/D.cpp
#include<bits/stdc++.h> using namespace std; #define ff first #define ss second #define mp make_pair #define pb push_back #define ll long long const int N = 1e6 + 11; int a[N]; int main() { ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0); int n; cin>>n; for (int i=1; i<=n*2; i++) cin>>...
ALGO
0.999897
3.523071
8c0918c9-b854-4345-9c39-d09de7511eda
fonte-nele/Competitive-Programming
URI Online Judge/uri1020.cpp
#include <iostream> using namespace std; int main() { int idade,cont1=0,cont2=0; cin>>idade; while(idade>29) { if(idade>365) { idade-=365; cont1++; } else { idade-=30; cont2++; } } cout<<cont...
ALGO
0.994477
3.200468
21939ac6-b260-4783-a3eb-f4689db1e280
ishandutta2007/codeforces
basic_string/normal/1500/A.cpp
#include<bits/stdc++.h> using namespace std; const int N=2e5+3; int a[N]; basic_string<int>b[2500009]; pair<int,int>p[5000009]; map<int,int>mp; int main(){ int T,n,i,j=0,k=0; scanf("%d",&n); for(i=1;i<=n;++i)scanf("%d",a+i),b[a[i]]+=i; for(i=0;i<2500009;++i)if(b[i].size()>1){ if(j)k=i; else j=i; } if(k){ p...
ALGO
0.999958
3.106135
dff0758d-0c8f-4846-bf07-403f952a20fc
npkhang99/Competitive-Programming
AtCoder/ABC054D.cpp
// AtCoder Beginner Contest 054 - D. Mixing Experiments #include <bits/stdc++.h> using namespace std; typedef pair<int,int> ii; struct Package { int a, b, c; Package(int x, int y, int z){ a = x; b = y; c = z; } }; int n, ma, mb, dp[509][509]; vector<Package> packs; int main(){ scanf("%d%d%d...
ALGO
0.999904
4.563896
204a0072-4aaa-4cea-80e1-29fbe443406b
Nasir-Uddin25/Basic-Data-Structure
Module-06/insert_at_tail_optimized.cpp
#include <bits/stdc++.h> using namespace std; class Node { public: int val; Node *next; Node(int val) { this->val = val; this->next = NULL; } }; void insert_at_tail(Node *&head, Node *&tail, int val) // Receive value { Node *newnode = new Node(val); if (head == NULL) { ...
ALGO
0.999377
4.93481
5221f790-2a6a-4ce9-af46-f236223d01a3
Impreciousmaku/coe322-Pmaku
hw5/hw5_coe322.cpp
// TACC Username: olusemiloremaku3773 //Precious Maku oem354 // Excercise 5 #include <iostream> #include <cmath> using namespace std; // function to check if a number is prime bool isprime(int n) { if (n <= 1) return false; for (int i = 2; i < n; i++) if (n % i == 0) return false; ...
ALGO
0.999258
4.842829
9ace06ef-d705-471d-b2cd-e3ec60158b66
ishandutta2007/codeforces
wailydest/normal/1304/A.cpp
#include <iostream> using namespace std; int main() { long long t, x, y, a, b; cin >> t; while (t--) { cin >> x >> y >> a >> b; if (!((y - x) % (a + b))) cout << (y - x) / (a + b) << '\n'; else cout << -1 << '\n'; } return 0; }
ALGO
0.999317
3.689062
290c0fc4-c8db-4b5c-a0db-cc07e7b297a5
mihaimoga/XMLSitemap
boost/libs/multiprecision/example/cpp_int_import_export.cpp
#include <boost/multiprecision/cpp_int.hpp> #include <iostream> #include <iomanip> #include <vector> #include <iterator> //[IE1 /*` In this simple example, we'll import/export the bits of a cpp_int to a vector of 8-bit unsigned values: */ /*= #include <boost/multiprecision/cpp_int.hpp> #include <iostream> #include <i...
TOOL
0.910326
5.442729
12e90d3b-4e7b-43ce-a963-b5dc1e58c583
astitvaaryan/node-based-image-processor
opencv/modules/core/src/lda.cpp
#include "precomp.hpp" #include <iostream> #include <map> #include <set> namespace cv { // Removes duplicate elements in a given vector. template<typename _Tp> inline std::vector<_Tp> remove_dups(const std::vector<_Tp>& src) { typedef typename std::set<_Tp>::const_iterator constSetIterator; typedef typename s...
ALGO
0.999615
6.232382
9b8639fd-fe1d-421c-a2f6-f614d423f760
tr1ten/Operating-System-Lab
MLQ.cpp
#include <bits/stdc++.h> using namespace std; typedef vector<int> VI; typedef vector<VI> VII; typedef long long ll; typedef pair<int, int> pi; typedef pair<int, int> pi; int startTime; void printTurnaroundTime(vector<vector<int>> &process, int n, vector<int> &completion) { vector<int> turnaround(n, 0); vector<...
ALGO
0.99994
3.891645
6fb560bf-d8d5-49a9-a221-6b4c9390b641
TheRealTirreg/hpcMolecularDynamics
notes_lecture/gemv_benchmarks.cpp
#include <Eigen/Core> #include <benchmark/benchmark.h> #include <vector> #define MY_BENCHMARK(function) \ BENCHMARK(function)->Range(8, 8 << 11)->Complexity(benchmark::oNSquared) using namespace Eigen; static void BM_GEMV_vectors_nested(benchmark::State& state) { ...
TEST
0.97629
5.273092
afff3e16-3ab4-4a54-86f0-3abcf65416d9
HarrisLim/Algorithms
LeetCode/56.cpp
class Solution { public: vector<vector<int>> merge(vector<vector<int>>& intervals) { sort(intervals.begin(), intervals.end()); vector<vector<int>> ret; int start = intervals[0][0]; int end = intervals[0][1]; for(int i=1; i<intervals.size(); i++) { if(inte...
ALGO
0.999998
6.080779
ee73370f-0577-46fe-8fb8-4ad3bbdff63b
refiel-l/caffe-libs
boost/boost_1_56_0/libs/numeric/odeint/examples/mtl/gauss_packet.cpp
#include <iostream> #include <complex> #include <boost/numeric/odeint.hpp> #include <boost/numeric/odeint/external/mtl4/mtl4.hpp> #include <boost/numeric/mtl/mtl.hpp> using namespace std; using namespace boost::numeric::odeint; typedef mtl::dense_vector< complex< double > > state_type; struct hamiltonian { ty...
ALGO
0.999822
4.904219
1331fe4e-9caa-425e-a010-2ff1c341af69
trinerdi/icpc-notebook
src/trinerdi/import/flow/minmax.cpp
template<class T, class U> class MincostMaxflow { public: class edge { public: int source, destination; T capacity, residue; U cost; edge(int s, int d, T cap, T res, U cost) : source(s), destination(d), capacity(cap), residue(res), cost(cost) { } }; vector< vector<int> > V;...
ALGO
0.995223
4.627844
6e58e845-c1d2-4168-8fbb-e9ea3c2530bf
devos50/programmingchallenges
UVA/445/main.cpp
#include <iostream> using namespace std; void solve(string s) { int cursum = 0; for(int i = 0; i < s.size(); i++) { // check if it is a number if(s.at(i) >= '0' && s.at(i) <= '9') cursum += (s.at(i) - '0'); else if(s.at(i) == 'b') { for(int j = 0; j < cursum; j++) cout << " "; cursum = 0; } else ...
ALGO
0.894036
3.73971
80e2e11e-92cc-4a71-9206-0effb47eb8ca
kazunetakahashi/atcoder
2018/1124_dowcon5th-prelims/B.cpp
/** * File : B.cpp * Author : Kazune Takahashi * Created : 11/24/2018, 8:10:20 PM * Powered by Visual Studio Code */ #include <iostream> #include <iomanip> // << fixed << setprecision(xxx) #include <algorithm> // do { } while ( next_permutation(A, A+xxx) ) ; #include <vector> #include <string> // to_string(...
ALGO
0.999993
3.984276
1d001c2b-74be-4c3d-822e-a5457d1c81a4
Atom-Atharva/CPP
C++ Lab Assignment/Type-1 Variable, Operator & Expression/s1q9.cpp
#include <iostream> using namespace std; int main() { int n1; cout << "\nEnter a Number= "; cin >> n1; (n1 > 0) ? cout << "Number is Positive" : cout << "Number is Negative"; return 0; }
ALGO
0.991731
3.103754
e33c54a0-6fe5-4914-b06d-43d94782fc47
pentaery/Algebraic_CEM
eigen-3.4.0/bench/sparse_trisolver.cpp
//g++ -O3 -g0 -DNDEBUG sparse_product.cpp -I.. -I/home/gael/Coding/LinearAlgebra/mtl4/ -DDENSITY=0.005 -DSIZE=10000 && ./a.out //g++ -O3 -g0 -DNDEBUG sparse_product.cpp -I.. -I/home/gael/Coding/LinearAlgebra/mtl4/ -DDENSITY=0.05 -DSIZE=2000 && ./a.out // -DNOGMM -DNOMTL // -I /home/gael/Coding/LinearAlgebra/CSparse/...
ALGO
0.997002
4.874496
6ec5adde-f863-4518-a969-40195e35ddfa
G0T-cha/G0T-cha.github.io
thirdparty/win/miracl/miracl_osmt/source/curve/pairing/zzn6a.cpp
/* * MIRACL C++ Implementation file ZZn6a.cpp * * AUTHOR : M. Scott * * PURPOSE : Implementation of class ZZn6 (Arithmetic over n^6) * * WARNING: This class has been cobbled together for a specific use with * the MIRACL library. It is not complete, and may not work in other * applications * */...
ALGO
0.986823
3.168252
e8fc2369-2703-499f-b239-0dedd9855f0d
applied-numerical-algorithms-group-lbnl/Chombo_3.2
lib/test/BoxTools/FaceSumOpTest.cpp
#ifdef CH_LANG_CC #endif #include <cmath> #include <cstdio> #include "BoxIterator.H" #include "ParmParse.H" #include "DebugDump.H" #include "FABView.H" #include "LoadBalance.H" #include "DisjointBoxLayout.H" #include "LevelData.H" #include "AMRIO.H" #include "BoxLayoutData.H" #include "ReductionOps.H" #include "Redu...
ALGO
0.99816
4.673559
bdee304c-8adc-4284-8843-dfbd6fd4fe67
POOMESH-19/Leet-Code-Problem
445-Add-Two-Numbers-II.cpp
#include <iostream> using namespace std; class Solution { int getLength(ListNode* node) { int length = 0; while (node) { length++; node = node->next; } return length; } ListNode* addLists(ListNode* l1, ListNode* l2, int& carry) { if (!l1) return nullptr; ListNode* nextNode = addLists(l1->next, l2->...
ALGO
0.9997
5.822403
7ba8324d-f6c8-4d16-b447-bb98542582b9
Domain-Cmap/assignments-day-1-to-day-9-JAI-REX
Day 4/Very Hard/2.cpp
#include <bits/stdc++.h> using namespace std; void printQueue(queue<long long int> Queue) { while (!Queue.empty()) { cout << Queue.front() << " "; Queue.pop(); } } void reverseQueue(queue<long long int> &q) { if (q.empty()) return; long long int data = q.front(); q.po...
ALGO
0.999879
4.478107
c653b4c2-936b-495a-a8ad-7dc1796fa4b0
Mikadore/llvm-project
llvm/lib/Transforms/IPO/LoopExtractor.cpp
#include "llvm/ADT/Statistic.h" #include "llvm/Analysis/AssumptionCache.h" #include "llvm/Analysis/LoopInfo.h" #include "llvm/IR/Dominators.h" #include "llvm/IR/Instructions.h" #include "llvm/IR/Module.h" #include "llvm/InitializePasses.h" #include "llvm/Pass.h" #include "llvm/Support/CommandLine.h" #include "llvm/Tran...
TOOL
0.985078
7.91164
e1d07610-13fd-4f59-b0c4-9a14e28d8b43
YerupalleVamsi/Leetcode
3430-count-days-without-meetings/count-days-without-meetings.cpp
class Solution { public: int countDays(int days, vector<vector<int>>& meetings) { sort(meetings.begin(), meetings.end()); int cnt = 0, last = 1; for (auto& meeting : meetings) { int s = meeting[0], e = meeting[1]; if (s > last) { cnt += s - last; ...
ALGO
0.999988
5.970346
aa942eed-9c4e-4594-bd3c-4ffc431f0a9f
banimania/CompetitiveProgramming
AceptaElReto/EspantaPerros.cpp
#include <bits/stdc++.h> using namespace std; typedef long long int ll; typedef vector<ll> vll; #define REP(i, a, b) for (int i = a; i < b; ++i) #define REPV(i, a, b) for (int i = a; i >= b; --i) #define SCAN(a) for (int i = 0; i < a.size(); ++i) cin >> a[i] #define PRINT(a) for (int i = 0; i < a.size(); ++i) { cou...
ALGO
0.995724
3.777777
0dbd5263-cf92-4059-9e36-401102a78f59
paivaskrt/Algoritmos-I
IF - Intervalo (URI 1037).cpp
#include <iostream> #include <cmath> #include <iomanip> using namespace std; int main() { float a; cin >> a; if ( (a >= 0) && (a <= 25)) cout << "Intervalo [0,25]" << endl; else if ( (a > 25) && (a <= 50)) cout << "Intervalo (25,50]" << endl; else if ( (a > 50) && (a <= 75)) cout << "Intervalo (50,75]" << endl; else...
ALGO
0.997572
3.766348
77056479-67c7-4838-a2ed-fdd37b0361ff
bob11vrdp/CVE-2022-39425
VirtualBox-6.1.38/src/VBox/Runtime/common/table/avlrpv.cpp
/* $Id: avlrpv.cpp $ */ /** @file * IPRT - AVL tree, void *, range, unique keys. */ #ifndef NOFILEID static const char szFileId[] = "Id: kAVLPVInt.c,v 1.5 2003/02/13 02:02:35 bird Exp $"; #endif /************************************************************************************************************************...
ALGO
0.873962
5.542708
30a5a862-6f4c-4c4a-bed5-a098fbfac703
abhyudaya7/Programs
dnfsort.cpp
#include <bits/stdc++.h> using namespace std; void swap (int arr[],int i,int j) { int temp = arr[i]; arr[i] = arr[j]; arr[j] = temp; } void dnfSort(int arr[] , int n) { int low=0,mid=0,high=n-1; while (mid <= high) { if (arr[mid] == 0) { swap(arr,low,mid); low++;mid...
ALGO
0.999928
4.266693
51094c36-d403-44e1-9c77-1a7bdb729120
bhavya278/DSA_GFG
04.String/07.LeftmostNonRepeatingCharacter.cpp
//Naive Code #include <bits/stdc++.h> using namespace std; int nonRep(string &str) { for (int i = 0; i < str.length(); i++) { bool flag = false; for (int j = 0; j < str.length(); j++) { if (i != j && str[i] == str[j]) { flag = true; ...
ALGO
0.999959
5.52269
96d1d4a1-1e47-4a95-b3eb-a7ce5749b6ef
jibinghu/leetcode
CLASSFICATION/Array/interval_sum/traditional.cpp
#include <iostream> #include <vector> // O(n*m) int main() { int n, m; std::cin >> n; std::vector<int> array; for (int i = 0; i < n; i++) { std::cin >> m; array.push_back(m); } int begin, end; while (std::cin >> begin >> end) { int sum = 0; for (int i ...
ALGO
0.999801
5.032836
5cba789a-ae5f-4ece-b69a-445abdd3c62a
Sosuke23/LeetCode
3018-make-string-a-subsequence-using-cyclic-increments/3018-make-string-a-subsequence-using-cyclic-increments.cpp
class Solution { public: bool canMakeSubsequence(string str1, string str2) { int ptr = 0; for (int i = 0; i < (int)str1.size(); i++) { char nxt = (str1[i] - 'a' + 27) % 26 + 'a'; cout << nxt << " "; if (str2[ptr] == str1[i] or str2[ptr] == nxt) { p...
ALGO
0.999901
5.914028
9b31ec2c-d141-495c-81d8-f743778ee135
dougbel/iT
src/provenancevectors_it.cpp
#include "provenancevectors_it.h" ProvenanceVectors_iT::ProvenanceVectors_iT( pcl::PointCloud<pcl::PointXYZ>::Ptr ibs, pcl::PointCloud<pcl::PointXYZ>::Ptr scene_cloud ): ibs(ibs), sceneCloud(scene_cloud) { this->maxV = std::numeric_limits<float>::min(); this->minV = std::numeric_limits<float>::max(...
ALGO
0.98021
4.520682
f770a326-4665-4135-afc5-1bae15334f79
lwher/Algorithm-exercise
C++/FJWC2014/FJWC2014 T2.cpp
#include<iostream> #include<cstdio> #include<cstdlib> #include<cmath> #include<cstring> #include<algorithm> #define mod 10007 using namespace std; int n,size[210],F[210],root,maxx,ans; int sz,to[510],pre[510],last[210]; int f[210][210],g[2][210][210],ve[210]; bool map[210][210]; void Ins(int a,int b) { sz++;to[sz]...
ALGO
0.999581
4.02126
362a5356-0516-4a4e-be9f-2b18723b0c15
Lydxn/Competitive-Programming
CSES/Chessboard_And_Queens.cpp
#include <bits/stdc++.h> #include <ext/pb_ds/assoc_container.hpp> using namespace std; using namespace __gnu_pbds; typedef long long ll; typedef unsigned long long ull; typedef long double ld; typedef pair<int, int> pii; typedef pair<ll, ll> pll; typedef pair<ll, int> plli; typedef pair<int, ll> pill; typedef pair<pa...
ALGO
0.999251
4.847925
fe7b0097-d1a0-4d9a-a728-2bb56cdfc5f3
Zimse12345/Code
Codeforces_Contest/CF1703/A.cpp
#include <cstdio> #include <algorithm> #include <cstring> #include <vector> #include <cmath> #include <set> #include <map> #include <queue> #include <stack> #include <iostream> #include <cstdlib> #include <ctime> #define ll long long #define ull unsigned long long using namespace std; inline int read(){int qrx=0,qry...
ALGO
0.99893
4.03232
842a47db-5d8f-43db-86a7-f9a51443dffe
twareproj/tware
experiments/reduce/streaming.cpp
#include <cmath> #include <emmintrin.h> #include <iostream> #include <smmintrin.h> #include <sys/time.h> #include <unordered_map> #include <xmmintrin.h> #define USEC 0.000001 #define DATA 10000000 #define KEYS 10000000 #define VALS 100 using namespace std; double getTime(struct timeval start, struct timeval stop) { ...
ALGO
0.967146
4.986038
0dbcd66f-3bf4-4f1b-bc0b-fa5c30c7417c
kerolus77/book_store
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.9988
6.76073
a82c7304-b20d-4561-858d-4da9899cfd2e
Eshuv/Data-Structures-in-C-plus-plus
ReverseANumber.cpp
#include <bits/stdc++.h> using namespace std; int Reverse(int n) { static int count = 0; if(n%10 == n) { count++; return n; } int res = n%10; int retValue = Reverse(n/10); int ans = (pow(10, count) * res) + retValue; count++; return ans; } int main() { int re...
ALGO
0.999775
4.909311
0a473376-00c6-4fc3-8f0b-77583889f0cf
fredwhite/Backup
11258.cpp
#include<stdio.h> #include<stdlib.h> #include<string.h> char str[250]; int d[250]; long long int dp[250]; int main(){ int t; int i,j,k; int l; long long int u,v,ma; scanf("%d",&t); for(;t>0;t--){ scanf("%s",str); l=strlen(str); for(i=0;i<l;i++){ d[i]=str[i]-'0'; } dp[0]=d[0]; for(i=1;i<l;i++){...
ALGO
0.99984
3.421469
4762ff80-ed9c-4ea8-9d4f-05662d7ccf6c
ifradK/Competitive-Programming-Solutions
C++ Programs/Eating Candies.cpp
#include<iostream> #include <bits/stdc++.h> #define fastio ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL) #define endl '\n' #define ll long long using namespace std; int main() { fastio; ll t,n,i,j; cin>>t; while(t--) { cin>>n; ll a[n],b[n]={0},c[n]={0},temp1=-1,temp2=...
ALGO
0.999891
3.775424
e034062a-22ff-42d3-b856-4369c06c22b0
molloy-lab/Dollo-CDP
src/boost_1_80_0/libs/spirit/classic/example/fundamental/subrule_calc.cpp
/////////////////////////////////////////////////////////////////////////////// // // This calculator example demontrates the use of subrules. // This is discussed in the "Subrule" chapter in the Spirit User's Guide. // // [ JDG 4/11/2002 ] // /////////////////////////////////////////////////////////////////////////...
ALGO
0.985104
7.693501
3ad31a83-b435-4692-af58-05d6a08e5f8c
shirudechirayu/LB
A35/A35Q2.cpp
#include<iostream> using namespace std; int sum(int iNo) { static int iSum = 0; if(iNo != 0) { iSum += iNo % 10; iNo = iNo / 10; sum(iNo); } return iSum; } int main() { int iValue = 0, iRet= 0; cout << "Enter the number" << endl; cin >> iValue; iRet = su...
ALGO
0.999589
4.382886
ed2374d2-2892-4b63-8770-ae0bc034858e
leonardoAnjos16/Competitive-Programming
Atcoder/flowers.cpp
#include <bits/stdc++.h> using namespace std; #define long long long int struct FenwickTree { private: int n; vector<long> tree; public: FenwickTree(int n) { this->n = n + 1; tree.assign(n + 1, 0LL); } void update(int i, long x) { if (!i) tree[0] = max(tree[0], x); ...
ALGO
0.999934
4.222896
5ba4f868-d1ec-4a00-be0b-887ac4ded5ee
msahasrabudhe/dd_mrf
fast_cycle/src/fast_cycle.cpp
#ifndef STDIO #define STDIO #include <cstdio> #endif #include <cstdlib> #include <vector> #include <time.h> #include <math.h> #include <assert.h> #include "thirdparty.h" #include "cycle.h" #include <Python.h> #include <arrayobject.h> // to handle NumPy arrays. /* The int array used by NumPy. */ typedef long ...
TOOL
0.974718
5.528652
a3415a76-1711-439d-a522-db52fdf0e4fb
sunnytsai3346/custom_operator
main.cpp
#include <iostream> #include <set> #include <string> class Person { public: std::string name; int age; Person(std::string name, int age) : name(name), age(age) {} }; struct PersonComparator { bool operator()(const Person& p1, const Person& p2) const { // Sort primarily by age, then ...
TOOL
0.982224
6.272074
8c40708a-a66c-409c-ada3-608917eacd7a
empodi/CSE3081
PHW02/s160169H02.cpp
#include "Graph_adj_array.h" void Read_Graph_adj_array(int Vnum, vertex V[], int Enum, edge E[]) { // read graph information // V와 E의 name field는 각각 자신의 인덱스를 저장한다 // V[].flag과 E[].flag은 반드시 false로 설정해야 한다. // ***이 함수를 작성한다 /* typedef struct _edge { int name; int vf, vr; // e = (vf, vr) where vf, vr are...
ALGO
0.999618
4.567267
9815e827-4655-491b-9080-e341fb927350
angelosalazarb/IPOO
EJERCICIOS_DIAPOSITIVAS/TAREA2/moneda/Coin.cpp
#include "Coin.h" #include <string> using namespace std; Coin::Coin(){ number = 0; } Coin::~Coin(){} void Coin::setNumber(int nNumber){ number = nNumber; } int Coin::getNumber(){ return number; } string Coin::getAnswer(){ if (number % 2 == 0){ return "El resultado es cara."; } else if(number % 5 ==...
ALGO
0.960585
4.995368
5c12759d-da8a-4656-8682-7fe0b19cfc56
sofikulsk02/DSA_in_c-
sets&map/countVowel.cpp
#include<bits/stdc++.h> using namespace std; int main(){ unordered_map<char,int>m; string s; cin>>s; for(int i=0; i<s.length();i++){ m[s[i]]++; } int maxi=0; char maxCh; for(auto ele:m){ if(ele.second>maxi){ maxCh=ele.first; maxi=ele.second; } } ...
ALGO
0.999874
4.003059
aaaabe74-ca63-43eb-8baa-00b5b58ab30e
palilo815/ps
baekjoon/18000/18262.cpp
#include <bits/stdc++.h> using namespace std; using ll = long long; using p = pair<int, int>; using tup = tuple<int, int, int>; const int max_N = 1000; vector<tup> adj[max_N + 1]; int cost[max_N + 1]; int flow[max_N]; int Dijkstra(int N, int limit) { memset(cost + 1, 0x3f, sizeof(int)*N); cost[1] = 0; p...
ALGO
0.999952
4.381048
03729225-c0df-4947-b725-e3bbbbdb7cd4
christophhart/HISE
JUCE/modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/IntegerRatio.cpp
#include "IntegerRatio.h" using namespace resampler; // Enough primes to cover the common sample rates. static const int kPrimes[] = { 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, ...
ALGO
0.995957
5.343403
748f3de4-79d9-448d-a2c3-b6da3449fd2f
RedaElmahdy/problem-Solving
C++_Problems/level_one/18 - even_odd.cpp
/* Create a function that takes an integer as an argument and returns "Even" for even numbers or "Odd" for odd numbers. */ #include <iostream> #include <string> std::string even_or_odd(int number) { // if (number % 2 == 0) // return "Even"; // return "Odd"; return number % 2 == 0 ? "Even" : "Odd"; } ...
ALGO
0.999165
6.961595
51bda938-45b0-42a9-b264-6d2e32a8a28b
KKyang/Medical-Image-Processing-Final-Project
fuzzy_clustering.cpp
#include "fuzzy_clustering.hpp" //#include <boost/foreach.hpp> #include <iostream> namespace SoftC { void Fuzzy::initRandom () { // // メンバーシップをランダム初期化 // std::cout << "C-means Random Initialization" << std::endl; srand ((unsigned int) time (NULL)); float normalization_factor; for (int ...
ALGO
0.998861
5.249583
2dfb4df6-312d-4478-940a-2c4f70ce3f57
anujarora0502/LEVEL-UP-PEP
july10/july10.cpp
#include <iostream> #include <vector> #include <queue> using namespace std; class Edge { public: int v; int w; Edge(int v, int w) { this->v = v; this->w = w; } }; vector<vector<Edge>> graph; int N; void addEdge(int u, int v, int w) { graph[u].push_back(Edge(v, w)); gra...
ALGO
0.999446
4.757237
ff627555-5f3c-49ca-9e9d-91520520fd09
ceyxasm/implementations
operating systems/CSL3030/lab_2/demo/file_access.cpp
#include <bits/stdc++.h> #include <sys/wait.h> #include <sys/fcntl.h> #include <sys/unistd.h> #include <sys/types.h> using namespace std; int main( int argc, char *argv[]) { FILE *fp, *fp2; //file pointer char *name= argv[1]; //name of the file to be access is assummed //to be passed as first argument ...
ALGO
0.972073
3.457154
a5dd89f9-6325-4658-8be3-ef8a51d5d5c1
Coder-Vippro/Code
Archived/GiaHung/GOCBOI (2).cpp
#include <bits/stdc++.h> using namespace std; int main() { freopen("GOCBOI.inp","r",stdin); freopen("GOCBOI.out","w",stdout); int a,s=1,dem=0; cin>>a; int sa; while(a/10>0){ sa=a; s=1; while(sa>0){ s=s*(sa%10); sa=sa/10; } a=s; dem++; } cout<<dem;...
ALGO
0.9999
3.564505
3e109ff5-1aca-4134-a119-6c8d844efa46
oheunji05/Coding-test
C/키순으로.cpp
/* https://dgsw.goorm.io/exam/132233/%EC%BD%94%EB%94%A9%ED%85%8C%EC%8A%A4%ED%8A%B81/quiz/8 */ #define _CRT_SECURE_NO_WARNINGS #include <stdio.h> int main() { int n; int arr[500] = { 0 }; int temp; scanf("%d", &n); for (int i = 0; i < n; i++) { scanf("%d", &arr[i]); } for (int i = 0; i < n - 1; i++) { for (...
ALGO
0.999995
3.962835
dafc9be6-3a3f-4e15-919f-3da0b46bdd5c
dc1394/ratompp
src/Fem1D/eigprob.cpp
#include "stdafx.h" #include "eigprob.h" #include <memory> // for std::unique_ptr #include <boost/format.hpp> // for boost::format // // Defines the problem // void EigProb::Define(double gamma, std::shared_ptr<util::Fun1D const> const & g) { DefineProb(Bndr(BndrType_Dir, 0), Bndr(BndrType_Dir, 0), gamm...
ALGO
0.999829
4.716408
6da8c509-d30c-4f00-8a15-30115df87493
embeditelectronics/circuitplayground
Circuit Playground Firmware/Adafruit_CircuitPlayground/utility/Adafruit_CPlay_Mic.cpp
// Adafruit Circuit Playground microphone library // by Phil Burgess / Paint Your Dragon. // Fast Fourier transform section is derived from // ELM-ChaN FFT library (see comments in ffft.S). #include <Arduino.h> #include "Adafruit_CPlay_Mic.h" #define DC_OFFSET (1023 / 3) #define NOISE_THRESHOLD 3 // ----------...
TOOL
0.851338
5.886179
76b20074-e476-4d51-9eb8-dc3ca782ad4b
violeta-kastreva/Introduction_To_Programming
Seminar/Seminar03/task4.cpp
#include <iostream> #include <cmath> int main() { int n; std::cin >> n; for (int x = std::max(2, n); x <= 100; x++) { bool prime = true; for (int divisor = 2; divisor < x; ++divisor) { if (x % divisor == 0) { prime = false; break; } ...
ALGO
0.999939
5.127967
7eb52198-1d63-4340-bed4-1a2127d7ca20
b4df00d/SeeD
Third/taskflow-master/3rd-party/tbb/examples/graph/cholesky/init.cpp
#include <cstdio> #include <cassert> #include <cstring> #include <cstdlib> #include <mkl_cblas.h> static void posdef_gen( double * A, int n ) { /* Allocate memory for the matrix and its transpose */ double *L = (double *)calloc( sizeof( double ), n*n ); assert( L ); double *LT = (double *)calloc( size...
ALGO
0.999046
4.929345
a20ba1bd-317a-446a-a2b7-03383a05a6c7
zukahai/VKU-OJ
replacesum.cpp
#include <bits/stdc++.h> using namespace std; vector <int> a; int search(int x, vector <int> a) { int n = a.size(); int l = 0, r = n - 1; if (a[0] >= x) return 0; if (x > a.back()) return n; while (l < r) { cout << l << " " << r << endl; int mid = (l + r) / 2; ...
ALGO
0.999845
4.88163
7499de5f-6f81-4574-98ab-eb269ff479a6
efornal/captura
christian_workspace/tp5/fuente/ejer4/ejer4_5.cpp
/* * ejer4_5.cpp * * Created on: 11/05/2010 * Author: christian */ #define cimg_use_fftw3 1 #ifdef cimg_use_fftw3 extern "C" { #include "fftw3.h" } #endif #include <iostream> #include <CImg.h> #include "../lib5/lib5.h" //#include "../lib5/figuras.h" //#include "../../../tp3/fuente/lib3/mask.h" #include ".....
ALGO
0.986938
3.887048
e23f129e-ab54-4b37-8eba-29c27088d934
fgaurat/flutter_15052023
tp_bloc/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.998643
6.763549
7c1fde08-059f-493a-92aa-04146dcc2933
aabhinavvvvvvv/CP_CF
Is_it_a_tree.cpp
/* * Competitive Programming Template * Author: Abhinav Gupta * GitHub: @aabhinavvvvvvv * MAHAKAL KI JAI */ #include <bits/stdc++.h> using namespace std; using ll = long long; using ull = unsigned long long; using ld = long double; using vi = vector<int>; using vll = vector<ll>; using pii = pair<int, int>; using...
ALGO
0.999979
4.655251
6753b05c-0899-4d20-b628-80a7ae74bdff
xjonwang/competitive-programming
usaco-guide/gold/modular-arithmetic/CSES-divisor-analysis/main.cpp
#include <bits/stdc++.h> using namespace std; #define ll long long #define ld long double #define ar array #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> using namespace __gnu_pbds; template <typename T> using oset = tree<T, null_type, less<T>, rb_tree_tag, tree_order_statistics_node_...
ALGO
0.999986
3.767867
521f90bd-b249-4056-a567-97ac17020362
Vaibhavkumar5158/50daychallenge
day-32/Day.32.2.cpp
class Solution { public: void rotate(vector<vector<int>>& matrix) { int n = matrix.size(); // Step 1: Transpose the matrix for (int i = 0; i < n; ++i) { for (int j = i + 1; j < n; ++j) { swap(matrix[i][j], matrix[j][i]); } } // Step 2...
ALGO
0.999993
7.36306
1c08fd6d-f174-4220-9c9b-f2e5b76339f6
Saurabh995/spoj
INVCNT.cpp
// @author- razor123 #include<iostream> #include<cstdlib> #include<cstdio> #include<vector> #include<cmath> #include<queue> #include<cstring> #include<list> #include<sstream> #include<algorithm> using namespace std; typedef long long ULL; typedef pair<int,int> PI; typedef pair<int,PI> PPI ; #define mem(a,n) memset(...
ALGO
0.999557
3.324419