uuid
string
repo_name
string
relative_path
string
content
string
category
string
algo_rel_score
float64
quality_score
float64
9ed11de2-674d-4b62-bc05-0f2907a39989
sayandip20/GeeksForGeeks
Difficulty: Medium/Indexes of Subarray Sum/indexes-of-subarray-sum.cpp
//{ Driver Code Starts #include <bits/stdc++.h> using namespace std; // } Driver Code Ends class Solution { public: vector<int> subarraySum(vector<int> &arr, int target) { // code here int left = 0; int right = 0; int sum = 0; while (right < arr.size()) { sum +...
ALGO
0.999586
6.37251
40f90b0a-1a68-4484-a501-d271690bf2c6
abdelqayyim/C-Tic-Tac-Toe
build-mac/Boost/libs/compute/perf/perf_bernoulli_distribution.cpp
#include <algorithm> #include <iostream> #include <vector> #include <boost/compute/system.hpp> #include <boost/compute/container/vector.hpp> #include <boost/compute/random/default_random_engine.hpp> #include <boost/compute/random/bernoulli_distribution.hpp> #include "perf.hpp" namespace compute = boost::compute; in...
TOOL
0.898076
4.707156
3d4f91ab-fce0-47c4-9d99-29353eadeb45
Dustzm/DataStructureForSlience
tree/DisjointSet.cpp
/** * @brief DisjointSet 并查集 * @author slience * @date 2023/11/28 16:13 **/ #include "iostream" using namespace std; const int SIZE = 10; //并查集数组 int uSet[SIZE]; //并查集权值 int uRank[SIZE]; /** * 初始化并查集 */ void makeSet(){ for(int i=0;i<SIZE;i++){ uSet[i] = i; uRank[i] = 0; } } /** * 查找根节点(...
ALGO
0.999741
5.044757
e823b87b-19d2-40b2-aef1-1b41a50cf646
fardinkhan69/xpsc-problem-solving
week3/Day1/maxsubarray.cpp
//{ Driver Code Starts #include <bits/stdc++.h> using namespace std; // } Driver Code Ends class Solution { public: long long maximumSumSubarray(vector<int>& arr, int k) { // code here int n = arr.size(),l=0,r=0; long long ans=0,sum=0; while(r<n){ sum += arr[r]; ...
ALGO
0.997891
6.211724
8669492f-a051-48bd-9357-2ae71ee2fe10
babayaga-13/Competitive-Programming
CODEFORCES/div.2/B_1_The_Strict_Teacher_Easy_Version.cpp
#include <bits/stdc++.h> #define ll long long #define endl "\n" #define yes cout << "YES" << endl #define no cout << "NO" << endl #define ln cout << endl #define all(v) v.begin(), v.end() #define count_one(x) __builtin_popcount(x) #define trailing_zero(x) __builtin_ctz(x) #define leading_zero(x) __builtin_clz(x) #defin...
ALGO
0.999545
4.287898
6c011d7c-16d2-4ca0-9aa1-6a296ccf8b12
tushar-amrit-6/Interview-Questions
Majority Element.cpp
/* Time Complexity: O(N) Space Complexity: O(1) Where 'N' is the number of elements in the given array/list */ vector<int> majorityElementII(vector<int> &arr) { int n = arr.size(); // Array for storing final answer. vector<int> majorityElement; // Variables for storing the elements which...
ALGO
0.999972
5.865209
daab7889-b3df-44d3-818a-699942be0dc6
hhkang94/LearnCplus
Basic/BAEKJOON/200NumberofIslands.cpp
#include <vector> #include <iostream> using namespace std; class Solution { public: void dfs(vector<vector<char>>& grid, int i, int j){ // 땅이 아닌 경우 종료 if (i < 0 || i >= grid.size() || j < 0 || j >= grid[i].size() || grid[i][j] != '1') return; grid[i][j] = '0'; dfs...
ALGO
0.999918
6.245279
52281b06-74e9-4710-9095-1f035a13f920
hareta0109/atcoder
submissions/abc/abc095/a.cpp
#include <iostream> #include <cstring> #include <algorithm> #include <vector> #include <string> #include <math.h> #include <iomanip> #include <limits> #include <list> #include <queue> #include <tuple> #include <map> #include <set> #include <sstream> #include <bitset> #include <string> using namespace std; #define MOD (...
ALGO
0.99614
3.375665
81a00725-52a5-4ae3-bf22-0518d56800bf
stonewinter/LeetcodeEx
cpp_LeetCode_algo_130.cpp
#include <iostream> #include <algorithm> #include <unordered_map> #include <vector> #include <queue> #include <unordered_set> #include <deque> using namespace std; vector<vector<int>> offset = { {-1,0}, {0,-1}, {0,1}, {1,0} }; struct COORD{ int r; int c; bool operator==(const COORD &coord...
ALGO
0.999463
5.078314
a8c849fe-f2f3-4b62-8e16-5a72f48273ae
ishandutta2007/codeforces
alexxela12345/normal/1251/C.cpp
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef long double ldb; template<typename T> istream &operator>>(istream &in, vector<T> &arr) { for (auto &el : arr) { in >> el; } return in; } template<typename T, typename TT> istream &operator>>(istream &in, pair<T, TT> &pp) { in >> pp.fir...
ALGO
0.999987
4.70612
6c36a9d0-e82c-4fbb-b828-e31de6b4f4a4
luckoo1/algorithm
CPP/programmers_R2/PROG_5_3.Error1_베스트앨범.cpp
#include <iostream> #include <string> #include <vector> #include <map> #include <algorithm> /* vector<string> c{"a", "a", "a", "b", "c"}; vector<int> d{2, 2, 2, 3, 4}; 반례가 있다. */ using namespace std; vector<int> solution(vector<string> genres, vector<int> plays) { map<string, vector<int>> hash_map; //hash_m...
ALGO
0.99928
5.216289
b45613af-2ccd-495b-bfe0-3e43459bc510
ayoubismaili/LLVM
lib/Analysis/StackLifetime.cpp
#include "llvm/Analysis/StackLifetime.h" #include "llvm/ADT/DepthFirstIterator.h" #include "llvm/ADT/STLExtras.h" #include "llvm/ADT/SmallVector.h" #include "llvm/ADT/StringExtras.h" #include "llvm/Analysis/ValueTracking.h" #include "llvm/Config/llvm-config.h" #include "llvm/IR/AssemblyAnnotationWriter.h" #include "llv...
TOOL
0.956117
7.803957
3950d421-8680-43e0-9779-e4be2f6f330f
rhyshawkins/AkiEstimate
InitialPhase/optimizer/optimizejoint.cpp
#include <exception> #include <stdio.h> #include <getopt.h> #include "likelihood.hpp" #include "autosigma.hpp" #include "simple.hpp" #include "quasinewton.hpp" static char short_options[] = "i:c:I:C:r:f:F:R:V:X:S:o:s:p:b:t:P:N:e:QWM:T:h"; static struct option long_options[] = { {"input-love", required_argument, 0...
ALGO
0.999471
5.604238
4b5aabb9-5fe8-4f8a-bef5-0cbad82aca18
113bommy/deepmind_codecontests_refine
cpp_source_filter_file/cpp_train_3934_15.cpp
#include "bits/stdc++h" using namespace std; int main(){ int n, m; cin >> n >> m; cout << (m >= n ? "unsafe" : "safe") << endl; }
ALGO
0.994631
3.870571
aa830d9c-6d11-43fc-9f57-31a87471ff52
MountEverestt/Beta.programming
1017.cpp
#include<bits/stdc++.h> #define ll long long #define vec vector #define st first #define nd second using namespace std; const int N=102, mod=1e9+7; int a[N][N], n, x, sumx[N], sumy[N], mem[N]; int main(){ ios::sync_with_stdio(0),cin.tie(0); cin >> n; int ch=0; for(int i=1; i<=n; i++){ for(int j=...
ALGO
0.999992
3.902614
5cdc0dd5-6651-4904-843f-93490d7c81c7
ishandutta2007/codeforces
yuto1115/normal/1552/A.cpp
#include<bits/stdc++.h> #define overload4(_1, _2, _3, _4, name, ...) name #define rep1(i, n) for (ll i = 0; i < ll(n); ++i) #define rep2(i, s, n) for (ll i = ll(s); i < ll(n); ++i) #define rep3(i, s, n, d) for(ll i = ll(s); i < ll(n); i+=d) #define rep(...) overload4(__VA_ARGS__,rep3,rep2,rep1)(__VA_ARGS__) #define rre...
ALGO
0.999907
4.586534
208572d5-201d-46f0-9014-5961265ea3d2
zdzapple/LeetCode
Maximum Subarray.cpp
class Solution { public: // Divide and Conquer int maxSubArray(int A[], int begin, int end) { if (begin == end) return A[begin]; int mid = (begin + end) / 2; int leftMax = maxSubArray(A, begin, mid); int rightMax = maxSubArray(A, mid+1, end); int middleMax = getCrossMax(A, begin, mid, end); return max...
ALGO
0.999973
5.558741
b687d161-6a88-4d35-9568-0b4fc81b678c
TaiKonne/Code_Forces
A_Technical_Support.cpp
#include <bits/stdc++.h> using namespace std; #define nl << '\n' #define vti vector<int> #define vtll vector<long long> #define yep cout << "YES" nl #define nope cout << "NO" nl #define ll long long #define lg long #define db double #define pb push_back #define bg begin() #define ed end() #define rbg rbegin() #define ...
ALGO
0.999422
4.548429
ac3ce6ef-5c8f-478c-8ee2-0541ff896091
jeete121/Coding
Programs/Practice/Prac/GraphAlgorithms/shortest_path_in_binary_matrix.cpp
#include <bits/stdc++.h> using namespace std; //define all 8 directions int dx[8]={-1,-1,-1,0,0,1,1,1}; int dy[8]={-1,0,1,-1,1,-1,0,1}; int vis[1001][1001]; int dist[1001][1001]; //function to check for //the cuurent cell is valid or not bool isValid(int x,int y,vector<vector<int>> &grid) { if(x<0||x>=grid.si...
ALGO
0.999953
5.583605
f7835fd3-ba35-4aa8-9451-332f8daa0e08
KangInyeong/codetree-TILs
240118/홀수만 더하기/add-only-odd-numbers.cpp
#include <iostream> using namespace std; int main() { int sumval = 0; int n, a; cin>> n; for(int i=0; i<n; i++){ cin >> a; if(a%2!=0 && a%3==0) { sumval += a; } } cout << sumval; return 0; }
ALGO
0.999972
4.163043
4be092cd-e41d-4abb-b973-c58cdac4ccc5
YilK/Programming_exercise
Codeup/《算法笔记》3.6小节/1785.cpp
#include <iostream> #include <string> using namespace std; int main() { string s1,s2; while(cin>>s1>>s2) { cout<<s1+s2<<endl; } return 0; }
ALGO
0.984652
3.549172
74752f3d-9a39-4282-98e0-084c7a222ade
amiteshkushwaha7/Striver-A2Z-Sheet
Step 6 - Linked List/Medium Problems of LL/160. Intersection of Two Linked Lists.cpp
/** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode(int x) : val(x), next(NULL) {} * }; */ class Solution { public: ListNode *getIntersectionNode(ListNode *headA, ListNode *headB) { int cntA = 0, cntB = 0; ListNode* currA = hea...
ALGO
0.999885
5.256492
481a1049-b5da-44fb-9019-68310141e4a2
Eunno-An/LeetCode
Linked List Cycle.cpp
1차 22-05-21 Success Time:11분 35초 Details Runtime: 7 ms, faster than 96.94% of C++ online submissions for Linked List Cycle. Memory Usage: 7.8 MB, less than 96.15% of C++ online submissions for Linked List Cycle. /** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ...
ALGO
0.99988
5.500003
0a7cd071-2fb1-42fa-b699-df5f2f4364e6
arriopolis/AOC2020
Day6/part2.cpp
#include <iostream> #include <string> #include <set> #include <algorithm> #include <vector> using namespace std; int main() { string s; set<char> questions; bool first = true; int ctr = 0; while (getline(cin,s)) { if (s.size() == 0) { // cout << questions.size() << " : "; // for (char c : que...
ALGO
0.998389
3.951221
05c76cf1-dcf6-464f-b941-a78dd137a1de
mbotsch/gm-meshproc-2023
src/01-reconstruction/reconstruction-poisson.cpp
#include "reconstruction.h" #include <poisson/poisson.h> using namespace pmp; //============================================================================= void reconstruct_poisson(const PointSet &pointset, SurfaceMesh &mesh, int depth, int...
ALGO
0.995439
5.508304
2da6519b-a119-4862-b013-dfbc4427d512
UnbearableFate/exercises
p202_easy/main.cpp
#include <iostream> #include <set> using namespace std; class Solution { public: bool isHappy(int n) { set<int>ok = {1,7,10,13,19,23,28,31,32,44,49,68,70,79,82,86,91,94,97}; set<int> results; do { results.insert(n); n = this->oneLoop(n); if (n ==...
ALGO
0.999718
5.889219
4c24d1a5-a917-4b50-bd9e-dcdfa2ee2bd6
Zlin0509/Zlin_ACM
_HDU/25 Spring/6/1002.cpp
// // Created by 27682 on 2025/4/11. // #include "bits/stdc++.h" #define endl '\n' using namespace std; typedef long long ll; typedef unsigned long long ull; typedef __int128 i128; typedef double db; typedef long double ldb; typedef vector<int> vi; typedef vector<ll> vll; typedef pair<int, int> pii; typedef pair<ll, ...
ALGO
0.999599
4.666044
699bd742-eb42-4b5e-923d-739281f1811e
Aquib-Nawaz/CP4-Book
UVa/10268.cpp
#include <iostream> #include <sstream> #include <string> #include <stack> using namespace std; int main(){ int x; string s; while(scanf("%d ", &x)==1){ getline(cin,s); stringstream ss(s); stack<int>st; int d,n; while(ss >> d)st.push(d); long long ans=0,p=1; ...
ALGO
0.999832
3.311713
f21b171e-b742-42a9-a272-68da72b2df28
sketchc89/ModelPredictiveController-P10
src/Eigen-3.3/doc/examples/Tutorial_ArrayClass_interop_matrix.cpp
#include <Eigen/Dense> #include <iostream> using namespace Eigen; using namespace std; int main() { MatrixXf m(2,2); MatrixXf n(2,2); MatrixXf result(2,2); m << 1,2, 3,4; n << 5,6, 7,8; result = m * n; cout << "-- Matrix m*n: --" << endl << result << endl << endl; result = m.array() * ...
ALGO
0.996782
4.306757
982c085e-588f-4353-abde-17344a1fd92f
SeBasT1fake/ImageProcess
src/buddy_allocator.cpp
#include "buddy_allocator.h" #include <iostream> #include <cmath> #include <algorithm> #include <cassert> BuddyAllocator::BuddyAllocator(size_t maxOrder) : maxOrder(maxOrder), totalAllocated(0) { poolSize = 1ULL << maxOrder; memoryPool = new char[poolSize]; // Initialize available blocks for each orde...
ALGO
0.961983
6.786886
427d9ead-b89d-44d1-bee4-a4bd75d10171
DevOpsAraj/dsa
Tree/02_treePrint.cpp
#include <bits/stdc++.h> using namespace std; class node { public: int data; node *left; node *right; node(int d) { this->data = d; this->left = NULL; this->right = NULL; } }; node *buildTree(node *root) { cout << "Enter the data : " << endl; int data; cin ...
ALGO
0.999781
4.865883
7be56dff-836f-4f5c-871f-58b4ca592334
agravi987/semester-II-all-notes
Oops_notes/module4/stl from kishor(AI-ML Engineer)/Asscociative container/1_set_problem.cpp
/* program that reads a list of words from the user stores them in a set to remove duplicates, an then prrints the unique words in alphabetical order. Input: apple orange banna apple grape orange Output: Unique words : apple banana grape orange */ #include<iostream> #include<set> usi...
ALGO
0.982816
5.227307
def31e07-3033-4f13-a747-2b82ad351313
asteroid5566/ZeroJudge
f281-志樺的亮度.cpp
// https://zerojudge.tw/ShowProblem?problemid=f281 #include<iostream> using namespace std; int main() { int min1 = 999999, min2 = 999999, n, l, c, temp; cin >> c; while (c--) { cin >> temp; if (temp < min1) { min2 = min1; min1 = temp; } else if (temp < min2) min2 = temp; } cin >> l; n = l - m...
ALGO
0.997984
3.280463
f172b6d6-570f-44c4-ba35-82cc714adea3
ribeiro-hr-pedro/ufu-computer-science
procedural-programming/homework-001/cpp/exercise-006.cpp
/* Student: Pedro Henrique Resende Ribeiro * Description: Convert from celsius to fahrenheit * Date: 2023-12-29 - Time: 00:20 */ #include <iostream> using namespace std; int main() { double celsius, fahrenheit; cout << "Enter a temperature in celsius: "; cin >> celsius; fahrenheit = celsius * (...
TOOL
0.893157
4.459167
7d9d9772-181e-4fa4-a31a-cca31481cb3c
Shruhil/CSES-solution
restauarnt.cpp
#include<bits/stdc++.h> using namespace std; int maxNumberCustomers(int n, int *a, int *b){ int maxNum = 0; int cnt = 0; sort(a, a+n); sort(b, b+n); int i=0, j=0; while(i<n && j<n){ if(a[i] < b[j]){ cnt++; i++; maxNum = max(maxNum, cnt); } ...
ALGO
0.999857
4.658809
97815898-5530-4352-95ea-42492b7ee9a2
timko1106/Analyser
src/encryption/aes.cpp
#ifndef ENCRYPTION_AES_CPP_ #define ENCRYPTION_AES_CPP_ #include "../../include/analyser/encryption/aes.hpp" #include <array> const aes::byte SBOX[256] = {0x63, 0x7c, 0x77, 0x7b, 0xf2, 0x6b, 0x6f, 0xc5, 0x30, 0x01, 0x67, 0x2b, 0xfe, 0xd7, 0xab, 0x76, 0xca, 0x82, 0xc9, 0x7d, 0xfa, 0x59, 0x47, 0xf0, 0xad, 0xd4, 0xa2,...
ALGO
0.991118
5.867594
f768c18a-5b83-4f44-9160-3e24f2fbccfb
ragingjedi/projects
hw4p1.cpp
#include <iostream> #include<bits/stdc++.h> using namespace std; int func(string arr,int n) { multiset<int> myset; myset.insert(arr[0]); int count = 0; multiset<int>::iterator x; for (int i=1; i<n; i++) { myset.insert(arr[i]); x= myset.upper_bound(arr[i]); count += distance(x, myset.end()); } return count; } i...
ALGO
0.999801
4.786648
bd90e4d5-14ff-45d6-b806-cead3b8787af
BidyasagarAnupam/DS-Implementation
Linked List/3_circular_ll.cpp
#include <bits/stdc++.h> using namespace std; struct node { int info; node *next; }; node *start = NULL; node *getNode() { node *newNode = new node; cout << "Enter the data: "; cin >> newNode->info; newNode->next = NULL; return newNode; } void create_circular_list(int size) { node *pt...
ALGO
0.998147
4.532936
e985f4d6-55f1-46ce-a1f5-ce91fba16687
Mthrun/ScatterDensity
src/c_inPSphere2D_parallel.cpp
#include <RcppArmadillo.h> #include <RcppParallel.h> #include <vector> #include <cmath> using namespace Rcpp; using namespace RcppParallel; //We define a PSphereWorker struct inheriting from RcppParallel::Worker. Its job is to loop over a range of bins (using a flattened index) and, for each bin, identify: //The d...
ALGO
0.999982
7.673579
2569b16b-1df5-4b85-ac7f-c00a26470cfc
minguncho/opencilk-test-eec289q
crossword/main.cpp
#ifndef _WIN32 #include <time.h> // https://stackoverflow.com/questions/459691/best-timing-method-in-c #endif #include "grid.h" #include "options.h" #include "wordlist.h" #include <cassert> #include <fstream> #include <map> #include <vector> #include <memory> #include <cilk/cilk.h> #include <cilk/cilk_api.h> #include <...
ALGO
0.999111
6.269925
ef3efd40-0358-4ee6-a784-6dcd1975a2ff
Requiem-of-Zero/CIS250-Solutions
final-exam-programs/program1/main.cpp
#include <iostream> // Fixed: Uncommented the include syntax using namespace std; // Fixed: Corrected standard to std // Step 1a: Create BASE class class polygon { protected: int width, height; public: void set_values(int inW, int inH) { // Fixed: Removed space for "inH" width = inW; height = inH; ...
TOOL
0.9634
7.296791
9bdd978f-a153-4a95-84f5-91ec053d2a40
0-jij-0/CompetitiveProgramming
Problems Archive/2000 - 2999/2083 - ICPC Balloons.cpp
#include <iostream> #include <string> #include <vector> using namespace std; string s; int main() { ios::sync_with_stdio(0); cin.tie(0); cout.tie(0); int t; cin >> t; while (t--) { int n; cin >> n >> s; int res = 0; vector<int> vis(26, 0); for (char c : s) { if (vis[c - 'A']) { res++; continue; } vis...
ALGO
0.999956
5.390602
8e306bb2-8ddf-49f7-b7a4-cda61ca512dd
subratamondalnsec/Pw-cpp-code
21Greedy/class/13MInimum_Number_of_Arrow_to_Brust_Bollons_Leetcode-452.cpp
#include <iostream> #include <vector> #include <algorithm> using namespace std; // Comparison function for sorting intervals based on the end time bool cmp(vector<int>& a, vector<int>& b) { return a[1] < b[1]; } class Solution { public: int findMinArrowShots(vector<vector<int>>& intervals) { sort(inte...
ALGO
0.999966
6.768455
7c1c8151-c9dd-4467-906c-27dc5127fff2
createamind/a3c333
PycharmProjects/autodriver/car-simulator/torcs-1.3.6/src/drivers/berniw/spline.cpp
#include <math.h> #include <stdlib.h> #include "spline.h" #ifdef DMALLOC #include "dmalloc.h" #endif /* solving tridiagonal nxn matrix with Givens-Rotations in linear time O(n) [ a1 b1 0 0 0 .......... ] [ c1 a2 b2 0 0 ...........] [ 0 c2 a3 b3 0 ...........] [ ...........................] [ .............
ALGO
0.999946
6.008465
ffaac080-f219-4253-bf2a-327251476e8a
visarbuza/Cpp-SystemMonitor
src/processor.cpp
#include "processor.h" #include "linux_parser.h" #include <iostream> #include <string> // Return the aggregate CPU utilization float Processor::Utilization() { if (currentValues.size() == 0) { ParseCurrentState(); return 0.0; } previousValues = currentValues; currentValues.clear(); ParseCurrentStat...
TOOL
0.859245
4.928917
154dfd3f-0251-479e-b59f-5c37c49cf4ea
ritvik1799/DSA-questions
509-fibonacci-number/509-fibonacci-number.cpp
class Solution { public: int fib(int N) { if(N < 2) return N; int a = 0, b = 1, c = 0; for(int i = 1; i < N; i++) { c = a + b; a = b; b = c; } return c; } };
ALGO
0.999995
5.821714
092f352c-8717-4467-b2b3-96fafaafd06a
sanjanprakash/Hackerrank
Algorithms/Greedy/maximumperimetertriangle.cpp
#include <cmath> #include <cstdio> #include <vector> #include <iostream> #include <algorithm> using namespace std; int main() { int n,i = 0,temp,flag = -1; cin >> n; vector<int> X; for (i = 0; i < n; i++) { cin >> temp; X.push_back(temp); } sort(X.begin(),X.end()); for(i = n -...
ALGO
0.999976
3.151623
1939fbfa-4ab5-4f8b-b83f-27b3794cc843
amalija-ramljak/advent-of-code-2020
day04/day04.cpp
#include <iostream> #include <fstream> #include <sstream> #include <cstring> #include <vector> #include <regex> #include <map> #define BIRTH_YEAR "byr" #define ISSUE_YEAR "iyr" #define EXPIRATION_YEAR "eyr" #define HEIGHT "hgt" #define HAIR_COLOUR "hcl" #define EYE_COLOUR "ecl" #define PASSPORT_ID "pid" #define COUNTR...
ALGO
0.948507
6.047054
048fac0e-cc16-4ab9-b14a-09f2800090d8
alexandraback/datacollection
solutions_5709773144064000_0/C++/JohnSmith/tb.cpp
// // Qualification round 2014 problem B // // Usually built with g++ 4.4.5 on Linux // #include <iostream> #include <iomanip> #include <algorithm> #include <set> using namespace std; int main( int argc, char ** argv ) { cout << setprecision(12); unsigned int n; unsigned int i; cin >> n; f...
ALGO
0.999193
3.638428
5f8aa066-6296-4590-a749-9a71efb83841
aberry5621/Book-Exercise-2.12
Book Exercise 2.12/main.cpp
#include <iostream> #include <cmath> using namespace std; int main() { // insert code here... cout << "Find Runway Length \n"; // D double speed_input = 0.0; double accel_input = 0.0; double runway_length_calc = 0.0; // I cout << "Enter speed and acceleration: "; cin ...
ALGO
0.995806
4.326041
f5e2e225-b7fd-49a0-b821-1b756a35758d
Ibrahim-Hegazi/Codeforces-Problem-Set-2023-2024
B. Honest Coach (1360 B).cpp
#include <bits/stdc++.h> using namespace std; #define ll long long // Fast input/output void fast() { ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); } int main() { fast(); int t; cin >> t; x: while (t--) { int n; cin >> n; vector<int>v(n); ...
ALGO
0.999819
4.101288
6c59f832-6d12-47b6-836d-9a971791f342
RobeJohnGS/GAT350
ThirdParty/glm/test/core/core_func_integer_bit_count.cpp
// This has the programs for computing the number of 1-bits // in a word, or byte, etc. // Max line length is 57, to fit in hacker.book. #include <cstdio> #include <cstdlib> //To define "exit", req'd by XLC. #include <ctime> unsigned rotatel(unsigned x, int n) { if (static_cast<unsigned>(n) > 63) { std::printf("r...
ALGO
0.999217
4.846448
f98e7a03-379f-4089-a83a-6656720c0c3d
rirash/vm3
iMath.cpp
#include "iMath.h" void iMath::change_flag(int32_t res, Processor& cpu) noexcept { if (res < 0) cpu.psw.setSF(1); else cpu.psw.setSF(0); if (res == 0) cpu.psw.setZF(1); else cpu.psw.setZF(0); } void iMath::operator()(Processor& cpu) { cmd32 com = cpu.get_Command32(); uint16_t adr1 = 0, adr2 = 0; switch (com.bb...
TOOL
0.986971
4.932882
98fe4d22-afc7-4214-b00b-03485ac5e335
okuraofvegetable/PKU
1274.cpp
#include <cstdio> #include <cstring> #include <cstdlib> #include <cmath> #include <complex> #include <string> #include <sstream> #include <algorithm> #include <vector> #include <queue> #include <stack> #include <functional> #include <iostream> #include <map> #include <set> using namespace std; typedef pair<int,int> P; ...
ALGO
0.999406
3.791671
e6c10b66-4136-4be4-9bdb-a0795e567954
alinmihai/programming-c
12_pila/pila.cpp
#include <stdio.h> #include <stdlib.h> #define N 10 void push(int pila[N], int *cima, int numero){ pila[(*cima)++] = numero; } int pop(int pila[N], int *cima){ return pila[--(*cima)]; } int main (int argc, char *argv[]){ int pila[N]; int cima = 0; push(pila, &cima, 10); push(pila, &cim...
ALGO
0.998114
3.594358
7899165e-3e6e-4871-b119-b71876ea7d94
helianthuswhite/Opencv-notes
LearningOpenCV_Code/ch10_ex10_2.cpp
// Example 10-2. Kalman filter sample code // // Use Kalman Filter to model particle in circular trajectory. // #include "opencv/cv.h" #include "opencv2/highgui.hpp" #include "cvx_defs.h" //将汽车位置从角度转换为笛卡尔坐标的矩阵 #define phi2xy(mat) \ cvPoint( cvRound(img->width/2 + im...
ALGO
0.99735
4.078977
18d9f03b-c9b0-4765-a709-d9cabce093c2
sarvex/leetcode-bhai
lcof/面试题57. 和为s的两个数字/Solution.cpp
class Solution { public: vector<int> twoSum(vector<int>& nums, int target) { int l = 0, r = nums.size() - 1; while (1) { if (nums[l] + nums[r] == target) { return {nums[l], nums[r]}; } if (nums[l] + nums[r] > target) { --r; ...
ALGO
0.999964
6.421319
54f2b178-0dea-4537-ac0c-ee585eed5c6c
dvyas98/Assignment1
ExternalResources/assimp-master/code/PostProcessing/OptimizeGraph.cpp
/** @file OptimizeGraph.cpp * @brief Implementation of the aiProcess_OptimizGraph step */ #ifndef ASSIMP_BUILD_NO_OPTIMIZEGRAPH_PROCESS #include "OptimizeGraph.h" #include "ProcessHelper.h" #include <assimp/SceneCombiner.h> #include <assimp/Exceptional.h> #include <stdio.h> using namespace Assimp; #define AI_RE...
ALGO
0.944667
7.291901
7bbcbe3b-2a91-495d-8f2e-044f1be55ebe
mmxsrup/procon
srm/tco/2017/roundC/b.cpp
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef vector<int> vint; typedef pair<int,int> pint; typedef vector<pint> vpint; #define rep(i,n) for(int i=0;i<(n);i++) #define reps(i,f,n) for(int i=(f);i<(n);i++) #define each(it,v) for(__typeof((v).begin()) it=(v).begin();it!=(v).end();it++) #defi...
ALGO
0.999788
4.024095
a34f5de8-048e-4a6f-b5d4-f07675fe69a5
AnasAbdullh/Soultions_Problems_Solving_Level2
S37.cpp
#include <cstdlib> #include <iostream> using namespace std; // Function to add an element to an array void AddArrayElement(int arr[], int &length, int number) { if (length < 100) { // Check array bounds arr[length] = number; length++; } else { cout << "Array is full. Cannot add more elements." ...
TOOL
0.944948
5.083017
bf79571b-5108-4d71-9aa0-181819cd6d23
theCmaker/ZZ3_project
sources/heuristics/heuristic_sequence.cpp
#include "heuristic_sequence.hpp" #include <cmath> #include <limits> #include <algorithm> Heuristic_sequence::Heuristic_sequence(const Problem & p) : Heuristic(p) { _name = "Sequence"; } Heuristic_sequence::~Heuristic_sequence() {} void Heuristic_sequence::run() { std::vector<unsigned> vec(_problem.nbMobiles()); ...
ALGO
0.999774
4.987601
a7f80a86-79a5-4b39-9328-884805197db1
firiexp/contest_log
codeforces/1101B.cpp
#include <iostream> #include <algorithm> #include <vector> #include <iomanip> #include <map> #include <set> #include <queue> #include <stack> #include <numeric> static const int MOD = 1000000007; using ll = long long; using u32 = unsigned; using namespace std; template<class T> constexpr T INF = ::numeric_limits<T>::...
ALGO
0.998104
4.507015
488b1117-aa7a-43a3-b491-2c343479e0c9
faros-ai/duckdb-java
src/duckdb/ub_src_core_functions_aggregate_algebraic.cpp
#include "src/core_functions/aggregate/algebraic/avg.cpp" #include "src/core_functions/aggregate/algebraic/covar.cpp" #include "src/core_functions/aggregate/algebraic/stddev.cpp" #include "src/core_functions/aggregate/algebraic/corr.cpp"
TOOL
0.959923
6.465656
8cd62d85-dab1-424e-ba3a-6bd72a1ea4f3
SHIVANGISINGH1/DSA-codes
dp/leetcode/min_climb_stairs.cpp
#include<iostream> #include<vector> using namespace std; class Solution { public: int minCostClimbingStairs(vector<int>& cost) { int n = cost.size(); vector<int> dp(n+1,0); dp[n] = 0; for (int idx=n-1; idx>=0; idx--) { int p1 = idx+1<=n ? cost...
ALGO
0.999923
5.706429
c681778b-cff6-41e1-affa-3193b33bc85b
withtahmid/cp
Codeforces/2023-09-21_[Div-4]_898/C.cpp
/** * * Author: withtahmid * Created: 2023-09-21 20:31:49 * **/ #include <bits/stdc++.h> using namespace std; #ifdef LOCAL #include <debug.h> #else #define debug(...) #define dbg(...) #endif #define endl '\n' #define pb push_back #define all(v) v.begin(),v.end() #define rall(v) v.rend(), v.rbegin() #define sp(n) s...
ALGO
0.999522
5.905642
1f677409-52ba-4a2a-87b7-72b17688d819
ishandutta2007/codeforces
redstar_13/normal/696/D.cpp
#define inf 0x3f3f3f3f3f3f3f3fLL #include<bits/stdc++.h> #define INPUT_LEN 1000 #define NN 222 #define C 26 using namespace std; typedef long long INT; template<typename T, typename U> inline void smax(T &a, const U &b) {if(a<b) a=b;} char gchar(){static char tbuf1[INPUT_LEN],*tmp_st=tbuf1,*tmp_ed=tbuf1;if(tmp_st==tmp...
ALGO
0.999792
3.389867
8ca598ab-b768-4b61-a7e9-25cfa31a00a8
RinCloud/TrickCatcher
Datasets/TrickyBugs/GenProgs/tc_generated_progs_cpp/p03333/p03333_num4_parsed.cpp
#include <iostream> #include <algorithm> #include <vector> int main(){ int n; std::cin >> n; std::vector<int> l(n), r(n); for(int i = 0; i < n; i++){ std::cin >> l[i] >> r[i]; } std::sort(l.begin(), l.end()); std::sort(r.begin(), r.end()); int y = 0; while(r[y...
ALGO
0.999977
4.424623
c4d28ecc-03bf-4b89-92c8-90ec382ab460
yash3001/Competitve-Programming
CSES/Problems/01. Introductory/missing_number.cpp
/* @author -> gamma30 */ #include <bits/stdc++.h> #include <limits> #define pb push_back #define eb emplace_back #define x first #define y second #define all(x) (x).begin(), (x).end() #define rall(x) (x).rbegin(), (x).rend() #define forf(t,i,n) for(t i=0;i<n;i++) #define forr(t,i,n) for(t i=n-1;i>=0;i--) using namesp...
ALGO
0.999457
4.030423
6c06170d-59a1-41eb-93cb-fc760675a369
FalconMadhab/PPE-Deepstream
nvdsinfer_custom_impl_Yolo/nvdsparsebbox_Yolo.cpp
#include <algorithm> #include <cmath> #include <sstream> #include "nvdsinfer_custom_impl.h" #include "utils.h" #include "yoloPlugins.h" extern "C" bool NvDsInferParseYolo( std::vector<NvDsInferLayerInfo> const& outputLayersInfo, NvDsInferNetworkInfo const& networkInfo, NvDsInferParseDetectionParams const&...
ALGO
0.973718
5.867761
baa37883-fa0c-4fc2-a170-40416d86d7e1
ArmyGuy255A/AbnSmurfCR10
buildroot/share/PlatformIO/variants/MARLIN_F103Rx/variant.cpp
#include "pins_arduino.h" #ifdef __cplusplus extern "C" { #endif const PinName digitalPin[] = { PA_0, PA_1, PA_2, PA_3, PA_4, PA_5, PA_6, PA_7, PA_8, PA_9, // RXD PA_10, // TXD PA_11, // USB D- PA_12, // USB D+ PA_13, // JTDI PA_14, // JTCK PA_15, PB_0, PB_1, PB_2, PB_3, // J...
CONFIG
0.868652
3.818233
e5ffc10f-c616-4572-9a4a-1f222ce31345
pingchungchang/CP
ABC229D.cpp
#include <bits/stdc++.h> using namespace std; int main(){ ios::sync_with_stdio(0);cin.tie(0);cout.tie(0); string s; int n; cin>>s>>n; int pref[s.size()+1] = {}; s = "#"+s; for(int i = 1;i<s.size();i++){ if(s[i] != 'X')pref[i] = 1; pref[i] += pref[i-1]; } int p = 1; ...
ALGO
0.999862
3.788814
0583933c-82e9-4635-a4d7-21bff7336475
lchyeon0123/kairos_project
libraries/opencv/samples/cpp/phase_corr.cpp
#include "opencv2/core.hpp" #include "opencv2/videoio.hpp" #include "opencv2/highgui.hpp" #include "opencv2/imgproc.hpp" using namespace cv; int main(int, char* []) { VideoCapture video(0); Mat frame, curr, prev, curr64f, prev64f, hann; char key; do { video >> frame; cvtColor(fram...
ALGO
0.938503
4.465924
401d14d3-188c-48e7-8607-2a94b6f43722
carnato/Algo
UVa Online Judge/Spanning Trees/Reconnect Computers (908)/Kruskal.cpp
#include <bits/stdc++.h> using namespace std; class UnionFind { vector<int> parent, rank; public: UnionFind(int n, bool oneBasedIndexing); void make_set(int v); int find_set(int v); void union_sets(int a, int b); }; UnionFind :: UnionFind(int n, bool oneBasedIndexing = false) { if(oneBasedIndexing) n++; ...
ALGO
0.999941
4.483975
7b522dbc-53b9-40e6-baf8-a730f3a715d5
apache/mesos
src/linux/seccomp/seccomp_parser.cpp
#include <string.h> // For strlen(). #include <stout/json.hpp> #include <stout/nothing.hpp> #include <stout/strings.hpp> #include <stout/os/read.hpp> #include "linux/seccomp/seccomp.hpp" #include "linux/seccomp/seccomp_parser.hpp" using std::string; using process::Owned; using mesos::internal::seccomp::SeccompFil...
TOOL
0.970397
6.965905
49972fe4-3963-4642-bc00-b87d4e031905
s4ng/algorithm
1000-9999/1000/1926.cpp
// 그림 #include <bits/stdc++.h> using namespace std; int board[502][502]; bool vis[502][502]; int n, m; int dx[4] = {1, 0, -1, 0}; int dy[4] = {0, 1, 0, -1}; int main(){ cin >> n >> m; for(int i = 0; i < n; i++) for(int j = 0; j < m; j++) cin >> board[i][j]; int mx = 0; int num = 0; for(int i = 0; i < n; i+...
ALGO
0.999792
3.716115
4b11eef8-e99e-42bc-86aa-836aa9fbb61e
SMiles02/CompetitiveProgramming
CodeChef/Cook-Off/August Cook-Off 2020/RBTREES.cpp
#include <bits/stdc++.h> #define ll long long #define sz(x) (int)(x).size() using namespace std; const int MAXN 1e5+10; vector<int> edges[MAXN]; int am[2]; void dfs(int c, int p, int h) { } void solve() { int n,u,v; cin>>n; for (int i=1;i<=n;++i) edges[i].clear(); for (int i=1;i<n;++i) ...
ALGO
0.999698
4.217199
373c5398-2e74-4703-b4a1-4b53d44f10f0
Ctnn/mp4_file_Json
mp4_Json.cpp
#include <iostream> #include <fstream> #include <filesystem> #include <vector> #include <nlohmann/json.hpp> using json = nlohmann::json; namespace fs = std::filesystem; // JSON verisini temsil eden bir struct struct VideoItem { int id; std::string name; // VideoItem'dan JSON nesnesi oluşturan işlev j...
TOOL
0.87416
6.293789
09b51633-1f1c-4067-938c-3a47f5933bc9
bakulman/codes
DP_to_set_tri.cpp
//三进制状态压缩, hdu3001 #include<bits/stdc++.h> using namespace std; #define de(x) cout << (#x) << " = " << (x) << endl; #define de2(x, y) cout << (#x) << " , " << (#y) << " = " << (x) << " ~ " << (y) << endl; #define endl '\n' #define fi(x) for(int i = 1; i <= x; ++i) #define fi0(x) for(int i = 0; i < x; ++i) #define fj(n...
ALGO
0.999864
3.931127
30cc73e8-c79e-4cde-91de-5781485de958
AlterFritz88/interactive_learn_cpp
task_2_8_15.cpp
#include <bits/stdc++.h> using namespace std; int main(){ int a, b, sum = 0; cin >> a >> b; for (int i = a; i <= b; i++){ sum += i / 10 % 10; } cout << sum; return 0; }
ALGO
0.998661
3.755619
a900dc21-f7b0-4bf7-b4db-3187075e6ebf
wcysai/Calabash
Petrozavodsk Winter-2019. Yandex Cup 2019/A.cpp
#include<bits/stdc++.h> #define right rrrrrrr using namespace std; const int maxn = 3e5+100; typedef pair<int,int> P; typedef long long ll; int n; P a[maxn]; int ans[maxn],ans_idx; void output(){ for (int i=0;i<n;i++){ printf("%d ",ans[i]+1); } puts(""); } struct Node{ ll val; int id; bo...
ALGO
0.999993
4.217774
78b401e6-44d9-40fd-9237-130fa98571bd
arvindsinghdevra7/DSA-Opps-practice
Introduction.homework/lakshy.cpp
#include <iostream> using namespace std; #define AUTHOR "arvind" int main(){ int a,b,c; cin>>a>>b>>c; cout<<max(a,max(b,c))<<endl; cout<<"written :"<<AUTHOR <<endl; return 0; }
ALGO
0.999556
3.562317
27bcd83b-2ae9-49d8-95a1-d362cfe98708
engineersajid/LinkedList
Solutions/store_value_right_position.cpp
/* Md Sajedur Rahman ID - 22231203060 */ // Create a linked list and search a user-given value: #include <iostream> using namespace std; struct Node { int value; Node *next; }; // Function to insert a value in a sorted linked list void insertValue(Node *&head, int newValue) { Node *newNode = ne...
ALGO
0.999979
5.662244
aaf48191-1759-4217-b914-986cc59b5e7c
yiminyangguang520/chtmoneyhub
moneyhub/ThirdParty/json/src/jsontestrunner/main.cpp
#include <json/json.h> #include <algorithm> // sort #include <stdio.h> #if defined(_MSC_VER) && _MSC_VER >= 1310 # pragma warning( disable: 4996 ) // disable fopen deprecation warning #endif static std::string readInputTestFile( const char *path ) { FILE *file = fopen( path, "rb" ); if ( !file ) ret...
TEST
0.853649
6.458588
3a126846-fb0d-4671-8886-48d7bc3475ed
yooniversal/PS
codeforces/263_A.cpp
#include <iostream> #include <string> #include <cstring> #include <cstdio> #include <vector> #include <deque> #include <queue> #include <stack> #include <cmath> #include <algorithm> #include <map> using namespace std; typedef long long ll; int main() { cin.tie(nullptr); cout.tie(NULL); ios_base::sync_with_stdio(f...
ALGO
0.999653
3.510391
5b0780b0-67d2-4e91-8ad8-4f7cdd8213fc
IEEE-NITK/SummerProjects17
Competitive-Coding/Assignment-0/himanshu/smpair.cpp
#include <iostream> #include<algorithm> using namespace std; int main() { int t,n,i,a[100001]; cin >> t; while(t--) { cin >> n; i=0; while(i<n) { cin >> a[i]; i++; } sort(a,a+n); cout << a[0] + a[1] << endl; } return 0; }
ALGO
0.999883
3.620306
d92ba1ee-0d2a-4f70-9fae-20e455ac5f77
Dhnnjaysrma/leetcode-progess_cpp
956 Tallest Billboard.cpp
class Solution { public: int tallestBillboard(vector<int>& rods) { const int sum = accumulate(rods.begin(), rods.end(), 0); vector<int> dp(sum + 1, -1); dp[0] = 0; for (const int h : rods) { vector<int> prev(dp); for (int i = 0; i <= sum - h; ++i) { if (prev[i] < 0) co...
ALGO
0.99943
6.066295
6651e222-0aee-4e66-bb76-b195279f5c07
tayu0110/atcoder
abc/abc220a.cpp
#include<iostream> #include<iomanip> #include<string> #include<vector> #include<algorithm> #include<utility> #include<tuple> #include<map> #include<queue> #include<deque> #include<set> #include<stack> #include<numeric> #include<cstdio> #include<cstdlib> #include<cstring> #include<cmath> #include<cassert> using namespa...
ALGO
0.999767
3.421293
c2bf55ba-6e34-4095-8b6a-407b948beea9
mariaaktermukti/vjudge
B_gotta_Catch_Em_All.cpp
#include <bits/stdc++.h> using namespace std; int main() { int T; cin>>T; while(T--) { int N,X,Y; cin>>N>>X>>Y; int totalcost=0; for(int i=0;i<N;i++) { int difficulties; cin>> difficulties; totalcost= totalcost+ min(difficulties...
ALGO
0.999505
3.570369
47e1dc58-0fcd-496c-9fdc-09c2acd1eacf
rathour08/Array-questions-solution
0704-binary-search/0704-binary-search.cpp
class Solution { public: int search(vector<int>& nums, int target) { int s=0; int e=nums.size()-1; while(s<=e){ int mid= s+(e-s)/2; if(target==nums[mid]){ return mid; } else if(target<nums[mid]){ e=mid-1; ...
ALGO
0.999929
6.191529
2180a270-93e8-434f-9ffc-7b57a208cc0a
Samia2001/Challange-100
Difficulty 1300/05.CF_1279B.cpp
#include<bits/stdc++.h> #include<ext/pb_ds/assoc_container.hpp> #include<ext/pb_ds/tree_policy.hpp> #define ll long long #define endl "\n" #define rep(X,Y) for(X=0;X<Y;X++) #define rep1(X,Y) for(X=1;X<=Y;X++) #define rrep(X,Y) for(X=Y-1;X>=0;X--) #define rrep1(X,Y) for(X=Y;X>=1;X--) #define ml l...
ALGO
0.999978
3.695024
a8c6517f-d347-4f70-b05c-58c85fae4321
prakharguptaujjain/DSA_assignments
Saves/11week/1lovesn.cpp
#include <bits/stdc++.h> using namespace std; typedef long long int ll; typedef vector<int> v32; typedef vector<ll> v64; typedef vector<ll> vi; typedef vector<pair<int, int>> pi; #define pb push_back #define mp make_pair #define e cout << endl; #define r return; #define er \ cout << endl; \ return; #defi...
ALGO
0.999941
4.025411
dad87f35-148f-4232-87ab-b63bdc2cd193
MethanePowered/MethaneKit
Modules/Platform/Utils/Sources/Methane/Platform/Utils.cpp
#include <Methane/Platform/Utils.h> #include <Methane/Instrumentation.h> namespace Methane::Platform { inline void SplitInChunks(const std::string_view str, size_t max_chunk_size, std::vector<std::string_view>& output) { if (str.empty()) { output.emplace_back(str); return; } for (size_...
TOOL
0.96465
6.682167
3f4930bc-c1b4-44ee-877a-0e6a11b6e226
kinredon/Harmonious-Teacher
cvpods/cvpods/layers/csrc/cocoeval/cocoeval.cpp
using namespace pybind11::literals; namespace cvpods { namespace COCOeval { // Sort detections from highest score to lowest, such that // detection_instances[detection_sorted_indices[t]] >= // detection_instances[detection_sorted_indices[t+1]]. Use stable_sort to match // original COCO API void SortInstancesByDetec...
DATA
0.996937
7.853813
09a46b49-a518-44b1-b32d-8ed77e006058
TheFenrisLycaon/DSA-C--
cp/CodeForces/1000-1099/1004C.cpp
#include <cstdio> #include <iostream> #include <vector> #include <set> typedef long long ll; int main(){ ll n; scanf("%lld", &n); std::vector<ll> v(n); for(ll p = 0; p < n; p++){scanf("%lld", &v[p]);} std::vector<ll> right(n); std::set<ll> ls, rs; std::vector<ll> rq(n, 0); for(ll p = n - 1; p...
ALGO
0.999934
3.690101
fa0513d6-c1a0-42c9-94b9-a79ef33bf22b
shubhamnegi9/MyLeetCodeSolutions
1700-minimum-time-to-make-rope-colorful/minimum-time-to-make-rope-colorful.cpp
class Solution { public: int minCost(string colors, vector<int>& neededTime) { int minTime = 0; int n = colors.size(); // Taking 2 pointers 'start' and 'end' int start = 0; int end = 0; while(start < n && end < n) { // groupMax for tracking maximum time in...
ALGO
0.999826
6.387053
19586e19-4283-4872-8f61-12ba968f7cbc
icinghuan/Con-oj
百度之星 2018/8.11 初赛(A)/1002.cpp
#include<iostream> #include<cstdio> #include<cmath> #include<algorithm> #include<stack> #include<queue> #include<map> using namespace std; class Deque{ int val; Deque pre; Deque next; Deque(int val) { this.val = val; } }; void read(int &x){ char ch = getchar();x = 0; for (; ch < '0...
ALGO
0.999785
3.730216
d375bcfd-a2cb-425c-9da5-6d6e6aca8f63
Capzera/Cpp
LGOJ/B3614.cpp
#include <bits/stdc++.h> using namespace std; string op; unsigned long long t, n, x; int main() { cin.tie(nullptr)->sync_with_stdio(0); cin >> t; while (t--) { cin >> n; vector<unsigned long long> stk; while (n--) { cin >> op; if (op == "push") { cin >> x; stk.push_back(x); } if (op == "pop...
ALGO
0.998498
4.859322
e9bf15df-0144-4c61-a886-123fa07ac142
Tukkel/AOD
Terkel/Hand-in_1/Hand-in_1-1/main.cpp
#include <iostream> #include <vector> #include <cstdlib> const int M = 1000; const int N = 10000; using namespace std; int main() { srand(time(NULL)); vector<int> arr; int gen; int matches = 0; for (size_t i = 0; i < M; i++) { arr.push_back(rand() % (M * 10)); } for (size_t i = 0; i < N; i++) { gen =...
ALGO
0.998173
3.228132
87ea36ac-5590-479d-8b25-efce1e1e5867
GabrielWechta/warm_cedar
rok_2/algorytmy_struktury_danych/250111/List_2/zad1.cpp
#include <iostream> #include <chrono> #include <fstream> #include <random> using namespace std; /********************UTILITIES********************/ void printArray(int array[], int size) { for (int i = 0; i < size; i++) { cout << array[i] << " "; } cout << endl; } bool checkIfSorted(const int ar...
ALGO
0.998815
5.709363
3ff98d71-c656-4c2c-9f2e-ae33a08ed4f1
matpx/blendini
src/extern/libigl/tutorial/203_CurvatureDirections/main.cpp
#include <igl/avg_edge_length.h> #include <igl/cotmatrix.h> #include <igl/invert_diag.h> #include <igl/massmatrix.h> #include <igl/parula.h> #include <igl/per_corner_normals.h> #include <igl/per_face_normals.h> #include <igl/per_vertex_normals.h> #include <igl/principal_curvature.h> #include <igl/read_triangle_mesh.h> ...
ALGO
0.984031
5.926027