uuid
string
repo_name
string
relative_path
string
content
string
category
string
algo_rel_score
float64
quality_score
float64
59bfe8bb-284c-4a2b-a82e-a62bf7c9622b
PAMCH/Coding_Magic_Iron
OOJ_1124/OOJ_1124/OOJ_1124.cpp
#define _CRT_SECURE_NO_WARNINGS #include <iostream> #include <cmath> #define MIN2(X,Y) ((X)<(Y)?(X):(Y)) int k; int main() { int n, m; scanf("%d", &k); for (int i = 1; i <= k; i++) { scanf("%d %d", &n, &m); printf("%d\n", MIN2(n, m) * 2 - 2); } return 0; }
ALGO
0.999585
3.083974
0f5c829c-85eb-483d-bbe4-bbb17aeaafeb
Shruti785/coding
1912-number-of-restricted-paths-from-first-to-last-node/number-of-restricted-paths-from-first-to-last-node.cpp
class Solution { using pi = pair<int,int> ; using ll = long long ; vector<int> dp ; vector<bool> vis ; ll MOD = 1e9 + 7 ; vector<int> dijkstras(vector<vector<pi>> &adj){ const int n = adj.size() ; vector<int> dist(n,INT_MAX) ; dist[n - 1] = 0 ; priority_queue<pi,v...
ALGO
0.999987
5.199367
b36a43d3-b26c-4b47-bfd7-04a1a8aebc61
Ackerman666/UVA
Square(10364).cpp
#include<iostream> #include<algorithm> using namespace std; bool dfs(int m , int ini ,int sidelen , int sidenum , int curlen , bool instack[] , int stick[]){ //ini : qstick[ini]}lզX if(curlen==sidelen){ curlen=0; sidenum++; ini=1; if(sidenum==3) return(1); } for...
ALGO
0.999909
4.316265
411df260-64bb-406a-b2f0-756c594bb871
andrewzolotukhin/leetcode
P02462TotalCosts/solution.cpp
class Solution { public: long long totalCost(vector<int> &costs, int k, int candidates) { int n = costs.size(), l = 0, r = n - 1; priority_queue<pair<int, int>, vector<pair<int, int>>, greater<>> pq; long long ans = 0; for (int i = 0; i < candidates; i++) { pq.push({costs[l], l}); l++; ...
ALGO
0.999965
5.561685
0cb08d0e-1eb8-4932-b6c4-cb02ab3c67a2
groggi/eth-algolab
almost-antenna/main.cpp
#include <iostream> #include <cmath> #include <unordered_set> #include <CGAL/Exact_predicates_exact_constructions_kernel_with_sqrt.h> #include <CGAL/Min_circle_2.h> #include <CGAL/Min_circle_2_traits_2.h> #include <CGAL/number_utils.h> // typedefs typedef CGAL::Exact_predicates_exact_constructions_kernel_with_sqrt K;...
ALGO
0.999603
5.150412
b7e8461e-13d3-4351-85e1-4151feb36b47
Inquisitive-ME/PathPlanningProject
src/main.cpp
#include <fstream> #include <math.h> #include <uWS/uWS.h> #include <chrono> #include <iostream> #include <thread> #include <vector> #include "Eigen-3.3/Eigen/Core" #include "Eigen-3.3/Eigen/QR" #include "json.hpp" #include "spline.h" #include "vehicle.h" using namespace std; // for convenience using json = nlohmann:...
WEB
0.864697
4.193513
9284a3c0-aba8-473b-b6df-3b2e4fc6af2b
YuJuYu0209/Leetcode_practice
0070-climbing-stairs/0070-climbing-stairs.cpp
class Solution { public: int climbStairs(int n) { vector<int> num(n+1); num[0] = 1; num[1] = 1; for(int i = 2; i <= n ;i++) { num[i] = num[i-1] + num[i-2]; } return num[n]; } };
ALGO
0.999975
6.046863
2d433f84-239c-4f0c-b115-8ae40e1f5a29
sarvex/leetcode-algol
solution/2500-2599/2516.Take K of Each Character From Left and Right/Solution.cpp
class Solution { public: int takeCharacters(string s, int k) { int cnt[3] = {0}; for (char& c : s) ++cnt[c - 'a']; if (cnt[0] < k || cnt[1] < k || cnt[2] < k) return -1; int ans = 0, j = 0; int n = s.size(); for (int i = 0; i < n; ++i) { int c = s[i] - 'a'...
ALGO
0.999987
5.735839
7cb2ec14-9f52-4719-9a22-869dc5d98ac1
fy0/my-leetcode
015.3Sum/main3.cpp
// 日 hash 之后仍旧咸鱼 // 生活不易啊 #include <algorithm> struct VectorHash { size_t operator()(const std::vector<int>& v) const { std::hash<int> hasher; size_t seed = 0; seed ^= hasher(v[0]) + 0x9e3779b9 + (seed<<6) + (seed>>2); seed ^= hasher(v[1]) + 0x9e3779b9 + (seed<<6) + (seed>>2); ...
ALGO
0.999882
5.539339
03a6587b-614a-4235-af43-b8686bbd2f9d
leverimmy/Codes
比赛/学校/2019-12-14测试/source/PC25_imzzy/lcp.cpp
#include <bits/stdc++.h> #define ll long long #define rgi register int #define rgl register ll #define maxn 100005 #define mod 998244353 #define inf 1000000007 using namespace std; string s; signed main() { freopen("lcp.in","r",stdin); freopen("lcp.out","w",stdout); ios::sync_with_stdio(false); int n,m,x,y,len; c...
ALGO
0.999972
4.551359
b481b9f6-817a-4091-981b-5e6a9477bdbc
gauravdubey101/Programming-in-c_pluse_pluse
kadne_algo.cpp
#include<bits/stdc++.h> using namespace std; int kadne(int a[],int n){ int current_sum = 0; int best_sum = 0; for(int i =0;i <n;i++){ current_sum = current_sum + a[i]; if(best_sum <current_sum){ best_sum = current_sum; } if(current_sum <0){ current_sum =0; } } return best_sum; } ...
ALGO
0.999855
3.708415
7248b01c-c990-48dd-b021-85b1abe659fb
Ckaroll/EPCC_ADA
EjerciciosClase/Semana03/insertioSort.cpp
//simulación de Insertion-Sort en el array #include<iostream> #include<conio.h> using namespace std; int main(){ int numeros[] = {31,41,59,26,41,58}; //array de ejemplo int i,pos,aux; for(i=0;i<6;i++){ pos = i; aux = numeros[i]; while((pos>0) && (numeros[pos-1] > aux)){ numeros[pos] = numeros[pos-1]...
ALGO
0.999993
4.086536
ae4c6a9c-48d9-4cf4-a4d7-0c45a87fa4ee
Beman/boost-trunk-git-svn
libs/algorithm/minmax/example/minmax_ex.cpp
#include <list> #include <algorithm> #include <cstdlib> #include <cassert> #include <iostream> #include <boost/algorithm/minmax.hpp> #include <boost/algorithm/minmax_element.hpp> int main() { using namespace std; // Demonstrating minmax() boost::tuple<int const&, int const&> result1 = boost::minmax(1, 0); as...
TEST
0.996076
4.902635
641fdd8c-6a59-47cc-8c2f-a0816645785f
Vayne-Lover/Practice
BagsOf01/BagsOf01/main.cpp
#include <iostream> using namespace std; int findM(int N,int K,int G[],int W[]) { int *M=new int[N+1],i,j,k; for(i=0;i<N+2;i++) M[i]=0; for(i=0;i<K;i++) { for(j=N;j>=G[i];j--) { for(k=1;j-k*G[i]>=0;k++) { M[j]=M[j]>k*W[i]+M[j-k*G[i]]?M[j]:k...
ALGO
0.999885
3.091101
b2b0e3a3-f9cb-47b9-a20f-5b07cdbafd7e
ong-wei-hong/coding-problems
leetcode/11/main.cpp
#include <bits/stdc++.h> using namespace std; class Solution { public: int maxArea(vector<int>& height) { int l=0,r=height.size()-1,ans=0; while(l<r) if(height[l]>height[r]) { ans=max(ans,height[l]*(r-l)); int i=l+1; while(i<r&&height[i]<=height[l]) ++i; l=i; } else { ans=max(...
ALGO
0.999752
6.308574
a82a3965-3f5b-42f4-ab9f-1e596a4688d0
ishandutta2007/codeforces
roundgod/normal/1015/C.cpp
/************************************************************************* > File Name: C.cpp > Author: Roundgod > Mail: <EMAIL> > Created Time: 2018-07-31 22:44:00 ************************************************************************/ #pragma GCC optimize(3) #include<bits/stdc++.h> #define MAXN 1...
ALGO
0.999991
3.437183
f6c0e77a-3446-4cbd-a70e-5377ed16c2cc
lgccv/PCL
PCL_Examples/src/day03/01_normal_estimation.cpp
// // Created by ty on 20-8-5. // #include <iostream> #include <pcl/io/io.h> #include <pcl/features/normal_3d.h> #include <pcl/io/pcd_io.h> #include <pcl/visualization/cloud_viewer.h> #include <thread> using namespace std; /** * 评估点云法向量 * * NormalEstimation * * setInputCloud * * setIndices * * setSearchSurf...
ALGO
0.991889
3.866263
0612a412-c476-49fd-9710-fd7e690f70ef
tyeong1102/Algorithm
BOJ/BOJ_C++/1149_RGB거리.cpp
#include <iostream> #include <algorithm> using namespace std; /* 만약 빨간색을 칠하면 다음 집에서는 초록색과 파란색만 사용할 수 있기 때문에 전 배열의 최소값을 비교한 후 현재의 배열의 색을 더해주는 방법을 사용하였다. */ int a[1001][3]; // 가격 배열 int d[1001][3]; // 색 배열 int main(){ ios_base::sync_with_stdio(false); cin.tie(nullptr); cout.tie(nullptr); int n; c...
ALGO
0.999435
5.189013
c42e562d-4b03-499b-9bbd-c3512d7a588c
mctr909/BitmapTools
CommonLib/Declease.cpp
#include <iostream> #include <fstream> #include <string> using namespace std; #include "../CommonLib/Bitmap.h" #include "Declease.h" #pragma pack(push, 4) struct Declease::HISTOGRAM { uint8_t srcH; uint8_t srcS; uint8_t srcL; uint8_t dstH; uint8_t dstS; uint8_t dstL; uint8_t reserved; uint8_t palette; uint3...
ALGO
0.964176
3.778695
d90bf7ba-176b-426b-9a28-eed423f4d80b
MirYeasirAbrar/CodeQuest-to-Career
Codeforces/ICPC-Preparation/ICPC Assiut University Community/Sheet #1 (Data type - Conditions)/D. Difference.cpp
#include <bits/stdc++.h> using namespace std; int main() { long long int a,b,c,d; cin >> a >> b >> c >> d; cout << "Difference = " << (a*b) - (c*d) << endl; return 0; }
ALGO
0.997621
4.331484
05762278-f8bc-48a7-ac60-b4c2dd1b74e8
keshav-goswami/DSA
TREES/Bottom_view.cpp
#include<bits/stdc++.h> using namespace std; struct Node{ int data; Node* left; Node* right; Node(int val){ data = val; left = right = NULL; } }; vector<int> topView(Node *root){ vector<int> vp; if(!root) return vp; queue<pair<Node*,int>> q; map<int,int> mp; q.pu...
ALGO
0.999996
4.714767
64902902-6dea-4168-af46-10b7e04b61cc
Wimpi18/Training_for_the_ICPC
Codeforces/Nivel A/A. Minimal Square.cpp
#include <iostream> #include <bits/stdc++.h> using namespace std; int main() { ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0); long long casos, ladoA, ladoB, resultado; cin >> casos; for (long long c = 0; c < casos; c++) { cin >> ladoA >> ladoB; if (ladoA == ladoB)...
ALGO
0.999909
5.047999
42547182-715c-4d0f-a127-07bfba6121ef
rpuntaie/c-examples
cpp/numeric_valarray_tanh.cpp
/* g++ --std=c++20 -pthread -o ../_build/cpp/numeric_valarray_tanh.exe ./cpp/numeric_valarray_tanh.cpp && (cd ../_build/cpp/;./numeric_valarray_tanh.exe) https://en.cppreference.com/w/cpp/numeric/valarray/tanh */ #include <cmath> #include <iostream> #include <valarray> auto show = [](char const* title, const std::valar...
TEST
0.920246
7.050096
b0cf9073-7d7c-4984-b0d7-b396f6f542bd
Arsh-ak7/-6Companies30Days
Amazon/colNameFromNUmber.cpp
string colName(long long int n) { // your code here string temp = ""; while (n > 0) { char ch = 'A' + (n - 1) % 26; temp = ch + temp; n = (n - 1) / 26; } return temp; }
ALGO
0.999785
4.38428
22f87a92-b9f5-41e0-9700-86791b3ee81e
Amit-Kumar2244/dsa-by-amit
Linked List/C++/LC 3217 - DELETE NODES FROM LINKED LIST PRESENT IN ARRAY.cpp
// LEET CODE 3217 - DELETE NODES FROM LINKED LIST PRESENT IN ARRAY // QUESTION LINK - https://leetcode.com/problems/delete-nodes-from-linked-list-present-in-array/ class Solution { public: ListNode* modifiedList(vector<int>& nums, ListNode* head) { ListNode* temp = nullptr; ListNode* prev = nullptr...
ALGO
0.999961
6.930525
89464af4-e932-4d84-b5f1-409867a2a296
kmjp/procon
2017-2021/2017/ddcc/final/c.cpp
#include <bits/stdc++.h> using namespace std; typedef signed long long ll; #undef _P #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 ITR(x,c) for(__typeof(c.begin()) x=c.begin();x!=c.end();x++) #define ALL(a) (a.begin()),(a.end()) #define ZER...
ALGO
0.999976
3.609089
a12aa609-b36f-4dcf-945b-ac3c2e11af5a
deepakantony/audio_plugins
VolumeControldB/JuceLibraryCode/modules/juce_cryptography/encryption/juce_Primes.cpp
namespace PrimesHelpers { static void createSmallSieve (const int numBits, BigInteger& result) { result.setBit (numBits); result.clearBit (numBits); // to enlarge the array result.setBit (0); int n = 2; do { for (int i = n + n; i < numBits; i += n) ...
ALGO
0.999797
7.559035
07082a5e-8771-45a6-9f2d-6a43265b2578
blithersoup/cses-solutions
02_sorting_and_searching/01_distinct_numbers.cpp
#include <iostream> #include <vector> #include <algorithm> using namespace std; int main() { int n; cin >> n; vector<int> v (n); for (int i = 0; i < n; i++) cin >> v[i]; int ret = n; sort(v.begin(), v.end()); for (int i = 1; i < n; i++) if (v[i] == v[i - 1]) ret--; cout << ret << "\n"; }
ALGO
0.999936
4.071465
4271557d-52dc-4afc-bdaf-6c3eeb52ba26
MichaelSedrak/Interactive-ARAP
ARAP/libs/libigl-2.2.0/include/igl/boundary_conditions.cpp
#include "verbose.h" #include "EPS.h" #include "project_to_line.h" #include <vector> #include <map> #include <iostream> IGL_INLINE bool igl::boundary_conditions( const Eigen::MatrixXd & V , const Eigen::MatrixXi & /*Ele*/, const Eigen::MatrixXd & C , const Eigen::VectorXi & P , const Eigen::MatrixXi & BE...
ALGO
0.972562
6.247374
e5d03eb4-e6ff-471c-9180-a932e58780b9
hoolighten/100joon
17626.cpp
#include<iostream> #include<algorithm> #include<vector> #include<limits.h> using namespace std; int main() { ios::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); int n; cin >> n; vector<int>dp(n + 1, 0); dp[1] = 1; for (int i = 2; i <= n; i++) { int Min = 500001; for (int j = 1; j * j <= i; ...
ALGO
0.999947
4.155244
f79dede3-8e35-40cf-a3b7-7f506896e98a
avinash201199/DSA-Questions
BST/C++/CheckforBalancedTree.cpp
/*Question statement:A binary tree is given to you.Check if it is height balanced or not.A tree is considered height balanced if difference between heights of left subtrees and right subtrees is not more than 1 for all the nodes present in the tree.*/ #include <iostream> #include<cmath> using namespace std; class node...
ALGO
0.999922
4.479195
4920f4d9-4985-4078-b2e5-3a25b6886b23
DelaplaineRomain/projet_jeu_tsi
projet_tsi/tools/glhelper.cpp
/*****************************************************************************\ * TP CPE * * ------ * * Fonctions d'aides pour OpenGL (affichage d'erreur, chargement de shaders, etc) * \*************************************************************...
TOOL
0.928741
4.13684
4729cf8d-80c3-472b-8b12-2f7df59bd3d5
FedericoMazzone/openfhe-statistics
openfhe-development-1.1.2/benchmark/src/NbTheory.cpp
/* * This code benchmarks number theory operations. */ #define _USE_MATH_DEFINES #include "lattice/lat-hal.h" #include "benchmark/benchmark.h" #include <iostream> using namespace lbcrypto; //================================== // GCD benchmarks // this benchmark returns a reference to a BBI which can be used for...
TEST
0.965553
6.887244
ea0604cf-fe3c-4aba-a779-fb71ad55e48c
rishi058/CP-DSA
Helpful Codes 2/PRIME+SEIVE.cpp
#include <bits/stdc++.h> using namespace std; #define int long long #define all(v) v.begin(), v.end() #define F(a,b,i) for (int i = a; i < b; i++) #define RISHI ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0); typedef long double ld; typedef vector<int> vi; //-----------------------------------------------------...
ALGO
0.999781
3.308401
6927e5d6-bdf2-4050-aa10-1875f08c0c8c
imopse/iMOPSE
optimizer/src/method/operators/crossover/crossovers/CUniformCX.cpp
#include "CUniformCX.h" #include "../../../../utils/random/CRandom.h" void CUniformCX::Crossover(const SProblemEncoding& problemEncoding, AIndividual &firstParent, AIndividual &secondParent, AIndividual &firstChild, AIndividual &secondChild) { const size_t sect...
ALGO
0.999756
5.090652
3beed3ef-42ac-4708-90b2-37ab9653660c
Santoroclass/moder_login_ui
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
b3dca764-f484-4ad3-a82b-b412ee2aa79b
victor110406/BOJ_Programmers.Cpp
코드업/1265.cpp
#include<iostream> using namespace std; int main() { int a; cin >> a; for (int i = 1; i <= 9; i++) { cout << a << "*" << i << "=" << a * i << endl; } return 0; }
ALGO
0.99903
3.405527
a8a15405-4e0c-4f2f-8057-c8f2aa0ce532
jk1ash/LeetCode
400.第-n-位数字.cpp
/* * @Author: jklash * @Description: 第 N 位数字 * @Date: 2021-11-30 09:55:35 * @LastEditors: jklash * @LastEditTime: 2021-11-30 10:22:01 */ /* * @lc app=leetcode.cn id=400 lang=cpp * * [400] 第 N 位数字 */ #include <iostream> #include <vector> #include <algorithm> #include <cmath> using namespace std; // @lc code=s...
ALGO
0.999896
6.781292
baed829e-f210-4308-90d8-71e78e8c4e33
dinogrgic1/fer-design-patterns-labs
lab2/lab2_5/src/ObserverMedian.cpp
#include "ObserverMedian.hpp" #include <iostream> #include <numeric> #include <algorithm> void ObserverMedian::update(std::vector<int> nums) { int size = nums.size(); std::sort(nums.begin(), nums.end()); if (size % 2 == 0) std::cout << "median: " << (nums[size / 2. - 1] + nums[size / 2.]) / 2. << ...
ALGO
0.999695
6.304692
b237cf8b-c98b-48fe-b5b0-53082a989927
derinu/FlyFF
Source/boost_1_50_0/libs/algorithm/string/example/predicate_example.cpp
// Boost string_algo library example file ---------------------------------// // See http://www.boost.org for updates, documentation, and revision history. #include <string> #include <iostream> #include <functional> #include <boost/algorithm/string/predicate.hpp> #include <boost/algorithm/string/classification.hpp...
TOOL
0.873145
6.180994
23f6437c-12a0-454b-b4c6-873faf963da3
navaljangir/DSA_A2Z
Trees/(gfg)ConstructTreeFromInorderAndPreOrderTraversal.cpp
class Solution{ public: int pos(int in[] , int n ,int i , int j, int element){ for(int k = i ; k<=j ; k++){ if(in[k]==element){ return k; } } return -1; } Node* solve(int in[] , int pre[] , int&n , int inOrderStart ,int inOrderEnd, int&...
ALGO
0.999998
6.398274
5d561fd7-cd63-4b50-be9c-be63469940d9
Mritunjay1729/Codeforces
Traffic_lights.cpp
#include <iostream> #include <iomanip> using namespace std; int main() { double l, d, v, g, r; cin >> l >> d >> v >> g >> r; double time = 0; time+=d/v; double k = time-(g+r)*(int)(time/(g+r)); if(k >= g) time+=(g+r)-k; time+=(l-d)/v; cout << fixed << setprecision(10) << time << endl; ...
ALGO
0.999231
3.449615
69406cd3-b224-408d-bf71-59626cbea032
mouryagutha/ciperschools
Lecture30-II-CipherSchools/lecture30-II.cpp
#include<iostream> using namespace std; class Queue { public: int queue[1000]; int size; int front; int rear; int max_capacity; Queue() { this->front = 0; this->rear = -1; this->max_capacity=1000; this->size=0; } enqueue(int data) { ...
ALGO
0.954264
3.728742
52659d88-aae6-44cd-b97a-974a43a9fa70
frankantony/beecrowd-solution
teste.cpp
#include <bits/stdc++.h> using namespace std; int main() { char first[] = { 'a', 'b', 'c', 'd', 'e' }; char second[] = { 'd', 'e','z','y'}; // char first[100],second[100]; // cin >> first; // cin >> second; int n = sizeof(first) / sizeof(first[0]); vector<char> v2; vector<char>::iterator it, ls; sort(first, f...
ALGO
0.999754
3.077106
bf3799f6-3335-4469-8af0-91fd4c714722
tusharshah21/Let-us-C-19th-Edition
3_Decision_control_instruction/axis_or_origin.cpp
// Given a point (x, y), write a program to find out if it lies on x-axis, yaxis or origin. #include <stdio.h> int main() { int x, y; printf("\nEnter the coordinates of point: "); scanf("%d%d", &x, &y); if (x == 0 && y == 0) printf("\nPoint lies on origin\n"); else if (x == 0) print...
ALGO
0.993477
4.338423
649ec658-e95a-406b-9829-5f1bf7963ebc
ishandutta2007/codeforces
kostia244/normal/920/A.cpp
#pragma comment(linker, "/stack:200000000") //#pragma GCC optimize("Ofast") #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native") #pragma GCC optimize ("trapv") #include<bits/stdc++.h> #include<ext/pb_ds/tree_policy.hpp> #include<ext/pb_ds/assoc_container.hpp> #define pb push_back #define __V ve...
ALGO
0.999946
4.202363
f7b0e544-7f80-4eb3-83ab-feedadeef706
RecStore/RecStore
third_party/gpudirect-nvme/include/freestanding/libcxx/test/std/algorithms/alg.modifying.operations/alg.replace/replace_copy.pass.cpp
// <algorithm> // template<InputIterator InIter, typename OutIter, class T> // requires OutputIterator<OutIter, InIter::reference> // && OutputIterator<OutIter, const T&> // && HasEqualTo<InIter::value_type, T> // constexpr OutIter // constexpr after C++17 // replace_copy(InIter first, InIte...
TEST
0.968775
6.625417
967be080-dfc6-46f5-96c5-29b3bb0c5665
Delthin/leetcode-solution
leetcode/editor/cn/[686]重复叠加字符串匹配.cpp
/** 给定两个字符串 a 和 b,寻找重复叠加字符串 a 的最小次数,使得字符串 b 成为叠加后的字符串 a 的子串,如果不存在则返回 -1。 注意:字符串 "abc" 重复叠加 0 次是 "",重复叠加 1 次是 "abc",重复叠加 2 次是 "abcabc"。 示例 1: 输入:a = "abcd", b = "cdabcdab" 输出:3 解释:a 重复叠加三遍后为 "abcdabcdabcd", 此时 b 是其子串。 示例 2: 输入:a = "a", b = "aa" 输出:2 示例 3: 输入:a = "a", b = "a" 输出:1 示例 4: 输入:a = "abc...
ALGO
0.999889
5.916597
e30e5e39-27c7-41d7-826b-e43ae3ea1bec
dune-sn-online-pointing/online-pointing-utils
app/match_clusters.cpp
#include <vector> #include <iostream> #include <fstream> #include <string> #include <ctime> #include <nlohmann/json.hpp> #include "CmdLineParser.h" #include "Logger.h" #include "position_calculator.h" #include "cluster_to_root_libs.h" #include "cluster.h" #include "match_clusters_libs.h" LoggerInit([]{ Logger::get...
DATA
0.91031
4.253163
77a22cfc-4e00-4d9d-8493-7dc36b72dd36
jakjank/KursyUWr_UP
kurs_C++/zad12/z5.cpp
#include <iostream> #include <functional> using namespace std; int main() { // [&] znaczy że przechowujemy wszystkie rzeczy w lambdzie przez referencje function<void(int)> collatz = [&](int n) { cout << n << " "; if (n == 1) { return; } if (n % 2 == 0) { ...
ALGO
0.999833
6.371397
f6722f3b-260d-475a-9892-cd8af46e83ce
rocmarchive/HCC_syscall
amp-conformance/amp_test_lib/src/device.cpp
namespace { template<typename T> inline bool has_bits_set(T val, T bits) { static_assert(sizeof(T) == sizeof(int), "has_bits_set requires the parameter type T to be the same size as an int."); return (static_cast<int>(val) & static_cast<int>(bits)) == static_cast<int>(bits); } template<typename T> inline b...
TEST
0.921755
7.286067
15d771ea-1132-4c32-88b5-74c136f65bea
DipanshuRaj2/Striver-A2Z-sheet-DSA
LeetCode_Solution/String/Largest_Odd_Number_In_String.cpp
/*1903. Largest Odd Number in String Easy Topics Companies Hint You are given a string num, representing a large integer. Return the largest-valued odd integer (as a string) that is a non-empty substring of num, or an empty string "" if no odd integer exists. A substring is a contiguous sequence of characters within a...
ALGO
0.999889
5.619305
624963a9-5387-4910-83b9-1e82c50af315
ishandutta2007/codeforces
ngochai94/normal/717/C.cpp
#include <bits/stdc++.h> using namespace std; #define For(i,a,b) for(int i=a;i<b;i++) #define reset(a,b) memset(a,b,sizeof(a)) #define mod 10007 #define pi acos(-1) #define eps 0.00000001 #define pb push_back #define off 250555 long long n,lis[100005],ans; int main(){ //freopen("input.txt","r",stdin); //freop...
ALGO
0.999974
4.006441
543f5fa3-5919-4ea5-a772-bfedd9114f53
dwi-ayush/codepsit
Semester2/LECTURE25/find_subsequences.cpp
// write a program in cPP to find all subsequences of an array // write a program in cPP to find all subsequences that sum up to a particular value //Subset sum - I #include <iostream> #include <vector> using namespace std; void findSubsequence(vector<int>& arr,int ind,vector<int> & current,int N){ if (ind == N)...
ALGO
0.999623
5.404308
72dcc6c0-5955-48df-882e-a31873c4b656
mollnn/conditional-mixture
mts3/src/integrators/volpath.cpp
NAMESPACE_BEGIN(mitsuba) template <typename Float, typename Spectrum> class VolumetricPathIntegrator : public MonteCarloIntegrator<Float, Spectrum> { public: MI_IMPORT_BASE(MonteCarloIntegrator, m_max_depth, m_rr_depth, m_hide_emitters) MI_IMPORT_TYPES(Scene, Sampler, Emitter, EmitterPtr, BSDF, BSDFPtr, ...
ALGO
0.987716
6.640399
7ef7a495-49ae-44ef-b1fc-8cf793132572
andreiarnautu/Algorithmic-Problems-Part-3
cycle_string.cpp
/** * Worg */ #include <string> #include <vector> #include <cstdlib> #include <iostream> #include <algorithm> const int TETA = 26; void print_after_frequency(std::vector<int>& freq) { std::cout << "YES\n"; for (int i = 0; i < TETA; i++) { char ch = 'a' + i; for (int j = 0; j < freq[i]; j++) { std::cout...
ALGO
0.999988
3.524907
d904327b-322d-49d6-b47b-cf4f8fcd4ca3
gondshailesh/cpp-programming
C++ Tutorial/p190.cpp
// logical #include<iostream> using namespace std; int main() { int n1, n2, sum = 0; cout<<"enter first number : "; cin>>n1; cout<<"enter second number : "; cin>>n2; for(int i = n1; i<=n2; i++) { sum = ((i % 10000 - i % 1000)/1000) + ((i % 1000 - i % 100)/100) + ((i % 100 - i % 10)...
ALGO
0.995834
3.344758
7dd42e6c-4725-4c33-96a0-b1b99e0bfde0
sslab-gatech/juxta
llvm/tools/clang/lib/Analysis/UninitializedValues.cpp
#include "clang/AST/ASTContext.h" #include "clang/AST/Attr.h" #include "clang/AST/Decl.h" #include "clang/AST/StmtVisitor.h" #include "clang/Analysis/Analyses/PostOrderCFGView.h" #include "clang/Analysis/Analyses/UninitializedValues.h" #include "clang/Analysis/AnalysisContext.h" #include "clang/Analysis/CFG.h" #include...
TOOL
0.904735
7.789063
3245850f-8288-47b6-84bd-9995151ea6d5
ThLentzas/leetcode
48/main.cpp
#include <iostream> #include <vector> #include <algorithm> /* * 48. Rotate Image You are given an n x n 2D matrix representing an image, rotate the image by 90 degrees (clockwise). You have to rotate the image in-place, which means you have to modify the input 2D matrix directly. DO NOT allocate anothe...
ALGO
0.999224
7.077253
967f25e1-0fda-4b80-8de1-f3c36aebc554
khaledman6122/how-to-C-plus-plus
not sorted/Untitled17.cpp
#include <iostream> #include <string> #include <algorithm> using namespace std ; int main () { string line,result; getline(cin,line); for(int i=0;i<line.length();i++) { if(isalpha(line[i])) result+=line[i]; } cout<<result<<endl; result.erase(unique(result.begin(),result.end()),result.end()); cout<<result<...
ALGO
0.998851
4.390004
5390bc99-aebd-4223-8cd1-21a3d464fae9
pingdynasty/OwlSim
JuceLibraryCode/modules/juce_audio_utils/native/juce_android_BluetoothMidiDevicePairingDialogue.cpp
//============================================================================== #define JNI_CLASS_MEMBERS(METHOD, STATICMETHOD, FIELD, STATICFIELD) \ METHOD (getMidiBluetoothAddresses, "getMidiBluetoothAddresses", "()[Ljava/lang/String;") \ METHOD (pairBluetoothMidiDevice, "pairBluetoothMidiDevice", "(Ljava/lang/Str...
TOOL
0.977582
3.982696
19063e03-c50f-4fa4-ac52-a35803b87d95
Neeraj-Koshyari/2nd_Year_coding
Graph/Bipartite_Graph.cpp
#include<bits/stdc++.h> using namespace std; vector<vector<int>> graph(6); vector<bool> vis(6,false); vector<int> clr(6,-1); bool ans=true; void color(int u,int cl){ if(clr[u]!=-1 && clr[u]!=cl){ ans=false; return; } clr[u]=cl; if(vis[u]) return; vis[u]=true; for(int i=0;i<graph[u].size();i++) color(gra...
ALGO
0.999994
5.329877
ecb7bbea-6d37-4842-ace9-25e8b0fa33e6
Hong-JinSuk/Emsys-AlgorithtmStudy
Hong-JinSuk/[4-1][11주차][골드5]BaekJoon_5582, 공통 부분 문자열(DP).cpp
#include<iostream> #include<algorithm> using namespace std; string F, S; int dp[4002][4002] = { 0, }; int MAX = 0; int main() { cin >> F >> S; for (int i = 0; i < F.length(); i++) { for (int j = 0; j < S.length(); j++) { if (F[i] == S[j]) { // ڿ ġϸ dp[i + 1][j + 1] = dp[i][j] + 1; // 밢 1 ޾ƿ´. } ...
ALGO
0.999779
3.85632
8f3cdb42-de06-4ff1-a4a3-6ddfbbbe96d8
milkyway20021012/Leetcode
linked-list/linked-list-cycle.cpp
/** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode(int x) : val(x), next(NULL) {} * }; */ class Solution { public: bool hasCycle(ListNode *head) { ListNode* slow = head; ListNode* fast = head; while(fast && fast->next){ ...
ALGO
0.999802
5.388882
94a59037-1cea-4a85-8721-59eb79350ec0
THEKNIGHTPROTOCOL/Leetcode
2054. Two Best Non-Overlapping Events.cpp
#include <vector> #include <algorithm> using namespace std; class Solution { public: int maxTwoEvents(vector<vector<int>>& events) { sort(events.begin(), events.end()); int n = events.size(); vector<pair<int, int>> best; int res = 0, maxVal = 0; for (int i = n - 1; i >= 0; ...
ALGO
0.999677
6.104805
4fc0312a-b35d-4142-b4ab-1c8764912a90
CIBC-Internal/boost
libs/msm/doc/PDF/examples/SimpleTimer.cpp
#include <vector> #include <iostream> #include <boost/msm/back/state_machine.hpp> #include <boost/msm/front/euml/euml.hpp> using namespace std; using namespace boost::msm::front::euml; namespace msm = boost::msm; // how long the timer will ring when countdown elapsed. #define RINGING_TIME 5 namespace // Concrete F...
TOOL
0.94977
6.781747
33a80d0b-0a0e-4f4f-8213-3e2302490013
deepam20050/competitive-programming
solutions/593B.cpp
#include "bits/stdc++.h" using namespace std; #define sz(x) int((x).size()) #define all(x) begin(x), end(x) #define eb emplace_back #define em emplace #define mp make_pair #define F first #define S second #define FOR(i, a, b) for (int i = (a); i < (b); ++i) #define lb lower_bound #define ub upper_bound using lli = lo...
ALGO
0.999923
3.52491
2ae574bb-1711-49a6-b1b8-b68b4957dc4e
The-No-Hands-company/RudeBase3D
third_party/libigl/libigl-2.5.0/include/igl/embree/shape_diameter_function.cpp
template < typename DerivedP, typename DerivedN, typename DerivedS > IGL_INLINE void igl::embree::shape_diameter_function( const igl::embree::EmbreeIntersector & ei, const Eigen::PlainObjectBase<DerivedP> & P, const Eigen::PlainObjectBase<DerivedN> & N, const int num_samples, Eigen::PlainObjectBase<Deri...
ALGO
0.997655
6.850093
9dffec5e-51c6-469a-8cf2-8f065ba9b6ed
lcdbezerra/pdi
buracos.cpp
#include <iostream> #include <opencv2/opencv.hpp> using namespace cv; using namespace std; int main(int argc, char** argv){ if (argc != 2){ cout << "\tArgumento invalido" << endl << "\t./buracos [imagem]" << endl; return 0; } Mat image, mask; CvPoint p; int fill = 0, nobjects = 0, nburacos = 0; p.x = 0; ...
ALGO
0.894365
4.93249
1199a42d-28b8-4105-9715-7a09d36bf725
Trinadh465/frameworks_av_CVE-2023-20933
media/libstagefright/MediaCodecListOverrides.cpp
//#define LOG_NDEBUG 0 #define LOG_TAG "MediaCodecListOverrides" #include <utils/Log.h> #include "MediaCodecListOverrides.h" #include <cutils/properties.h> #include <gui/Surface.h> #include <media/ICrypto.h> #include <media/IMediaCodecList.h> #include <media/MediaCodecInfo.h> #include <media/MediaResourcePolicy.h> #i...
TOOL
0.871588
7.049749
399f76f6-c8a9-46d7-bd32-cdd255d66fec
StudyingFather/my-code
Codeforces/978A.cpp
#include <stdio.h> int t[1005],n,a[55],ans[55],cnt; int main() { scanf("%d",&n); for(int i=1;i<=n;i++) scanf("%d",&a[i]); for(int i=n;i>=1;i--) { t[a[i]]++; if(t[a[i]]==1)ans[++cnt]=a[i]; } printf("%d\n",cnt); for(int i=cnt;i>=1;i--) printf("%d ",ans[i]); return 0; }
ALGO
0.999988
3.527408
a69048bf-6071-4aef-9e7e-de01778c6485
JustBeYou/infoarena
infoarena/probleme/ferma.cpp
#include <bits/stdc++.h> using namespace std; int v[10000]; int main() { freopen("ferma.in", "r", stdin); //freopen("ferma.out", "w", stdout); int n, k; cin >> n >> k; for (int i = 0; i < n; i++) { cin >> v[i]; } int sol = 0; for (int i = 0; i < k; i++) { int sum = 0; int start, finish, ...
ALGO
0.999979
3.758586
54c33f47-2883-4731-b23b-d018fefd69bf
himanshumaharshi/LeetCode-DSA
42-trapping-rain-water/trapping-rain-water.cpp
class Solution { public: int trap(vector<int>& height) { int n = height.size(); if (n == 0) return 0; vector<int> left(n); vector<int> right(n); // Fill left array left[0] = height[0]; for (int i = 1; i < n; i++) { left[i] = max(left[...
ALGO
0.999994
7.284719
79ecba32-ca22-4708-9b52-7eb22b114480
LocalClustering/HeidelbergMotifClustering
experimental_data/Faster Local Motif Clustering via Maximum Flows/algorithms/SOCIAL/lib/partition/uncoarsening/refinement/quotient_graph_refinement/flow_refinement/flow_solving_kernel/cut_flow_problem_solver.cpp
/****************************************************************************** * cut_flow_problem_solver.cpp * * * XXX. * XXX *****************************************************************************/ #include <fstream> #include <iostream> #include <map> #include <math.h> #include <sstream> #include <unorde...
ALGO
0.994296
4.804472
d87d331c-53f3-43e5-8916-555326554cd4
kves/flutter_simple_shop_app
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
e827f5da-c8d5-481d-9896-3fa378b53450
rogacky11/sorting
asdasdasdasdasdasdasdasd/bucketSort.cpp
#include "bucketSort.h" #include "FilmData.h" #include <algorithm> #include <iostream> void bucketSort(vector<FilmData>& arr) { int max = arr[0].filmRating; int min = arr[0].filmRating; for (int i = 1; i < arr.size(); i++) { if (arr[i].filmRating < min) { min = arr[i].filmRating; } else if (arr[i].filmRat...
ALGO
0.999134
4.931626
a21e664a-e254-49fa-a907-b4dfaefdd97a
raskarabhi45/Codes
program158.cpp
//if letter is capital then make letters in lowercase to upper case /* Enter String Abhi Raskar String in upper case ABHI RASKAR */ #include<iostream> using namespace std; void struprX(char str[]) { int cnt=0; while(*str!='\0') { if((*str>='a')&&(*str<='z')) { *str=*str-32; ...
ALGO
0.977302
4.279647
e4045bfc-f09b-443a-8a48-b8544ceaa88e
rueiminl/Leetcode
Maximum Subarray.cpp
class Solution { public: int maxSubArray(vector<int>& nums) { if (nums.empty()) return 0; // max_sub_array[i] := max sum end at i vector<int> max_sub_array(nums.size()); max_sub_array[0] = nums[0]; int result = max_sub_array[0]; for (int i = 1; i < nums.size(); i++) { max_sub_array[i] = nums[i] + max...
ALGO
0.999919
6.328846
b29cc25e-9962-476e-87b5-dbce1cb76253
07Sushant/C-Plus-Journey-
Academic/DPP/Unit 4/Pavani.cpp
#include <iostream> using namespace std; class Distance { private: int feet; int inches; public: Distance() : feet(0), inches(0) {} Distance(int feet, int inches) : feet(feet), inches(inches) {} void displayDistance() { cout << feet << "' " << inches << endl; } // Overload the unary operator - to...
TOOL
0.85148
4.926758
eee92d69-414f-41cf-bf13-314b588c7f62
melody413/JUCE_project
modules/juce_dsp/frequency/juce_FFT.cpp
namespace juce { namespace dsp { struct FFT::Instance { virtual ~Instance() = default; virtual void perform (const Complex<float>* input, Complex<float>* output, bool inverse) const noexcept = 0; virtual void performRealOnlyForwardTransform (float*, bool) const noexcept = 0; virtual void performRealOnl...
ALGO
0.932751
6.908769
09b69180-d43d-442e-bd80-220b06204c63
resist15/platform_hardware_qcom_display
sdm/libs/utils/rect.cpp
#include <math.h> #include <utils/rect.h> #include <utils/constants.h> #include <algorithm> #define __CLASS__ "RectUtils" namespace sdm { bool IsValid(const LayerRect &rect) { return ((rect.bottom > rect.top) && (rect.right > rect.left)); } bool IsCongruent(const LayerRect &rect1, const LayerRect &rect2) { retu...
TOOL
0.967085
7.006063
d3a5929b-681d-4c83-8a27-7253e990af0b
WIZARD-CXY/pl
leetcode2/sumroot2leafnumbers.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 Solution { public: int sumNumbers(TreeNode* root) { int sum=0; helper(root,0,sum); ...
ALGO
0.999965
6.355498
dcce48f1-c3c2-470b-b7a4-622ef10256f9
mefisto385/HRinformatics
HONI/labirint.cpp
#include <bits/stdc++.h> using namespace std; const int maxn = 107; char vrata[maxn][maxn][maxn][maxn]; int n, m, q; int dists[maxn][maxn]; int runSolver(int ai, int bi, int ci, int di, int blue, int green, int yellow, int red){ queue<pair<int, int>> q; q.push({ai, bi}); for(int i = 0; i < n; i++){ for(int j...
ALGO
0.999523
4.616642
262710ac-a529-40a2-8466-6000622c938c
TrisTaNarchie2589/OHEebjiLY
Array/12. Count pairs with given sum.cpp
//Initial template for C++ #include <bits/stdc++.h> using namespace std; // } Driver Code Ends //User function template for C++ class Solution{ public: int getPairsCount(int arr[], int n, int k) { // code here unordered_map<int, int> m; int ans = 0; for(int i = 0; i < n; i+...
ALGO
0.999692
5.208259
a0a38b96-7d8f-494e-a177-69c3f76cba85
HPCL/pedestrian-counting
object.cpp
#include "object.h" using namespace std; using namespace cv; /*************************** Constructors ***************************/ Object::Object() { is_found = false; } Object::Object(const vector<Point> &contour) { Moments temp_moment = moments(contour); center = Point2d(temp_moment.m10/temp_moment.m00 , te...
TOOL
0.946364
5.779343
ea22d184-07d9-435d-ab11-3879ed71dbbd
113bommy/deepmind_codecontests_refine
cpp_gold_filter_file/cpp_train_8151_21.cpp
#include <bits/stdc++.h> using namespace std; int main() { int n, k, l, c, d, p, nl, np; cin >> n >> k >> l >> c >> d >> p >> nl >> np; int x = k * l / nl; int y = c * d; int z = p / np; cout << min(z, min(x, y)) / n; return 0; }
ALGO
0.999324
3.489407
1ecad6ea-015e-4b40-bc55-9c9c365a2e33
fatimafdez/rpg_ultimate_slam_open
imp/imp_correspondence/src/klt_neon.cpp
#ifndef __ARM_NEON__ //# error "This file requires NEON support. Check your compiler flags." #else # include <arm_neon.h> #endif #include <imp/correspondence/patch_utils.hpp> #include <imp/correspondence/klt.hpp> namespace ze { KltResult alignPatchNeon( const KltParameters& params, const uint8_t* __restrict_...
ALGO
0.999725
5.638695
3fc98bc0-483f-40b8-9fbe-40d569c5c51e
tushar04mishra/coding
c++/graph/topologial_sort_kahn_algo.cpp
#include <bits/stdc++.h> using namespace std; vector<list<int>> graph; int v; void add_edge(int src, int dest, bool bi_dir = true) { graph[src].push_back(dest); if(bi_dir) graph[dest].push_back(src); } void topoBFS() { vector<int> indegree(v,0); for(int i = 0; i>graph.size(); i++) { fo...
ALGO
0.99999
5.361721
a78b0e9e-c654-4235-aca0-799fb0a84cfc
Priyanshu2022/crackYourInternship
zday11/removeAllAdjacentDuplicatesInString2.cpp
// if k duplicates are together remove them // stack of char ,int (count of that element) // st.top has same char increment it's count // if count==k st.pop() // now form the ans string string removeDuplicates(string s, int k) { stack<pair<char,int>> st; for(int i=0;i<s.length();i++){ if(st...
ALGO
0.999744
4.822809
20f5c4ca-5cc4-49ac-9caf-e421249b86f3
ishandutta2007/codeforces
rafbill/normal/668/A.cpp
#pragma GCC optimize ("-O3") #define _GLIBCXX_USE_CXX11_ABI 0 #include <bits/stdc++.h> #define FOR(i, n) for(lli i = 0; i < (lli)(n); ++i) #define FORU(i, j, k) for(lli i = (j); i <= (lli)(k); ++i) #define FORD(i, j, k) for(lli i = (j); i >= (lli)(k); --i) #define DESTRUCT2(t, x, y) \ auto ...
ALGO
0.999852
4.629783
9a37a1de-c7d1-4f52-9c7f-4e0e41838bbb
Rinnegatamante/easyrpg-player-vita
src/utils.cpp
// Headers #include "utils.h" #include <algorithm> #include <cctype> std::string Utils::LowerCase(const std::string& str) { std::string result = str; std::transform(result.begin(), result.end(), result.begin(), tolower); return result; } std::string Utils::UpperCase(const std::string& str) { std::string result = ...
TOOL
0.92284
6.365674
ca246d31-5d99-48c3-a33a-5737af7a7b72
suciluz/competitive-programming
MostFrequentNumber/main.cpp
#include <bits/stdc++.h> using namespace std; #define pb push_back #define fin '\n' int arr[10001],n,ans; int main() { ios_base::sync_with_stdio(0);cin.tie(NULL);cout.tie(NULL); cin>>n; for(int i=0,tmp; i<n; i++) {cin>>tmp; arr[tmp]++;} for(int i=1,mx=-1; i<=10001; i++) { if(mx<arr[i]) { ...
ALGO
0.999823
4.111081
fe920652-7ff8-4a8f-b9bd-f98d33398c1f
luoxiao23333/ProcessResourceLimiter
containers/slam/opencv3/modules/core/src/matrix_expressions.cpp
/* //////////////////////////////////////////////////////////////////// // // Mat basic operations: Copy, Set // // */ #include "precomp.hpp" #include <opencv2/core/utils/logger.hpp> namespace cv { //This and its overload below are used in various MatExpr operator overloads //implemented to check that Matrix operan...
TOOL
0.916601
7.362061
0604408e-8a21-49d5-af19-44fe4c713f89
Ahnaf-41M/Codeforces_AtCoder
codeforces/702/A.cpp
#include "bits/stdc++.h" #define ff first #define ss second #define pb push_back #define MX 100005 #define int long long #define endl "\n" #define gcd(a,b) __gcd(a,b) #define lcm(a,b) (a*b)/gcd(a,b) #define all(v) v.begin(),v.end() #define ...
ALGO
0.999747
4.227511
f0d16946-96ab-4e75-b4d4-7ec051745373
BIT-zhaoyang/competitive_programming
uva10298.cpp
#include <bits/stdc++.h> using namespace std; int main() { string line; vector<int> table(1000011, -1); while(cin >> line){ if(line == ".") break; int n = line.size(); int i = 0, j = -1; while(i < n){ while(j >= 0 && line[i] != line[j]) j = table[j]; ++i, ++j; table[i] = j; ...
ALGO
0.99928
3.5058
469d2583-2b54-46e9-b069-9244d9b668cc
ROCm/flang
flang-classic/llvm-classic/llvm/lib/CodeGen/GlobalISel/Localizer.cpp
#include "llvm/CodeGen/GlobalISel/Localizer.h" #include "llvm/ADT/DenseMap.h" #include "llvm/ADT/STLExtras.h" #include "llvm/Analysis/TargetTransformInfo.h" #include "llvm/CodeGen/GlobalISel/Utils.h" #include "llvm/CodeGen/MachineRegisterInfo.h" #include "llvm/CodeGen/TargetLowering.h" #include "llvm/InitializePasses.h...
TOOL
0.908064
7.941137
c89dcaa1-01df-4472-92ec-58d5d393b729
vatanaksoytezer/zephyr
rpg_vikit/vikit_common/src/vision.cpp
/* * vision.cpp * * Created on: May 14, 2013 * Author: cforster */ #include <vikit/vision.h> #if __SSE2__ # include <emmintrin.h> #elif __ARM_NEON__ # include <arm_neon.h> #endif namespace vk { #ifdef __SSE2__ void halfSampleSSE2(const unsigned char* in, unsigned char* out, int w, int h) { const unsign...
ALGO
0.994604
5.142269
393928de-82f9-41ad-ae11-8a141bb81754
akshaydmc/DSALGO
Binary Tree/check_if_given_tree_is_sum_tree_or_not.cpp
#include <iostream> using namespace std; // Data structure to store a Binary Tree node struct Node { int key; Node *left, *right; Node(int key) { this->key = key; this->left = this->right = nullptr; } }; // Recursive function to check if given binary tree is a sum tree or not int ...
ALGO
0.999957
7.136025
67a33621-fe84-41a9-87f1-21ee6064c239
LokeshSingh07/Leetcode-POTD
June/29_number_of_subsequences_that_satisfy_the_given_sum_condition.cpp
// 1498. Number of Subsequences That Satisfy the Given Sum Condition class Solution { public: int MOD = 1e9+7; int power(int a, int b){ if(b==0) return 1; int half = power(a, b/2); int result = (1LL * half * half) % MOD; if(b&1){ result = (1LL * result * a) % MOD; ...
ALGO
0.999998
6.066387
f0e0f691-9510-47da-adb5-c3cedee868be
phprashanthans/Cplusplus-Constructs
C++14.cpp
/*---------------------------------------------------------------------------------- C++14 i) Template Enhancements i.i) Variable Templates i.ii) Template Parameter deduction i.iii) Generic Lambdas in Templates ii) Advanced Lambda Expressions ii.i) Explicit return types i...
TOOL
0.928967
3.726835