uuid
string
repo_name
string
relative_path
string
content
string
category
string
algo_rel_score
float64
quality_score
float64
49c5222b-0a39-4b5d-baa2-b91726a15bc5
ShafayetSadi/GeeksforGeeks
Data Structures and Algorithms/02. Mathematics/11_computingPower.cpp
#include <bits/stdc++.h> using namespace std; // Naive Solution // Time complexity is big O(n) // int power(int x, int n){ // int res = 1; // for(int i=0;i<n;i++){ // res *= x; // } // return res; // } // Efficient Solution using recursion /* power(x, n) = { if n is even -> power(x, n/2)*power(x, n/2) el...
ALGO
0.999997
5.749469
6d830c5f-2eae-4081-9f9e-691c07c2732c
pri2025/gfg
Easy/Find Nth root of M/find-nth-root-of-m.cpp
//{ Driver Code Starts #include<bits/stdc++.h> using namespace std; // } Driver Code Ends class Solution{ public: int fn(int i,int n,int &ans){ if(n == 0){ return 1; } ans = ans*i; fn(i,n-1,ans); return ans; } int NthRoot(int n, int m) { // Code here. for(int i =1; i<=m; i...
ALGO
0.999991
6.221961
7d483eef-04d2-4745-b2d4-671641990c0b
RoGgu/CodingTest
it 취업을 위한 알고리즘 문제풀이 (with CC++) 코딩테스트 대비/섹션 3. 재귀 & 깊이넓이 우선탐색(DFS, BFS)/65. 미로탐색 (2차원 배열 DFS) [O].cpp
#define _CRT_SECURE_NO_WARNINGS #include<stdio.h> // cin,cout말고 이제 c에서 제공하는 sanf, printf 사용 - 속도가 조금 더 빠름 #include<vector> #include<algorithm> using namespace std; const int n = 7; // 맵 크기는 7로 고정 int map[n][n] = { 0 }; // 맵 int checkMap[n][n] = { 0 }; // 경로 체크 배열 int cnt = 0; // 총 경로 수 int dx[] = { 1, -1, 0 , 0 }; ...
ALGO
0.999891
4.608847
2c38c749-df9e-4040-9761-c1fae6a19ee2
Abhishek-Maurya-D/C-Prog
127.cpp
// Find the minimum value out of all the elements in the array #include<iostream> using namespace std; int main() { int arr[] = {45,4,65,67,687,85,4,332,32,34,45,565,76}; int mn = INT8_MIN; for(int i=1; i<(sizeof(arr)/4); i++) mn = min(mn, arr[i]); cout<<mn; }
ALGO
0.999417
3.781758
f9a5e695-dade-4ba7-9b82-44dd94b283fc
Nayanita657/Competitive-coding
Tree/Count Nodes which contains data greatre than x.cpp
#include <iostream> #include <queue> #include <vector> using namespace std; template <typename T> class TreeNode { public: T data; vector<TreeNode<T>*> children; TreeNode(T data) { this->data = data; } ~TreeNode() { for (int i = 0; i < children.size(); i++) { delete children[i]...
ALGO
0.999887
5.236019
5eebffa2-e7b7-43de-a646-429fa4b0ea79
emotionless/Programming-Problem-Solution
codeforces/A.cpp
#include <cstring> #include <cassert> #include <vector> #include <list> #include <queue> #include <map> #include <set> #include <deque> #include <stack> #include <bitset> #include <algorithm> #include <functional> #include <numeric> #include <utility> #include <sstream> #include <iostream> #include <iomanip> #include <...
ALGO
0.999575
3.807341
38642ba6-a871-4c5b-a523-aa95faaf8fc9
Saurava69/LeetCode
768-partition-labels/partition-labels.cpp
class Solution { public: vector<int> partitionLabels(string s) { unordered_map<char, int> endIndex; for (int i = 0; i < s.length(); i++) { endIndex[s[i]] = i; } vector<int> partitions; int start = 0, end = 0; for (int i = 0; i < s.length(); i++) { ...
ALGO
0.999521
6.435839
bb4cf41e-c620-486b-8732-de7f32ad9bf9
bliscosque/CPPProblemsVSCode
DS_Alg_CPP/problem_solving/c1/11.cpp
#include <bits/stdc++.h> using namespace std; int main() { vector<int> v{1,2,3,4,5}; int i=0, e=v.size()-1; while (i<e) { swap(v[i],v[e]); i++; e--; } for (auto i:v) { cout << i << " "; } cout << endl; return 0; }
ALGO
0.999908
3.98051
1031e288-dd62-43ae-8eaf-1430372f01b2
gusai184/Pastry
neighbourSet.cpp
#include "header.h" extern string nodeId; extern NodeAddress selfAdd; extern vector<NodeAddress> leafSet; extern vector<pair<double, NodeAddress>> neighbourSet; extern vector<vector<NodeAddress>> routeTable; extern unordered_map<string, string> hashTable; extern int L; extern int M; extern int ROW; extern int COL; ext...
ALGO
0.998591
3.731143
7ef270f5-d776-48d7-ac08-21b514a3c3c3
mcmilk/cppcrypto
cppcrypto/speck.cpp
/* This code is written by kerukuro for cppcrypto library (http://cppcrypto.sourceforge.net/) and released into public domain. */ #include "speck.h" #include "portability.h" #include <memory.h> #include <bitset> #ifdef _MSC_VER #define inline __forceinline #endif //#define CPPCRYPTO_DEBUG namespace cppcrypto { spe...
ALGO
0.997937
5.70097
3ec4f00a-e838-4704-8d44-971f672177a0
am-chourasia/Leetcode-Practice-Solutions
Generate Parentheses - GFG/generate-parentheses.cpp
// { Driver Code Starts //Initial Template for C++ #include <bits/stdc++.h> using namespace std; vector<string> AllParenthesis(int n) ; // } Driver Code Ends //User function Template for C++ // N is the number of pairs of parentheses // Return list of all combinations of balanced parantheses class Solution { ve...
ALGO
0.999651
6.361702
306400ff-6d3b-4d29-9a54-75076b719f14
RadhikaBhasin0711/DSA-daily-questions
Day 37/Number of Substrings Containing All Three Characters.cpp
class Solution { public: int numberOfSubstrings(string s) { unordered_map<char,int> count={{'a',0},{'b',0},{'c',0}}; int left=0; int cnt=0; for(int right=0;right<s.length();right++){ count[s[right]]++; while(count['a']>0 && count['b']>0 && count['c']>0){ ...
ALGO
0.999836
5.723379
85d111ee-553c-4921-a86f-8a62fbd803c6
andrefakhoury/competitive-programming
problems/gyms/NCPC 2016/G.cpp
#include <bits/stdc++.h> #define pb push_back #define eb emplace_back #define fi first #define se second; #define rank jdksl using namespace std; typedef long long ll; typedef pair<int, int> ii; const int N = 100007, inf = 0x3f3f3f3f; void legend() { cout << "Legend" << endl; exit(0); } int tot[50]; int rank = ...
ALGO
0.999757
3.750556
513ccec6-d25a-4a51-8011-290f7b9e5bc6
Moon-ChangHyun/BOJ
2268/source.cpp
#include<cstdio> #include<vector> using namespace std; class fenwickTree { public: fenwickTree(int n) : tree(n + 1) {} long long sum(int pos) { ++pos; long long ret = 0; while (pos > 0) { ret += tree[pos]; pos &= (pos - 1); } return ret; } void add(int pos, int val) { ++pos; while (pos < tree.si...
ALGO
0.999881
3.998718
8017a3be-ab5a-439d-81b1-1bd4fcecaf8c
chiseungii/SWEA
D2/01983.cpp
#include <iostream> #include <vector> #include <algorithm> using namespace std; #define MIDDLE_TEST 0.35 #define FINAL_TEST 0.45 #define HOMEWORK 0.2 string grades[10] = { "A+", "A0", "A-", "B+", "B0", "B-", "C+", "C0", "C-", "D0" }; bool compare(pair<int, double> p1, pair<int, double> p2) { return p1.second > p2.s...
ALGO
0.995295
3.87481
b9a2f6fc-b413-43f1-9227-7916af6a4e69
danvarela-dev/Estructura-de-Datos-II
Prueba2-ED2/21651030_main.cpp
#include <iostream> #include <string> #include <fstream> using namespace std; #pragma warning(disable : 4996) void wc(char c, string filename) { ifstream myfile; int contWords = 0, contChars = 0; myfile.open(filename, ios::in); if (!myfile) { cerr << "Error reading file..." << endl; return; } myfile.se...
TOOL
0.976466
4.278855
cdf2ec14-007f-4449-91ec-ce1a7a76807b
PriyanshuXsingh/ADA
binarysearch.cpp
#include <iostream> using namespace std; bool binarySearch(int arr[], int key, int s, int e) { if (s > e) return false; // Base case: element not found int mid = s + (e - s) / 2; if (key == arr[mid]) return true; // Base case: element found if (key < arr[mid]) return binar...
ALGO
0.999909
5.565331
59bafdff-8a4b-45dd-9582-1758f6a69fd4
Mry3ll0w/Proyectos-universidad
AEED/curso c++/vid22.cpp
#include <iostream> using namespace std; /*Ejercicio del video 22 pero con el algoritmo ruso de la multipl*/ void mult_table(int,int); int main(){ int n; cout<<"Introduce el numero del que quieras saber la tabla"<<endl; cin>>n; for (int i = 1; i < 11; i++) { mult_table(n,i); } retu...
ALGO
0.999297
3.818264
612df8a3-3cef-4560-8e56-11eb906ce68d
Bhanuprakash-M04/leetcode-DSA
1058-lexicographically-smallest-equivalent-string/lexicographically-smallest-equivalent-string.cpp
class Solution { public: // DFS to find the smallest lex character in the component char dfs(unordered_map<char, vector<char>>& adj, char cur, vector<int>& vis) { vis[cur - 'a'] = 1; char minChar = cur; for (char neighbor : adj[cur]) { if (vis[neighbor - 'a'] == 0) { ...
ALGO
0.999973
6.851446
596e72f3-d1f4-4616-b426-d5d6651821ac
not-a-dev0/Awesome-Quant-Machine-Learning-Trading
C++/find-minimum-in-rotated-sorted-array-ii.cpp
// Time: O(logn) // Space: O(1) class Solution { public: int findMin(vector<int>& nums) { int left = 0, right = nums.size() - 1; // Find min left s.t. nums[left] < nums[left']. while (left < right && nums[left] >= nums[right]) { int mid = left + (right - left) / 2; ...
ALGO
0.999989
6.288294
b6951a7d-531f-4cd4-9f56-1817667c7b28
bookzhan/bzdlib
app/src/main/cpp/dlib-19.19/examples/assignment_learning_ex.cpp
/* This is an example illustrating the use of the dlib machine learning tools for learning to solve the assignment problem. Many tasks in computer vision or natural language processing can be thought of as assignment problems. For example, in a computer vision application where you are tr...
ALGO
0.985347
7.513552
08d46a3c-ab13-4a93-9058-a17a418bd084
Altu-Bitu/AlgorithmStudy_LYJ
9월 7일 - 맵과 셋/14425.cpp
/* * * 알튜비튜 - 0907 * 14425번 * 문자열 집합 * * 총 N개의 문자열로 이루어진 집합 S가 주어진다. * 입력으로 주어지는 M개의 문자열 중에서 집합 S에 포함되어 있는 것이 * 총 몇 개인지 구하는 프로그램을 작성하시오. * */ #include <iostream> #include <set> #include <string> using namespace std; set<string> s; int main() { int N, M; string str; cin >> N >> M; for (in...
ALGO
0.99977
4.658636
6d7c99b8-8f2d-474a-a8f9-fb8264000ad3
Suchitagupta17950/-Crackyourplacement
148-sort-list/sort-list.cpp
/** * 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) {} * }; */ class Solution { private: ListNode* findMi...
ALGO
0.999996
5.870326
b474206d-7eb3-4bd0-97cf-a21ec990209d
shdehghan/chesstest
src/queen.cpp
#include "queen.h" #include "plate.h" Queen::Queen(int i,int j,Id wob_queen):row(i),column(j),wob_queen(wob_queen){} vector<vector<bool>> Queen::valid() { Plate valid_plate1; Plate plate_asli; plate_asli.vectorSaz(plate_asli.plate); valid_plate1.validPlateSaz(valid_plate1.valid_plate); for (int i=0...
ALGO
0.964704
3.659396
2a01a54b-e245-4421-afaf-2fe07233338c
managarm/mlibc
options/internal/generic/search.cpp
#include <mlibc/search.hpp> #include <frg/string.hpp> #include <stdlib.h> #include <stdint.h> #include <errno.h> struct _ENTRY { ENTRY entry; bool used; }; namespace mlibc { int hcreate_r(size_t num_entries, struct hsearch_data *htab) { if(!htab) { errno = EINVAL; return 0; } htab->table = static_cast<_ENT...
ALGO
0.996668
5.904683
e228987c-bec8-438d-9c70-2f0d17863d9f
faiq157/If-Else-Question
Write a C program to check whether the triangle is equilateral, isosceles or scalene triangle..cpp
# include <iostream> using namespace std; int main(){ int side1,side2,side3; cout<<"Enter Sides of Triangle"<<endl; cin>>side1,side2,side3; if(side1==side2 && side2==side3){ cout<<"Triangle is Equilteral"; } else if(side1==side2 || side1==side3 || side2==side3){ cout<<"Triangle is isosceles "; } e...
ALGO
0.999381
4.114592
bdb99ae1-273e-4309-9048-ebf889323de1
kingarthur11/leetcode
solution/0000-0099/0020.Valid Parentheses/Solution.cpp
class Solution { public: bool isValid(string s) { string stk; for (char c : s) { if (c == '(' || c == '{' || c == '[') stk.push_back(c); else if (stk.empty() || !match(stk.back(), c)) return false; else stk.pop_back(...
ALGO
0.999583
6.606872
3458664b-4ce1-4f16-a9b5-89171dd488ce
Dramacydal/murlocs_434
src/bindings/ScriptDev2/scripts/northrend/ulduar/halls_of_lightning/boss_bjarngrim.cpp
/* ScriptData SDName: Boss General Bjarngrim SD%Complete: 70% SDComment: Waypoint needed, we expect boss to always have 2x Stormforged Lieutenant following SDCategory: Halls of Lightning EndScriptData */ #include "precompiled.h" #include "halls_of_lightning.h" enum { //Yell SAY_AGGRO ...
TOOL
0.923465
4.95992
bcf4adb6-2380-45e0-93e9-ceb48297f174
Smu1zel/mesa-amber-debian
src/gallium/drivers/r600/sfn/sfn_nir_lower_fs_out_to_vector.cpp
#include "sfn_nir_lower_fs_out_to_vector.h" #include "nir_builder.h" #include "nir_deref.h" #include "util/u_math.h" #include <set> #include <vector> #include <array> #include <algorithm> namespace r600 { using std::multiset; using std::vector; using std::array; struct nir_intrinsic_instr_less { bool operator ...
TOOL
0.893992
7.668197
bfc18b14-7d86-4881-b5af-eaf463ec6315
vuquangsang/VQS
hirehp.cpp
/* Vu Quang Sang from Le Khiet High School for Gifted */ #include <bits/stdc++.h> using namespace std; //#define ll int #define lg(x) __lg(x) #define alla(a,n) a+1,a+n+1 #define el "\n" #define all(x) x.begin(),x.end() #define pb push_back #define ll long long #define fi first #define ...
ALGO
0.999978
3.371019
6ce39b94-2b18-4cf8-997d-2567e1f9c878
Thomas180105/likou
solver/slidingWindow/992.cpp
// 自己做完全没思路 // class Solution { // public: // int subarraysWithKDistinct(vector<int>& nums, int k) { // //按照题意是不需要去重的 // //既然是连续的子数组,第一想法就是滑动窗口,但是怎么work起来需要想想 // //毕竟这里我们可以很明显地看到对答案产生贡献的区间并不符合一般的滑动窗口的规律,如果维持两个指针不往复的话我们可能需要某些统计策略 // //p.s. 要是问最长好子数组,那确实就是直接滑动窗口搞定 // //1 2 1 2...
ALGO
0.999973
6.111365
de408651-0de2-4cc7-9861-b804a266fc5c
bohm/binstretch
tests/explorationtest.cpp
#include <cstdio> #include <cstdlib> #define IBINS 10 #define IR 19 #define IS 14 #include "common.hpp" #define PREDEFINED_FILENAME "/comp/bs/iterative/experiments/6bins-basicroot.txt" #include "binconf.hpp" #include "filetools.hpp" #include "minimax/computation.hpp" #include "minimax/recursion.hpp" #include "ser...
ALGO
0.999192
5.098526
57981663-cea9-43df-9a47-49e1948e6932
amoljadhav250/cpp
LinkedList.cpp
#include<bits/stdc++.h> #define LL long long int #define sc(x) scanf("%d",&x) #define sl(x) scanf("%lld",&x) #define pf(x) printf("%d\n",x) #define pl(x) printf("%lld\n",x) #define F first #define S second #define d(x) cout<<#x<<":"<<x<<"\t" #define dn(x) cout<<#x<<":"<<x<<"\n" using namespace std; struct Node{ int d...
ALGO
0.999928
3.851827
0edaf57c-2055-48b4-9982-5e52e11f0077
ishandutta2007/codeforces
wzyeustia/normal/1542/C.cpp
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef long double ld; typedef pair<int, int> pii; typedef pair<ll, ll> pll; typedef pair<ld, ld> pld; typedef tuple<ll, ll, ll> t3l; typedef tuple<ll, ll, ll, ll> t4l; typedef vector<ll> vl; typedef vector<vl> vvl; typedef vector<vvl> vvvl; typedef...
ALGO
0.999863
4.269995
2c99773a-38ab-498b-8b3b-aaa490d47c7b
Yoyuuhi/cpp-atcoder
_result/_AtCoderLibraryPracticeContest/D-Maxflow/main.cpp
#include <bits/stdc++.h> #include <atcoder/all> #define out(X) cout << (X) << endl; #ifdef __LOCAL #define DBG(X) cout << #X << " = " << (X) << endl; #else #define DBG(X) #endif #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define rep2(i, s, n) for (int i = (s); i < (int)(n); i++) #define all(v) v.begin(), v.e...
ALGO
0.999994
4.204879
f84f1cec-3796-466e-84d4-753d3772eb45
kunljha/LeetCode
0106-construct-binary-tree-from-inorder-and-postorder-traversal/0106-construct-binary-tree-from-inorder-and-postorder-traversal.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.999971
6.265623
0ea4f4f3-4d27-40f2-8d79-00681e8c8499
rkks/refer
snippets/prog-pearls/sortedrand.cpp
/* From 'Programming Pearls' by Jon Bentley */ /* sortedrand.cpp -- output m sorted random ints in U[0,n) */ #include <iostream> #include <set> #include <algorithm> using namespace std; int bigrand() { return RAND_MAX*rand() + rand(); } int randint(int l, int u) { return l + bigrand() % (u-l+1); } void genknuth(in...
ALGO
0.999617
5.073551
c7df84f3-b63d-4965-bcf5-6a4b9af9bd37
Shimmen/ProxyGen
code/deps/eigen-3.3.7/unsupported/doc/examples/EulerAngles.cpp
#include <unsupported/Eigen/EulerAngles> #include <iostream> using namespace Eigen; int main() { // A common Euler system by many armies around the world, // where the first one is the azimuth(the angle from the north - // the same angle that is show in compass) // and the second one is elevation(the angl...
ALGO
0.99732
5.125681
df08a91b-bff6-408c-82bd-89f5ab0303d4
thaituanUIT/23521706---CuNguyenHuyThaiTuan---KHMT4
Bai066/Bai066.cpp
#include <iostream> using namespace std; int main() { int n, t, dv, flag; cin >> n; flag = 0; t = n; while (t != 0) { dv = t % 10; if (dv % 2 == 0) flag = 1; } if (flag == 1) cout << "TT"; else cout << "ko TT"; return 0; }
ALGO
0.999908
3.699183
f9cfb2da-2eaa-4ee3-925a-5f9dbbef9ab3
atalia/leetcode
959.regions-cut-by-slashes.cpp
/* * @lc app=leetcode id=959 lang=cpp * * [959] Regions Cut By Slashes */ // @lc code=start #include<iostream> #include<vector> #include<string> using namespace std; class Solution { private: vector<int> root_p; int cnt; public: int regionsBySlashes(vector<string>& grid) { int n = grid.size();...
ALGO
0.999121
5.69015
9828b58e-4b14-4299-858e-d3f94dd75afe
Ivantt/BANKCOIN18
src/bitcoinrpc.cpp
#include "init.h" #include "util.h" #include "sync.h" #include "ui_interface.h" #include "base58.h" #include "bitcoinrpc.h" #include "db.h" #undef printf #include <boost/asio.hpp> #include <boost/asio/ip/v6_only.hpp> #include <boost/bind.hpp> #include <boost/filesystem.hpp> #include <boost/foreach.hpp> #include <boost...
WEB
0.947972
6.443349
d8362712-66a8-48bf-82b2-03cd96cb685c
yonsei-hpcp/gcom
third-party/boost_1_86_0/libs/compute/example/point_centroid.cpp
//[point_centroid_example #include <iostream> #include <boost/compute/algorithm/copy.hpp> #include <boost/compute/algorithm/accumulate.hpp> #include <boost/compute/container/vector.hpp> #include <boost/compute/types/fundamental.hpp> namespace compute = boost::compute; // the point centroid example calculates and di...
ALGO
0.999344
4.58674
65dd2145-b848-40d5-8040-4c5c894b59cc
JubayerAhmmodShuvo/leetcodesolve
OddEvenLinkedList.cpp
/** * 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) {} * }; */ class Solution { public: ListNode* oddEvenList...
ALGO
0.999933
5.58089
b696dc63-0d86-454e-9c90-e47d8200f9e0
jamesmtuck/ncstate_ece309_spring2021
week4/List/List.cpp
#include <iostream> #include <string> #include "List.h" List::List(const List &other) { // initialize head and tail head = nullptr; tail = nullptr; ListNode *tmp = other.head; // loop over other list’s nodes and append them in same order while(tmp) { append(tmp->item); tmp = tmp->next; ...
TOOL
0.872303
3.621409
44b063ef-2478-4c05-8d63-c8a6271f5854
kishore089/Cryptography-
program 2.cpp
#include <stdio.h> #include <ctype.h> void monoalphabeticSubstitution(char message[], char key[]) { int i; for (i = 0; message[i] != '\0'; ++i) { char ch = message[i]; if (isalpha(ch)) { if (islower(ch)) { message[i] = key[ch - 'a']; } else { ...
ALGO
0.999639
6.368023
31fd9a11-ab2b-4f62-91c4-e06987ce8ada
sansriti14/Leetcode
1765-map-of-highest-peak/1765-map-of-highest-peak.cpp
class Solution { private: bool isValid(int row, int col, int m, int n) { return (row >= 0 && row < m && col >= 0 && col < n); } public: vector<vector<int>> highestPeak(vector<vector<int>>& isWater) { int m = isWater.size(); int n = isWater[0].size(); queue<pair<...
ALGO
0.999998
6.572523
17941cb9-b4d5-4288-9539-a4b590f60564
AndySomogyi/SuiteSparse
SPQR/Source/spqr_fsize.cpp
// ============================================================================= // === spqr_fsize ============================================================== // ============================================================================= // Compute the number of rows in front F, initialize its staircase, and // ...
ALGO
0.994696
3.86233
85ed1fd0-827c-48bb-953e-646f721a796e
G33k1973/CodingGames
Ball_in_the_Maze.cpp
typedef pair<int, int> ip; typedef pair<ip, int> iip; #define mp make_pair #define pb push_back class Solution { protected: int n, m; public: int shortestDistance(vector<vector<int>>& maze, vector<int>& start, vector<int>& destination) { this->n = static_cast<int>(maze.size()); if (n == 0)return -1; this->m = s...
ALGO
0.999973
5.523278
753e6a98-af39-4667-bf79-5025596c9a4d
PrinceLeBon/favorite_place
windows/runner/utils.cpp
#include "utils.h" #include <flutter_windows.h> #include <io.h> #include <stdio.h> #include <windows.h> #include <iostream> void CreateAndAttachConsole() { if (::AllocConsole()) { FILE *unused; if (freopen_s(&unused, "CONOUT$", "w", stdout)) { _dup2(_fileno(stdout), 1); } if (freopen_s(&unuse...
TOOL
0.998859
6.785645
67d7e9a0-3dbf-4a59-89d6-85fa2b504fc4
Afraz-Khan1/Practice-Questions-OOP
final lab oop.cpp
#include<iostream> #include<math.h> using namespace std; class vector{ int **arr; int x,y; public: vector(int xx=0,int yy=0):x(xx),y(yy){ arr=new int*[x]; for(int i=0;i<x;i++){ arr[i]=new int[y]; } } vector operator+(const vector &other)const{ vector result; resul...
ALGO
0.997864
3.985502
ef34bddf-0528-427c-888a-e0ee4b4f52a3
MinjooShin/Coding-Test-Study
week3/mix_strings.cpp
/* ó: α׷ӽ : ڿ ̵: Level 0 ּ: https://school.programmers.co.kr/learn/courses/30/lessons/181942 */ #include <string> #include <vector> using namespace std; string solution(string str1, string str2) { vector<char> result; int j = 0, k = 0; for(int i = 0; i < str1.length() + str2.length(); i++){ i...
ALGO
0.999962
4.309326
ff5047c4-3f8f-43e0-bcb1-f313a25a893b
mikeryanmay/tensoRphylo
inst/include/TensorPhylo/Likelihood/Kernels/CPU/Branchwise/EigenIntegrationKernel.cpp
/* * EigenIntegrationKernel.cpp * * Created on: Sep 4, 2019 * Author: xaviermeyer */ #include "EigenIntegrationKernel.h" #include "../EigenUtils.h" #include "../EigenUtilsMatrix.h" #include "../Misc/StiffnessRatio.h" #include "Tensor/IncTensor.h" #include "SynchronousEvents/IncSynchronousEvents.h" #include...
ALGO
0.946491
7.030304
b8fb583c-6e48-4c7a-bfce-e807d7bedd99
DeependraParmar/DSA
My Programs/17 Recursion/10_checkPalindrome.cpp
#include <iostream> using namespace std; bool checkPalindrome(string s, int start, int end){ if(start > end){ return true; } if(s[start] != s[end]){ return false; } else{ bool ans = checkPalindrome(s, start+1, end-1); return ans; } } int main(){ string s; ...
ALGO
0.999423
5.186458
22e0e610-d4fc-4448-972a-26cb817ae985
goodstudyqaq/ACM
codeforces/2100-2199/2118/D.cpp
#include <bits/stdc++.h> using namespace std; #ifdef LOCAL #include "copypaste/debug.h" #else #define debug(...) 42 #endif typedef long long ll; typedef pair<int, int> pii; typedef pair<ll, ll> pll; struct fast_ios { fast_ios() { cin.tie(nullptr); ios::sync_with_stdio(false); cout << fix...
ALGO
0.999922
4.168307
251bf978-725f-402f-87e8-28174d32e7dd
Pebriyantii/modul-7
modul 7 9.10.cpp
#include <stdio.h> #define n 10 main() { int A[n]; int i, max; printf("Input %i bilangan:\n\n", n); for(i=0; i<n; i++) { printf("Bil %i: ", (i+1)); scanf("%i", &A[i]); } max = A[0]; for(i=1; i<n; i++) { if (A[i] > max) { max = A[i]; } } printf("Nilai terbesar = %i", max); return 0; }
ALGO
0.99949
3.533766
116951a3-b15b-42c8-8653-eac9c215c072
yang2640/HeIvIndex
hamming/he_quantize.cpp
#include "he_ivindex.h" #include <sys/stat.h> vector<string> readlines(string path) { ifstream ifs(path); vector<string> lines; if (ifs.is_open()) { string line; while (getline(ifs, line)) { if (line.empty()) { continue; } lines.push_back...
ALGO
0.914657
4.29524
808fe88b-2142-4380-88bf-68883336f738
sarvex/leetcode-emoji-code
solution/2000-2099/2052.Minimum Cost to Separate Sentence Into Rows/Solution.cpp
class Solution { public: const int inf = INT_MAX; int n; int minimumCost(string sentence, int k) { istringstream is(sentence); vector<string> words; string word; while (is >> word) words.push_back(word); n = words.size(); vector<int> s(n + 1); for (in...
ALGO
0.999955
5.674814
8c356fe6-f428-4a02-a1e9-e2b192133780
amir-hosen7/Graph
DFS/LeetCode/2581. Count Number of Possible Root Nodes.cpp
class Solution { public: int res, vis[200000]; map<pair<int, int>, int> mark; vector<int> adj[200000]; int get_cnt(int root) { vis[root] = 1; int cnt = 0; for (auto i : adj[root]) { if (!vis[i]) { cnt += mark[{root, i}] + get_cnt(i); } ...
ALGO
0.999903
5.391438
83b53782-15fd-49e7-a30a-9cc2ac4bfef1
JaiBhalla03/dsa
gcd_of_2_string.cpp
class Solution { public: string gcdOfStrings(string str1, string str2) { return (str1 + str2 == str2 + str1) ? str1.substr(0, gcd(size(str1), size(str2))) : ""; } };
ALGO
0.99983
6.102536
24f453bb-e5ad-4566-a08b-c5d6420b1167
sridharreddy7/hashTagCounter
dontdelete.cpp
#include <iostream> #include <stdlib.h> #include <fstream> #include <sstream> #include <math.h> #include <vector> #include <queue> #include <stack> #include <map> #include <string> using namespace std; // #include "fibonacci_heap.hpp" // using boost::heap::fibonacci_heap; // typedef fibonacci_heap<int, boost::hea...
ALGO
0.998889
3.687327
6c085ee8-60e2-432b-983f-1d415461acaa
PratheekB/suv
llvm/llvm/lib/CodeGen/MachineInstrBundle.cpp
#include "llvm/CodeGen/MachineInstrBundle.h" #include "llvm/ADT/SmallSet.h" #include "llvm/ADT/SmallVector.h" #include "llvm/CodeGen/MachineFunctionPass.h" #include "llvm/CodeGen/MachineInstrBuilder.h" #include "llvm/CodeGen/Passes.h" #include "llvm/CodeGen/TargetInstrInfo.h" #include "llvm/CodeGen/TargetRegisterInfo.h...
TOOL
0.894593
7.919427
75f70cf0-448e-4248-9bcd-c72ead55f9c4
bpc6/aoc24
puzzles/day09/main.cpp
#include "day09.h" #include <iostream> int main() { std::cout << part1("input.txt") << std::endl; std::cout << part2("input.txt") << std::endl; return EXIT_SUCCESS; }
ALGO
0.998817
5.678957
064c4abe-39ba-4095-9016-1cbfd4344535
Tarequl-islam/Programming-competition
Codeforces/1379 b.dubious cyrpto.cpp
#include<bits/stdc++.h> using namespace std; #define fo(i, n) for (i = 0; i < n; i++) #define FOR(i,a,b) for (int i = (a); i < (b); ++i) #define ll long long #define si(x) scanf("%d", &x) #define sl(x) scanf("%lld", &x) #define ss(s) scanf("%s", s) #define pi(x) printf("%d\n", x) #define pl(x) printf("%lld\n", x) #defi...
ALGO
0.999734
3.227658
303eed84-ef3f-4d7d-bc7b-e9aaaf91e071
zwshen/notes-learning
skills/Acm/Others/my-idle-codes/maratona/UVa/p11677.cpp
#include <stdio.h> #include <stdlib.h> int main() { int h1, m1, h2, m2; scanf("%d%d%d%d", &h1, &m1, &h2, &m2); while (h1!=0 || m1!=0 || h2 !=0 || m2 !=0) { int iMin, fMin, dif; iMin = 60*h1 + m1; fMin = 60*h2 + m2; if (iMin>fMin) fMin+= 60*24; dif = abs(fMin - iMin); printf("%d\n", dif); s...
ALGO
0.999671
3.429859
dc69b12e-7d6e-459a-9f85-6627e77cc44b
saurabhsoodpec/selfdriving
CarND-MPC-Project/src/Eigen-3.3/doc/snippets/Tutorial_solve_triangular.cpp
Matrix3f A; Vector3f b; A << 1,2,3, 0,5,6, 0,0,10; b << 3, 3, 4; cout << "Here is the matrix A:" << endl << A << endl; cout << "Here is the vector b:" << endl << b << endl; Vector3f x = A.triangularView<Upper>().solve(b); cout << "The solution is:" << endl << x << endl;
ALGO
0.999622
3.024108
bc190e63-d036-4668-a455-7fd3364c0315
xiroV/ninja-castle-game
src/core.cpp
#include"core.h" Collision::Collision() {} void Collision::init(std::string filename) { std::ifstream inFile; this->center_point = glm::vec2(22.5, 31.0); this->player_position.push_back(glm::vec4(0, 0, 0, 0)); this->player_position.push_back(glm::vec4(0, 0, 0, 0)); std::vector<unsigned int> vert...
TOOL
0.918109
4.031516
074562f8-db07-461a-9170-b5c53469514c
letiziaburioli/llvm-project
libcxx/test/std/algorithms/alg.modifying.operations/alg.remove/remove_if.pass.cpp
// <algorithm> // template<ForwardIterator Iter, Predicate<auto, Iter::value_type> Pred> // requires OutputIterator<Iter, RvalueOf<Iter::reference>::type> // && CopyConstructible<Pred> // constexpr Iter // constexpr after C++17 // remove_if(Iter first, Iter last, Pred pred); #include <algorithm>...
TEST
0.903247
7.036469
a15429bb-fd02-4a0a-9875-0bad2ac27f8a
ishandutta2007/codeforces
antoine/normal/920/G.cpp
#include <iostream> #include <algorithm> #include <cstring> #include <string> #include <vector> #include <set> #include <map> #include <queue> #include <cmath> #include <stack> #include <iomanip> #include <functional> using namespace std; const int MaxN = 1e6; int spf[MaxN + 1] = { 0 }; auto getPrimes(int x) { vect...
ALGO
0.99999
3.838474
13dd8aeb-245f-4953-ba22-0c01f9c74dd0
Jesus2421/ProyectosSoftware
C++/Librerias.cpp
// Inclusion y uso de librerias #include <iostream> // Librería para entrada y salida estándar en C++ #include <cmath> //librería proporciona funciones matemáticas , //como raíces cuadradas, exponenciación, funciones trigonométricas, etc. #include <string> //Para manejar cadenas de caracteres. #include <vector>//Para ...
TOOL
0.925075
4.17222
bcd29220-d3a7-41e3-b76e-a56c73ab2e83
siddhantttt/algorithms-ds-leetcode
Palindrome Linked List/Palindrome Linked List/main.cpp
//Problem: https://leetcode.com/explore/learn/card/linked-list/219/classic-problems/1209/ //Implementation: Incomplete. Use fast and slow pointers instead of length. #include <vector> #include <iostream> #include <stack> #include <queue> #include <string> #include <map> #include <set> #include <unordered_set> using n...
ALGO
0.999152
5.79402
68c0601a-5db0-4346-9e00-722620da50ec
FelixMatrixx/23521215_23521704_23521494_23521821_23521208_23521327_BT03
Bai058/Bai058.cpp
#include <iostream> #include <iomanip> using namespace std; void Nhap(float[], int&); void Xuat(float[], int); float LonNhat(float[], int); int DemLonNhat(float[], int); int main() { float b[500]; int k; Nhap(b, k); cout << "Mang da nhap la: "; Xuat(b, k); cout << "\nSo luong cac gia tri lon nhat co trong mang:...
ALGO
0.995096
3.353356
f54959c4-f503-48a1-b348-ae44557bda77
0SNP0/itmo-ct
y2020-s2/dm_labs/cf-grammar/A.cpp
#include <iostream> #include <algorithm> #include <vector> void open_files(const std::string & name) { freopen((name + ".in").c_str(), "r", stdin); freopen((name + ".out").c_str(), "w", stdout); } template<typename T> T next(std::istream & in = std::cin) { T res; in >> res; return std::move(res); } std::string ...
ALGO
0.999955
5.007972
a57d95c5-5f0b-40cb-836d-e360ace38347
FDA12345/smart_home
sdk/boost_1_73_0/libs/graph/example/kuratowski_subgraph.cpp
#include <boost/graph/boyer_myrvold_planar_test.hpp> #include <boost/graph/is_kuratowski_subgraph.hpp> using namespace boost; int main(int argc, char** argv) { typedef adjacency_list< vecS, vecS, undirectedS, property< vertex_index_t, int >, property< edge_index_t, int > > graph; // Create a...
ALGO
0.866936
7.044669
876e0b1a-2d77-40d8-b0e3-979a1084e98b
neelotpal-d/VectorField_Multiaxis
ThirdPartyDependence/eigen3/doc/examples/tut_matrix_coefficient_accessors.cpp
#include <iostream> #include <Eigen/Dense> using namespace Eigen; int main() { MatrixXd m(2,2); m(0,0) = 3; m(1,0) = 2.5; m(0,1) = -1; m(1,1) = m(1,0) + m(0,1); std::cout << "Here is the matrix m:\n" << m << std::endl; VectorXd v(2); v(0) = 4; v(1) = v(0) - 1; std::cout << "Here is the vector v:\n...
ALGO
0.999082
3.65288
b3e62ae6-4920-4b0c-99ef-31f05e253dfb
aryansingh10/DSA_ARYAN_SINGH
BinarySearchTrees/PreorderTraversalofaBST.cpp
BinaryTreeNode<int> *solve(vector<int> &preorder, int mini, int maxi,int &i) { if(i>= preorder.size()){ return NULL; } if(preorder[i] < mini || preorder[i] > maxi){ return nullptr; } BinaryTreeNode<int> * root = new BinaryTreeNode<int>(preorder[i++]); root->left = solve(p...
ALGO
0.999989
5.720469
4c0da3e9-3c0b-4fe5-8086-68de09509792
singhkumaryash/DSA_StriversA2Z
01_Basics/Basic_Recursion/Q9_fibonacciNumber.cpp
// Problem Statement : The Fibonacci numbers, commonly denoted F(n) form a sequence, // called the Fibonacci sequence, such that each number is the sum of the two // preceding ones, starting from 0 and 1. That is, // F(0) = 0, F(1) = 1 // F(n) = F(n - 1) + F(n - 2), for n > 1 // Input: n = 4 // Output: 3 // Explanatio...
ALGO
0.999694
6.52406
fbda068d-c984-472a-ab9b-cf2bbffb0626
Santanu2003/Data-Structure
Heap Sort.cpp
// Heap Sort #include<stdio.h> #include<stdlib.h> void maxheap(int *a,int i,int n){ int l=2*i+1; int r=2*i+2; int largest=i; if(l<n && a[l]>a[i]) largest=l; if(r<n && a[r]>a[largest]) largest=r; if(largest!=i){ int temp=a[i]; a[i]=a[largest]; a[largest]=temp; maxheap(a,largest,n); } } void heapify(in...
ALGO
0.999986
3.837168
0210d6ca-7569-4e1a-b14a-f86bb87c48f0
harihar2909/CPP
LINKED_LIST/DoublyLinkedList/DoublyLLClass.cpp
// Doubly Ll ClASS // Some changes are there as compared to Singly Linked List #include<iostream> using namespace std; class Node{ public: int val; Node* next; Node* prev; Node(int val){ this->val=val; this->next=NULL; this->prev=NULL; } }; void display(Node*head){ while(head!=NULL){ cout<<head->val<<" "; ...
ALGO
0.999834
5.013329
aa3fc0e8-c423-464a-acda-11801a587a91
vuquangsang/VQS
harem.cpp
/* Vu Quang Sang from Le Khiet High School for Gifted */ #include <bits/stdc++.h> using namespace std; //#define ll int #define lg(x) __lg(x) #define alla(a,n) a+1,a+n+1 #define el "\n" #define all(x) x.begin(),x.end() #define pb push_back #define ll int #define fi first #define se se...
ALGO
0.999783
3.961782
4516ec3a-2782-4304-baf2-5652f7ac3d20
SMHMS-01/VsCode
CPP_STORAGE/OFFER_/indexUgly.cpp
#include <iostream> #include <windows.h> #include <cmath> using namespace std; int Min(int number1, int number2, int number3); bool isUgly(int number) { while (number % 2 == 0) number = number >> 1; while (number % 3 == 0) number /= 3; while (number % 5 == 0) number /= 5; return...
ALGO
0.999867
4.158979
e830a447-9213-46da-8346-64e7d4f564ee
Galaxy2416/bookstore
coding_life/Programer interview guide with CPP Code/cppcode/dynamic_planning/minPathSum.cpp
#include <iostream> #include <algorithm> using namespace std; template <size_t M, size_t N> constexpr int minPathSum1(const int (&m)[M][N]) { if ( m == nullptr || m[0] == nullptr) return 0; int dp[M][N] = {}; dp[0][0] = m[0][0]; for (size_t i = 1; i != M; ++i) dp[i][0] = dp[i- 1][0] + m[i][0]; for (size_t i =...
ALGO
0.999959
4.629145
38082176-6b9d-4950-8e46-5b9c55cd1bb8
Andrew-liu/Leetcode
FindPeakElement.cpp
// 二分查找 class Solution { public: int findPeakElement(vector<int>& nums) { int len = nums.size(); if(len == 0) { return 0; } int beg = 0; int end = len - 1; int mid; while(beg <= end) { mid = beg + (end - beg) / 2; if ((mid =...
ALGO
0.999982
5.605929
63c3e0f8-049e-488a-a102-fe753284fd1b
Tamimkhan7/CF
Random/D. Area.cpp
#include <bits/stdc++.h> using namespace std; #define ordered_set tree<int, null_type, less<int>, rb_tree_tag, tree_order_statistics_node_update> #define MTK \ ios_base::sync_with_stdio(0); \ cin.tie(0); \ cout.tie(0); typedef long long int ll; #define all(x) x.begin(...
ALGO
0.9982
3.918966
c5868bf2-6810-48c5-a37f-8851faa04a27
sahadat-11/CodeLibrary
Segment Tree/Segment with the Maximum Sum.cpp
//In The Name of AintAH #include <bits/stdc++.h> using namespace std; #define ll long long const int N = 1e5 + 7; int n, q; int a[N]; int pre[4 * N], suf[4 * N], psum[4 * N], t[4 * N]; void merge(int l, int r) { int p = l + r; pre[p] = max(t[l], t[l] + pre[r]); suf[p] = max(t[r], t[r] + suf[l]); psum[p] = max(psum[...
ALGO
0.999916
3.883065
e3f0d735-9ccb-46a4-baf9-72de2228ea54
cbchoi/lucidPID
lucidPID/lucidPICtrl.cpp
#include "lucidPICtrl.h" lucidPICtrl::lucidPICtrl() :m_PropController(-1), m_IntgController(-1) { } lucidPICtrl::lucidPICtrl(double _Kp, double _Ki) :m_PropController(_Kp), m_IntgController(_Ki) { } double lucidPICtrl::compute(double dt, double desired, double actual) { return m_PropController.compute(desired, ac...
ALGO
0.944826
4.395366
385f851c-e8a7-41f9-806d-6a94adb20ba8
PaukIsUha/optimizing_formating_code
predictions/submissions-aizu-gpt4/Codenet/p00884/141696737/response_2.cpp
#include <iostream> #include <vector> #include <unordered_set> #include <unordered_map> using namespace std; unordered_map<string, vector<string>> groups; unordered_map<string, unordered_set<string>> members; void dfs(const string& group, unordered_set<string>& allMembers) { if (members.find(group) == members.en...
ALGO
0.998615
5.350597
87f77469-e0bf-44ec-8f65-022ba4882ed7
Arindam01gi/DSA-Practice
Array/Alternate Positive Negative.cpp
//Alternate Positive Negative //GFG //https://www.geeksforgeeks.org/problems/array-of-alternate-ve-and-ve-nos1401/1?itm_source=geeksforgeeks&itm_medium=article&itm_campaign=practice_card //Aproach 1 - Two Pointers T.C - O(n) S.C - O(n) //{ Driver Code Starts #include <bits/stdc++.h> using namespace std; // } Driv...
ALGO
0.998974
5.654916
fd47582b-7191-4dd3-9268-5f0e69239852
ishandutta2007/codeforces
lawrenceli/normal/477/D.cpp
#include <bits/stdc++.h> using namespace std; typedef long long ll; const int MAXN = 5005; const int MOD = 1e9 + 7; int n, pw[MAXN], z[MAXN][MAXN]; char s[MAXN]; void init() { pw[0] = 1; for (int i=1; i<MAXN; i++) pw[i] = (ll(pw[i-1])*2)%MOD; for (int i=0; i<n; i++) { int l = i, r = i;...
ALGO
0.999992
4.217515
d2323118-a0b8-452e-a869-9a52086de2b6
husainl337/sort
SelectionSortGivenInp.cpp
#include <iostream> #include <vector> void selectionSort(std::vector<int>& arr) { int n = arr.size(); for (int i = 0; i < n - 1; i++) { int minIndex = i; for (int j = i + 1; j < n; j++) { if (arr[j] < arr[minIndex]) { minIndex = j; } } std...
ALGO
0.999986
6.075571
56e196fc-e175-4b79-a197-cfcc4f2e7bc8
wcysai/Calabash
2019牛客暑期多校训练营(第五场)/C.cpp
#pragma GCC optimize(3) #include<bits/stdc++.h> #include<time.h> #define MAXN 100005 #define INF 1000000000000000005LL #define MOD 1000000007 #define F first #define S second using namespace std; typedef long long ll; typedef pair<int,int> P; int T,x0,a,b,p,q; ll n; P mul(P A,P B) { P C; C.F=1LL*A.F*B.F%p; ...
ALGO
0.999589
3.419174
8a10b312-62ed-4469-af77-b5e026f7ab6a
wennitao/Luminescent-Aurora
math/FWT.cpp
#pragma GCC optimize(3,"Ofast","inline") #include<bits/stdc++.h> using namespace std; typedef long long ll; const int mod=998244353; namespace { inline int Add(const int &x,const int &y) { int res=x+y; if(res>=mod) res-=mod; return res; } inline int Sub(const int &x,const...
ALGO
0.999978
3.853674
c6678751-647c-47cb-9e8e-29845350bae8
ishandutta2007/codeforces
maspy/normal/801/C.cpp
#line 1 "/home/maspy/compro/library/my_template.hpp" #include <bits/stdc++.h> using namespace std; using ll = long long; using pi = pair<ll, ll>; using vi = vector<ll>; using u32 = unsigned int; using u64 = unsigned long long; using i128 = __int128; template <class T> using vc = vector<T>; template <class T> using v...
ALGO
0.999839
3.649265
3dc624d8-a2f4-4bb5-832e-eb4461c40dd8
JustDeny/BinaryTree-and-RBtree
RBtree.cpp
// // Created by denny on 04.05.2022. // #include "RBtree.h" bool RBtree::insert(RBNode &&node) { // Ordinary Binary Search Insertion NodePtr new_node = new RBNode{node}; new_node->parent = nullptr; new_node->left = TNULL; new_node->right = TNULL; new_node->color = Color::RED; // new node must...
ALGO
0.996694
5.052211
8f00b927-6b68-4e74-8c17-559e1d2ac914
Gautam203/DSA_using_CPP
Middle Of Linked List.cpp
Node *findMiddle(Node *head) { Node *p1 = head; Node *p2 = head; while (p1 != NULL && p1->next != NULL) { p1 = p1->next->next; p2 = p2->next; } return p2; }
ALGO
0.999813
4.761963
7ce49fc5-bbba-44f3-9211-25ae12287ff3
afifabroory/CompetitiveProgramming
CodeChef/TWOROOKS/solution.cpp
#include <iostream> using namespace std; int main() { unsigned short test; cin >> test; while (test--) { unsigned short int x_1, y_1, x_2, y_2; cin >> x_1 >> y_1; cin >> x_2 >> y_2; if (x_1 == x_2 or y_1 == y_2) cout << "YES\n"; else cout << "NO\n"; } ret...
ALGO
0.999704
4.106061
3265e87b-03d5-4e06-ae49-56a64799bca2
anupriyachhabra/Model-Predictive-Control
src/Eigen-3.3/doc/examples/Tutorial_ReductionsVisitorsBroadcasting_colwise.cpp
#include <iostream> #include <Eigen/Dense> using namespace std; int main() { Eigen::MatrixXf mat(2,4); mat << 1, 2, 6, 9, 3, 1, 7, 2; std::cout << "Column's maximum: " << std::endl << mat.colwise().maxCoeff() << std::endl; }
ALGO
0.999423
3.779679
b0c067cb-16d6-40ce-b98f-41baa3231c11
v0dro/scratch
c_shizzle/topcoder/task4_brute_force.cpp
#include <iostream> #include <vector> #include <cmath> #include <bits/stdc++.h> using namespace std; int main(int argc, char *argv[]) { int N, M; vector<vector<long long int> > list; vector<vector<long long int> > sums; cin >> N >> M; for (int i = 0; i < N; ++i) { vector<long long int> scores(3); ...
ALGO
0.999274
3.778653
04470227-9e4f-4fc3-b1d8-15b5c5120535
al3ks1002/Competitive-Programming-Library
src/graphs/biconnected-components-bridge-graph/BCCBridgeGraph.cpp
#include <stdio.h> #include <algorithm> #include <vector> using namespace std; // Class that represents an undirected graph where // you can find the biconnected components (separated by bridges). class BCCBridgeGraph { public: explicit BCCBridgeGraph(const int num_vertices) : num_vertices_(num_vertices) { dis...
ALGO
0.999985
5.589653
054a9e0d-db36-4d17-ba59-c11de980f63a
chichunchen/AOOP
source/iterator example.cpp
#include <iostream> #include <algorithm> #include <vector> #include <iterator> #include <functional> using namespace std; int main() { istream_iterator<int>input(cin); istream_iterator<int>end_of_stream; vector<int>vec; copy(input, end_of_stream, inserter(vec, vec.begin())); sort(vec.begin(), vec.end(), greater...
ALGO
0.999884
4.52764
8cf80dc4-5c26-40a2-a614-55afe727f6eb
Nomalah/School
Chess2/main.cpp
#include <iostream> #include <fstream> #include <math.h> using namespace std; #include "minimax.h" void display (int board [8][8]); int main() { int masterBoard [8][8] = { {4,2,3,6,5,3,2,4}, {1,1,1,1,1,1,1,1}, {0,0,0,0,0,0,0,0}, {0,0,0,0,0,0,0,0}, {0,0,0,0,0,0,0,0}, ...
ALGO
0.874418
4.323885