uuid
string
repo_name
string
relative_path
string
content
string
category
string
algo_rel_score
float64
quality_score
float64
112f81e2-1837-4214-b8fb-9441a6d54db0
aritradev/codeforces-800-solutions
1766A.cpp
#include <iostream> #include <string> using namespace std; int main() { int t; cin >> t; while (t--) { string n; cin >> n; int len = n.size(); int ans; len -= 1; //cout<<len<<endl; ans = ((n[0])-'0') + (9 * len); cout << ans << endl; }...
ALGO
0.999694
4.247886
14b041d5-f372-49dd-a5d0-605435c4614a
gdt050579/AppCUI
AppCUI/src/Dialogs/FileDialog.cpp
#include "AppCUI.hpp" #include <set> #include <stack> namespace AppCUI { using namespace OS; using namespace Graphics; using namespace Controls; using namespace Dialogs; using namespace std::literals; constexpr uint32 ALL_FILES_INDEX = 0xFFFFFFFFU; static void ConvertSizeToString(uint64 size, char result[32]) { ...
TOOL
0.917003
6.484287
bce8e2f8-9b33-46b7-9c6a-ec54a03da0d0
parsa/blaze
blazemark/src/mtl/DMatSMatAdd.cpp
//================================================================================================= //================================================================================================= //************************************************************************************************* // Includes //****...
ALGO
0.98594
5.619654
76e856d5-7f9f-4cd8-a921-ba2e8735812d
dhustkoder/gists
cpp/problems/old/intervals.cpp
#include <iostream> int main() { constexpr const char* const intervalsText[] { "[0,25]", "(25,50]", "(75,100]" }; const auto getInterval = [](const float x)->const char* { if (x < 0.0) return -1; else if (x <= 25.0) return intervalsText[0]; else if (x <= 50.0) return intervalsText[1]; else if (x...
ALGO
0.977759
5.064623
9737668c-5b1d-4a98-8cbb-77a418257790
brobwind/rpi0w-brillo-m10-frameworks-av
media/libstagefright/codecs/amrnb/dec/src/d1035pf.cpp
/* ------------------------------------------------------------------------------ Pathname: ./audio/gsm-amr/c/src/d1035pf.c Date: 04/14/2000 ------------------------------------------------------------------------------ REVISION HISTORY Description: Updated template used to PV coding template. First attempt...
ALGO
0.999905
5.665246
b233c1e3-e7ce-4350-a845-5993ca4253a7
mitali-1703/C_plus_plus-Lab-Programs
8.cpp
//Write a program to check whether a no. is Armstrong no. or not. #include <iostream> using namespace std; int main() { int n, temp, a, sum = 0; cout << "Enter a number" << endl; cin >> n; temp = n; while (n != 0) { a = n % 10; sum = sum + a * a * a; n = n / 10; } ...
ALGO
0.999959
5.358839
c239d3a8-8a84-4174-8132-3c5efd3aabeb
jishad10/Problem-Solving
C++/LeetCode/3rd 10 Leetcode Problems/P-46.cpp
#include <iostream> #include <vector> using namespace std; class Solution { private: void solve(vector<int> nums, vector<vector<int>>& ans, int index) { // Base case if (index >= nums.size()) { ans.push_back(nums); return; } for (int j = index; j < n...
ALGO
0.999997
6.838069
07fb99c3-4916-4139-9527-a5257fa78045
Aayushman47/sorting
Bubblesort.cpp
#include <iostream> void bubbleSort(int arr[], int size) { for (int i = 0; i < size - 1; ++i) { for (int j = 0; j < size - 1 - i; ++j) { if (arr[j] > arr[j + 1]) { std::swap(arr[j], arr[j + 1]); } } } } int main() { int arr[] = {64, 34, 25, 12, 22, 1...
ALGO
0.999884
5.69894
d78e3d5e-c94b-4c1c-b53e-7679698f741f
WebKit/WebKit-http
Source/WebCore/layout/blockformatting/BlockFormattingContextGeometry.cpp
#include "config.h" #include "BlockFormattingContext.h" #if ENABLE(LAYOUT_FORMATTING_CONTEXT) #include "BlockFormattingState.h" #include "FormattingContext.h" #include "InlineFormattingState.h" #include "LayoutBoxGeometry.h" #include "LayoutChildIterator.h" #include "LayoutContext.h" #include "LayoutInitialContaining...
TOOL
0.871682
7.905707
6182eda0-a6a4-4804-827b-2073ac603295
sstuqtd/vocal
thridparty/boost/libs/icl/example/user_groups_/user_groups.cpp
/** Example user_groups.cpp \file user_groups.cpp \brief Shows the availability of set operations on interval maps. In the example there is a user group 'med_users' of a hosptial staff that has the authorisation to handle medical data of patients. User group 'admin_users' has access to administrative ...
ALGO
0.87604
5.316942
6df47799-49a7-43b7-9506-bafaaede09b0
VanshJohari29/DSA-Sheet-by-Arsh
4Sum.cpp
class Solution { public: vector<vector<int>> fourSum(vector<int>& nums, int target) { vector<vector<int>> ans; if(nums.size()<4) return ans; int n = nums.size(); sort(nums.begin(), nums.end()); for(int i=0;i<n;i++){ for(int j=i+1;j<n;j++){ int front=j+1, back=n-1; int target_2 = target -...
ALGO
0.999966
5.834754
31c45080-3047-4f01-a159-6dce3091ed2f
DukeWF/TJUT_CS_Helper
[必修]C++/2.25.cpp
#include <iostream> using namespace std; int fun(int &x,int &y) { if(x>y) { int t = x; x = y; y = t; } } double fun(double &x,double &y) { if(x>y) { double t = x; x = y; y = t; } } int main() { double a, b; cin>>a>>b; fun(a,b); cout<<a<<' '<<b; return 0; }
ALGO
0.999892
4.36893
504ac736-1474-48d9-aca9-462c71fce67b
smy999/practice_algorithm
baekjoon/입출력과 사칙연산/10869.cpp
#include <iostream> //C++ 표준 입출력 헤더파일 using namespace std; int main() { /* #10869*/ //unsigned int A, B; int A, B; cin >> A >> B; cout << A + B << "\n"; cout << A - B << "\n"; cout << A * B << "\n"; cout << A / B << "\n"; cout << A % B; }
ALGO
0.997815
3.506478
0be509ce-b9f5-4427-8de5-5adf442d3ca7
CSprograms/CPP_Online_Class_Programs
26-Online-Class.cpp
// PRACTICAL PROGRAM 04 - Friend Class and Friend Function #include <iostream> using namespace std; class c1 { private: int a; int b; public: c1(int t1, int t2) { a = t1; b = t2; } friend class c2; // Friend Class friend void get(c1); // Friend Fun...
ALGO
0.956519
5.415932
f83de343-e83f-4d99-a592-1b305d96700b
whysodrooled/BOJ
cpp/18310.cpp
#include <bits/stdc++.h> using namespace std; int n; int house[200000]; priority_queue<int> q; int result = 0; int temp; bool compare(int a, int b) { return a < b; } int main() { cin.tie(NULL); ios_base::sync_with_stdio(false); cin >> n; for(int i = 0; i < n; i++) { cin >> house[i];...
ALGO
0.999853
4.034881
cf9c311c-964f-4c46-be9f-4a1627111653
brownPenguin43/LCdaily
SearchSpace(BS)/productDistribution.cpp
// https://leetcode.com/problems/minimized-maximum-of-products-distributed-to-any-store/?envType=daily-question&envId=2024-11-14 class Solution { public: bool canDistribute(int mid, vector<int>& quantities,int n){ int strcnt=0; for(int i=0;i<quantities.size();i++){ // strcnt+=((quantiti...
ALGO
0.999995
6.468355
ed5ddd7f-5b39-47ff-946a-97cba24427aa
Viktoria574/seaod
Siaod6.cpp
#include <iostream> #include <ctime> #include <chrono> using namespace std; void createMas(int* massive, int n){ for (int i=0; i<n; i++){ massive[i]=rand()%100; //cin>>massive[i]; } } void revers(int arr[], int size) { for (int i = 0,j=size-1; i < (size/2); i++,j--) { int x = ...
ALGO
0.998847
3.841786
576e2b1e-509b-4792-9265-3fb6a163fad0
yuzu2yan/Atcoder_ABC
201~250/248/C.cpp
#include <iostream> #include <vector> int main() { int n, m, k; std::cin >> n >> m >> k; long long mod = 998244353; std::vector<std::vector<long long>> dp(n + 1, std::vector<long long>(k + 1, 0)); for (int i = 1; i <= m; i++) { dp[1][i] = 1; } for (int i = 2; i <= n; i++) { for (int j = 1; j <=...
ALGO
0.999989
5.067318
ca6e01f2-54d2-4d69-bde3-bc61b96dce5f
Ishwarendra/Contests
CODEFORCES_CONTEST/Previous Contests/Educational_122/B.cpp
#include <bits/stdc++.h> using namespace std; #define FIO ios_base::sync_with_stdio(false), cin.tie(NULL), cout.tie(0); #define all(a) ((a).begin()), ((a).end()) #define printarr(v, start, end)for (int _i = (start); _i < (end); _i++) cout << (v[_i]) << " ";cout << "\n"; #define log(v) for(auto __i = ((v).begin()); __i...
ALGO
0.999954
4.989148
5a980369-51df-4f09-81ce-0298d931fb82
rishabhkukreja30/Faang-questions
Linked List/Deep_Copy.cpp
node* copyRandomList(node* head) { node* temp = head; while(temp != NULL) { node* n = new node(temp->val); n->next = temp->next; temp->next = n; temp = temp->next->next; } temp = head; while(temp != NULL) { if(temp->random != NULL) { temp->next->random = temp->random->next; } temp = temp->nex...
ALGO
0.999592
3.273846
eaa07637-15f7-4810-a5e7-83c12f251cb3
Ph0en1xGSeek/ACM
Codeforces/1152B.cpp
#include <iostream> #include <stdio.h> #include <algorithm> #include <vector> using namespace std; int check(int x) { int pos = -1; int cnt = 0; while(x > 0) { ++cnt; if((x & 1) == 0) { pos = cnt; } x >>= 1; } return pos; } int main () { int x; ...
ALGO
0.999962
4.168055
d2e07820-929b-4f5e-8919-93fff8c81c0c
Dras227/solve-dsa-problems
string game.cpp
#include<bits/stdc++.h> #include<stdio.h> #include<string.h> #include<algorithm> #include<fstream> using namespace std; #define int long long void solve(); void dras227() { #ifndef dras2272000 freopen("input.txt", "r", stdin); freopen("output.txt", "w", stdout); #endif } void count_101() { cout << "\n\n\n\n...
ALGO
0.999835
3.596027
83421f81-d2ab-4011-9fa6-d94431a3e7eb
Lopes-7/jogo-single-ea872
model.cpp
#include <vector> #include <chrono> #include <thread> #include <iostream> #include "model.hpp" //implementacao da classe Posicao Posicao::Posicao(int x, int y) { this->x = x; this->y = y; } int Posicao::get_x() { return this->x; } int Posicao::get_y() { return this->y; } void Posicao::set_x(int novo) { this->x =...
ALGO
0.973088
4.189453
ee9b630e-ae1f-40ea-a1a4-35bbb512b275
j343my/spectrogarm-qt
thirdparty/opencv/samples/cpp/tutorial_code/snippets/imgproc_HoughLinesPointSet.cpp
#include <opencv2/core.hpp> #include <opencv2/imgproc.hpp> using namespace cv; using namespace std; int main() { Mat lines; vector<Vec3d> line3d; vector<Point2f> point; const static float Points[20][2] = { { 0.0f, 369.0f }, { 10.0f, 364.0f }, { 20.0f, 358.0f }, { 30.0f, 352.0f }, { 40.0f,...
ALGO
0.993671
3.559576
f5ca5f6a-93c7-4411-bda5-630a741cfb4e
an3m/brand_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.9988
6.76073
b3d47636-95c9-40b1-936f-91517e058391
sabbirahmedfahim/ProblemSolving
CSES/Sum_of_Two_Values.cpp
#include <bits/stdc++.h> #define nl '\n' #define ll long long #define all(c) c.begin(),c.end() #define print(c) for(auto e : c) cout << e << " "; cout << nl using namespace std; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); int n, x; cin>>n>>x; vector<int>a(n); for(auto &e : a) cin>>e; ...
ALGO
0.999944
4.705226
2f243e19-6431-4cbd-b4af-43104f1685ec
wangtongxue-369/xcpc_Code_file
file/nowcoder/2025winter_race1/G.cpp
#include <bits/stdc++.h> using namespace std; #define ll long long #define ull unsigned long long #define INF 0x3f3f3f3f #define PII pair<ll, ll> const ll mod = 1e9 + 7; const ll MAXN = 500005; const ll base1 = 131; const ll base2 = 127; ll _ = 1, n, m, ans = 0, a[MAXN], f[MAXN]; void solve() { cin >> n; ll sum...
ALGO
0.999761
4.307873
2c1f9922-4eda-4b0d-9e66-13bb66fcf968
MysticalFae/cppStuff
MessingAround2.cpp
#include <iostream> int main() { int firstArray [3]={1,2,3}; int secondArray [2][3] = { {1,2,3}, {4,5,6} }; int i; std::cout<<"For 1D array"<<"\n"; for(i=0;i<sizeof(firstArray)/sizeof(firstArray[0]);i++) //to get the size of an array, u have to do sizeof(array)/sizeof(...
TOOL
0.910616
3.184908
0bac9390-aabd-45f1-b0d3-ae76aa3cfa0e
FusionSP/android_frameworks_av
media/libstagefright/codecs/amrnb/enc/src/hp_max.cpp
/* ------------------------------------------------------------------------------ Filename: /audio/gsm_amr/c/src/hp_max.c Date: 02/01/2002 ------------------------------------------------------------------------------ REVISION HISTORY Description: Replaced "int" and/or "char" with OSCL defined types. Des...
ALGO
0.999618
7.219464
3a3c1146-58e4-4abb-82e2-38c95c69e305
akshay-koshti/coding-ninjas-assignments
28 Applications Of NT - 1/2 Advanced GCD.cpp
/* Varun explained its friend Sanchit the algorithm of Euclides to calculate the GCD of two numbers. Then Sanchit implements the algorithm int gcd(int a, int b) { if (b==0) return a; else return gcd(b,a%b); } and challenges to Varun to calculate gcd of two integers, one is a little integer and other in...
ALGO
0.999681
5.183518
5e2813fa-d6bf-478a-9713-29a5a38250ba
ollenorelius/RosCanBus
src/roscanbus/lib/xlnt/source/detail/serialization/zstream.cpp
#include <algorithm> #include <array> #include <cassert> #include <cstring> #include <fstream> #include <iomanip> #include <iostream> #include <iterator> // for std::back_inserter #include <stdexcept> #include <string> #include <miniz.h> #include <xlnt/utils/exceptions.hpp> #include <detail/serialization/vector_stream...
TOOL
0.879714
7.256657
4fce760b-2d65-4a34-b9c5-25351689d99a
Yugesh-0831/Coding
dsa_sem4.cpp
#include <iostream> using namespace std; int main(){ int plotreg_num; int k,j; cin>>plotreg_num; cin>>k; string prn= to_string(plotreg_num); string ans=prn; for(int i=0;i<prn.length();i++){ j=i; if((i%2)==0){ for(int l=0;l<k;l++){ j++; if(j>prn.length()){ j=0; ...
ALGO
0.99986
3.235986
29b79c1d-cb87-4c8c-b4e9-6059c40604a7
VivaXiZzz/Kub_Lab
Sem1/Programming_basics_C++/16/enc_temp_folder/21f4202732d6e6cc8fec8b1062979fc6/16.cpp
// 16.cpp : Этот файл содержит функцию "main". Здесь начинается и заканчивается выполнение программы. // #include <iostream> using namespace std; int rec1(int n) { if (n == 0)return 1; return 2 * rec1(n - 1) + 1; } int rec2(int n) { if (n == 0)return 1; if (n == 1)return 2; return 2 * rec2(n - 1)...
ALGO
0.999638
3.897776
5c0e5457-52b7-4bfd-8bff-1b9dbe014fe9
raincross7/code-similarity
codes/train_code/problem120/problem120_35.cpp
#include <bits/stdc++.h> using namespace std; #ifndef ONLINE_JUDGE #include <boost/multiprecision/cpp_int.hpp> #include <boost/multiprecision/cpp_dec_float.hpp> using bll = boost::multiprecision::cpp_int; using bdouble = boost::multiprecision::cpp_dec_float_100; #endif #ifdef LOCAL_DEV void debug_impl() { std::cer...
ALGO
0.999933
4.654047
8b9ef6e8-22ed-420e-8b80-be1e2c47d451
mohitmallick17/LeetCodeSolutions
312-burst-balloons/312-burst-balloons.cpp
class Solution { int solve(int i, int j, vector<int> &v, vector<vector<int>> &dp){ if(i > j)return 0; if(dp[i][j] != -1)return dp[i][j]; int ans=INT_MIN; for(int k=i;k<=j;k++){ int cost = (v[k] * v[i-1] * v[j+1]) + solve(i, k-1, v, dp) + solve(k+1, j, v, dp); ...
ALGO
0.999995
5.324574
76d45454-396b-4e5a-8332-b9d63daf6750
ishandutta2007/codeforces
ivan100sic/normal/920/C.cpp
// Retired? #include <bits/stdc++.h> using namespace std; typedef long long ll; typedef long unsigned long ull; typedef double long ld; int n; int a[200005]; string s; int main() { ios::sync_with_stdio(!cin.tie(0)); cin >> n; for (int i=0; i<n; i++) cin >> a[i]; cin >> s; for (int i=0; i<n-1; i++) { int ...
ALGO
0.999984
3.829371
ae61899c-c1a9-4db3-bfe6-67721b24e092
lisemi/CPP-Practice
07-DataStructure/Tree/BinaryTree.cpp
/* 1)在二叉树的第i层上最多有2i-1 个节点 。(i>=1) 2)二叉树中如果深度为k,那么最多有2k-1个节点。(k>=1) 3)n0=n2+1 n0表示度数为0的节点数,n2表示度数为2的节点数。 4)在完全二叉树中,具有n个节点的完全二叉树的深度为[log2n]+1,其中[log2n]是向下取整。 5)若对含 n 个结点的完全二叉树从上到下且从左至右进行 1 至 n 的编号,则对完全二叉树中任意一个编号为 i 的结点有如下特性: 1) 若 i=1,则该结点是二叉树的根,无双亲, 否则,编号为 [i/2] 的结点为其双亲结点; 2) 若 2i>n,则该结点无左孩子, 否则,编号为 2i 的结点为其左孩子结点; 3) ...
ALGO
0.999485
3.849329
511a1753-f7c2-494b-ab5a-bbc7f10564c9
RigoLigoRLC/Fritzing-build
boost_1_82_0/libs/hana/benchmark/make/compile.std.array.erb.cpp
#include <array> template <int i> struct x { }; int main() { constexpr std::array<int, <%= input_size %>> array = {{ <%= (1..input_size).to_a.join(', ') %> }}; (void)array; }
TOOL
0.900017
3.57223
8f84d63d-8eb0-4f3c-8b23-3933f49b8699
CircuitMess/Arduino-ESP8266
cores/esp8266/libb64/cdecode.cpp
/* cdecoder.c - c source to a base64 decoding algorithm implementation This is part of the libb64 project, and has been placed in the public domain. For details, see http://sourceforge.net/projects/libb64 */ #include <pgmspace.h> #include <stdint.h> #include "cdecode.h" extern "C" { static int base64_decode_value_s...
ALGO
0.980372
6.173221
894592c9-1dd7-4349-9149-021781a2035e
samad-yar-khan/dsa-problemset
DP/superUglyNumbers.cpp
#include<bits/stdc++.h> using namespace std; //https://leetcode.com/problems/super-ugly-number/submissions/ //https://www.youtube.com/watch?v=0FMKNDEopR0&ab_channel=Pepcoding class trip{ public: int numIndex ; int numPtr ; long long numVal; trip(int a , int...
ALGO
0.999991
5.543906
6a81e070-fd98-4c01-a14a-8e5720d0dfc9
jgillis/Ipopt
Ipopt/examples/ScalableProblems/LuksanVlcek7.cpp
#include "LuksanVlcek7.hpp" #ifdef HAVE_CONFIG_H #include "config.h" #else #include "configall_system.h" #endif #ifdef HAVE_CMATH # include <cmath> #else # ifdef HAVE_MATH_H # include <math.h> # else # error "don't have header file for math" # endif #endif #ifdef HAVE_CSTDIO # include <cstdio> #else # ifdef HAVE_S...
ALGO
0.998408
5.618197
ae3ca748-592e-4207-8a7b-4a6a86838aae
ishandutta2007/codeforces
physics0523/normal/1674/E.cpp
#include<bits/stdc++.h> using namespace std; int ceil(int a,int b){if(a%b==0){return a/b;}return (a/b)+1;} int main(){ ios::sync_with_stdio(false); cin.tie(nullptr); int n; cin >> n; vector<int> a(n+2); a[0]=1e9;a[n+1]=1e9; for(int i=1;i<=n;i++){cin >> a[i];} vector<int> ma=a; sort(ma.begin(),ma.en...
ALGO
0.9999
3.682861
b8653416-ebde-440b-86dd-d2926bb93466
Aryan-Ro-y/oodp-lab
week-3/4-Circle.cpp
#include <iostream> #include <cmath> using namespace std; class Circle { float radius; public: Circle(float new_radius) { radius = new_radius; } float compute_area() { return M_PI * radius * radius; } float compute_perimeter() { return 2 * M_PI * radius; } }; ...
ALGO
0.9257
5.499907
211561cc-56a1-4ef4-b0e7-27f5262a7b14
Bruno81930/japanopens_2008_obake
rcsc/action/bhv_before_kick_off.cpp
// -*-c++-*- /*! \file bhv_before_kick_off.cpp \brief behavior definition when playmode is BeforeKickOff */ ///////////////////////////////////////////////////////////////////// #ifdef HAVE_CONFIG_H #include <config.h> #endif #include "bhv_before_kick_off.h" #include "bhv_scan_field.h" #include "neck_turn_to_re...
ALGO
0.98913
6.129789
0ca5bb58-f775-48b8-ab89-0875d464acdc
lleviackermann/CpCodes
codeforces/D_Buying_Jewels.cpp
#include <bits/stdc++.h> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> using namespace std; using namespace __gnu_pbds; template <typename T> using ordered_set = tree<T, null_type, less<T>, rb_tree_tag, tree_order_statistics_node_update>; #define endl "\n" #define fo(i, n) for (i = 0;...
ALGO
0.999892
4.033718
a4e00852-8676-4372-a1ce-e033eb6d255d
takveer/Ds_File
DOUBLU_LINK_LIST EXP-4( ii ).CPP
/*Aim:Write a menu driven program that implements the following operations on a Doubly linked list. " Insert a new element at the beginning, end and in-between the given list " Delete an existing element " Search an element " Display all the elements*/ #include<iostream> using namespace std; class DLL { struct ...
ALGO
0.999666
3.939627
2a00d308-c1d6-47e4-8699-ea84d46b29fb
Shivam2501/MSI-GEM5
ext/systemc/src/sysc/utils/sc_hash.cpp
/***************************************************************************** sc_hash.cpp -- Implementation of a chained hash table with MTF (move-to-front). Original Author: Stan Y. Liao, Synopsys, Inc. CHANGE LOG AT END OF FILE **************************************************************...
ALGO
0.957039
6.123883
c83a6b06-7662-4622-abfd-6188834cdecb
Marionetista/ssbook_challenge
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.99887
6.783439
cb9257cd-df6f-446b-955e-adb355668ed4
DevJSter/dsa
Interview_DS_Algo/Linked List/Reverse Linked List.cpp
/* MY YOUTUBE VIDEO ON THIS Qn : https://www.youtube.com/watch?v=RreHsOfi14w Company Tags : Paytm, VMWare, Zoho, Accolite, Amazon, Microsoft, Samsung, Snapdeal, D-E-Shaw, MakeMyTrip, Teradata, Walmart, Goldman Sachs, Intuit, Adobe, SAP Labs, Tejas Network,...
ALGO
0.999977
5.18489
df4c0899-33ea-499f-a55d-672835121bd8
jose-melo/competitive-programming-studies
ladders/0-1000/44.cpp
#include <bits/stdc++.h> using namespace std; #define ll long long int #define pii pair<int, int> #define INF 0x3f3f3f3f #define fi first #define mp make_pair #define se second #define FI(n) for(int i = 0; i < n; i++) #define FOR(i,a,n) for (int i=(a);i<(n);++i) #define debug(x) if(on)cout << x << endl #define on tr...
ALGO
0.999883
4.39057
44637af8-b587-4c79-b266-ea8b8f698b31
Red-0111/Leetcode
2755-extra-characters-in-a-string/2755-extra-characters-in-a-string.cpp
class Solution { public: map<string, int> m; int x(int i, string &s, vector<int>&dp) { if(i>=s.size()) return 0; int ans=INT_MAX; if(dp[i]!=-1) return dp[i]; ans=1+x(i+1,s,dp); string k=""; for(int j=i;j<s.size();j++) { k+=s[j]; ...
ALGO
0.999941
5.757706
68b9d3c0-c36c-405d-82f8-ac363b86476f
AnikethSDeshpande/dp
backtracking/nQueensPrintOne.cpp
#include <iostream> using namespace std; void printBoard(int board[][20], int n){ for(int i=0; i<n; i++){ for(int j=0; j<n; j++){ cout << board[i][j] << " " ; } cout << endl; } } bool canPlace(int board[][20], int n, int x, int y){ // check column for(int k=0; k<x...
ALGO
0.99981
5.664389
62310e9a-1499-4838-8336-83ecc94277b3
AnahiSU/PracticasProgramacionCompetitiva
ejerciciosVariadosDeContest/Divination.cpp
/* - Deja ir el pasado y camina hacia el futuro. - El trabajo duro supera al talento cuando el talento no trabaja duro. - Del fracaso se aprende, del éxito no mucho. - Para sentirse vivo se necesita una meta en la que trabajar. - ¡Demonios Rocky! No hay ningún mañana. */ #define srt(a) sort(a.begin(),a.end()) #include...
ALGO
0.999822
4.384478
41e96492-d278-4bdb-9a20-675a066c26b2
pandayed/LeetCode
2225-find-players-with-zero-or-one-losses/2225-find-players-with-zero-or-one-losses.cpp
class Solution { public: vector<vector<int>> findWinners(vector<vector<int>>& matches) { //first is win and second is loose unordered_map<int, pair<int, int>> m; for(auto mat: matches){ if(m.find(mat[0])==m.end()){ m[mat[0]] = pair<int, int>(1, 0); }el...
ALGO
0.999873
5.604393
249be0b2-826d-41b3-ac48-f11c344e71a0
AmeenUrRehman/Cpp-Basics
Linked List/RemoveCycle.cpp
#include<iostream> #include<map> using namespace std; class Node{ public: int data; Node* next; Node(int data){ this -> data = data; this -> next = NULL; } }; void InsertAttail(Node* &tail , int d){ Node* temp = new Node(d); tail -> next = temp; tail = tail -> next; ...
ALGO
0.999929
4.431253
c1934f82-8302-48ae-a9fd-0330e6eba0e8
ishandutta2007/codeforces
bench0310/normal/1368/B.cpp
#include <bits/stdc++.h> using namespace std; typedef long long ll; int main() { ios::sync_with_stdio(0); cin.tie(0); ll k; cin >> k; auto p=[](ll b)->ll { ll res=1; for(int i=1;i<=10;i++) res*=b; return res; }; ll a=1; while(p(a)<k) a++; ll x=p(a); ...
ALGO
0.999929
3.624901
295f5a02-0490-430b-98ca-b2efa0c66519
kherihughes/cuda_kernels
part_b/src/q1.cpp
// q1.cpp: CPU-based vector addition for performance comparison with GPU implementations #include <iostream> #include <cstdlib> #include <chrono> // Simple CPU function for vector addition void add_arrays(const float *a, const float *b, float *c, int size) { for (int i = 0; i < size; ++i) { c[i] = a[i] + ...
ALGO
0.961567
5.890155
311c3a0e-5b77-4d3a-a369-77970d87cc1d
Aries-Surya/SkillRack-Solutions
C++/AVERAGE CHALLENGES/C++ - AVERAGE - PART005/Pattern Printing - Numbers [ZOHO].cpp
#include <iostream> int main() { int n; std::cin >> n; int curr = 1; for (int i = 0; i < n; ++i) { for (int j = 0; j < n - i; ++j) { std::cout << curr << " "; curr = curr + (n - j); } std::cout << std::endl; curr = i + 2; } }
ALGO
0.99989
4.153045
e22adf53-f13a-4582-967c-75fd873fd13b
Leeazy/labs_vvp
11lab.cpp
#include <iostream> #include <algorithm> using namespace std; void f1() { cout << "task 1" << endl; int a, b; cout << "input a, b = "; cin >> a >> b; if (a > b) { b = a; } else if (b > a) { a = b; } else { a = b = 0; } cout << "a = " << a << " " << "b = " << b << endl; } void f2() { cout << "task 2" ...
ALGO
0.998122
3.170645
5a3ca807-4135-4284-94c0-52617f898778
TheVTV/pliki-matura
JM48/maturaAGHans/zadanie2-4.cpp
#include <iostream> #include <fstream> #include <vector> #include <string> #include <cmath> #include <iomanip> using namespace std; int main(){ ifstream in("pliki/liczby.txt"); ofstream out("wynik2.txt", ios::app); string s1, s2; long long int suma=0; vector<long long int> v(17, 0); whil...
ALGO
0.984819
3.779092
c5bdb9ab-238a-42f6-8251-5dba9c0c89ba
AbdelrahmanAyman1/masarify
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.998733
6.76775
eab4007a-f495-4c25-9acc-0a049447e66b
VijayNegi/LeetCodeProblems
solutions/576. Out of Boundary Paths.cpp
const int mod = 1e9+7; class Solution { public: // dfs without memo : TLE // memo 21 ms int findPaths0(int m, int n, int maxMove, int startRow, int startColumn) { vector<vector<vector<int>>> memo(maxMove+1,vector(m,vector(n,-1))); function<long(int,int,int)> dfs = [&](int r,int c,int moves){...
ALGO
0.999934
5.447107
376fd533-30ac-4b2d-b461-f90b15484963
Junk-Bear/9th_Mission
Source/SampleChat/BPFL_CalcBaseball.cpp
#include "BPFL_CalcBaseball.h" void UBPFL_CalcBaseball::InitLife() { CheckLife = 3; } FString UBPFL_CalcBaseball::CalcBaseball(FString msg, FString ThrowBall) { Strike = 0; Ball = 0; //문자열 확인 if (msg.Len() != 3) { return FString::Printf(TEXT("3자리 숫자를 입력해주세요.")); } if (msg.IsNumeric() == false) { return ...
ALGO
0.996284
5.158033
57fe607b-b781-40ac-a315-1f670200bfa2
DE-NISkA/android_frameworks_base
media/libstagefright/codecs/m4v_h263/dec/src/post_proc_semaphore.cpp
/* ------------------------------------------------------------------------------ INPUT AND OUTPUT DEFINITIONS Inputs: q_block = pointer to buffer of inverse quantized DCT coefficients of type int for intra-VOP mode or buffer of residual data of type int for inter-VOP mode Local Sto...
ALGO
0.993392
7.19238
132826fa-7a9d-401d-a305-0593d4a6e39b
luliyucoordinate/Leetcode
src/1038-Binary-Search-Tree-to-Greater-Sum-Tree/1038.cpp
static int x = []() {std::ios::sync_with_stdio(false); cin.tie(0); return 0; }(); class Solution { public: TreeNode* bstToGst(TreeNode* root) { if (root->right) bstToGst(root->right); pre = root->val = pre + root->val; if (root->left) bstToGst(root->left); return root; } pr...
ALGO
0.999957
4.886009
cc56e439-dbe5-4d4a-9639-8a4f00343034
tshipenchko/contester.ru
300/318.cpp
#include <iostream> #include <cmath> using namespace std; double calculate(double a, double n) { double result = 1/a; for (int i = 1; i <= n; ++i) { result += 1/(pow(a, i*2)); } return result; } int main() { double a, n; cin >> a >> n; cout << calculate(a, n); return 0; }
ALGO
0.998711
4.030131
8c528c8d-4c69-4e7a-9d19-b29310309a97
chengshunzhang/my_leetcode
401-500/489_Robot_Room_Cleaner/489_Robot_Room_Cleaner.cpp
class Solution { private: set<pair<int, int> > visited; void goBack(Robot& robot) { robot.turnLeft(); robot.turnLeft(); robot.move(); robot.turnLeft(); robot.turnLeft(); } void helper(Robot& robot, int x, int y, int direction) { pair<int, int> offset[4] = ...
ALGO
0.998897
5.619501
566e7c61-2e5d-4322-b4fb-74e03b22eaf2
manikanta2901/ubuntu
.history/codingChallenges/cpp/Codechef/longChallenges/Year2021/January/WatchingCpl_20210103133515.cpp
#include<bits/stdc++.h> #include<vector> #include<iostream> #include<cmath> #include<algorithm> #include<iterator> #include<string> #include<map> #define vv vector #define F first #define S second #define MP make_pair #define EXECUTE_FASTER ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); #define printM...
ALGO
0.999996
4.18909
5264e6dd-9e33-4bb0-ade0-029de7e0bf86
abhishekolympics/My_daily_leetcode_solutions
2nd revision/longest consecutive sequence .cpp
class Solution { public: bool search(vector<int>& nums,int x) { for(int i=0;i<nums.size();i++) { if(x==nums[i]) { return true; } } return false; } int longestConsecutive(vector<int>& nums) { //brute force ...
ALGO
0.999935
5.48755
f82e6d68-40d1-4ca5-989d-d7d1012d1e07
leslieyip02/leetcode
completed/0560.cpp
class Solution { public: int subarraySum(vector<int>& nums, int k) { unordered_map<int, int> prefixSums; prefixSums[0] = 1; int count = 0; int current = 0; for (int num : nums) { current += num; int target = current - k; auto itr = prefix...
ALGO
0.999939
6.512487
6d469c6a-aa8b-4ed0-900f-591267eb7277
gaoyike/playAlgoCpp
Algorithms/exponentialsearch/exponentialsearch.cpp
#include <bits/stdc++.h> using namespace std; int binarySearch(int a[], int l, int r, int key) { int m; while (l <= r) { m = l + (r - l) / 2; if (a[m] == key) { return m; } else if (a[m] > key) { r = m - 1; } else ...
ALGO
0.999884
5.061791
4c46298b-ef6f-4636-97d7-e1cf31743db1
kyomangold/ETH-ComputationalMethodsEngineeringApplications
Series_1/series1_code/numerical_LA/syssolve.cpp
#include <iostream> #include <Eigen/Dense> #include <chrono> /// /// Solve linear system Ax=b by computing inv(A)*b /// @param[in] A is an NxN Eigen::MatrixXd /// @param[in] b is an N Eigen::VectorXd /// @return x which approximately solves Ax=b /// //----------------SolveInverseBegin---------------- Eigen::VectorX...
ALGO
0.999447
5.529006
6c7b6352-0ca4-4cf3-93dc-9a7c1e5e725f
alokpandeygzp/GFG-Leetcode
Diameter of a Binary Tree - GFG/diameter-of-a-binary-tree.cpp
//{ Driver Code Starts #include <bits/stdc++.h> using namespace std; /* A binary tree node has data, pointer to left child and a pointer to right child */ struct Node { int data; struct Node* left; struct Node* right; }; Node* newNode(int val) { Node* temp = new Node; temp->data = val; temp-...
ALGO
0.999162
6.974674
2a24b1a6-9f8d-4984-8eb4-5b5d3198bbd7
ishandutta2007/codeforces
shik/normal/216/E.cpp
// by shik #include <cstdio> #include <cstring> #include <algorithm> #include <iostream> #include <map> #define N 100010 #define SZ(x) ((int)(x).size()) #define FOR(it,c) for ( __typeof((c).begin()) it=(c).begin(); it!=(c).end(); it++ ) using namespace std; typedef long long LL; int a[N]; int main() { LL ans=0,z=0; i...
ALGO
0.999943
3.174877
52b6f0ae-be55-4edf-b97e-b234c783ead6
KashishJuneja101003/LeetCode-Problems
74. Search a 2D Matrix.cpp
class Solution { public: bool searchMatrix(vector<vector<int>>& matrix, int target) { int r = matrix.size(), c = matrix[0].size(); int start = 0, end = r-1; while(start <= end){ int midRow = start + (end-start)/2; if(matrix[midRow][0] <= target && target <= matrix[m...
ALGO
0.999829
6.312054
ff6cd8ab-c8c8-4c3e-a47f-c7a493ef0a23
BMRRgroup/trabecular_bone_QSM
code/3rd/MEDI_toolbox_20171107/functions/bet2/parse.cpp
#include "options.h" #include <fstream> namespace Utilities { using namespace std; BaseOption * OptionParser::find_matching_option(const string& optstr) { for(Options::iterator o = options_.begin(); o != options_.end(); ++o) if((*o)->matches(optstr)) return *o; return 0; } unsigned int O...
TOOL
0.877861
4.904324
4fa64709-ee4d-474f-bd19-86a2773da2ad
ishandutta2007/codeforces
filibuster/normal/1615/C.cpp
#include <bits/stdc++.h> #define f first #define s second //#define int li using namespace std; using li = long long; using ld = long double; using pii = pair<int, int>; const int INF = 1e9 + 13; const li INF64 = 2e18 + 13; const int N = 2e5 + 113; const int K = 1e5 + 113; const int M = 1e9 + 7; const int A = 26; /...
ALGO
0.999976
4.342676
02f33491-3b7d-4946-b596-6cd1b161f2d9
zimougao/Openvslam_ROS
eigen-eigen-5a0156e40feb/doc/special_examples/Tutorial_sparse_example_details.cpp
#include <Eigen/Sparse> #include <vector> #include <QImage> typedef Eigen::SparseMatrix<double> SpMat; // declares a column-major sparse matrix type of double typedef Eigen::Triplet<double> T; void insertCoefficient(int id, int i, int j, double w, std::vector<T>& coeffs, Eigen::VectorXd& b, con...
ALGO
0.998803
5.388735
685fa626-e847-45fe-8029-488b23f25769
Priyanshuraj2712/HR-Mentor-Intern-Mobile-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.998733
6.76775
9ba25547-9d43-4123-9638-b14f287ee674
derinu/FlyFF
Source/boost_1_50_0/libs/graph/example/incremental-components-eg.cpp
#include <iostream> #include <vector> #include <boost/foreach.hpp> #include <boost/graph/adjacency_list.hpp> #include <boost/graph/incremental_components.hpp> #include <boost/pending/disjoint_sets.hpp> using namespace boost; int main(int argc, char* argv[]) { typedef adjacency_list <vecS, vecS, undirectedS> Graph...
ALGO
0.998479
6.33569
3b15d52f-1886-4b6e-9eed-d7f76af2d506
hsol0708/ECE-C-
CUDAandSFML/CUDA_SFML/src/main.cpp
/* Author: Fan Han Hoon Class: ECE6122 (Fall 2024) Last Date Modified: Sep 30,2024 Description: Lab 4: CUDA-based John Conway’s Game of Life What is the purpose of this file? Main file given from lecture */ #include <SFML/Graphics.hpp> #include "cuda_kernels.cuh" #include "commandline.h" #include <cuda_runtime.h> #in...
ALGO
0.973152
6.94441
631cbddb-6aee-4b2d-b3f2-03de05597bed
Sarthak104/Jaynam-Sir-100-Programs
82.cpp
#include<iostream> using namespace std; int main() { int n; scanf("%d",&n); int arr[n]; for(int i=0;i<n;i++) { scanf("%d",&arr[i]); } int lar; lar=arr[0]; for(int i=1;i<n;i++) { if(lar<arr[i]) { lar=arr[i]; } } printf("%d",lar ); return 0; }
ALGO
0.999796
3.218509
c042c2a8-1fb0-4d40-8dd1-0f4f9dd83688
Taejin1221/Re-PS
Baekjoon/Baekjoon13414.cpp
// Baekjoon13414.cpp #include <iostream> #include <map> #include <string> using namespace std; int main(void) { ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0); int n, k; cin >> k >> n; string arr[500]; map<string, int> table; for (int i = 0; i < n; i++) { cin >> arr[i...
ALGO
0.999978
4.68716
51285dbe-1e98-44c9-89d8-9210b10718cf
yoon2000/Algorithm
real_project/성심당ver2.cpp
#include <iostream> #include <vector> #include <set> #include <queue> #include <algorithm> using namespace std; int dir[4][2] = {{-1,0}, {0,-1}, {0,1}, {1,0}}; int dir_r[4][2] = {{1,0}, {0,1}, {0,-1}, {-1,0}}; int is_market[16][16]; int is_house[16][16]; int is_block[16][16]; bool cmp(pair<int,int> a, pair<int,int> b...
ALGO
0.999932
4.245448
4cc7b7eb-ff09-49f8-862f-ca81fc651261
disabel1a/viterbi
src/lib/my_bitset.cpp
#include "../include/my_bitset.h" #include <functional> #include <stdexcept> bits_partition_t my_bitset::char_to_hex(const char &ch) { bits_partition_t result(0); if (ch < 48 || ch > 70) { return result; } if (ch > 57) { if (ch < 65) { return result; ...
ALGO
0.948557
5.421855
ed2d6f31-6190-4476-a5ef-5d8623b6bc2b
PandoraClub/WizaTV
lib/UnrarXLib/match.cpp
#include "rar.hpp" static bool match(char *pattern,char *string); static bool match(wchar *pattern,wchar *string); inline uint toupperc(byte ch) { /* */ #if defined(_WIN_32) return((uint)CharUpper((LPTSTR)(ch))); #elif defined(_UNIX) return(ch); #else return(toupper(ch)); #endif } inline uint touppercw(uint ch...
TOOL
0.918902
4.519872
cd641b5a-35a0-4309-94f6-3b4f1117edea
gofastlily/gen-iii
tools/preproc/asm_file.cpp
#include <cstdio> #include <cstdarg> #include <stdexcept> #include "preproc.h" #include "asm_file.h" #include "char_util.h" #include "utf8.h" #include "string_parser.h" #include "../../include/constants/characters.h" #include "io.h" AsmFile::AsmFile(std::string filename, bool isStdin, bool doEnum) : m_filename(filenam...
TOOL
0.903754
6.167513
e8058a35-fee5-4e9b-b8e0-a715597b9ea3
SameerShaikh-7/sameer-labwork.c-
pr-3 (31-July)/Q-1.cpp
#include <iostream> using namespace std; int main() { for(int i = 41; i <= 45; i++) { for(int j = 41; j<=i; j++) { cout << j << " "; } cout << endl; } }
ALGO
0.99875
3.361815
09439459-8e5a-4354-942a-953323122cf5
islamshaheb/Algorithm_Data_structure_and_OOP
Linked List/Linked List Remove and Detect cycle.cpp
#include<bits/stdc++.h> using namespace std; class Node { public: int data; Node* next; Node(int val) { data=val; next = NULL; } }; int i =0; //Insert in the end void insertend(Node* &head,int value) { Node* new_node = new Node(value); if(head==NULL) { hea...
ALGO
0.999972
4.035465
b5ae269d-e57c-4624-ba0f-5beee871c1f9
angelo-martinovic/bmm
BMM_cpp/Grammar/Production.cpp
#include "Production.h" #include <string> #include <sstream> namespace Grammar { Production::Production() { this->lhs = pSymbol(); this->probability = 1.0; this->count = 1; this->invCovariance = Eigen::MatrixXd(1,1); this->invCovariance.setZero(); this->mean = Eigen::VectorXd(1); this->...
ALGO
0.978357
5.875795
6c65f1a4-5e01-4369-b513-4279e78c458a
8057vivek/Leetcode
0783-search-in-a-binary-search-tree/0783-search-in-a-binary-search-tree.cpp
/** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode() : val(0), left(nullptr), right(nullptr) {} * TreeNode(int x) : val(x), left(nullptr), right(nullptr) {} * TreeNode(int x, TreeNode *left, TreeNode *right) : val(x), l...
ALGO
0.999993
6.216903
5469e0bf-edbf-47f6-ad94-f2f10d6912f3
DeveloperMindset-com/faiss-mobile
faiss/benchs/bench_heap_replace.cpp
#include <omp.h> #include <cstdio> #include <faiss/impl/FaissAssert.h> #include <faiss/utils/Heap.h> #include <faiss/utils/random.h> #include <faiss/utils/utils.h> using namespace faiss; void addn_default( size_t n, size_t k, const float* x, int64_t* heap_ids, float* heap_val)...
ALGO
0.998163
6.099047
3b8fce96-9a3f-4446-95ab-321a04e34fd2
Kuldeepagrahari/Programming-DSA-Shell-BashScripting-OOPS
algos/Binary_Tree/construction.cpp
#include<bits/stdc++.h> using namespace std; class Tree{ public: int data; Tree *left; Tree *right; Tree(int d){ data = d; left = right = nullptr; } }; void traversal ( Tree*root ){ if ( root ){ cout << root-> data << " "; traversal (root -> left); ...
ALGO
0.999673
4.42817
ac847676-f226-42b9-b7c0-9ff77f8bc336
VIKASGULIA17/practice
c++/dsa/sort/mergesort.cpp
#include <iostream> using namespace std; int merge(int arr[], int b, int mid, int e) { int x = mid - b + 1; int y = e - mid; int ar[x], br[y]; for (int i = 0; i < x; i++) { ar[i] = arr[b + i]; } for (int i = 0; i < y; i++) { br[i] = arr[mid + 1 + i]; } int i = 0; ...
ALGO
0.999993
5.049345
58592458-be74-40e6-83e1-781997f388d3
UangoWW/Cpp-Study-Neo
W3426.cpp
#include <iostream> #include <algorithm> using namespace std; int a[10085]; int pm[10086]; int main() { int n; cin >> n; for (int i = 0; i < n; ++i) { cin >> a[i]; pm[i] = 1; } for (int i = 0; i < n; ++i) { for (int j = 0; j < n; ++j) { if (a[j] < a[i]) {...
ALGO
0.999931
3.698797
6c2948f4-d61b-43e1-8e8e-d6dc3e198014
lds217/lds
DTQG/c++/ngảy/haliton.cpp
// Template // #include <algorithm> #include <bitset> #include <complex> #include <deque> #include <exception> #include <fstream> #include <functional> #include <iomanip> #include <ios> #include <iosfwd> #include <iostream> #include <istream> #include <iterator> #include <limits> #include <list> #include <locale> #incl...
ALGO
0.999775
4.662123
238bb6d4-83bb-449d-be09-b4bb14f16d45
DavidCampbellIII/Timing-Attack-Simulator
TimingAttack.cpp
#include "TimingAttack.h" #include <iostream> #include <chrono> TimingAttack::TimingAttack(const Database& database, const char minASCII, const char maxASCII, const int maxLength) : database(database), minASCII(minASCII), maxASCII(maxASCII), maxLength(maxLength) { //purposely empty... } void TimingAttack::StartT...
ALGO
0.939881
4.202639
3e46f441-a038-4104-bdfa-eedf222643d5
jconnell/BreakoutGame
libs/Box2D/Collision/b2BroadPhase.cpp
#include <Box2D/Collision/b2BroadPhase.h> #include <cstring> b2BroadPhase::b2BroadPhase() { m_proxyCount = 0; m_pairCapacity = 16; m_pairCount = 0; m_pairBuffer = (b2Pair*)b2Alloc(m_pairCapacity * sizeof(b2Pair)); m_moveCapacity = 16; m_moveCount = 0; m_moveBuffer = (int32*)b2Alloc(m_moveCapacity * sizeof(int...
TOOL
0.926426
6.955707
8e4616db-4efd-496d-9fc4-26bc3791dfdb
JoanneLin168/ComputerGraphicsRenderer
libs/utils/Rasteriser.cpp
#include <Constants.h> #include <glm/glm.hpp> #include <CanvasTriangle.h> #include <vector> #include <CanvasPoint.h> #include <Colour.h> #include <CanvasTriangle.h> #include <ModelTriangle.h> #include <TextureMap.h> // Interpolate canvas points std::vector<CanvasPoint> interpolateCanvasPoints(CanvasPoint from, CanvasP...
ALGO
0.900663
5.602067
e3114aa0-2838-4071-b956-a177abf6e077
eldon-chung/bench-binary-search
src/algos/linear_search_vector_twin_load.cpp
#include <errno.h> #include <fcntl.h> #include <stdint.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <sys/mman.h> #include <sys/stat.h> #include <unistd.h> #include <iostream> #include <string_view> #include <vector> #include "../File.h" #include "../search.h" void test_all(File const &file,...
TEST
0.862537
5.979858