uuid
string
repo_name
string
relative_path
string
content
string
category
string
algo_rel_score
float64
quality_score
float64
db066bd7-88a6-4d9d-a81d-fadb700ed34a
SimplyDifficult/Leetcode-Problems
Backtracking and Trie/*131. Palindrome Partitioning.cpp
class Solution { public: vector<vector<string>>ans; vector<string>curr; bool ispalindrome(string s,int l,int r){ while(l<=r){ if(s[l]!=s[r])return false; l++,r--; } return true; } void f(string s,int start){ if(start==s.size()){ ...
ALGO
0.999967
6.501305
ef847965-8ff9-42e5-9ef9-3e04e78fb3ec
alexandraback/datacollection
solutions_1480487_0/C++/r2jitu/A.cpp
#include <iostream> #include <iomanip> using namespace std; int main() { int T, N; double s[200], sum, v[200]; cin >> T; for (int i=0; i<T; i++) { cin >> N; sum = 0; for (int j=0; j<N; j++) { cin >> s[j]; sum += s[j]; v[j] = 0; } double remain = sum; while (remain >...
ALGO
0.999689
3.462563
0f16fa03-fd00-4b41-8741-142918ab5bf1
alifalhasan/CP-code-vault
AtCoder/abc133/abc133_f/29844850.cpp
#pragma GCC optimize("Ofast") #include<bits/stdc++.h> #include<ext/pb_ds/tree_policy.hpp> #include<ext/pb_ds/assoc_container.hpp> using namespace std; using namespace __gnu_pbds; #define ll long long template<typename temp>using ordered_set = tree<temp, null_type, less<temp>, rb_tree_tag,tree_order_statistics_node_...
ALGO
0.999851
4.305382
7d1c6410-c511-4685-bd13-62b022640029
yukunqi/NiuKe
第二章_排序/排序(1)/归并排序练习题/MergeSort.cpp
#include <iostream> using namespace std; class MergeSort { public: int* mergeSort(int* A, int n) { mergePass(A,0,n-1); return A; } void mergePass(int *A,int low,int high){ if(low<high){ if(high-low<=10){//ԪظСһʱò Լָ InsertionSort(A,low,high); return ; } int middle=(low+hi...
ALGO
0.999936
4.525894
05673aa8-6a51-414d-9d2d-7d4e67b1cc92
Rost585/programacion1f2025
main (2).cpp
#include <iostream> using namespace std; int main() { //Declarar una variable entera int var1 = 24; int var2 = 2; int var3 = 6; int var4 = 4; int operacion = (var1 + var2 * var3) / var4; cout << "el valor de la operacion es: " << operacion << endl; }
ALGO
0.985062
3.028737
c0fb69b2-6e7a-470d-ae6f-04abef1eb4de
ddamddi/PS
백준/2798.cpp
#include <iostream> #include <vector> #include <algorithm> using namespace std; int card[100]; int main(){ int n, m; cin >> n >> m; for(int i=0; i<n; i++) cin >> card[i]; vector<int> v; for(int i=0; i<n-2; i++){ for(int j=i+1; j<n-1; j++){ for(int k=j+1; k<n; k++){ int sum = card[i] + card[j] + ca...
ALGO
0.999987
4.527722
514fda79-c31b-478c-b7a8-f1073efd757a
PoolC/algospot
ITES/thgnltn123.cpp
#include<stdio.h> #include<stdlib.h> #include<malloc.h> #define QUEUEMAX 5000000 int cQueue[QUEUEMAX]; int start; int end; int queueSum; int main() { int numOfCase; int inputs[20][2]; scanf("%d", &numOfCase); for(int i=0;i<numOfCase;i++) scanf("%d %d", &inputs[i][0], &inputs[i][1]); int findMax=0; for(in...
ALGO
0.999583
3.349929
9346d2e9-be1e-4431-a630-4379ad79e8f3
ishandutta2007/codeforces
keko37/normal/785/C.cpp
#include<iostream> #include<cmath> #include<cstdio> using namespace std; typedef long long llint; llint n, m; int main () { cin >> n >> m; if (m>=n) { cout << n; return 0; } llint low=1, high=2000000000, mid; while (low<high) { mid=(low+high)/2; if (n-m-mid*(mid+1)/2<=0) { high=mid; } else { lo...
ALGO
0.99995
3.695895
55f2d640-c075-453a-896e-1c865a42e33c
ReynaldoMV08/3KLSC-REYNALDOMENDEZ-10
3KLSC-REYNALDOMENDEZ-10/3KLSC-REYNALDOMENDEZ-10.cpp
// 3KLSC-REYNALDOMENDEZ-10.cpp : Este archivo contiene la función "main". La ejecución del programa comienza y termina ahí. // #include <iostream> using namespace std; int sumaRecursiva(int n) { if (n <= 9) return n; else return sumaRecursiva(n / 10) + n % 10; } int sumaIterativa(int n) { ...
ALGO
0.997854
6.119778
d7ecf567-45a2-4dcc-8467-fba07d2fdf27
DerellLicht/gstuff
font.dialog.cpp
//******************************************************************************** // this is used *only* by ascii class //******************************************************************************** #undef __STRICT_ANSI__ // used by ascii class #include <windows.h> #include "gstuff.h" // for timer funct...
TOOL
0.900644
4.90244
4a883f0f-285a-43bd-b8bf-a84d25184b85
EricLampley/PointersAndArrays
Pointers and Arrays.cpp
#include <iostream> using namespace std; int getMin(int numbers[], int size) { int min = numbers[0]; for (int i = 1; i < size; i++) { if (numbers[i] < min) { min = numbers[i]; } } return min; } int getMax(int numbers[], int size) { int max = numbers[0...
ALGO
0.999682
4.274076
e05e58cb-e2d3-4dd7-a189-6575bb6f856b
raincross7/code-similarity
codes/train_code/problem294/problem294_96.cpp
#include <bits/stdc++.h> using namespace std; #define ll long long const double Pi=acos(-1); int main() { double a,b,x; cin>>a>>b>>x; if(a*a*b<2*x){ double left=2*b-2*(x/(a*a)); double answer=atan(left/a); //cout<<left<<endl; cout << fixed << setprecision(9) << answer/Pi*180 << endl; } else{ ...
ALGO
0.999824
3.915789
54431d3c-2fb7-4321-98bf-7f77318c7315
ApolloMonasa/DS
Algorithm_AND_DataStructure/C15_FenwickTreeAndSegmentTree/22.P1438.cpp
/************************************************************************* > File Name: 22.P1438.cpp > Author: HDU-Apollo > Mail: <EMAIL> > Created Time: Mon 21 Jul 2025 09:18:06 AM CST ************************************************************************/ #include<cstdio> #include<cstdlib> #include<vector> #in...
ALGO
0.999918
4.509426
3d4bb088-f78d-49f5-9f00-2c730d140fe5
vendraminii/ArduPilot
libraries/AP_Common/float16.cpp
#include "float16.h" /* float16 implementation algorithm with thanks to libcanard: https://github.com/dronecan/libcanard */ float Float16_t::get(void) const { union FP32 { uint32_t u; float f; }; const union FP32 magic = { (254UL - 15UL) << 23U }; const union FP32 was_inf_nan = {...
ALGO
0.990204
6.052806
414ae7b1-5c0c-46f3-a984-314eaac57d0d
rorororom/Differentiation
main.cpp
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <time.h> #include "differentiation.h" #include "log_funcs.h" #include "print_tree.h" #include "vis.h" #include "recurs.h" void Visual(const char* filename); void TransformAndEvaluate(Differ* differ, Lines* text) { int changeCount = 0; do { ...
TOOL
0.958638
3.284394
42325efc-b09c-4318-a7b8-690dec46f491
DavidChicharro/Estructuras-de-Datos
Problemas/relacion3/ejercicio16.cpp
/* Ejercicio 16 */ #include <iostream> #include <string> #include <list> using namespace std; template <typename T> list<pair<T, int> > comprimir(const list<T> &l){ list<pair<T, int> > lista_comprimida; typename list<T>::const_iterator it; typename list<pair<T, int> >::iterator it_lc = lista_comprimida.begin(); ...
ALGO
0.999772
3.805311
a63f1862-b152-4a36-97bc-c0c038d9534a
arevindh/demo-glsl
Terrain/Terrain.cpp
#include "Terrain.h" #include "../ImageTools.h" #include "../VarManager.h" #include "../BoundingBox.h" #include <assert.h> #include "Quadtree.h" #include "QuadtreeNode.h" #include "TerrainChunk.h" #include "TerrainObject.h" #include "../VertexBufferObject.h" #define COORD(x,y,w) ((y)*(w)+(x)) Terrain::Terrain() { m_...
TOOL
0.967145
3.879119
e585d1b3-0261-482a-be7a-7d5b36b606d1
jameskkk/UVCCamera
opencv_2.4.13.2/sources/3rdparty/openexr/Imath/ImathFun.cpp
#include "ImathFun.h" namespace Imath { float succf (float f) { union {float f; int i;} u; u.f = f; if ((u.i & 0x7f800000) == 0x7f800000) { // Nan or infinity; don't change value. } else if (u.i == 0x00000000 || u.i == 0x80000000) { // Plus or minus zero. u.i = 0x...
ALGO
0.960545
6.87551
687af6b8-805f-4b6e-b7cb-45f3ffba09f8
ossimlabs/ossim-alpine-dep-geos
geos/src/operation/distance/FacetSequenceTreeBuilder.cpp
#include <geos/operation/distance/FacetSequenceTreeBuilder.h> #include <geos/geom/LineString.h> #include <geos/geom/Point.h> using namespace geos::geom; using namespace geos::index::strtree; namespace geos { namespace operation { namespace distance { std::unique_ptr<STRtree> FacetSequenceTreeBuilder::build(const Geo...
ALGO
0.923999
7.322657
197306a0-7d01-4850-bd9b-1f7ac7cc7c0b
NikBeastDeve/TrackingAI
eigen-3.4.0/doc/snippets/EigenSolver_EigenSolver_MatrixType.cpp
MatrixXd A = MatrixXd::Random(6,6); cout << "Here is a random 6x6 matrix, A:" << endl << A << endl << endl; EigenSolver<MatrixXd> es(A); cout << "The eigenvalues of A are:" << endl << es.eigenvalues() << endl; cout << "The matrix of eigenvectors, V, is:" << endl << es.eigenvectors() << endl << endl; complex<double> l...
ALGO
0.999156
3.093769
b25c4d78-becf-4bc5-a8d9-e79978a491ee
sabernaserifar/RexPoN
src/npair_half_size_nsq_newton.cpp
#include <string.h> #include "npair_half_size_nsq_newton.h" #include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" #include "group.h" #include "my_page.h" #include "error.h" using namespace LAMMPS_NS; /* ---------------------------------------------------------------------- */ NPairHal...
ALGO
0.99989
5.646938
c6796f8b-8922-4f1e-818f-43058dfdf985
DoneitP1/LeetCode
0144-binary-tree-preorder-traversal/0144-binary-tree-preorder-traversal.cpp
class Solution { public: vector<int> v; vector<int> preorderTraversal(TreeNode* root) { if(root == NULL) return v; v.push_back(root->val); preorderTraversal(root->left); preorderTraversal(root->right); return v; } };
ALGO
0.999965
6.186938
961cbd19-a992-4d8e-839d-d41172df6f99
ichn/3-code-for-ac
BZOJ/1015-星球大战.cpp
#include<cstdio> #include<cstring> #include<algorithm> #include<vector> using namespace std; const int maxn=400000; const int maxm=200000; vector<int> g[maxn+50]; int q[maxn+50],a[maxn+50],f[maxn+50],n,m,len; bool p[maxn+50],visit[maxn+50]; int find(int x) { if(f[x]==x) return f[x]; return f[x]=find(f[x]); } in...
ALGO
0.999992
3.616554
2231abaa-4f85-464e-bc94-8312b74d821b
University-of-Utah-CS3505/a9-edu-app-wyattbworld
Box2D/Dynamics/Contacts/b2PolygonAndCircleContact.cpp
#include <Box2D/Dynamics/Contacts/b2PolygonAndCircleContact.h> #include <Box2D/Common/b2BlockAllocator.h> #include <Box2D/Dynamics/b2Fixture.h> #include <new> b2Contact* b2PolygonAndCircleContact::Create(b2Fixture* fixtureA, int32, b2Fixture* fixtureB, int32, b2BlockAllocator* allocator) { void* mem = allocator->All...
ALGO
0.959012
7.291923
481a300f-ea3e-409b-9831-848eba7dd969
aarya280404/Leetcoder
Difficulty: Easy/Find pairs with given sum in doubly linked list/find-pairs-with-given-sum-in-doubly-linked-list.cpp
//{ Driver Code Starts //Initial Template for C++ #include <bits/stdc++.h> using namespace std; class Node { public: int data; Node *next, *prev; Node(int val) : data(val), next(NULL), prev(NULL) { } }; // } Driver Code Ends //User function Template for C++ /* Doubly linked list node class class...
ALGO
0.99978
6.105629
1a933d31-5ed4-4c24-bd77-ff7eb93a321a
blacksea3/leetcode
cpp/leetcode/5068. before-and-after-puzzle.cpp
#include "public.h" // //O(n^2) class Solution { private: vector<string> getPreAndLat(string input) { vector<string> res(2); if (input.find(' ') == input.npos) return { input, input }; //һ int preIndex = 0; while (input[preIndex] != ' ') preIndex++; res[0] = input.substr(0, preIndex); preIndex = inp...
ALGO
0.999461
4.785036
1c5f485e-e0df-4bef-9089-43692c28cf44
StolasIn/leetcode_Submissions
content/coin-change-2/Accepted/5-27-2021, 8_54_59 AM/Solution.cpp
// https://leetcode.com/problems/coin-change-2 class Solution { public: int dp[5050]; int change(int amount, vector<int>& coins) { for(int i=0;i<=amount;i++){ dp[i]=0; } dp[0]=1; for(auto& i : coins){ for(int j=i;j<=amount;j++){ dp[j]+=dp[...
ALGO
0.999967
6.073558
5f5ea547-be80-41c5-bc93-8eec7ed129d6
Rajesh351/Leetcodeall
0368-largest-divisible-subset/0368-largest-divisible-subset.cpp
class Solution { public: vector<int> largestDivisibleSubset(vector<int>& nums) { sort(nums.begin(), nums.end()); vector<int> dp(nums.size(), 1), prev(nums.size(), -1); int maxi = 0; for (int i = 1; i < nums.size(); i++) { for (int j = 0; j < i; j++) { if (...
ALGO
0.999996
5.761667
59e0a816-b810-478d-991b-056118db7218
divyanshgaba/Competitive-Coding
Dhoni and holidays!/main.cpp
#include<bits/stdc++.h> #define fast ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0); #define F first #define S second #define PB push_back #define MP make_pair #define REP(i,a,b) for (int i = a; i <= b; i++) #define FOR(i,a,b) for (int i = a; i < b; i++) #define MAX 1e9 using namespace std; typedef long long l...
ALGO
0.999677
3.42158
0d5695ef-0377-4b74-83ca-ff5efca61ec4
rahulkumarguptaa/coding-ninjas-data-structure
Binary Trees/Construct Tree from Postorder and Inorder.cpp
/* For a given postorder and inorder traversal of a Binary Tree of type integer stored in an array/list, create the binary tree using the given two arrays/lists. You just need to construct the tree and return the root. Note: Assume that the Binary Tree contains only unique elements. Input Format: The first line of inpu...
ALGO
0.999997
5.570617
42160986-8ed8-4011-88c1-c177969ac6f9
knst/Competitive-programming
codeforces/300/a.cpp
/***************************************************************************** * codeforces: knst * topcoder: knstqq * projecteuler: knstqq * **************************************************************************/ #include <algorithm> #include <iostream> #include <limits> #include <map> #include <set> #i...
ALGO
0.999976
3.957181
eaedd54c-6846-4d7d-a8f6-3589c9b7d3c3
AREM-Projets/robot-CdR-2023
lib/ReseauCapteur/ReseauCapteur.cpp
#include "ReseauCapteur.h" ReseauCapteur::ReseauCapteur(Ultrasonic* AvantDroite, Ultrasonic* AvantGauche) { Avant1 = AvantDroite; Avant2 = AvantGauche; } uint32_t ReseauCapteur::EvitementTranslation(int signe, BlocMoteurs* motors) { uint32_t stop_time; uint32_t start_time; uint32_t time_lost = 0; ...
TOOL
0.97736
3.720657
1d7119b1-35fa-42ab-ae28-c5a7f7301c38
joseneto0/Code-Forces
Problems/SoldierAndBananas.cpp
//problema 546A #include <bits/stdc++.h> using namespace std; int main(void){ int k, n, w, cont=0; cin >> k >> n >> w; for (int i = 1; i <= w; i++){ cont += (k * i); } if (cont < n){ cout << 0 << '\n'; } else { cout << abs(n - cont) << '\n'; } return 0; }
ALGO
0.999818
3.510823
62e2d95a-a3ee-4380-aa0f-9c43bedcf2a7
jee-van24/LeetCode
3447-clear-digits/3447-clear-digits.cpp
class Solution { public: string clearDigits(string s) { string res=""; for(int i=0;i<s.size();i++){ if(!res.empty()&&isdigit(s[i])){ res.pop_back(); }else{ res+=s[i]; } } return res; } };
ALGO
0.999123
5.848347
a189aa17-a4b6-4ee6-b569-5f2de0a39b2c
HEltim7/cpcode
CF/EDU/136/A_Immobile_Knight.cpp
#include <vector> #include <iostream> #include <algorithm> using namespace std; #define endl '\n' using LL=long long; void solve() { int r,c; cin>>r>>c; cout<<(r+1)/2<<' '<<(c+1)/2<<endl; } int main() { ios::sync_with_stdio(0); cin.tie(nullptr); int t; cin>>t; while(t--) solve(); ...
ALGO
0.999839
4.780233
cb15c988-565e-4433-9e29-96caf8de1e58
duongnguyen291/DSA
exam/New folder/ex1.cpp
#include <bits/stdc++.h> using namespace std; typedef struct node{ char ID[12]; int amount; char date[100]; double money; node *next; }node; node *makeNode(node *head, char ID[], int amount,char date[], double money ){ node *p = new node(); if(p == NULL){ cout << "loi truy cap du lie...
TOOL
0.941202
4.050059
30f99499-60ec-4eb2-ab80-420c9fd6ec14
polarr/competitive-programming
Codeforces/2102/E.cpp
/** * Solution by Charles Ran (polarity.sh) * Date: 2025-05-11 * Contest: Codeforces 2102 * Problem: E **/ #include <bits/stdc++.h> using namespace std; using ull = unsigned long long; using ll = long long; using vi = vector<int>; using vl = vector<ll>; using pii = pair<int, int>; #define pb push_back #define rep...
ALGO
0.999923
4.851486
0ff68834-19fc-40ae-83f5-f9fa572e3f7f
guyongpu/LeetCode
src/P0128_LongestConsecutiveSequence.cpp
// // Created by yongpu on 2019/12/2 9:02. // #include "P0128_LongestConsecutiveSequence.h" /** * 题目:最长连续序列 * 描述:给定一个未排序的整数数组,找出最长连续序列的长度. * 思路:将每个nums[i]-1不在序列中的数作为起点,然后进行遍历,能够保证比较时间复杂度为O(n) * 备注:暴力法/排序法时间复杂度较高 */ int P0128_LongestConsecutiveSequence::longestConsecutive(vector<int> &nums) { if (nums.size()...
ALGO
0.999532
5.471466
2b6e238d-1968-4abf-bbea-ce7fca9a5dea
TUS123456/DSAjourney
recursion.cpp
#include<bits/stdc++.h> using namespace std; void print_vec(vector<int> &arr,int i, int s){ if(i>=s){ return; } cout<<arr[i]<<" "; print_vec(arr,++i,s); } main(){ vector<int> arr={1,2,3,4,5}; int i=0; print_vec(arr,i,5); }
ALGO
0.998822
3.761281
caecbd02-bf6f-4061-9c04-b8181c202d4c
DionysiosB/CodeForces
0200-0299/272B-DimaAndSequence.cpp
#include <cstdio> int findBinaryOnes(long input){ int output(0); while(input > 0){output += input % 2; input /= 2;} return output; } int main(){ long n(0); scanf("%ld", &n); const int maxNumBits = 30; int *array = new int[maxNumBits + 1]; for(int k = 0; k <= maxNumBits; k++){array[k]...
ALGO
0.999866
4.71985
20ec88b6-c798-4ef0-a2cc-38271283d482
cskrren/LUOGU
P1428.cpp
#include<iostream> using namespace std; inline int read() { register int x = 0, f = 1; register char c = getchar(); while (c < '0' || c>'9') { if (c == '-') f = -1; c = getchar(); } while (c >= '0' && c <= '9') x = (x << 3) + (x << 1) + (c ^ 48), c = getchar(); return x * f; } int n; int a[101]; int main() { n = ...
ALGO
0.999963
3.432173
71e47d44-2ef1-4c8b-8b10-7206925bceed
7Kaloyan7Markov7/Introduction-To-Programming-FMI
week 05/AnalyzeArray3.cpp
#include <iostream> const int MAX_SIZE = 100; int AnalyzeArray(const int arr[MAX_SIZE], int size) { if (size < 2 || size >= MAX_SIZE) { return -1; } int sum = 0; for (int i = 0; i < size; ++i) { sum += arr[i]; } if (sum % 2) return 0; int tempSum = 0; for (int i = 0; i < size; ++i) { tempSum += a...
ALGO
0.999523
5.159066
f93cdca8-a0bf-4498-bed0-42b4b6f935ed
ishandutta2007/codeforces
sys/normal/1657/F.cpp
#include <bits/stdc++.h> using namespace std; const int Maxn = 400005; int n, q, ct, scc, top, cnt, dfn_cnt, val[Maxn], x[Maxn], y[Maxn], fa[Maxn], dep[Maxn], head[60 * Maxn], dfn[60 * Maxn], low[60 * Maxn], sta[60 * Maxn], bel[60 * Maxn]; vector <int> G[Maxn]; string str[Maxn]; bool in_stack[60 * Maxn]; struct edg { ...
ALGO
0.999995
4.380263
bd5e9858-cc4b-4059-a61f-2d92343f53a7
fafa1899/BuildCppDependency
Source/geos-3.12.2/src/operation/sharedpaths/SharedPathsOp.cpp
#include <geos/operation/sharedpaths/SharedPathsOp.h> #include <geos/geom/GeometryFactory.h> #include <geos/geom/Geometry.h> #include <geos/geom/LineString.h> #include <geos/geom/MultiLineString.h> #include <geos/linearref/LinearLocation.h> #include <geos/linearref/LocationIndexOfPoint.h> #include <geos/util/IllegalArg...
ALGO
0.995731
6.442611
2a388ad4-cac3-4ddb-a26a-59a6fb35f92c
Hurrinecane/Lab24.-Dynamic-two-dimensional-arrays-in-continuous-memory
Lab24/two-dimensional array.cpp
#include "two-dimensional array.h" int ** CreateMas(int h, int w) { if (!(h > 0 && w > 0)) exit(1); int **mas = (int**)malloc(h * sizeof(int*)); for (int i = 0; i < h; i++) mas[i] = (int*)malloc(w * sizeof(int)); return mas; } void WriteIn(int h, int w, int **mas) { for (int i = 0; i < h; i++) for (int j = 0...
ALGO
0.997673
3.409914
fb3f89d9-6093-465c-a454-b62f6932fd5d
blockspacer/bootstrap-redux
ext/boost-1.70.0/libs/graph/example/topo-sort-with-leda.cpp
int main() { using namespace boost; typedef GRAPH < std::string, char >graph_t; graph_t leda_g; typedef graph_traits < graph_t >::vertex_descriptor vertex_t; std::vector < vertex_t > vert(7); vert[0] = add_vertex(std::string("pick up kids from school"), leda_g); vert[1] = add_vertex(std::string("buy groce...
ALGO
0.998148
4.55441
31c19064-0767-4bca-91fb-a9cacddd721c
dhiraj2105/codehub
Array-Vector/Array-Vector_cpp/Basics/multiDimensional.cpp
#include <iostream> using namespace std; int main() { // =========================== // 2D Array Example // =========================== // Declaration and Initialization of a 2D array int arr2D[2][3] = {{1, 2, 3}, {4, 5, 6}}; // Accessing elements in the 2D array cout << "2D Array Element...
ALGO
0.983462
5.522065
1f7facd7-b835-40d2-87eb-b2627bdad5f5
Nika96/Algorytmy
sortedArrayList.cpp
#include "sortedArrayList.h" #define cc const_cast<SortedArrayList&> SortedArrayList::SortedArrayList() { for(int i = 0; i<maxlength; i++) elements[i] = -1; size = 0; } /*int SortedArrayList::size() { int counter =0; for(int i=0; i<maxlength; i++) { if(elements[i] != -1) counter++; } return counter; }...
TOOL
0.996405
4.391165
326536ee-816b-47d2-b561-2ccf08dd29f6
sandysihotang/CPP
sandy/Code/Panda OJ/JC9A.cpp
#include <cstdio> #include <algorithm> using namespace std; int main() { int a,qwe[10005]; scanf("%d",&a); for(int i=1;i<=a;i++) { scanf("%d",&qwe[i]); } sort(qwe,qwe+a+1); int x=1; for(int i=1;i<=10000;i++) { if(qwe[i]==qwe[i-1]) x--; if(qwe[i]!=x) { printf("%d\n",x); break; } x++;...
ALGO
0.999918
3.160758
b971d921-0dbb-4b29-80ee-271a50f4e5ec
travistabbal/frameworks_base
media/libstagefright/codecs/m4v_h263/dec/src/vlc_decode.cpp
/***********************************************************HeaderBegin******* * * File: vlc_dec.c * * Author: Paulo Nunes (IST) - <EMAIL> * Created: 1-Mar-96 * * Description: This file contains the VLC functions needed to decode a * bitstream. * * Notes: * The functions contained in this file were adapt...
ALGO
0.98912
4.133549
2a1d621e-1577-4b7c-9d48-066fd593a80b
thomas-rou/Geppetto
gazebo/project_ws/src/slam_gmapping/openslam_gmapping/particlefilter/particlefilter_test.cpp
#include <stdlib.h> #include <iostream> #include <fstream> #include "particlefilter.h" using namespace std; #define test(s) {cout << s << " " << flush;} #define testOk() {cout << "OK" << endl;} struct Particle{ double p; double w; inline operator double() const {return w;} inline void setWeight(double _w) {w=_w...
ALGO
0.997738
4.045019
3b3191fb-4179-4051-bc58-52108d543ab6
Aospify/platform_frameworks_av
media/libcpustats/CentralTendencyStatistics.cpp
#include <stdlib.h> #include <cpustats/CentralTendencyStatistics.h> void CentralTendencyStatistics::sample(double x) { // update min and max if (x < mMinimum) mMinimum = x; if (x > mMaximum) mMaximum = x; // Knuth if (mN == 0) { mMean = 0; } ++mN; double delta =...
ALGO
0.991887
6.204975
0244017e-bb5b-4927-807a-5bf58c0a3901
shubham452/algo
dp/matrix chain multiplication/05_boolean paranthesis recursive for true.cpp
#include<bits/stdc++.h> using namespace std; int solve(string str, int i, int j, bool istrue) { if(i>j) { return 0; } if(i==j) { if(istrue==1) { return str[i]=='T'; } else { return str[i]=='F'; } } int k,ans=0; ...
ALGO
0.999988
5.396998
af1556f4-1304-47ef-bc01-bd6f505ac05f
surajjadhav64/lp2
Expert_System_EmployeePerformance.cpp
#include <iostream> #include <string> using namespace std; struct Employee { string name; float attendance; float punctuality; float taskCompletion; float teamwork; float initiative; }; float calculateAverage(const Employee& emp) { return (emp.attendance + emp.punctuality + emp.taskComplet...
TOOL
0.891564
6.893995
5544d97f-65f9-4257-9964-684e7bbd8e13
dudareolon/CS260_Assignment_07
complex_hash.cpp
#include <sstream> #include <functional> #include "hash.hpp" using std::stringstream; // Initializes the Hash Table under the class requirements HashTable::HashTable(int initialCapacity) { capacity = initialCapacity; //how many slots are available in the table size = 0; // starts it empty // create arra...
ALGO
0.990417
5.781478
8c3dc53f-2dd0-44ea-9503-3f1dcb457241
AnmoolKumar/CPP
Practical-6/task-3/code_manual.cpp
#include <bits/stdc++.h> using namespace std; void reverse(string str) { for (int i=str.length()-1; i>=0; i--) cout << str[i]; } int main(void) { string s; getline(cin,s); reverse(s); cout<<"\n"; return (0); }
ALGO
0.999558
4.279907
ef074323-33df-4bb7-a206-13c716b3c78a
anuragyes/DSA
Tree/identical-tree.cpp
#include <iostream> using namespace std; class node { public: int data; node *left; node *right; node(int val) { data = val; left = NULL; right = NULL; } }; bool same(node *root1, node *root2) { // case first if (root1 == NULL && root2 == NULL) { re...
ALGO
0.999619
4.648337
c45f2c0b-2667-479b-98cb-67d07bb6efab
Vladlen2d/LR_3.1
ch10/ex10_03_04.cpp
// // @author Yue Wang // @date 01.12.2014 // // Exercise 10.3: // Use accumulate to sum the elements in a vector<int>. // // Exercise 10.4: // Assuming v is a vector<double>, what, if anything, // is wrong with calling accumulate(v.cbegin(), v.cend(), 0)? // Check below. // #include <iostream> #include <string> #i...
ALGO
0.989039
5.62637
9b2486bc-d78c-4b81-bcd0-4d4d3d4bd4dc
alexandraback/datacollection
solutions_5751500831719424_1/C++/sergio10barca/solution.cpp
#include <iostream> #include <vector> #include <string> #include <map> #include <algorithm> #include <set> #include <stack> #include <deque> #include <queue> #include <cstdlib> #include <cmath> #include <cctype> #include <cstring> #include <iomanip> #include <climits> #include <cfloat> #include <cstdio> #define x first...
ALGO
0.999946
3.710344
70b474f3-5232-46ba-85ea-3e01aa446091
ilhomjonov-ogabek/exam_second
task_59.cpp
#include <iostream> using namespace std; int main() { int n; cout << "Massiv uzunligini kiriting: "; cin >> n; int* arr1 = new int[n]; int* arr2 = new int[n * 2](); for (int i = 0; i < n; i++) { cout << "1-massivning " << i << "-elementini kiriting: "; cin >> arr1[i]; } ...
ALGO
0.996846
3.618248
c878e9a7-8097-4f94-b31c-65026772c543
abuss/ECE420_W20
pthread/pth_hello.cpp
/* File: * pth_hello.cpp * * Purpose: * Illustrate basic use of pthreads compiled using C++: create some threads, * each of which prints a message. * * Input: * none * Output: * message from each thread * * Compile: g++ -g -Wall -o pth_hello_cpp pth_hello.cpp -lpthread * Usage: ./pth_...
ALGO
0.874828
5.780006
c64e710c-7900-4e0d-995d-a48476011626
Maderanx/cryptography_cia_sem6_Madhavv-Arul---22011102053
autokey_cipher.cpp
#include <iostream> #include <string> using namespace std; string generateAutokey(string text, string key) { string autokey = key; for (int i = 0; i < text.length() - key.length(); i++) { autokey += text[i]; } return autokey; } string encrypt(string text, string key) { string result = ""; ...
ALGO
0.99993
5.248073
35cd9b4d-001a-4d80-bcfa-1114d22697f3
Marwansalem122/Problem-Solving
Strings/isCircularSentence.cpp
#include<string> using namespace std; class CircularSentence{ public: bool isCircularSentence(string sentence){ bool isCircular=false; for (int i=0;i<sentence.length();i++) if(sentence[i]==' '&&sentence[i-1]!=sentence[i+1]) return false; return sentence[0]==sentence.back(); } };
ALGO
0.999809
4.625641
28481032-f22a-4b27-b6b5-d2767308e331
yashk9293/NeetCode-150
17_Math & Geometry/02_Spiral Matrix.cpp
// Question Links :- https://leetcode.com/problems/spiral-matrix // Spiral Matrix // T.C = O(n*m) The algorithm visits each element exactly once. // S.C = O(1) auxiliary space class Solution { public: vector<int> spiralOrder(vector<vector<int>>& matrix) { int n = matrix.size(); int m = matrix[0].s...
ALGO
0.999997
6.704011
1d1df2c3-9353-44f5-bf71-71ad49481786
aaman007/codeforces
Equator.cpp
#include<bits/stdc++.h> #define ll long long #define pii pair<int,int> #define sf(a) scanf("%d",&a) #define pf(a) printf("%d\n",a) #define mem(a,b) memset(a,b,sizeof(a)) #define all(x) x.begin(),x.end() #define rall(x) x.rbegin(),x.rend() #define pb push_back #define F ...
ALGO
0.999747
3.752397
a9bdb87a-fecf-415d-b033-cd7e0c0f8308
MirunaCaragioiu/structuri_de_date
GrafListeAdiacenta_Magazin/GrafListeAdiacenta_Magazin/GrafListeAdiacenta_Magazin/Source.cpp
#include<string.h> #include<malloc.h> #include<stdio.h> struct Magazin { int idMagazin; char* denumire; char* localitate; float suprafata; int nrAngajati; }; Magazin creareMagazin(int idMagazin, char* denumire, char*localitate, float suprafata, int nrAngajati) { Magazin m; m.idMagazin = idMagazin; m.denumire =...
ALGO
0.993829
3.69769
12cd181e-896b-4fa9-8deb-d60068d1e403
PaukIsUha/optimizing_formating_code
predictions/submissions-aizu-cot-gpt4/Codenet/p00099/438612178/response_6.cpp
#include <cstdio> #include <queue> using namespace std; const int MAX = 1000001; int S[MAX]; struct data { int num, score; data() {} data(int n, int s) : num(n), score(s) {} bool operator<(const data &d) const { if (score != d.score) return score < d.score; return num > d.num; } }; int main() { ...
ALGO
0.999944
3.493093
6e9763e4-621a-4212-8f6d-ee484338405f
Rajveer-CSE-27/Coding-Journey-CPP
Dynamic Programming/Karthik Arora/Beginner_to_Advanced/array_description.cpp
#include <bits/stdc++.h> using namespace std; #define ll long long /** Problem link :: https://cses.fi/problemset/task/1746 Approach :: use matrix dp[i][j]; dp[i][j] = number of array possible with ith position in array = j. {Note :: assume that we are starting array from ith position.} ...
ALGO
0.999997
5.144141
aa9c0c49-e492-4ed6-8284-460e6ce44b20
Priyasharma02821/GeeksforGeeks-DSA-Solutions
Difficulty: Hard/Trapping Rain Water/trapping-rain-water.cpp
//{ Driver Code Starts #include <bits/stdc++.h> using namespace std; // } Driver Code Ends class Solution { public: int maxWater(vector<int> &arr) { int n=arr.size(); if (n <= 2) return 0; long long res=0; int lmax[n], rmax[n]; lmax[0]= arr[0]; for (int i=1; i<n; i++...
ALGO
0.99956
6.429459
1d834b7f-85d9-42e9-8607-d728d41f23e9
LLlkaiwen/adrc_control
src/adrc/adrc_secondorder.cpp
#include "adrc/adrc_secondorder.h" namespace adrc { Adrc_SecondOrder::Adrc_SecondOrder() : Adrc_Base() , _state_eso_z1(0.0) , _state_eso_z2(0.0) , _state_eso_z3(0.0) , _state_cur_u(0.0) , _para_b0(1.0) , _para_eso({mode : NLESO, beta1 : 200.0, beta2 : 1768.0, ...
ALGO
0.998966
6.249569
fba06dee-45bd-4aba-89d1-d0c9c7bf8404
WiNe1109/Lab_Programming_Meeting_3
meeting5/Problem2/Problem2Test.cpp
#include <iostream> #include <vector> #include <algorithm> using namespace std; vector<int> reversevector(const vector<int>& input) { vector<int> reversed(input); reverse(reversed.begin(), reversed.end()); return reversed; } int main() { vector<int> vec = {7, 0, 9, 5, 5, 3, 1}; vector<int> reve...
ALGO
0.999585
5.52422
de658a5d-ce70-4613-90e4-ea79036133b0
labanidas/-CrackYourInternship
85. Rearrange a given linked list in-place..cpp
// https://leetcode.com/problems/reorder-list/ /** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode() : val(0), next(nullptr) {} * ListNode(int x) : val(x), next(nullptr) {} * ListNode(int x, ListNode *next) : val(x), next(next) {} * }; */ cla...
ALGO
0.999945
6.162282
b15d10b6-215b-4967-8e5a-365d5a7734d1
TaliSm4N/procademy
LanServer/LanServer/TextParser.cpp
#include <Windows.h> #include <cstring> #include <fstream> #include <map> #include "TextParser.h" TextParser::TextParser() :curBlock(NULL) { } bool TextParser::init(const WCHAR *filename) { WCHAR line[256]; errno_t err; err =_wfopen_s(&file, filename, L"r,ccs=UTF-16LE"); if (err != 0) { return false; } w...
TOOL
0.859082
3.299363
82ac4f68-9e4f-499e-8de9-47ba5fc13c67
onecoolx/davinci
source/webkit-2.2.8/Source/JavaScriptCore/runtime/Options.cpp
#include "config.h" #include "Options.h" #include "HeapStatistics.h" #include <algorithm> #include <limits> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <wtf/NumberOfCores.h> #include <wtf/PageBlock.h> #include <wtf/StdLibExtras.h> #include <wtf/StringExtras.h> #if OS(DARWIN) && ENABLE(PARALLEL...
TOOL
0.8761
7.609595
59de0d68-91c4-4a4d-9e60-96bca28ba225
MatejKois/Grafy_bc
Sources/Algorithms/Floyd.cpp
#include "../../Headers/Algorithms/Floyd.h" namespace Grafy { void Floyd::calculate(DistanceMatrix& matrix) { for (int k = 1; k <= matrix.size(); ++k) { for (int startNode = 1; startNode <= matrix.size(); ++startNode) { for (int endNode = 1; endNode <= ma...
ALGO
0.999877
3.920017
8b0176b2-bfe1-4d1d-8495-367aed7301b8
kimyoo5659/kimardupilot
Blimp/commands.cpp
#include "Blimp.h" // checks if we should update ahrs/RTL home position from the EKF void Blimp::update_home_from_EKF() { // exit immediately if home already set if (ahrs.home_is_set()) { return; } // special logic if home is set in-flight if (motors->armed()) { set_home_to_current...
TOOL
0.951978
7.226615
1d7f442c-e371-455f-864c-5de03ef3e2d1
ishandutta2007/codeforces
bench0310/normal/1408/G.cpp
#include <bits/stdc++.h> using namespace std; typedef long long ll; const int mod=998244353; const int N=1505; vector<int> p(N,0); vector<int> sz(N,1); vector<int> cnt(N,0); vector<vector<int>> dp(N,{0,1}); int find_set(int a) { if(a==p[a]) return a; else return p[a]=find_set(p[a]); } void merge_sets(int a,...
ALGO
0.999786
4.329959
2c9789cf-ba02-4208-99d4-9633005b16ff
JJesusGO/DeteccionImagenes
src/PSO.cpp
#include "PSO.h" /*CONTRUCTOR DE LA CLASE PSO, ENCARGADO DE LA INICIALIACION DE TODOS SUS COMPONENTES*/ PSO::PSO(int particulas,float *rmin,float *rmax,int dimensiones,int iteraciones){ this->cantidad = particulas; this->dimensiones = dimensiones; this->iteraciones = iteraciones; this->rmin = new flo...
ALGO
0.998821
4.343124
4b556453-b1e6-4e7b-bfec-d4af4c23c25f
yaoxiaokui/linux_ever
stlsrc/template_stl/ch12/replace_copy_if.cpp
/************************************************************************* > File Name: replace_copy.cpp > Author: > Mail: > Created Time: 2016年01月10日 星期日 16时57分20秒 ************************************************************************/ #include <iostream> #include <vector> #include <iterator> #include <algor...
ALGO
0.998989
4.301661
71e44b72-50ba-42ef-9d2d-31a1d58530d6
sanchit-sinha/CP
Contests/Codeforces/CF-Contest/1551/B/sol.cpp
#include "bits/stdc++.h" using namespace std; #define f first #define s second #define pb push_back #define ll long long #define ld long double #define lb lower_bound #define ub upper_bound #define m...
ALGO
0.999941
4.670525
973cfd11-fa6f-42f0-958a-b76c56b1c70d
huynh-vch/code_c
chuong03_mangmotchieu/bai078.cpp
#include <iostream> #include <iomanip> using namespace std; void Nhap(float[], int &); void Xuat(float[], int); void Xuly(float[], int); int main() { float a[100]; int n; Nhap(a, n); Xuat(a, n); Xuly(a, n); return 1; } void Nhap(float a[], int &n) { cout << "Nhap so phan tu mang: "; cin >> n; srand(time(NULL)...
ALGO
0.993578
3.766643
777b1b04-35d1-4af8-872a-fc512ea82a34
zcobell/hmdf
thirdparty/boost_1_73_0/libs/multiprecision/example/hashing_examples.cpp
#include <boost/multiprecision/cpp_int.hpp> #include <boost/random.hpp> #include <boost/functional/hash.hpp> #include <unordered_set> #include <city.h> //[hash1 /*` All of the types in this library support hashing via boost::hash or std::hash. That means we can use multiprecision types directly in hashed containers s...
TOOL
0.956496
6.850633
f0a21d82-9f7c-4659-8f20-55f11330a1b5
rakibulhasan-swe/problem-solving
codeforces/Random codeforces problems/nearlyLucky.cpp
//https://codeforces.com/problemset/problem/110/A #include<bits/stdc++.h> using namespace std; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); long long n, count = 0; cin >> n; while(n!=0){ int lastDigit = n%10; if(lastDigit==4 || lastDigit==7){ count++; ...
ALGO
0.999609
4.769144
ccb98978-b23d-4773-a28e-bf92d462c098
BitcoinHard/BitcoinHard-Source
src/spork.cpp
#include "spork.h" #include "base58.h" #include "chainparams.h" #include "validation.h" #include "messagesigner.h" #include "net_processing.h" #include "netmessagemaker.h" #include <boost/lexical_cast.hpp> CSporkManager sporkManager; std::map<uint256, CSporkMessage> mapSporks; std::map<int, int64_t> mapSporkDefault...
TOOL
0.901787
6.044818
7d4daa55-431a-43ba-841a-21a3c0303fe7
yunfeix2009/cpp_intro
ide_created/q005_prefix_sum_ex1/main.cpp
//basic c++ prefix sum. input n, then n numbers, output the prefix sum array #include<iostream> using namespace std; const int mx_n = 1000; int n, q, l, r; int a[mx_n], s[mx_n]; int main(){ cin >> n >> q; memset(a, 0, sizeof(a)); memset(s, 0, sizeof(s)); for (int i=0;i<n;i++) cin >> a[i]; s[0] = ...
ALGO
0.999568
4.37958
2cbc1d84-7151-45e5-a6f8-5601af39f9b9
sogapalag/problems
atcoder/arc058f.cpp
#include <bits/stdc++.h> using namespace std; // z[i] = len of lcp of s, s[i..]; lcp(longest common prefix) vector<int> z_fn(const string& s) { int n = s.size(); vector<int> z(n, 0); for (int i = 1, l = 0, r = 0; i < n; i++) { if (i <= r) z[i] = min(r-i+1, z[i-l]); while (i+z[i...
ALGO
0.999983
4.375272
f5139dd6-716a-449e-857f-a8a79738a35d
luqmanarifin/cp
TOKI Open 2017/beauty/grader.cpp
#include "beauty.h" #include <stdio.h> #include <vector> int main() { int N, M, Q; scanf("%d %d %d", &N, &M, &Q); std::vector<int> T(N); std::vector<int> U(M), V(M); std::vector<int> A(Q), B(Q); for (int i = 0; i < N; ++i) { scanf("%d", &T[i]); } for (int i = 0; i < M; ++i) { scanf("%d %d", &U...
ALGO
0.999839
4.525623
6db5908d-9818-4ba0-9350-836ac8d7b2a8
alexandraback/datacollection
solutions_5639104758808576_0/C++/dbradac/stovation.cpp
#include <cstdio> #include <vector> using namespace std; const int MAX = 1<<10; char s[MAX]; vector <int> V; int main() { int tt; scanf("%d", &tt); for (int ii=1; ii<=tt; ii++) { int n; V.clear(); scanf("%d%s", &n, s); int ima=0, rez=0; for (int i=0; i<=n; i++) { rez += max(0, ...
ALGO
0.9979
3.900205
7de00769-74db-4ec1-af65-3c9b314f04b7
sogapalag/problems
atcoder/arc076e.cpp
#include <bits/stdc++.h> using namespace std; // after some drawing, note only both end on board matter. // transform board to a straight line, then each seg must not intersect(can contain). stack maintain. void solve() { int R,C; cin >> R >> C; auto on_board = [&](int x, int y){ return x==0 || x=...
ALGO
0.999757
4.096624
d8e8a4bb-2c81-40ee-88f3-f810344ef1a6
jmanday/Master
TFM/library/boost_1_63_0/libs/intrusive/example/doc_avl_set.cpp
using namespace boost::intrusive; //This is a base hook optimized for size class MyClass : public avl_set_base_hook<optimize_size<true> > { int int_; public: //This is a member hook avl_set_member_hook<> member_hook_; MyClass(int i) : int_(i) {} friend bool operator< ...
TOOL
0.956514
5.919651
c2663b11-18dd-4715-9b62-37a7bcfd140e
Web3Expert47/faceRecognition
src/main/resources/opencv/sources/samples/cpp/tutorial_code/ShapeDescriptors/moments_demo.cpp
/** * @function moments_demo.cpp * @brief Demo code to calculate moments * @author OpenCV team */ #include "opencv2/imgcodecs.hpp" #include "opencv2/highgui.hpp" #include "opencv2/imgproc.hpp" #include <iostream> using namespace cv; using namespace std; Mat src; Mat src_gray; int thresh = 100; int max_thresh = 2...
ALGO
0.966271
7.414207
85d1ce2f-71ae-47f7-ae30-5c21c6833a68
BME-MIT-IET/iet-hf-2022-team-1
code/dynamic_programming/src/longest_palindromic_substring/longest_palindromic_substring.cpp
/* Part of Cosmos by OpenGenus Foundation */ #include <iostream> #include <string> using namespace std; int longestPalSubstr(string str) { int n = str.size(); bool ispal[n][n]; for (int i = 0; i < n; ++i) for (int j = 0; j < n; ++j) ispal[i][j] = false; // All substrings of len...
ALGO
0.99988
5.374627
eafd7776-a320-439a-8494-2535fc418d2b
Yoshi252/gudlife
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
97fa8763-9aef-4788-9609-cc7bf6a6d651
cdegree/ACM
日常/String/G.cpp
#include <cstdio> #include <cstdlib> #include <cstring> #include <cmath> #include <cctype> #include <vector> #include <stack> #include <queue> #include <map> #include <algorithm> #include <iostream> #include <string> #include <set> #define X first #define Y second #define sqr(x) (x)*(x) #pragma comment(linker,"/STACK:1...
ALGO
0.998395
3.251609
5b50387b-fb87-4cca-8f7e-b3fc1aabb758
adityaThakkar001/problem-solving
TLE/800/1791A.cpp
#include<bits/stdc++.h> using namespace std; int main(){ int t; cin>>t; while(t--){ int n; cin>>n; string s; cin>>s; int i = 0; while(s[i]!=s[n-1]){ i++; n--; } if((n-i)<0)cout<<0<<endl; else cout<<n-i<<endl; } }
ALGO
0.999833
3.904151
c5ea3838-bd79-4c9b-8755-2c8d8f8f7616
PankajS2002/DSA
Arrays(with searching & sorting)/linearandbinary.cpp
#include<iostream> using namespace std; int binarysearch(int key, int arr[], int n){ int s=0; int e=n-1; while(s<=e){ int mid=(s+e)/2; if(arr[mid]==key){ return mid; } else if(arr[mid]>key){ e=mid-1; } else{ s=mid...
ALGO
0.999666
5.039099
31e2f473-d50e-4c8d-848a-7e5ba8cb2212
ZexinYan/CSP
group2/group2_ex4.cpp
#include <iostream> #include <queue> #include <vector> #define MAXSIZE 10005 #define INF 0xfffffff using namespace std; struct Point { int index; int distance; Point(int t_index, int t_distance) { index = t_index; distance = t_distance; } friend bool operator < (Point a, Point b)...
ALGO
0.999807
4.20744
b657833c-df06-4c06-9954-0d864974a1b8
Andor0016/Petlja2020
Kvalifikacija 2/Zadatak 3/main.cpp
#include <iostream> #include <string.h> using namespace std; int main() { char abc[26]; strcpy(abc,"ABCDEFGHIJKLMNOPQRSTUVWXYZ"); long long int n,sz=1, x[26]={0},vsz; cin >> n; char abcd[n]; fflush(stdin); gets(abcd); for(int i=0; i<26; i++) for (int j=0; j<n; j++) ...
ALGO
0.999918
3.884319
9803b303-afb1-46c2-b2b3-e5fcb0ba3c91
edgeimpulse/edge-impulse-sdk-pack
edgeimpulse/edge-impulse-sdk/tensorflow/lite/micro/kernels/micro_tensor_utils.cpp
#include "edge-impulse-sdk/tensorflow/lite/micro/kernels/micro_tensor_utils.h" #include <algorithm> #include <cmath> #include <cstdint> #include <cstring> #include <limits> #include <utility> #include "edge-impulse-sdk/third_party/gemmlowp/fixedpoint/fixedpoint.h" // from @gemmlowp #include "edge-impulse-sdk/tensorf...
ALGO
0.98165
7.534788
9be5f99c-be46-4092-a47c-7d7762dc26b8
nadim45448/Leetcode-DSA
0048-rotate-image/0048-rotate-image.cpp
class Solution { public: void rotate(vector<vector<int>>& matrix) { int n=matrix.size(); // transpose matrix for(int i=0;i<n;i++){ for(int j=0;j<i;j++){ swap(matrix[i][j],matrix[j][i]); } } //reversing each row of the matrix for(int i=0;i<n;i++){ rev...
ALGO
0.99997
6.759007