uuid
string
repo_name
string
relative_path
string
content
string
category
string
algo_rel_score
float64
quality_score
float64
c2da934b-a7d2-439f-aa74-42aa696ed86f
JinHyung16/Algorithm_Practice
Solvedac & Baekjoon/[Algorithm]Greedy/1931.cpp
#include<iostream> #include<vector> #include<algorithm> #define FastIO ios::sync_with_stdio(false); std::cin.tie(NULL); std::cout.tie(NULL); /// <summary> /// Silver1 ȸǽ - Greedy ˰ /// ִ ȸ ᱹ ð ݴ ä ȴ. /// ȸ ð {start, end} ־ٸ /// {end, start} ־ٸ Ͽ ð ǰ ٲ۴. /// /// Ʋȴ ) ݷ /// ó ȸǿ ؼ ѹ ȴ. /// N=5 -> {2...
ALGO
0.999974
4.975779
2e5c0688-18a1-4bc8-b505-a8ce6877c2ce
kmjp/procon
atcoder/abc351-400/abc378/a.cpp
#include <bits/stdc++.h> using namespace std; typedef signed long long ll; #define _P(...) (void)printf(__VA_ARGS__) #define FOR(x,to) for(x=0;x<(to);x++) #define FORR(x,arr) for(auto& x:arr) #define FORR2(x,y,arr) for(auto& [x,y]:arr) #define ALL(a) (a.begin()),(a.end()) #define ZERO(a) memset(a,0,sizeof(a)) #define ...
ALGO
0.99928
3.941212
996ba224-b85c-40e7-bdec-0b0c63e73328
ishandutta2007/codeforces
leapfrog/normal/1561/D1.cpp
//{{{ #include<bits/stdc++.h> using namespace std;typedef long long ll; template<typename T>inline void read(T &x) { x=0;char c=getchar(),f=0; for(;c<48||c>57;c=getchar()) if(!(c^45)) f=1; for(;c>=48&&c<=57;c=getchar()) x=(x<<1)+(x<<3)+(c^48); f?x=-x:x; } template<typename T,typename...L>inline void rea...
ALGO
0.999967
3.326342
3bf910ec-4a1a-4579-8624-9f63585dc160
AzatTaziev426/lab6
lab6.cpp
#include <iostream> #include <cmath> #include <fstream> using namespace std; double F(double x1, double x2) { return -(x1 * x1 * x2 - 10 * x1 * x1 + 26 * x1 * x2 - 260 * x1 + x2 * x2 * x2 - 30 * x2 * x2 + 460 * x2 - 2599); } double zol1(double x1) { //metod svena double a = 8.267; double t = 0.001; double ...
ALGO
0.999942
3.56487
b3ddfe0c-c3dc-4d63-93ba-fb4ce6b5674e
Abhijit25Mishra/code-chef
LONG/JUNE 21/Dual_Distance.cpp
#include <bits/stdc++.h> using namespace std; #define pi (3.141592653589) #define mod 1000000007 #define pb push_back #define is insert #define ff first #define ss second #define all(x) x.begin(), x.end() #define min3(a, b, c) min(c, min(a, b)) #define min4(a, b, c, d) min(d, min(c, min(a, b))) #define rfr(n) for (int ...
ALGO
0.999692
3.637179
df3bb5e6-c7a0-40e9-9e55-9967e627650f
ashwanisingh1/leetcode-sol
medium/1277.cpp
class Solution { public: int countSquares(vector<vector<int>>& matrix) { int n=matrix.size(); int m=matrix[0].size(); int i,j,ans=0; vector<vector<int>> dp(n+1,vector<int>(m+1,0)); for(i=1;i<=n;i++) { for(j=1;j<=m;j++) { if(matrix[i-1][j-1]) { ...
ALGO
0.999858
6.221018
d9f3ddda-04f6-4ef8-b8a6-8f6381e22e5e
abhishekpawl/dsa
Recursion/reverseArray.cpp
#include <bits/stdc++.h> using namespace std; void recReverse(int a[], int i, int n) { if(i >= n/2) { return; } swap(a[i], a[n-i-1]); recReverse(a, i+1, n); } int main() { int n; cin>>n; int *a = new int[n]; for(int i = 0; i < n; i++) { cin>>a[i]; } recReverse(a, 0, n); for(int i = 0; i < n; i++) { ...
ALGO
0.999823
4.411023
bce0900c-1419-4f72-85ca-501aee92b4b8
ishandutta2007/codeforces-k
kude/normal/1670/C.cpp
#include<bits/stdc++.h> namespace { using namespace std; #include <cassert> #include <numeric> #include <type_traits> #ifdef _MSC_VER #include <intrin.h> #endif #include <utility> #ifdef _MSC_VER #include <intrin.h> #endif namespace atcoder { namespace internal { constexpr long long safe_mod(long long x, long lo...
ALGO
0.999837
4.599012
a8549bcb-9912-43ba-9254-80a5d11c1003
HEMAPINDI/IPMP
trees/TimeToInform.cpp
class Solution { public: int dfs(int i, vector<int>& manager, vector<int>& informTime){ if(manager[i]!=-1){ informTime[i]+=dfs(manager[i],manager,informTime); manager[i]=-1; } return informTime[i]; } int numOfMinutes(int n, int headID, vector<int>& manager, ve...
ALGO
0.999953
6.015426
8409b111-26b7-4c80-830e-48c7af022e0d
MinByeongChan/myMBC
Codingtest/Baekjoon/1712_Break_even_pointer.cpp
#include <iostream> using namespace std; int main(int argc, char** argv) { int a=0; //고정비용 int b=0; //가변비용 int c=0; //제품 가격 cin >> a >> b >> c; if(c-b <= 0) cout << -1 << endl; else cout << a / (c-b)+1 << endl; return 0; }
ALGO
0.999583
3.440601
30b41ec8-31cd-4613-ba68-cb6a87479af7
jjhartmann/ORBSLAM2-WIN
Thirdparty/g2o/g2o/core/optimization_algorithm_gauss_newton.cpp
#include "optimization_algorithm_gauss_newton.h" #include <iostream> #include "../stuff/timeutil.h" #include "../stuff/macros.h" #include "solver.h" #include "batch_stats.h" #include "sparse_optimizer.h" using namespace std; namespace g2o { OptimizationAlgorithmGaussNewton::OptimizationAlgorithmGaussNewton(Solve...
ALGO
0.998499
6.723323
7049ad4e-96ab-415f-853c-e170b49e6573
toufu-24/AtCoder
ABC/ABC418/D.cpp
#include <bits/stdc++.h> #include <atcoder/all> using namespace std; using namespace atcoder; #define all(v) v.begin(), v.end() #define SORT(v) sort(v.begin(), v.end()) #define RSORT(v) sort(v.rbegin(), v.rend()) #define REVERSE(v) reverse(v.begin(), v.end()) #define ll long #define ld long double #define int ll int...
ALGO
0.999989
5.310754
14dfe7ec-0df2-4da9-b707-c17db27f9420
s417-lama/ppopp21-preemption-artifact
lammps/src/USER-FEP/pair_lj_charmm_coul_long_soft.cpp
/* ---------------------------------------------------------------------- Contributing author: Paul Crozier (SNL) Soft-core version: Agilio Padua (Univ Blaise Pascal & CNRS) ------------------------------------------------------------------------- */ #include "pair_lj_charmm_coul_long_soft.h" #include <mpi.h> #i...
ALGO
0.999915
5.726014
1a0bb293-c560-4ebc-8398-ee95066056cd
FeverDream-cy/DSA-code.ptit
DSA02004 - DI CHUYỂN TRONG MÊ CUNG 2.cpp
#include<bits/stdc++.h> #define mod 1000000007 #define ll long long #define p(x) pair<x,x> #define v(x) vector<x> #define Tree node* #define sz(a) a.size() #define x first #define y second #de...
ALGO
0.99985
4.344289
986ebfab-ee0e-40e0-ba67-78712f900f6a
Harsh20221/DSA
C++ Basics/Functions.cpp
#include <iostream> #include <stdio.h> #include <stdlib.h> using namespace std; int Add(int a, int b){ int c=a+b; return(c); } int main(){ int x=10; int y=8; int z=Add(x,y); printf("The sum of X and y is:%d",z); }
TOOL
0.984896
3.867877
e3da6192-40ae-46a7-8a07-e97c51bfbff3
ishandutta2007/codeforces
nebuchadnezzar/normal/1109/D.cpp
#ifdef LOCAL # define _GLIBCXX_DEBUG #else # define cerr __get_ce #endif #include <bits/stdc++.h> #define ff first #define ss second #define szof(x) ((int)x.size()) using namespace std; typedef long long ll; typedef long double ld; typedef pair<int, int> pii; int const INF = (int)1e9 + 1e3; ll const INFL = (ll)1e18 ...
ALGO
0.999992
3.940269
95339c95-6b6f-43e8-b2f2-12e7d6f17ced
LordAro/AdventOfCode
2022/src/day6.cpp
#include <bitset> #include <fstream> #include <iostream> template<int N> bool is_substr_unique(const std::string &communication, size_t start_idx) { std::bitset<26> set; for (size_t i = start_idx; i < start_idx + N; i++) { set.set(communication[i] - 'a'); // all lower-case } return set.count() == N; } int main(...
ALGO
0.988918
5.829221
d44d5a8c-5629-4cfb-94e8-79a348c4e819
laurayinglu/LeetCode
data_struct_lc/array/48.cpp
// https://leetcode.com/problems/rotate-image/ // solution1: rotate each number by 90 degree // solution2: transpose + flip class Solution { public: void rotate(vector<vector<int>>& matrix) { // int temp = 0, n = matrix.size()-1; // for (int i = 0; i <= n / 2; ++i) { // for (int j = i; j ...
ALGO
0.999982
7.033777
ee0a1aa7-a28d-4e5d-9cbf-83db386cc104
Kwok-Yee/kommandos
kommandos/Collision.cpp
#include "Collision.h" #include "irrlicht.h" using namespace irr; using namespace core; using namespace scene; using namespace video; using namespace io; using namespace gui; irr::core::array<ISceneNode*> wallList, staticList, dynamicList; irr::core::array<Powerup*> powerupList; bool Collision::SceneNodeWithSceneNod...
ALGO
0.957246
4.295699
a8c69b42-e40e-4b9e-8623-f8bbd0a1101a
mpc-hc/mpc-hc
src/thirdparty/unrar/rs.cpp
#include "rar.hpp" #define Clean(D,S) {for (int I=0;I<(S);I++) (D)[I]=0;} void RSCoder::Init(int ParSize) { RSCoder::ParSize=ParSize; // Store the number of recovery volumes. FirstBlockDone=false; gfInit(); pnInit(); } // Initialize logarithms and exponents Galois field tables. void RSCoder::gfInit() { fo...
ALGO
0.998448
4.762784
cbec9c72-6576-4d6a-a59c-813d23090bac
lvaldivia/Fundamentos201902
depts/include/Box2D/Common/b2Math.cpp
#include "Box2D/Common/b2Math.h" const b2Vec2 b2Vec2_zero(0.0f, 0.0f); /// Solve A * x = b, where b is a column vector. This is more efficient /// than computing the inverse in one-shot cases. b2Vec3 b2Mat33::Solve33(const b2Vec3& b) const { float32 det = b2Dot(ex, b2Cross(ey, ez)); if (det != 0.0f) { det = 1.0f...
ALGO
0.999499
7.071196
6b53c4a7-94ea-4911-9f36-47cace4cb097
xuda25/C-study
leetcode/95.不同的二叉搜索树-ii.cpp
/* * @lc app=leetcode.cn id=95 lang=cpp * * [95] 不同的二叉搜索树 II */ // @lc code=start /** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode() : val(0), left(nullptr), right(nullptr) {} * TreeNode(int x) : val(x), left(nullptr)...
ALGO
0.999934
6.603188
8db8fd0b-474d-4c4f-9704-46e5b8345670
Crowbar1024/myAlgorithms
DP/StateCompress.cpp
#include "myheader.h" // 1986 medium 可以用一个框sessionTime装一些数,可以不装满,问最少几个框用掉所有数 // n<15,所以可以用状态压缩DP做 // dp[i]=1101,表示用了第1,3,4个数,状态表达为13 int minSessions(vector<int>& tasks, int sessionTime) { int n = tasks.size(), m = 1 << n; vector<int> dp(m, 0x3f3f3f3f); // 如果该状态代表的数的和能被框装下,标记为1 for (int i = 1; i < m; ++...
ALGO
0.999852
5.095666
934e5ddc-7376-4cd3-b941-bae673d3fa7a
andrewsosag/blockchainCpp
Block.cpp
#include "Block.h" #include "sha256.h" #include <sstream> #include <sys/time.h> #include <iomanip> /* Block Constructor: Input: - Current Index of Blockchain - Current block data */ Block::Block(int currentIndex, const std::string currentData) { // Set Block Index and Data blockIndex = currentIndex; ...
ALGO
0.970218
5.82557
40e51fa2-2ac4-431e-b609-96a70092806f
Abirrahman2/COMPETITIVE
detectcycleusingdfs.cpp
#include<bits/stdc++.h> using namespace std; bool detect(int node,vector<int>adj[],int vis[],int path[]) { vis[node]=1; path[node]=1; for(auto it:adj[node]) { if(!vis[it]) { if(detect(it,adj,vis,path)==true) { return true; } } ...
ALGO
0.999909
5.104042
8fe32a85-c689-461b-a1b0-b7ac7c7b4552
lilianeascosta/DataStructure
C++/ListaDuplamenteEncadeada/main.cpp
#include <iostream> #include <locale.h> #include <stdlib.h> #include <ctype.h> #include <windows.h> using namespace std; #include "ListaDupEncadeada.h" void setDados(TInfo& item){ cout << "Informe o codigo: "; cin >> item.chave; } void setPosicao(int& pos){ cout << "Informe a posio: "; cin >> pos; } ...
TOOL
0.952616
4.322753
a32ad9e0-16d0-4fd3-9ae2-1d7a520342f1
oganaa2472/Leetcode
1915-check-if-one-string-swap-can-make-strings-equal/check-if-one-string-swap-can-make-strings-equal.cpp
class Solution { public: bool areAlmostEqual(string s1, string s2) { unordered_map<char,int> m1,m2; int cnt = 0; int n = s1.size(); for(int i = 0;i<n;i++){ m1[s1[i]]++; m2[s2[i]]++; if(s1[i]!=s2[i]) cnt++; } if(m1!=m2|| cnt>2) retur...
ALGO
0.99996
6.19178
401206b4-7560-45ad-a0fa-71fdda1c8327
nmpogg/CodePTIT
c/sosmith.cpp
#include <stdio.h> int sum(long long n){ long long digit; long long sum = 0; while(n > 0){ digit = n % 10; sum += digit; n /= 10; } return sum; } int sum_of_factors(long long n){ long long i = 2, sum2 = 0;; while(n >= 2){ if(n % i == 0){ sum2 += sum(i); n /= i; } else i++; } return sum2;...
ALGO
0.999957
4.493894
0d328261-30cf-430d-b3b4-3b66695417a4
Wan3rd/Looping-31-to-40
Problem #32.cpp
// Programmer is John Carl Samson // AM5 - BSIT // September 28, 2023 // Display User's name #include<iostream> #include<string> using namespace std; int main() { string name; int numtimes; cout<<"Enter your name: "; cin>>name; cout<<"Enter number: "; cin>>numtimes; for (int ctr = 1...
TOOL
0.894058
3.485591
7fffb879-255e-4be5-8c7a-1904bbeff828
Sonykhan1121/Learning-Flutter-
flutter30dayschallenge/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.9982
6.76775
83665252-3b6e-4dd4-aab7-20e3370c83f2
abhishekmittal15/Competitive-Programming-
codechef/June21Lunchtime/C_HTMLTAGS/sol.cpp
#include<iostream> using namespace std; #define int long long int signed main(){ int t; cin>>t; while(t--){ string s,ans="Success"; cin >> s; int n = s.length(); if(s[0]!='<' || s[1]!='/' || s[n-1]!='>') ans = "Error"; else{ for (int i = 2; i ...
ALGO
0.999426
3.42057
ef974ea3-ad1c-4b66-83d2-f4d85e8ed366
vrohan319/codes
graphs/cycledetectionInUndirectedgraph.cpp
#include <bits/stdc++.h> using namespace std ; vector<int> arr[10001] ; int visited[10001] ; bool check_cycle_using_dfs(int sv , int parent){ visited[sv] = 1 ; for(int child: arr[sv]){ if(visited[child] == 0){ if(check_cycle_using_dfs(child ,sv)){ return true ; ...
ALGO
0.99999
5.041217
bc9cca96-145b-4df4-9c44-5989c2939096
Vineethkumaar/Coding
1221. Split a String in Balanced Strings-LeetCode.cpp
class Solution { public: int balancedStringSplit(string s) { int temp=0,res=0; bool flg=false; if(s[0]=='R') flg=true; for(int i=0 ; i<s.length() ; i++) { if(flg==true && s[i]=='R') temp++; ...
ALGO
0.999883
5.695549
f048026b-5e19-4baa-8c86-0ee259f54c6f
ANONDO1250/Data_STRUCTURE_IN_CPP
Doubly_Linklist/Same_to_Same.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, int v) { Node *newNode = new Node(v); if (head == NULL) { head = newNode; ...
ALGO
0.999916
3.674674
eea9c99d-f5d6-41ca-991d-7397da347140
Rohxn16/CP
Old/Contests/Codeforces/think_cell/A.cpp
#include <bits/stdc++.h> using namespace std; int main(int argc, char const *argv[]) { int t; cin >> t; while(t--){ int n; cin >> n; int n2 = 2 * n; long long res = 0; long long arr[n2]; for(int i= 0; i < n2; i++){ cin >> arr[i]; } sort(arr,arr+n2); for(int i = 0; i < n2; i+=2){ int a = arr[...
ALGO
0.999869
4.303588
31ce0003-5154-4e3f-8f1d-a43677ab98df
IITH-Compilers/LLVM-Loop-Profiler_MonoRepo
clang/lib/DirectoryWatcher/windows/DirectoryWatcher-windows.cpp
#include "DirectoryScanner.h" #include "clang/DirectoryWatcher/DirectoryWatcher.h" #include "llvm/ADT/STLExtras.h" #include "llvm/Support/ConvertUTF.h" #include "llvm/Support/Path.h" #include "llvm/Support/Windows/WindowsSupport.h" #include <condition_variable> #include <mutex> #include <queue> #include <string> #inclu...
TOOL
0.915431
7.516921
8b4a0b77-ecc1-4dfe-82d7-5918d6350ee1
soup1997/Algorithm
Softeer/Level3/성적 평균/성적 평균.cpp
#include<iostream> #include<vector> using namespace std; double get_average(const vector<int>& S, int& A, int& B) { int s_index = A - 1; int number = B - s_index; double average = 0; for(auto i = s_index; i < B; i++) { average += static_cast<double>(S[i]); } return average / number; } void print_result(con...
ALGO
0.999939
4.376815
a9dbe3c2-b77a-4a7b-b576-726706ee6649
Dplex/ACMICPC
Acm/1436.cpp
#include <stdio.h> int main() { int n; scanf("%d", &n); for (int i = 666; n; i++) { int j; for (j = i; j&& j % 1000 != 666; j /= 10); if (j) n--; if (!n) { printf("%d\n", i); return 0; } } }
ALGO
0.999096
3.257091
0bd0d5c1-d7f5-4534-a290-fe22f83a1842
Jeongfeel/algorithm_code
math/Baekjoon_4796_캠핑.cpp
/* problem site : baekjoon problem number : 4796 problem name : 캠핑 algorithm : math */ #include <iostream> using namespace std; int main() { int numberOfCase = 0; while (1) { int usableDay, continuousDay, holiday; cin >> usableDay >> continuousDay >> holiday; if (usableDay == 0 && continuousDay == 0 && ...
ALGO
0.999582
4.494848
df953d29-4839-497b-bb34-6f18c4832c55
ZacharyKim7/Gradebook
gradebook/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.997958
6.76775
b99b49c0-6be4-4159-84a0-359b6b30ff59
happy-go-lucky/MonsieurBones
libraries/eigen/doc/snippets/Tutorial_AdvancedInitialization_LinSpaced.cpp
ArrayXXf table(10, 4); table.col(0) = ArrayXf::LinSpaced(10, 0, 90); table.col(1) = M_PI / 180 * table.col(0); table.col(2) = table.col(1).sin(); table.col(3) = table.col(1).cos(); std::cout << " Degrees Radians Sine Cosine\n"; std::cout << table << std::endl;
ALGO
0.943536
3.543272
c3d10c33-4d89-4015-acdb-456113bf2449
Nishikawa5/Competitive-Programming
15-295 CMU/Contest 1/knitpicking.cpp
#include <bits/stdc++.h> using namespace std; void solve() { int n; cin >> n; map<string, map<string, int>> socks; // type -> (fit -> count) for (int i = 0; i < n; i++) { string type, fit; int count; cin >> type >> fit >> count; socks[type][fit] += count; }...
ALGO
0.999556
4.310543
645128e3-3f19-472e-acfe-6a51443bda3f
kaizen2112/Data-Structure-Algorithm
negative cycle floyd warshall.cpp
#include <bits/stdc++.h> using namespace std; const int N = 300; const int INF = INT_MAX; int main() { int v, e; cin >> v >> e; int dist[N][N]; for (int i = 0; i < N; i++) { for (int j = 0; j < N; j++) { if (i == j) dist[i][j] = 0; else ...
ALGO
0.999961
3.712523
9f9b6783-80e1-4afe-8c1e-a81aef1af451
ThoseBygones/ACM_Code
HDU/HDU 1492.cpp
/* ******************************************************************************** * Author: ThoseBygones * Version: V1.0 * Date: 2020-11-09 * Subject: ACM-ICPC * Language: C/C++14 * OJ: HDU * Algorithm: Ψһֽⶨ ******************************************************************************** * Algo-Desc...
ALGO
0.999877
3.711104
13d50b39-1662-40d4-a51f-cfe36fba9f03
DSutyak/CUSail
Individual_Functions_for_Arduino_Code/pixy.cpp
#include <SPI.h> #include <Pixy.h> #include "mex.h" Pixy pixy; pixy.init(); angleofattack = 15; //this code block comes from https://forum.arduino.cc/index.php?topic=45626.0 template<typename Data> class Vector { size_t d_size; // Stores no. of actually stored objects size_t d_capacity; // Stores allocated ca...
TOOL
0.946542
5.069222
359da2cf-3539-4502-b6a5-c65085980445
danieltrt/SBFL
results/py/FIND_A_FIXED_POINT_IN_A_GIVEN_ARRAY.cpp
int f_filled ( int * arr , int n ) { for ( int i = 0 ; i < n ; i ++ ) { if ( arr [ i ] == i ) return i ; } return - 1 ; }
ALGO
0.99862
3.877846
4b0a5e70-41c3-4919-b29d-4ceb04e32d20
ishandutta2007/codeforces
yp155136/normal/940/A.cpp
#include <iostream> #include <cstdio> #include <vector> #include <algorithm> #include <cstring> #include <utility> #include <cmath> #include <ctime> #include <cstdlib> #include <queue> #include <stack> #include <set> #include <map> #include <cassert> #include <iomanip> #include <bitset> using namespace std; typedef lo...
ALGO
0.999933
3.36486
e85c0d2b-f253-4e67-877d-0429fd06d251
cstom4994/SourceEngineRebuild
src/Engine/engine/components/filesystem/linux_support.cpp
#include "linux_support.h" #include "tier0/threadtools.h" // For ThreadInMainThread() #include "tier1/strtools.h" char selectBuf[PATH_MAX]; int FileSelect(const struct dirent *ent) { const char *mask = selectBuf; const char *name = ent->d_name; //printf("Test:%s %s\n",mask,name); if (!strcmp(name, "...
TOOL
0.92027
4.720842
028955ef-4771-4aea-bdb9-fb359299c233
128128128/myme
external_library/DirectXTK-master/Src/SimpleMath.cpp
#include "pch.h" #include "SimpleMath.h" /**************************************************************************** * * Constants * ****************************************************************************/ namespace DirectX { namespace SimpleMath { const Vector2 Vector2::Zero = { 0.f, 0.f }...
TOOL
0.954501
7.538304
8c1c631d-317e-4424-834f-ca792753cab1
AI-4-SE/workload_coverage_companion
misc/code/z3/src/sat/sat_elim_vars.cpp
#include "sat/sat_simplifier.h" #include "sat/sat_elim_vars.h" #include "sat/sat_solver.h" namespace sat{ elim_vars::elim_vars(simplifier& s) : simp(s), s(s.s), m(20) { m_mark_lim = 0; m_max_literals = 11; m_miss = 0; m_hit1 = 0; m_hit2 = 0; } bool elim_vars::oper...
ALGO
0.999146
6.318403
d1fa21ba-ebf2-45fd-a358-9a171a8d8d86
beelisais2793/FX
Synthesizer/Waves/PhysicalModel/Physically-based-modelling/RigidBodySimulation/RigidBodySimulation/include/eigen-eigen-323c052e1731/doc/examples/DenseBase_middleRows_int.cpp
#include <Eigen/Core> #include <iostream> using namespace Eigen; using namespace std; int main(void) { int const N = 5; MatrixXi A(N,N); A.setRandom(); cout << "A =\n" << A << '\n' << endl; cout << "A(2..3,:) =\n" << A.middleRows(2,2) << endl; return 0; }
ALGO
0.94742
3.307581
432fca12-f9bd-4464-9cec-2f2038759339
AdityaNik/sppu-seit-cg-practicals
Timepass/main.cpp
#include<iostream> #include<stdlib.h> #include<GL/glut.h> using namespace std; float x1,x2,y1,y2; int steps; int x,y; int interchange; int dx,dy,S1,S2; void init() { glClearColor(1.0,1.0,1.0,1.0); glColor3f(0,0,0); glPointSize(5); glMatrixMode(GL_PROJECTION); glLoadIdentity(); gluOrtho2D(-500,5...
ALGO
0.999322
4.672038
5db3abf9-9402-42ef-be3f-a44b22238e38
9967han/PS-Algorithm
BaekJoon/9020.cpp
#include<iostream> #include<algorithm> using namespace std; void getPartition(int n); int map[10001]; int main(){ int T, n; for(int i=2; i<=100; i++){ for(int j=i+i; j<=10000; j+=i){ map[j] = 1; } } map[2] = 0; cin >> T; for(int i=1; i<=T; i++){ cin >> n; getPartition(n); } } void getPartition(int n)...
ALGO
0.999891
3.819194
3fbd146c-3b5b-47e0-a49f-72bb4e49e46e
MdMostafizurRahaman/Operating-System
SJF_Nonpremptive.cpp
#include<bits/stdc++.h> using namespace std; int main() { struct comparator{ bool operator()(pair<string,int>&a, pair<string,int>&b) { return a.second>b.second; } }; priority_queue<pair<string,int>, vector<pair<string,int>>, comparator>pq; int no_of_process; cout<<...
ALGO
0.999789
4.229266
aade2afa-ee4b-4dc1-b7a6-8f625e1436d4
liujiapeng678/homework
07/源.cpp
#include"Ŀ_1953729_.h" using namespace std; int main() { int x, y, a, sum = 0; Priority_Queue<int>minnumber; //int͵С minnumber.buildheap(); //С a = minnumber.size(); //Ԫصĸ for (int i = 1; i < a - 1; i++) //ѭ { x = minnumber.Out_Queue(); y = minnumbe...
ALGO
0.999619
3.153016
b5fda1dd-bb11-4b9d-a7a4-0f6e23a7e1cb
OmerFarukYilmaz-github/IndependenceWarStoryGame
Library/PackageCache/com.unity.ide.visualstudio@2.0.14/Editor/COMIntegration/COMIntegration~/COMIntegration.cpp
#include <iostream> #include <sstream> #include <string> #include <filesystem> #include <windows.h> #include <shlwapi.h> #include "BStrHolder.h" #include "ComPtr.h" #include "dte80a.tlh" constexpr int RETRY_INTERVAL_MS = 150; constexpr int TIMEOUT_MS = 10000; // Often a DTE call made to Visual Studio can fail after ...
TOOL
0.949674
6.969462
ce89e40a-81c6-49c2-9e59-f696c450667b
watemus/cp-prog
codeforces/cf685/B.cpp
// // Created by watemus on 23.11.2020. // #ifdef LOCAL #define _GLIBCXX_DEBUG #endif #include <bits/stdc++.h> using namespace std; #define ALL(a) a.begin(), a.end() #define RALL(a) a.rbegin(), a.rend() #define FF first #define SS second using ll = long long; using ld = long double; #define int ll template<typen...
ALGO
0.999884
4.527282
09ae0167-634e-4776-81a1-5d49bdd5fcd7
temychshev/oopip
Lab 6/Lab 6/Lab 6.cpp
#include <iostream> #include <string> #include <vector> class CipherStrategy { public: virtual std::string Process(const std::string& input, const std::string& key) = 0; }; class EncryptStrategy : public CipherStrategy { public: std::string Process(const std::string& input, const std::string& key) override { ...
ALGO
0.998964
5.678636
0810e90d-b5d0-4051-a11c-06484ab869c6
alexmac/alcexamples
OpenCV-2.4.2/samples/cpp/video_homography.cpp
/* * video_homography.cpp * * Created on: Oct 18, 2010 * Author: erublee */ #include "opencv2/calib3d/calib3d.hpp" #include "opencv2/highgui/highgui.hpp" #include "opencv2/imgproc/imgproc.hpp" #include "opencv2/features2d/features2d.hpp" #include <iostream> #include <list> #include <vector> using namespace std;...
ALGO
0.969422
5.841825
5a81b090-db3e-41b4-b89a-6991603d1c78
Saanvi26/GeeksForGeeks_DSA
School/Print 1 To N Without Loop/print-1-to-n-without-loop.cpp
//{ Driver Code Starts #include <bits/stdc++.h> using namespace std; // } Driver Code Ends class Solution{ public: //Complete this function void print(int i,int N){ if(i>N){ return; } cout<<i<<" "; print(i+1,N); } void printNos(int N) { print(...
ALGO
0.998824
6.073397
5c51d715-5ec0-4d28-9ae2-343c9d211670
EazyPayZa/EZPAY
src/crypto/hmac_sha256.cpp
#include "crypto/hmac_sha256.h" #include <string.h> CHMAC_SHA256::CHMAC_SHA256(const unsigned char* key, size_t keylen) { unsigned char rkey[64]; if (keylen <= 64) { memcpy(rkey, key, keylen); memset(rkey + keylen, 0, 64 - keylen); } else { CSHA256().Write(key, keylen).Finalize(rke...
ALGO
0.985362
5.856034
9434371c-7705-4c0f-b3d8-08ab4fe2f422
DimaBabich0/221Homework
Archive/DZ20/ArrayValueCalculator.cpp
#include "ArrayValueCalculator.h" #include "ArraySizeException.h" #include "ArrayDataException.h" #include <string> using namespace std; int ArrayValueCalculator::doCalc(char** ptr, int cols, int rows) { if (cols != 4 && rows != 4) { throw ArraySizeException("Size not equals 4"); } int sum = 0; for (int i = 0;...
ALGO
0.881093
4.382398
983e50ef-5648-475d-88f4-868425acd21d
theshubhamsoni/leetcode
209_Minimum_Size_SubArray.cpp
#include <iostream> #include <vector> #include <climits> using namespace std; class Solution { public: int minSubArrayLen(int target, vector<int>& nums) { int len = nums.size(); int start = 0; int curr_sum = 0; int minSize = INT_MAX; for(int i = 0; i < len ; i++) { cur...
ALGO
0.999962
5.999518
53442db7-1367-4f67-ba52-8214aaf7f31c
CodingPO8/ORE
QuantLib/ql/experimental/exoticoptions/analyticholderextensibleoptionengine.cpp
/* -*- mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ #include <ql/exercise.hpp> #include <ql/experimental/exoticoptions/analyticholderextensibleoptionengine.hpp> #include <ql/math/distributions/bivariatenormaldistribution.hpp> #include <utility> using std::pow; using std::log; using std::ex...
ALGO
0.999556
7.746736
18cc9a38-ec01-4891-8d8d-5bc249ba8006
nobinov/image_resizer_server
include/boost_1_75_0/libs/geometry/example/04_boost_example.cpp
// Boost.Geometry (aka GGL, Generic Geometry Library) #include <iostream> #include <boost/geometry/geometry.hpp> #include <boost/geometry/geometries/point_xy.hpp> #include <boost/geometry/geometries/linestring.hpp> #include <boost/geometry/geometries/polygon.hpp> #include <boost/geometry/geometries/adapted/boost_tupl...
TOOL
0.954727
7.774071
207cc08f-ea24-4240-b67c-42487084448e
J4wHar/Problem-solving
0049-group-anagrams/0049-group-anagrams.cpp
class Solution { public: vector<vector<string>> groupAnagrams(vector<string>& strs) { map<string, vector<string>> mp; vector<vector<string>> ans; for(auto x: strs){ string s = x; sort(s.begin(), s.end()); mp[s].push_back(x); } for(auto x: m...
ALGO
0.999993
6.485169
161996af-4d3f-470a-aab2-999dbcfc10c0
alok-38/computer-science
learn_c++/24-06-25/cipher.cpp
#include <iostream> #include <string> using namespace std; int main() { string input; cout << "Enter a word to cipher into ASCII: "; cin >> input; cout << "\nCiphered output (ASCII values):\n"; for (char c : input) { cout << (int)c << " "; } cout << "\n\nDone!\n"; return...
TOOL
0.888104
5.371707
aac7814c-8e67-4f17-81d9-97c9c5d1606a
ashok201198/C-course
C-LinkedLists2-Worksheet/insertAtEveryKthNode.cpp
/* OVERVIEW: Given a single linked list insert a new node at every Kth node with value K. E.g.: 1->2->3->4->5, k = 2, 1->2->2->3->4->2->5 INPUTS: A linked list and Value of K. OUTPUT: Insert a new node at every Kth node with value K. ERROR CASES: Return NULL for error cases. NOTES: */ #include <stdio.h> #include <...
ALGO
0.999668
3.794217
4ad762c2-79a1-4933-87b8-22b22f8b616f
andreykirkicha/cppCourse_part-I
6_2/minimum.cpp
#include <iostream> #include <cstddef> //================================================================================================================ template <typename Type> class Array { public: explicit Array(size_t size = 0, const Type& value = Type()) : size_(size), data_(new Type[size]) ...
ALGO
0.999033
4.987149
db4ccc87-71cf-4d52-a413-c7e2640aa4eb
SkyrimYun/myleetcode
62.cpp
/* 递归的速度相较于循环其实是比较慢的,因为会涉及到过多的函数调用 此题用动态规划速度会比dfs递归快很多 */ #include <iostream> #include <vector> #include <unordered_map> #include <unordered_set> using namespace std; class Solution { public: int uniquePaths(int m, int n) { vector<vector<int>> dp(m, vector<int>(n, 0)); for (int i = 0; i < m;...
ALGO
0.999873
5.840378
dc3a8b0a-bda2-488e-8597-0ef8c99faf98
SAURABH11072004/DSA-ASSIGNMENTS
1.CPP
#include <iostream> // Include the input-output stream library for console operations #include <string> // Include the string library to use the string class using namespace std; // Use the standard namespace to avoid prefixing with std:: const int MAX_STUDENTS = 15; // Define a constant for the maximum number of st...
ALGO
0.999553
6.457542
6010005e-b46b-4815-bb9f-316eee261b0f
mrshivamshaw/DSA-cpp
questions/hollowRect.cpp
#include<iostream> using namespace std; int main(){ int a,b ; cout<<"Enter number of rows"<<endl; cin>>a; cout<<"Enter number of columns"<<endl; cin>>b; for(int i = 1; i<=a;i++){ for(int j = 1; j <= b; j++){ if(i == 1 || i == a || j == 1 || j == b){ cout<<"* ...
ALGO
0.998674
3.237566
a316d819-324f-4ae6-be58-57732ac4fd99
Abhishek1027/DataStructures-Algo-s
Functions_C++/ncrfunctions.cpp
#include<bits/stdc++.h> using namespace std; int factorial(int n){ int i=1; int ans=1; while(i<=n){ ans=ans*i; i++; } return ans; } int main(){ int n,r; cin >> n>> r; int fact_n=factorial(n); int fact_r=factorial(r); int fact_n_r=factorial(n-r); int ans= fact_n/(fact...
ALGO
0.999894
4.197556
83619641-eec9-48d9-868a-46f8b315000b
sj7699/Algo
Atcoder/Atcoder_Beginner_Contest_260/C.cpp
#include<stdio.h> #include<queue> #include<vector> #include<iostream> #include<map> #include<set> #include<algorithm> using namespace std; long long mod=1e9+7LL; long long N,X,Y; long long solve=0; void B(long long k,int step); void R(long long k,int step){ if(step<=1) return; R(k,step-1); B(k*X,step); } vo...
ALGO
0.999845
3.466967
ecd74986-34d6-4dff-9cd5-b4bf1921ed4f
Fi281001/c-
bai tap c/chenhlechminmax.cpp
#include<bits/stdc++.h> using namespace std; int nhonhat(int a[],int n) { int min = a[0]; for (int i = 1; i < n; i++) if (min > a[i]) min = a[i]; return min; } int lonnhat(int a[] , int n) { int max = a[0]; for (int i = 1; i < n; i++) if (max < a[i]) ...
ALGO
0.999888
3.754866
dbc45374-a750-4156-b716-41c4de06c10f
wh-acmer/acm-shiyuan
Code in 2014/week1/loj1422.cpp
#include <cstdio> #include <iostream> #include <algorithm> #include <cmath> #include <vector> #include <cstring> using namespace std; #define maxn 110 int a[maxn],dp[maxn][maxn]; int main(){ int T,cas=0; scanf("%d",&T); while(T--){ int n; scanf("%d",&n); for(int i=1;i<=n;i++){ ...
ALGO
0.999608
3.703205
930dee41-114f-4e62-9158-d6f5e016b5a2
LancersSEO/Algorithms-Data-Structure
pair-with-greatest-product.cpp
// C++ program to find a pair with product // in given array. #include<bits/stdc++.h> using namespace std; // Function to find greatest number that us int findGreatest( int arr[] , int n) { int result = -1; for (int i = 0; i < n ; i++) for (int j = 0; j < n-1; j++) for (int k =...
ALGO
0.999936
4.949807
569f814c-065d-4d3e-bc04-d79b4880faea
113bommy/deepmind_codecontests_refine
cpp_gold_filter_file/cpp_train_3827_3.cpp
#include <bits/stdc++.h> using namespace std; const int N = 500500; const int mod = 1e9 + 7; const long long inf = 1e18; int q[N * 10 + 1]; inline int bin(int x, int k, int mod) { int res = 1; while (k) { if (k & 1) res = res * 1ll * x % mod; x = x * 1ll * x % mod; k >>= 1; } return res; } long long...
ALGO
0.999916
3.639826
0dd6e7ab-aa60-4cb7-8e90-7aa896577d54
AnshSingh0443/C-
Patterns/inverted_full_pyramid.cpp
#include<iostream> using namespace std; void inverted__full_pyramid(int row){ for(int i=0;i<row;i++){ //print spaces for(int j=0;j<i;j++){ cout<<" "; } //stars for(int k=0;k<row-i;k++){ cout<<"*"; } cout<<endl; } } int main(){ ...
ALGO
0.999238
3.693248
095e64f6-1aad-4358-a2a8-4c5ce1c563fe
UCLA-VAST/sisyphus-fpga25-artifact
vitis/sisyphus/2023_float_with_tree_red/gesummv_MEDIUM/code_generated.cpp
#include <ap_int.h> #include <hls_stream.h> #include <hls_vector.h> #include <cstring> typedef hls::vector<float,16> float16; typedef hls::vector<float,8> float8; typedef hls::vector<float,4> float4; typedef hls::vector<float,2> float2; typedef hls::vector<float,1> float1; void load_tmp (float tmp[250], float2 vtmp[1...
ALGO
0.974955
3.244545
6a8b58c4-301c-4d96-9e25-31ae0def88be
NovAero/Custom-Physics-Engine
LineRenderer/Collision.cpp
#include "Collision.h" #include "Collider.h" #include "Actor.h" #include "RigidBody.h" void CollisionInfo::Resolve() { if (!IsOverlapping()) return; float aInvMass = colliderA->parent->GetRigidBody().GetInverseMass(); float bInvMass = colliderB->parent->GetRigidBody().GetInverseMass(); float totalInvMass = aInvM...
ALGO
0.989862
3.83373
b40d681f-c758-4d6c-be4c-341c48d9e233
ishandutta2007/codeforces
monogon/normal/1340/C.cpp
#include <bits/stdc++.h> #define ll long long using namespace std; // vertex is (i, t), 0 <= i < m, and 0 <= t <= g // store as (m * t + i) // 0-1 BFS const int M = 1e4 + 5, G = 1005; int n, m, g, r, d[M]; ll dist[M * G]; bool vis[M * G]; int main() { ios::sync_with_stdio(false); cin.tie(0); cin >> n >>...
ALGO
0.99971
3.623375
28cc3b1a-5aeb-4dd2-9f9f-a7fdddcee2b1
mazenhaouari40/Solved_Problem_Codeforces
B. Intercepted Inputs.cpp
#include<iostream> using namespace std; #include<algorithm> #include<vector> void solve(){ int k,vl; cin>>k; vector <int> t; for(int i=0;i<k;i++){ cin>>vl; t.push_back(vl); } sort(t.begin(),t.end()); int taille = k-2; int d,f=k-1,mil,nb=0; for(int i=0;i<k;i++){ ...
ALGO
0.999949
3.30412
55fb301a-d564-4d23-8b39-42974cbe6b55
ishandutta2007/codeforces
kostya_by/normal/228/D.cpp
#include <iostream> #include <cstdio> #include <cmath> #include <vector> #include <map> #include <set> #include <string> #include <cstring> #include <algorithm> #include <iomanip> #include <queue> #include <cstdlib> #include <ctime> #include <stack> #include <fstream> typedef unsigned long long ull; #define mp make_pa...
ALGO
0.999535
3.413333
8108eff4-3df3-4ec3-aaec-2463eeafe057
AdityaNikam-03/Programming
Searching/Square_Root.cpp
#include<iostream> #include<algorithm> using namespace std; float square_root(int n,int p) { int s=0,e=n,mid,i=0; float ans=0,inc=0.1; while(s<=e) { mid=(s+e)/2; if((mid*mid)==n) { cout<<"Exact"; return mid; } else if((mid*mid)<=n) ...
ALGO
0.999955
3.528119
7d811901-8bf1-4625-99be-7fca9a8ff766
sarvex/leetcode-giz
solution/0800-0899/0860.Lemonade Change/Solution.cpp
class Solution { public: bool lemonadeChange(vector<int>& bills) { int five = 0, ten = 0; for (int v : bills) { if (v == 5) ++five; else if (v == 10) { ++ten; --five; } else { if (ten) ...
ALGO
0.999756
6.129733
9907540c-d1bc-4324-b9a9-ade0d51f0edb
ishtiaquemahmud/folder
c++/123.cpp
#include<bits/stdc++.h> using namespace std; int main() { string a; cin>>a; for(int i=0;i<a.size();i+= 2) { for(int j=0;j<a.size()-1;j+=2) { if(a[j]>a[j+2]) { swap(a[j],a[j+2]); } } } cout<<a; }
ALGO
0.999993
3.943457
30ef796f-dac8-4b7b-92b6-5d70fbf68cf7
samarthcode1/CodeForces1
B_Array_Craft.cpp
#include <bits/stdc++.h> using namespace std; int main() { int t; cin >> t; while (t--) { int n, x, y; cin >> n >> x >> y; x--; y--; vector<int> v(n, 1); int shouldToggle = 1; for (int i = x + 1; i < n; i++) { if (shouldToggle...
ALGO
0.999874
4.272086
7ccaeff6-1a36-4d76-adac-c1d34a3f168b
duongtran1702/Session_2_Mynato_1702
bai_2.cpp
#include<stdio.h> int main(){ int a,b; printf("Nhap a :"); scanf("%d",&a); printf("Nhap b :"); scanf("%d",&b); int sum=a+b; printf("%d+%d=%d",a,b,sum); return 0; }
TOOL
0.976833
3.016919
5e37d373-eb71-4f49-a0c2-9eb7253bd22b
boostorg/compute
perf/perf_prev_permutation.cpp
#include <algorithm> #include <iostream> #include <numeric> #include <vector> #include <boost/compute/system.hpp> #include <boost/compute/algorithm/next_permutation.hpp> #include <boost/compute/algorithm/prev_permutation.hpp> #include <boost/compute/container/vector.hpp> #include "perf.hpp" int rand_int() { retu...
ALGO
0.998493
5.289071
3541db96-8dd0-4c80-8ec4-300d96ebd0c6
ethanboyuan/LeetCode
Anagrams.cpp
#include <vector> #include <iostream> #include <string> #include <unordered_map> using namespace std; class Solution { public: vector<string> anagrams(vector<string> &strs) { unordered_map<string, vector<string>> group; for(const auto &it :strs){ string key = it; sort(key.begin()...
ALGO
0.999956
5.754444
3c80e3e9-03d6-49fa-b0a3-8c14dc214016
nmessa/CPlusPlus---2024
Lab Exercise 2.9.2024/Problem 3/Problem 3/main.cpp
//Lab Exercise 2/9/2024 Problem 3 //Author: #include <iostream> #include <iomanip> using namespace std; //Define constant values #define QP 1.6e-19 #define QE 1.6e-19 #define K 9.0e9 #define M 9.11e-31 #define C 3e8 //Function prototype double calcVelocity(double); int main() { //Declare variables bool isValid =...
ALGO
0.996823
4.37484
c8cab3c7-67ac-499a-8476-a31b586068da
luoyang1998/C-code
code/function/funcCite.cpp
#include <iostream> using namespace std; template <typename Type1> void swap_C(Type1& a,Type1& b); void swap_A(int* a,int* b); void swap_B(int& a,int& b); int& CDE(int&c); int main() { int a = 200; int b = 500; cout << "ָ뷨" << endl; swap_A(&a,&b); cout << "a:" << a << " b:" << b << endl; co...
ALGO
0.988846
3.747088
cc32d3a3-eb00-4368-8902-b61fb632de87
D3ENNY/ripetizioni
C++/Es17/es17.cpp
#include<iostream> // data in input la quantità di numeri da prendere in input, calcolarne la somma complessiva int main(){ int n, val, tot=0; std::cout << "Inserire quanti numeri vuoi inserire: "; std::cin >> n; for (int i=0; i<n; i++){ std::cout << "\nInserire un numero: "; std...
ALGO
0.924431
3.798038
0393ae55-85a4-4981-9fbc-1b48f7ab53f1
Aditya-20BCE2275/Personal-practice
Graphs/tempCodeRunnerFile.cpp
#include <bits/stdc++.h> using namespace std; int main() { // n is the number of vertices // m is the number of edges int n, m; cin >> n >> m; int adjMat[n + 1][n + 1] = {0}; for (int i = 0; i < m; i++) { int u, v; cin >> u >> v; adjMat[u][v] = 1; adjMat[v][u...
ALGO
0.999946
4.114976
25f6279c-e11f-47ee-9aeb-75df2a11f956
ishandutta2007/codeforces
huangxiaohua/normal/1451/C.cpp
#include <bits/stdc++.h> using namespace std; typedef long long ll; #define M 998244353 int i,j,k,n,t,a[30],b[30]; char sb1[1005000],sb2[1005000]; int main(){ cin>>t; while(t--){ cin>>n>>k; cin>>sb1+1>>sb2+1; memset(a,0,sizeof(a)); memset(b,0,sizeof(b)); for(i=1;i<=n;i++){ a[sb1[i]-'a'+1]++; } for(...
ALGO
0.999988
4.935819
1beb0d63-6d4b-4e89-82f6-57b2b816ca2a
gabrielcassolbach/programming_training
cses-problem-set/Collecting Numbers II.cpp
#include <bits/stdc++.h> using namespace std; #define fastio ios_base::sync_with_stdio(false); cin.tie(0); typedef long long ll; vector<int> pos; vector<int> v; int n, m, ans; int solve(int pos_a, int pos_b) { int a = v[pos_a]; int b = v[pos_b]; map<int, bool> m; set<int> s; s.insert({a, b}); if(a +...
ALGO
0.999968
4.487061
66004444-d117-4ba1-b565-5ffc9749fe2c
limyunkai19/competitive-programming-codes
Competition/Shopee Code League 2022 - Final/i-event.cpp
#include <vector> #include <iostream> #include <unordered_set> using namespace std; class DisjointSet { private: int numSets; vector<int> parent, rank, setSize; public: DisjointSet(int n) { numSets = n; parent.assign(n, 0); rank.assign(n, 0); setSize.assign(n, 1); ...
ALGO
0.999961
5.215297
f3ed14f5-94c4-4682-843d-3e284eed875a
jeando/projetS7
src/test/dtw3.cpp
#include"../MyAL.h" #include"../traitement.h" #include"../sdl.h" #include<iostream> int main() { std::chrono::time_point<std::chrono::system_clock> time_1; std::chrono::time_point<std::chrono::system_clock> time_2; std::vector<ALshort> samples; std::vector<std::pair<std::vector<ALshort>,SF_INFO> >samples_ref; samp...
ALGO
0.97691
4.105579
2bf38064-9ba8-40e4-9201-977dff6fadf6
omarmorle/codeforces
1059A.cpp
#include <bits/stdc++.h> using namespace std; struct nodo { int t,l; }p[1000100]; int main(void) { int n,L,a; cin>>n>>L>>a; for(int i=0;i<n;i++) cin>>p[i].t>>p[i].l; int ans=0; ans+=p[0].t/a; for(int i=0;i<n-1;i++) { if(p[i].t+p...
ALGO
0.999138
3.103337