uuid
stringlengths
36
36
repo_name
stringlengths
5
133
relative_path
stringlengths
3
3.76k
content
stringlengths
282
4.03M
category
stringclasses
6 values
algo_rel_score
float32
0.9
1
quality_score
float32
3
8.13
source_meta
dict
9f1bbf83-99d6-403f-8689-5114b94b90aa
pmdiano/shuati
cpp/129-Sum-Root-to-Leaf-Numbers/solution2.cpp
/** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x), left(NULL), right(NULL) {} * }; */ class Solution { public: int sumNumbers(TreeNode* root) { int sum = 0, num = 0; TreeNode* last = nullptr...
ALGO
0.99994
5.657414
{ "github_metadata": { "branch": "master", "commit_count": 1125, "repo_created_at": "2016-05-12T06:37:50.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ff0aa6f...
4ba9b025-fdc5-4f9c-a6a6-a93c5b5f2482
Lyd1995/Leetcode
C++/390. 消除游戏.cpp
#include<algorithm> #include<stdio.h> #include<iostream> #include<vector> #include<queue> #include<stack> #include<map> #include<set> #include<math.h> using namespace std; // 暴力法 class Solution1 { public: int lastRemaining(int n) { vector<int> arr(n + 1, 1); double a = log(n) / log(2); int ...
ALGO
0.999937
3.751234
{ "github_metadata": { "branch": "master", "commit_count": 9, "repo_created_at": "2018-10-15T06:02:47.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "507a0af85a...
4abee4d1-3051-4b63-9f3e-f99f91203ca9
Tazri/Problem-Solving-By-C-and-C-Plus-Plus
codeforce/1100/706.B.Interestingdrink.cpp
// link : https://codeforces.com/problemset/problem/706/B #include <bits/stdc++.h> using namespace std; typedef long long ll; typedef double dl; #define optimize() \ ios_base::sync_with_stdio(0); \ cin.tie(0); \ cout.tie(0) #define fraction() \ cout.uns...
ALGO
0.999929
4.655027
{ "github_metadata": { "branch": "master", "commit_count": 15, "repo_created_at": "2024-11-25T23:59:55.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "96cd667c5...
7673c43b-5b87-4481-9bae-41c3a0e0d910
SarifIqbal/DSA-by-Abdul-Bari-Sir
003 Array/002 ArrayADT/binarysearchrecursion.cpp
#include <iostream> #include <stdio.h> using namespace std; struct Array { int A[20]; int size; int length; }; void display(struct Array arr) { int i; printf("Elements are: "); for (i = 0; i < arr.length; i++) printf("%d ", arr.A[i]); cout << endl; } int binarysearchrecursion(struct ...
ALGO
0.999641
4.899033
{ "github_metadata": { "branch": "main", "commit_count": 16, "repo_created_at": "2022-12-18T08:05:53.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "0ba844617fb...
fbdfa213-a4fa-4185-bdb8-6436162d59b8
TU-Berlin-DIMA/analyzing-stream-modern-hardware
other/streambox_saber/streambox_release_March_10_2018/Kaskade/tests/acml_to_stdlapack_test/acml_to_stdlapack_test.cpp
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ /* */ /* This file is part of the library KASKADE 7 */ /* see http://www.zib.de/projects/kaskade7-finite-element-toolbox */ ...
ALGO
0.961403
4.986932
{ "github_metadata": { "branch": "master", "commit_count": 6, "repo_created_at": "2019-07-02T08:39:45.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 3, "forks": 2, "issues": 0, "pull_requests": 13 }, "file_meta": { "content_id": "4b761136bf...
1cb44925-4131-4913-8342-8b9032d56777
ml6417/game
2048.cpp
# game #include<iostream> #include<cstdlib> #include<fstream> #include<string> #include<vector> #include<cmath> int rowcoltoi(int x, int y, int rowlen); void rotate_anti_clock(std::vector<int>& v); void print_grid(const std::vector<int>& v); bool random_two(std::vector<int>& v,bool pot_move); bool game_over(const s...
ALGO
0.997246
3.901009
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2018-04-08T10:34:52.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "aca17ffbc5...
4615ff39-1a79-423f-a345-54ac09a95653
ak7550/cpp-codes
practise/big_facto.cpp
#include<iostream> using namespace std; int facto_count(int); void printarr(int[], int); int main() { int n; cout<<"Enter the value to count the factorial: "; cin>>n; cout<<"The numbers present in the factorial of "<<n<<" is: "<<facto_count(n); return 0; } int facto_count(int n) { int fac[100],m...
ALGO
0.999758
4.724675
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2020-08-25T12:26:56.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "f64ed33153...
4048c555-26ff-46f0-aa94-11fac738c161
JuanjoV/HLS_LinearSolver
CholeskyLS.cpp
#include "CholeskyLS.h" #include <iostream> constexpr int UNROLL_FACTOR = 5; constexpr int ARRAY_SIZE = A_LEN/2; void MatrixTranspose(fixedP A[A_LEN][A_LEN],fixedP AT[A_LEN][A_LEN]) { for (int i = 0; i < A_LEN ; i++) { #pragma HLS UNROLL for (int j = 0; j < A_LEN; j++) { #pragma HLS UNROLL AT[i][j] = A[j][i...
ALGO
0.997965
3.809761
{ "github_metadata": { "branch": "main", "commit_count": 5, "repo_created_at": "2020-11-20T02:46:22.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "8cd602e8524f...
794df66f-f989-4e04-bdf8-2ae658e5c479
yeqing123/cpp_study
chapter_11/ex_4.cpp
#include <iostream> #include <map> #include <fstream> #include <algorithm> using namespace std; void trans(string &word) { for (int p = 0; p < word.size(); ++p) { // 只删除单词两端的标点符号,中间的不删除 if ((p == word.size() - 1 || p == 0) && ispunct(word[p])) { word.erase(p, 1); } else if (wor...
ALGO
0.999307
4.088789
{ "github_metadata": { "branch": "master", "commit_count": 15, "repo_created_at": "2024-02-02T11:59:57.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b1a22787a...
6877be31-4bc0-44db-8185-00b94fd40b90
Yamil-Serrano/Rayku-Engine
src/main.cpp
#include "raylib.h" #include "src/Player/Player.hpp" #include "src/Enemy/Enemy.hpp" #include "src/Blocks/Blocks.hpp" #include <cmath> #include <vector> using namespace std; int main() { // Initialization const int screenWidth = 800; const int screenHeight = 450; InitWindow(screenWidth, screenHeigh...
ALGO
0.96204
4.867366
{ "github_metadata": { "branch": "main", "commit_count": 9, "repo_created_at": "2025-07-17T00:24:43.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "f82e9d95cd69...
3648ea92-f605-4084-8809-b21d158b9442
sophiejacquin/UCP
Stochastic/UCP-Stochastique/src/eoUCPStochasticEvalFunc.h
#ifndef _eoUCPStochasticEvalFunc_h #define _eoUCPStochasticEvalFunc_h #include <fstream> #include <limits> #include <math.h> #include <time.h> #include <sys/time.h> /*! * \file eoUCPStochasticEvalFunc.h * \brief Evaluation of a UCP solution using multiple scenarios * \author <NAME> */ /*! * \class eoUCPStochas...
ALGO
0.986517
4.657488
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2016-07-27T15:05:45.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "88bdffec77...
f379639a-d6e6-4040-b423-5ef90407180f
devedu-AI/Data-Structures-and-Algorithms-in-Cpp-Mayank-Arora
018 - Greedy/MinCoins.cpp
// Min Coins #include <iostream> #include <cmath> #include <bits/stdc++.h> #include <climits> using namespace std; int minCoins(int coin[], int n, int amount) { sort(coin, coin + n); int res = 0; for(int i = n - 1; i >= 0; i--) { if(coin[i] <= amount) { int c = floor(amount...
ALGO
0.999766
4.888797
{ "github_metadata": { "branch": "main", "commit_count": 308, "repo_created_at": "2023-04-06T21:21:28.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 1, "forks": 2, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "8c533b21f8a...
5ede7df6-c990-46be-9098-e2d814e8893d
dipuhasan/Bit-Algorithm
6. smallest Of 3.cpp
Write a C program to find the smallest of three integers, without using any of the comparison operators. Let 3 input numbers be x, y and z. Method 1 (Repeated Subtraction) Take a counter variable c and initialize it with 0. In a loop, repeatedly subtract x, y and z by 1 and increment c. The number which becomes 0 firs...
ALGO
0.999982
4.530663
{ "github_metadata": { "branch": "master", "commit_count": 11, "repo_created_at": "2015-09-02T08:49:03.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "775cece3b...
50e490b4-68b1-495a-9da1-508d519c8237
pipo-chen/play-pat
data-structure/A1077/main.cpp
// // main.cpp // A1077 // // Created by mark on 2021/1/3. // Copyright © 2021 xihe. All rights reserved. // #include <iostream> #include <cstring> #include "stdio.h" using namespace std;; int main(int argc, const char * argv[]) { int n; scanf("%d",&n); char str[100][260]; char common[260]; in...
ALGO
0.999898
3.442053
{ "github_metadata": { "branch": "master", "commit_count": 191, "repo_created_at": "2020-08-27T01:29:02.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "8df22ed1...
0aa7344a-7ff2-4f5e-8e82-b813931a419f
codingClaire/leetcode
totalProblem(CN)/283.移动零.cpp
/* * @lc app=leetcode.cn id=283 lang=cpp * * [283] 移动零 */ // @lc code=start // @lc code=end // 87.34 % 91.2 % class Solution { public: void moveZeroes(vector<int> &nums) { int left = 0, right = 0; int len = nums.size(); while (right != len) { if (nums[right] != ...
ALGO
0.999848
6.280711
{ "github_metadata": { "branch": "main", "commit_count": 85, "repo_created_at": "2021-11-13T03:57:23.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "d103ac9086f...
ce0ec12a-813b-4bf5-a1e9-1f2a38039abf
miyajan/atcoder
typical90/019.cpp
#include <bits/stdc++.h> using namespace std; using ll = long long; int main() { ll N; cin >> N; vector<ll> A(2 * N + 1); for (int i = 1; i <= 2 * N; i++) { cin >> A.at(i); } vector<vector<ll>> dp(2 * N + 1, vector<ll>(2 * N + 1, 0)); for (int i = 1; i <= 2 * N - 1; i++) { ...
ALGO
0.999894
4.425885
{ "github_metadata": { "branch": "main", "commit_count": 111, "repo_created_at": "2019-05-04T11:44:53.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "3e9b577502...
1131b6cf-c096-422c-ae84-1d6891025f69
Peaches491/DM-MP
Homework 3/RRT.h
#ifndef _DM_MP_RRT_H_ #define _DM_MP_RRT_H_ #include <vector> #include <random> #include <iostream> #include <time.h> #include <stdio.h> #include "RRTData.h" #include "RRTConfig.h" class RRT { private: std::ostream& sout; std::default_random_engine _rand; std::uniform_real_distribution<double> goal_rand...
ALGO
0.999253
5.245837
{ "github_metadata": { "branch": "master", "commit_count": 27, "repo_created_at": "2015-03-10T18:34:08.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "0e3a6eb50...
f6eb3379-3da8-47fc-8e47-8241768de1ba
t108590016/OOP
OOP_HW6/src/polygon.h
#ifndef POLYGON #define POLYGON #include "bubble_sort.h" #include "shape.h" class Polygon : public Shape{ private: int _numVertices; Vector *_vertices; public: Polygon(Vector *vecs, int numVertices){ _numVertices = numVertices; _vertices = new Vector [_numVertices]; for(int i=0 ; i<_numVertices ; i++)...
ALGO
0.962061
4.851497
{ "github_metadata": { "branch": "main", "commit_count": 2, "repo_created_at": "2022-06-06T07:24:01.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ef73e914fbe6...
29b376e4-1b4f-4321-9704-b2e12c775642
VandanaPunjabi/Daily-coding
sort/Triplet Sum in Array.cpp
//{ Driver Code Starts #include <bits/stdc++.h> using namespace std; // } Driver Code Ends class Solution{ public: //Function to find if there exists a triplet in the //array A[] which sums up to X. bool find3Numbers(int A[], int n, int X) { //Your Code Here sort(A,A+n); in...
ALGO
0.999703
5.850421
{ "github_metadata": { "branch": "master", "commit_count": 405, "repo_created_at": "2023-02-02T16:47:21.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "45b419a8...
8227a03d-1675-41fc-a2d5-df8fea616f90
ray-arindam/Data-Structure-Problems
Searching&Sorting/SearchRotatedSortedArray/92_1_SearchRotatedArray.cpp
#include<bits/stdc++.h> using namespace std; // DSA450 92: Search in a rotated Sorted Array int search(vector<int>& nums, int target) { // If there is no element in an array if(nums.size() == 0) return -1; int lo = 0, hi = nums.size()-1; while (lo <= hi){ int mid = lo + (hi-lo)/2; ...
ALGO
0.999994
5.766222
{ "github_metadata": { "branch": "main", "commit_count": 225, "repo_created_at": "2021-08-29T17:11:55.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "57c9f18a58...
32bc4f56-fe2d-4472-a6ec-4ded0ad17b0d
samadhansk/competitive-programming
count_pairs_with_given_sum.cpp
//count pairs with given sum // { Driver Code Starts //Initial template for C++ #include <bits/stdc++.h> using namespace std; // } Driver Code Ends //User function template for C++ class Solution{ public: int getPairsCount(int arr[], int n, int k) { int cnt=0,i; map<int,int> m; for(i=0;i<n...
ALGO
0.999884
5.701467
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2020-09-06T06:10:48.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b26baf572e...
9d44ccfd-3c01-42a9-b2e3-b3e7f5858d62
cyber-robot1/Algorithmic-Problem-Solving
Codeforces/A part 2/300A.cpp
/* Author: <NAME> Problem name: Array Problem link: https://codeforces.com/problemset/problem/300/A Date: 7/9/2023 */ #include <iostream> #include <algorithm> #include <deque> using namespace std; int main() { deque<int> d; int n, x; cin >> n; for (int i = 1; i <= n; i++) { cin >> x; d.push_back(x); } sor...
ALGO
0.999817
3.798034
{ "github_metadata": { "branch": "main", "commit_count": 1001, "repo_created_at": "2021-01-09T14:56:29.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "33a30cfcc...
13096eb9-dfb6-4534-9bec-16ad2aa9a6ee
kuzsen/my-Cplusplus
LeetCode刷题/375猜数字游戏II.cpp
//动态规划题 //https://leetcode-cn.com/problems/guess-number-higher-or-lower-ii/solution/dong-tai-gui-hua-c-you-tu-jie-by-zhang-xiao-tong-2/ #include<iostream> #include<vector> using namespace std; class Solution { public: int getMoneymount(int n) { if (n == 1) { return 0; } //定义状态二维数组(n+1)x(n+1) //int dp[n+1][...
ALGO
0.999824
3.915686
{ "github_metadata": { "branch": "master", "commit_count": 165, "repo_created_at": "2021-10-03T10:35:33.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "842de5a3...
8177ab96-56bf-409a-97c5-affe34f24b8d
makoevvv/LeetCode
problem_36__valid__sudoku__.cpp
class Solution { public: bool isValidSudoku(vector<vector<char>>& board) { for (int i = 0; i < 9; i++) { set <char> validRow; for (int j = 0; j < 9; j++) { char curElem = board[i][j]; if (curElem == '.') { continue; ...
ALGO
0.998125
6.549246
{ "github_metadata": { "branch": "main", "commit_count": 57, "repo_created_at": "2024-07-26T21:16:42.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "29833c20012...
a2059295-1a97-4a24-afb2-a3aea4595d52
hmson3/TSP
held_karp/src/held_karp.cpp
#include "../include/held_karp.hpp" #include <vector> #include <climits> #include <iostream> using namespace std; int held_karp(const vector<vector<int>>& dist) { int n = dist.size(); cout << "[held_karp] n = " << n << " (input matrix loaded)\n"; // 1. dp 노드 초기화 int FULL = 1 << n; vector...
ALGO
0.999939
4.679629
{ "github_metadata": { "branch": "main", "commit_count": 18, "repo_created_at": "2025-05-13T11:07:54.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "d9646795cb4...
1464d523-61a8-4692-8891-144a88e372bf
Lixu518/leetcode
329/longestIncreasingPath.cpp
#include<iostream> #include<vector> using namespace std; vector<vector<int>>dir = {{0, -1}, {0, 1}, {-1, 0}, {1, 0}}; int dfs(vector<vector<int>> &matrix, vector<vector<int>> &dp, int i, int j){ if(dp[i][j]) return dp[i][j]; int mx = 1, m = matrix.size(), n = matrix[0].size(); for(auto a:dir){ int x...
ALGO
0.999981
5.512598
{ "github_metadata": { "branch": "master", "commit_count": 92, "repo_created_at": "2018-06-17T08:32:07.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "1bf1dbe69...
1f69d044-119a-48c3-8fe3-2ea7dd4884c4
AfandiM/CPP-Redis-Clone
hashtable.cpp
#include <assert.h> #include <stdlib.h> // calloc(), free() #include "hashtable.h" // n must be a power of 2 static void h_init(HTab *htab, size_t n) { assert(n > 0 && ((n - 1) & n) == 0); htab->tab = (HNode **)calloc(n, sizeof(HNode *)); htab->mask = n - 1; htab->size = 0; } // hashtable inserti...
ALGO
0.96882
4.849672
{ "github_metadata": { "branch": "main", "commit_count": 7, "repo_created_at": "2025-03-24T19:25:04.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "2fce779187bc...
3b09c99d-a356-496e-9b7d-b3a0e76520c4
HET-CE/Codeforces-level-A-level-B
Codeforces Problems/CpotionsEASY.cpp
#include<bits/stdc++.h> using namespace std; #define ll long long #define ld long double #define vll vector<ll> #define vi vector<int> #define vb vector<bool> #define pi pair<int,int> #define pll pair<ll,ll> #define vp vector<pi> #define vpll vector<pll> #define pb push_back #define mp make_pair #define mt make_tuple #...
ALGO
0.999995
4.571759
{ "github_metadata": { "branch": "main", "commit_count": 7, "repo_created_at": "2021-05-10T16:30:50.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "34e494c698ea...
3ff6007f-d234-40a7-8976-03c6edba31b7
Hotrook/Challenges
TRNGLFLD.cpp
#include <iostream> #include <cstdio> #include <cstdlib> #include <vector> #include <algorithm> #define FOR(i,a,b) for(long long i = a ; i < b ; ++i ) #define PB push_back using namespace std; const int size = 45009; struct input{ int x; int y; int numer; }; bool malejacoYcomp( input a , input b ){ return a....
ALGO
0.999897
3.335073
{ "github_metadata": { "branch": "master", "commit_count": 98, "repo_created_at": "2016-04-03T11:44:49.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "98022818c...
e27f7c36-9eae-4549-b4a4-66be10ae7ea8
GabrielVantuil/DCA1202
Unidade 2/Projeto-Sudoku/Sudoku/sudoku.cpp
#include <iostream> #include <fstream> #include <string> #include <stack> #include "sudoku.h" using namespace std; Jogada::Jogada(int I, int J, int V){ // Construtor (por default, cria Jogada que termina o jogo) if (I<0 || I>8) I=-1; if (J<0 || J>8) J=-1; if (V<0 || V>9) V=-1; i = I; j = J; v = V; } ...
ALGO
0.98124
4.05815
{ "github_metadata": { "branch": "master", "commit_count": 15, "repo_created_at": "2017-10-09T16:59:30.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "7df4a7af6...
de07d5bc-f2a2-4c23-9f38-1048ffd241e1
intel/libxcam
xcore/fisheye_dewarp.cpp
/* * fisheye_dewarp.cpp - fisheye dewarp implementation * * Copyright (c) 2017-2019 Intel Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/...
ALGO
0.967893
6.486696
{ "github_metadata": { "branch": "master", "commit_count": 1242, "repo_created_at": "2015-01-15T07:37:41.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 601, "forks": 234, "issues": 14, "pull_requests": 1 }, "file_meta": { "content_id": "abf...
f4f0ef18-9a0e-4a5d-8c22-ff7f5ac77209
s-nandi/contest-problems
general-techniques/greedy-algorithms/general/sbcs_hangar.cpp
// combo/greedy, nck (pascal's identity) // https://codeforces.com/gym/102861/problem/H // 2021 Brazil Subregional #include <bits/stdc++.h> using namespace std; #define rep(i,a,b) for(auto i=(a); i<(b); ++i) #define trav(a,x) for(auto& a: x) #define all(x) begin(x),end(x) #define sz(x) (int)size(x) #define PB push_ba...
ALGO
0.999984
4.327365
{ "github_metadata": { "branch": "master", "commit_count": 1205, "repo_created_at": "2017-12-06T06:51:11.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "cdb9afe...
b248b685-c758-4adf-b588-832a0e84227f
Zahid-Hasan-Mozumder/Interesting-CP-Problems
Prefix Sum (2D)/Counting Rectangles.cpp
// Problem link: https://codeforces.com/problemset/problem/1722/E //------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------...
ALGO
0.999476
4.817955
{ "github_metadata": { "branch": "main", "commit_count": 332, "repo_created_at": "2022-12-21T19:59:26.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b5d5b77687...
45571750-6e0a-4bdb-ba44-7c747855e70e
nimamasoumi/DiffeoRaptor
DiffeoRaptor/Cxx/src/Base/FftOper.cxx
# include "FftOper.h" FftOper::FftOper(const float _alpha, const float _gamma, const int _lpow, const GridInfo _grid, const int _truncX, const int _truncY, const int _truncZ) { alpha = _alpha; gamma = _gamma; lpow = _lpow; grid = _grid; fsx = grid.size().x; fsy = grid.s...
ALGO
0.994136
5.225294
{ "github_metadata": { "branch": "main", "commit_count": 6, "repo_created_at": "2021-10-03T01:44:28.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 4, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "a7f9056651a4...
c95ddb72-0183-487d-9166-ab40ba16b253
sanjeetboora/Launchpad_29Dec2019
Lecture08/maxSumSubmatrix.cpp
#include <iostream> using namespace std; int maxSumSubmatrix(int arr[10][10], int r, int c){ int sum = INT_MIN; //suffix sum matrix //row wise sum for (int i = r-1 ; i >= 0; i--) { for (int j = c-2; j >=0 ; j--) { arr[i][j] += arr[i][j+1]; } } //column wise sum for (int i = r-2 ; i >= 0; i--) { fo...
ALGO
0.999902
4.900812
{ "github_metadata": { "branch": "master", "commit_count": 48, "repo_created_at": "2019-12-30T07:17:32.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 10, "issues": 0, "pull_requests": 1 }, "file_meta": { "content_id": "dd5f12a7...
bba263ba-c7a2-4dc9-9bc9-bddecea5a434
o8n/competitive_programming
abc/75/abc075/b.cpp
#include <iostream> #include <vector> #include <string> using namespace std; vector<int> DX = {1, 0, -1, 0, 1, -1, -1, 1}; vector<int> DY = {0, 1, 0, -1, 1, 1, -1, -1}; int main() { // H*Wの盤面を入力 int H, W; cin >> H >> W; vector<string> S(H); for (auto& row : S) { cin >> row; } for (int i = 0; i < H;...
ALGO
0.999978
4.469777
{ "github_metadata": { "branch": "main", "commit_count": 46, "repo_created_at": "2022-09-11T05:51:11.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "0e291a4242f...
9dbd158a-9975-4c3d-9c8f-50716a8f3fea
dearfl/leetcode-solutions
src/1925-count-square-sum-triples.cpp
// A square triple (a,b,c) is a triple where a, b, and c are integers and a2 + b2 = c2. // // Given an integer n, return the number of square triples such that 1 <= a, b, c <= n. // class Solution { public: int countTriples(int n) { int ans = 0; for (int i = 1; i <= n; i++) { for (int j...
ALGO
0.999134
5.843254
{ "github_metadata": { "branch": "master", "commit_count": 277, "repo_created_at": "2020-02-23T09:11:13.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "399db768...
e4a9d98b-774e-4c06-8464-27ade6ab63df
dmkz/competitive-programming
acmp.ru/0505.cpp
#pragma GCC diagnostic ignored "-Wunused-result" #include <stdio.h> #include <bits/stdc++.h> template<typename T> bool operator<(const std::vector<T>& a, const std::vector<T>& b) { assert(a.size() == b.size()); for (int i = 0; i < (int)a.size(); ++i) { if (a[i] < b[i]) { return true; ...
ALGO
0.993606
4.022624
{ "github_metadata": { "branch": "master", "commit_count": 2019, "repo_created_at": "2018-04-25T11:54:48.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 41, "forks": 9, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ca14ec...
0f45497c-cb36-4d2c-bf17-87b69798c918
tryst-kumar/DATA-structure
DynamicBitArray/main.cpp
#include <iostream> #include <vector> #include <cmath> void findPrimes(int limit) { std::vector<bool> is_prime(limit + 1, true); is_prime[0] = is_prime[1] = false; for (int p = 2; p * p <= limit; p++) { if (is_prime[p]) { for (int i = p * p; i <= limit; i += p) { is_pr...
ALGO
0.999735
5.148839
{ "github_metadata": { "branch": "main", "commit_count": 16, "repo_created_at": "2025-06-08T06:12:23.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "e8799899da3...
3b003da7-e40c-4001-841a-44b71e4c7e6a
mag-noise/mssaprocessingpipeline
MSSAProcessingPipeline/src/Utilities/MatrixDefinitions.hpp
#pragma once #include <algorithm> #include <vector> #include <deque> #include <numeric> #include <cmath> #include <stdexcept> #ifdef _DEBUG #include <assert.h> #endif // ! namespace Utils{ /// <summary> /// Singleton class to maintain flags across signals /// </summary> class FlagSystem { public: en...
TOOL
0.914737
7.051379
{ "github_metadata": { "branch": "main", "commit_count": 112, "repo_created_at": "2024-03-20T08:42:17.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 0, "forks": 0, "issues": 1, "pull_requests": 0 }, "file_meta": { "content_id": "22b12857050...
2252a273-0d14-4619-b442-2bd5ffb5bb07
minhtan0804/CTDL-GT
Searching and Sorting/Hợp và giao của hay dãy 1/HopVaGiaoCuaHaiDay1.cpp
#include<bits/stdc++.h> using namespace std; void nhap(int A[], int n) { for (int i = 0; i < n; i++) cin >> A[i]; } void Tao(int A[], int B[], int n) { for (int i = 0; i < n; i++) B[A[i]]++; } void HopVaGiao(int A[], int B[], int n, int m) { int C[100005] = {0}; Tao(A, C, n); Tao(B, C, m); for (int i = 0; i <...
ALGO
0.999978
3.673767
{ "github_metadata": { "branch": "main", "commit_count": 7, "repo_created_at": "2022-03-23T10:37:30.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "19fb8d1a6cc4...
7fba2fa6-84e3-4d2b-8737-0af526de5c6f
xinyandai/similarity-search
src/include/bench/benchrecord.hpp
#pragma once #include <vector> #include <algorithm> #include <utility> #include <unordered_set> using std::vector; using std::pair; using std::unordered_set; class BenchRecord { private: int _query_id; vector<pair<float, int> > _knn; unordered_set<int> _knn_ids; public...
ALGO
0.960047
6.2813
{ "github_metadata": { "branch": "master", "commit_count": 56, "repo_created_at": "2018-08-07T07:01:47.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 19, "forks": 10, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "d41f6ff...
a7299271-bf3d-4b80-bbf4-db1da25067f6
MrityunjayNPandey/vscode
CP/C_Bombs.cpp
#include <bits/stdc++.h> using namespace std; #define endl "\n" #ifdef DEBUG #include "algo/debug.h" #else #define debug(...) #endif #define free freopen("input.txt","r",stdin);freopen("output.txt","w",stdout);freopen("error.txt","w",stderr); #define all(x) x.begin(), x.end() #define rall(x) x.rbegin(), x.rend() #defi...
ALGO
0.999852
3.453382
{ "github_metadata": { "branch": "master", "commit_count": 172, "repo_created_at": "2022-01-11T10:38:16.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "cf8cfd00...
5c1e47d0-8bed-4b95-89e8-7a5ef8469f74
jimindacoder/rUNSWift-Bootcamp-team1
robot/perception/vision/detector/RefereeHandsDetector.hpp
#ifndef PERCEPTION_VISION_DETECTOR_REFEREEHANDSDETECTOR_H_ #define PERCEPTION_VISION_DETECTOR_REFEREEHANDSDETECTOR_H_ #include "DetectorInterface.hpp" #include <opencv2/opencv.hpp> #include "types/RefereeHandDetectorSettings.hpp" struct RectangleRegion { int left; int top; int width; int height; }; s...
ALGO
0.903616
7.403623
{ "github_metadata": { "branch": "main", "commit_count": 25, "repo_created_at": "2024-10-21T06:45:56.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "5691eab83b0...
2f2b9ae7-6bae-4de4-8838-f90ab33a5543
xyang619/gsim-old
AdmSimulator/Chrom.cpp
/* * Chrom.cpp * * Created on: Sep 26, 2014 * Author: xiong_yang */ #include <iostream> #include "Chrom.h" Chrom::Chrom() { std::vector<Segment> segments; this->segments = segments; std::vector<double> breaks; this->breaks = breaks; } Chrom::Chrom(const std::vector<Segment> & segments) : segme...
TOOL
0.911735
4.215161
{ "github_metadata": { "branch": "master", "commit_count": 15, "repo_created_at": "2015-01-18T10:53:13.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "09c65f5ce...
bdc02b10-6728-4fb1-99d1-518eec418e70
GouravShDev/codeforces-sol
MainakandArray.cpp
#include <bits/stdc++.h> using namespace std; #define sync_off \ ios::sync_with_stdio(0); \ cin.tie(0); #define ll long long int int main() { sync_off; #ifndef ONLINE_JUDGE freopen("input.txt", "r", stdin); #endif int tc; cin >> tc; while (tc--) { int n; cin ...
ALGO
0.999837
4.556249
{ "github_metadata": { "branch": "main", "commit_count": 4, "repo_created_at": "2022-09-05T19:20:19.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "0b4085fc8677...
4594f034-86d4-4496-9173-4d7da27710f2
nawngs/CompetitiveProgramming
gspvh/putnik.cpp
#include <bits/stdc++.h> #define name "putnik" #define ll long long #define ld long double #define fi first #define se second #define pll pair < ll, ll > #define pii pair < int, int > #define fast ios::sync_with_stdio(0);cin.tie(0);cout.tie(0); #define SZE(x) ((int)(x).size()) #define pb push_back #define mp make_pai...
ALGO
0.999951
3.484554
{ "github_metadata": { "branch": "main", "commit_count": 27, "repo_created_at": "2021-06-19T07:51:36.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "36e4cdec40a...
4486ab6f-c091-4ea2-86ad-263aee2d8a96
AkhetAtonStudentRada/Subjects-helper
Перший курс/ІПЗ/Основи програмування (1 частина)/Код до звітів Основ програмування/лаб_2/Project_1_5/Project5/Source.cpp
#include <iostream> #include <cmath> using namespace std; int main() { double x_1, x_2, n, step; tryagain: cout << "x_1, x_2, n, step : " << endl; cin >> x_1 >> x_2 >> n >> step; if ((n < 1) || (step <= 0) || (x_1 > x_2)) { goto tryagain; } else { while (x_1 <= x_2) { if (x_1 <= 0) { double y = 0, i...
ALGO
0.998015
3.78864
{ "github_metadata": { "branch": "main", "commit_count": 94, "repo_created_at": "2023-02-01T19:02:32.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ecaf5a4e1e3...
d6209479-1a61-4313-8079-7c0aa455f54f
abunaim1/data_structure
week-3 doubly_list/practice_day1/pbl-5.cpp
// #include <iostream> // #include<list> // using namespace std; // int main() // { // int n; // cin>>n; // int a[n]; // for(int i=0; i<n; i++){ // cin>>a[i]; // } // list<int>myList(a,a+n); // myList.sort(); // for(int v:myList){ // cout<<v<<" "; // } // return 0...
ALGO
0.999889
4.885956
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2024-03-06T10:36:32.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "6ad71d7512c2...
e3ae8121-5749-42f7-8518-7286b9ddfdb7
dmehrab06/Time_wasters
codeforces/upsolve/489D.cpp
#include <bits/stdc++.h> #define MIN(X,Y) X<Y?X:Y #define MAX(X,Y) X>Y?X:Y #define ISNUM(a) ('0'<=(a) && (a)<='9') #define ISCAP(a) ('A'<=(a) && (a)<='Z') #define ISSML(a) ('a'<=(a) && (a)<='z') #define ISALP(a) (ISCAP(a) || ISSML(a)) #define MXX 100000000000000000 #define MNN -MXX #define VALID(X,Y,N,M) ((X)>=1 && (X)...
ALGO
0.999805
3.301778
{ "github_metadata": { "branch": "master", "commit_count": 8, "repo_created_at": "2017-09-26T07:24:08.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "58f1cfb981...
233c1c9b-8603-4025-ac7b-b67d96fc4db8
cvc5/cvc5
src/theory/quantifiers/oracle_engine.h
/****************************************************************************** * Top contributors (to current version): * <NAME> * * This file is part of the cvc5 project. * * Copyright (c) 2009-2025 by the authors listed in the file AUTHORS * in the top-level source directory and their institutional affiliat...
TOOL
0.912291
7.404398
{ "github_metadata": { "branch": "main", "commit_count": 13437, "repo_created_at": "2012-12-06T18:45:04.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 1150, "forks": 259, "issues": 116, "pull_requests": 56 }, "file_meta": { "content_id": "a...
80114657-1831-466a-9b21-e6101c7b41e5
B20DCCN528/C-
phuongantoiuu.cpp
#include <bits/stdc++.h> #define endl '\n' using namespace std; string ans; vector<pair<int, int>> x; vector<vector<int>> F; void trace(int n, int k) { if (n == 0) return; if (F[n][k] == F[n - 1][k]) trace(n - 1, k); else { trace(n - 1, k - x[n].first); ans[n - 1] = '1'; ...
ALGO
0.999996
3.316007
{ "github_metadata": { "branch": "main", "commit_count": 21, "repo_created_at": "2021-08-19T14:35:15.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "1bd176234ec...
315e6cc3-5774-4d75-9b73-fef6e34a6970
SamCPollock/GAME2001-F2020
Week 1/MemoryAccess.cpp
#include <time.h> #include <iostream> using namespace std; const int n = 750; float TestData[n][n][n]; // Helper function that will convert clock ticks to milliseconds. double diffClock(clock_t clock1, clock_t clock2) { double diffticks = clock1 - clock2; // difference between 2 sep clock ticks double diffms = (di...
ALGO
0.960094
3.668564
{ "github_metadata": { "branch": "main", "commit_count": 4, "repo_created_at": "2020-09-13T23:48:56.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "cc92a66d8159...
fcafde72-d539-4123-9bf8-f16c5d92a4e1
Sandy192110564/DATASTRUCTURES3
DS implement Array operations such as Insert, Delete and Display.cpp
#include <stdio.h> #define MAX_SIZE 100 void display(int arr[], int size) { printf("Array elements: "); for (int i = 0; i < size; i++) { printf("%d ", arr[i]); } printf("\n"); } int insert(int arr[], int size, int position, int element) { if (size >= MAX_SIZE) { printf("Array is ful...
ALGO
0.99704
5.702147
{ "github_metadata": { "branch": "main", "commit_count": 31, "repo_created_at": "2023-08-01T04:22:26.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "266a7730635...
df5359d0-eaa7-4312-b480-83da2518d126
rockieCao/LeetCodeSolution
TwoPointers/4Sum.cpp
#include<iostream> #include<vector> #include<unordered_map> #include<algorithm> using namespace std; // K-sum problem: // can be reduced to 2-sum problem finally // an O(n^2*logn) solution can refer to http://blog.csdn.net/linhuanmars/article/details/24826871 class Solution { public: vector<vector<int> > fourSum(v...
ALGO
0.999949
5.248561
{ "github_metadata": { "branch": "master", "commit_count": 49, "repo_created_at": "2015-12-12T08:48:48.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "2d345028b...
29e8e66f-0f45-4328-afa2-1218718ed367
sylvainprigent/BioImageLib
BioImageLib/src/blRAT/blRATTracker.h
/// \file blRATTracker.h /// \brief blRATTracker class /// \author <NAME> /// \version 0.1 /// \date 2015 #pragma once #include "blRATCostManager.h" #include "blRATFramesLoader.h" #include <vector> #include "blCore/blProcess.h" /// \class blRATTracker /// \brief Class that implement the recursive association trackin...
ALGO
0.974907
5.296399
{ "github_metadata": { "branch": "master", "commit_count": 29, "repo_created_at": "2015-01-03T14:24:15.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "0bd4ad9e9...
21c007da-5604-48b6-85ac-0e474b7732cb
kjnh10/pcw
work/atcoder/arc/arc060/E/answers/55413_H19980412.cpp
#include <cstdio> #include <cstring> #include <cstdlib> #include <cmath> #include <ctime> #include <cassert> #include <string> #include <algorithm> #include <vector> #include <queue> #include <stack> #include <functional> #include <iostream> #include <map> #include <set> #include <cassert> using namespace std; typedef ...
ALGO
0.999927
3.441985
{ "github_metadata": { "branch": "master", "commit_count": 40, "repo_created_at": "2018-05-23T15:03:22.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "11f473b0c...
a5ed0818-414a-4771-babf-babcb1cca8a8
kouki8710/Programming-competitions
AtcoderARC/arc98/d.cpp
//#define _GLIBCXX_DEBUG #include <bits/stdc++.h> using namespace std; using ll = long long; using ld = long double; #define INF 100000000 #define rep(i, s, n) for (int i = (int)(s); i < (int)(n); i++) #define repp(i, n, s) for (int i = (int)(n); i >= (int)(s); i--) #define mp make_pair #define tp make_tuple typedef pa...
ALGO
0.999994
3.751429
{ "github_metadata": { "branch": "master", "commit_count": 9, "repo_created_at": "2020-12-26T11:02:20.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "674a32a979...
a511193a-c900-4ab5-bd31-7c9b9d907258
mikhil-c/ooaia-labs
Lab10/main.cpp
#include <iostream> #include <string> #include <vector> #include <iomanip> #include <algorithm> #include <cassert> using std::cin; using std::cout; using std::string; using std::vector; using std::fixed; using std::setprecision; using std::min; // #define int long long // #define float long double template <class T> ...
ALGO
0.994646
4.175549
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2025-06-19T17:28:14.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "6d5437b9dc2a...
ba8aae3c-76b3-4d96-939c-492f009333ca
HiddenWoodpecker/NewVector
VectorNew.cpp
#include "VectorNew.h" using ValueType = double; Vector::Iterator::Iterator(ValueType *ptr) { _ptr = ptr; } ValueType *Vector::Iterator::operator->() { return _ptr; } const ValueType *Vector::Iterator::operator->() const { return _ptr; } Vector::Iterator Vector::Iterator::operator++() { _ptr++; return *this; } Ve...
TOOL
0.926775
5.554959
{ "github_metadata": { "branch": "master", "commit_count": 6, "repo_created_at": "2024-03-16T12:45:18.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "4ec922a13c...
ee9dda38-442c-45de-b030-b1a8a4ba8b14
ymd45921/HUST-ACM-training
offline/2020/CCPC2020Weihai/H.cc
/** * * */ #include <bits/stdc++.h> using namespace std; using longs = long long; using uint = unsigned; using ulongs = unsigned long long; using longd = long double; using lll = __int128; #define minimize(a, b) ((a) = min(a, b)) #define maximize(a, b) ((a) = max(a, b)) #define sgn(x) ((x) < 0 ? -1 : (x) > 0) #def...
ALGO
0.999481
3.624568
{ "github_metadata": { "branch": "master", "commit_count": 423, "repo_created_at": "2020-12-02T04:26:06.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "9f7d6140...
55a02264-4bf0-4e7e-b9a8-b199e0b334c6
Wankupi/cpp
搜索/折半/[USACO12OPEN]Balanced Cow Subsets G.cpp
// Accepted with O2 #include <cstdio> #include <vector> #include <algorithm> using namespace std; int n = 0, Mid = 0; int a[21]; struct State { int st; long long sum; }; inline bool operator<(State const &lhs, State const &rhs) { return lhs.sum < rhs.sum; } vector<State> A, B; void dfs(int d, int limit, long long sum...
ALGO
0.999986
3.891919
{ "github_metadata": { "branch": "master", "commit_count": 57, "repo_created_at": "2019-12-21T12:37:05.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "2bb33f98f...
5cd4e316-486a-40cc-bb19-3e426084c5da
MujtabaChohan190/Cpp-Programs
C++ OOP/factorial_oop.cpp
/*Task 1: Write the following code using Object-Oriented Programming. #include <iostream> using namespace std; int factorial(int n) { if (n == 0 || n == 1) { return 1; } else { return n * factorial(n - 1); } } int main() { int number; cout << "Enter a number: "; cin >> number; if (number < 0) { cout << "Factorial is n...
ALGO
0.999477
5.551624
{ "github_metadata": { "branch": "main", "commit_count": 29, "repo_created_at": "2024-11-30T11:33:35.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "316dbc6416b...
4d307c10-d202-4d14-998d-4f3e3e045586
BEaANIKET/365-Days-of-code-challenge
2.geegs_for_geeks/easy/Least_Prime_Factor.cpp
//{ Driver Code Starts // Initial Template for C++ #include <bits/stdc++.h> using namespace std; // } Driver Code Ends // User function Template for C++ class Solution { public: vector<int> leastPrimeFactor(int n) { // code here // code using sieve of Eratosthenes logic ...
ALGO
0.999292
5.396498
{ "github_metadata": { "branch": "main", "commit_count": 216, "repo_created_at": "2023-03-09T15:09:23.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "1929db4428...
d90819ab-f521-4aa0-80aa-2603094b3f3a
Drasko97/SystemC
loto.cpp
#include "loto.hpp" #include <cstdlib> #include <ctime> #include <random> #include <algorithm> using namespace std; using namespace sc_core; Module01::Module01(sc_core::sc_module_name name, int limit) : limit(limit) { SC_THREAD(lotto_machine); SC_THREAD(player1); SC_THREAD(player2); SC_THREAD(player3); SC_THREA...
ALGO
0.998728
4.082356
{ "github_metadata": { "branch": "master", "commit_count": 3, "repo_created_at": "2019-04-01T19:45:14.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "6ed0d99339...
84c6ecb0-faf1-4828-9b4f-fb868ab12015
yy-nm/LeetCode
vs-project/128. Longest Consecutive Sequence/128. Longest Consecutive Sequence.cpp
// 128. Longest Consecutive Sequence.cpp : This file contains the 'main' function. Program execution begins and ends there. // #include <iostream> #include <vector> #include <unordered_set> using namespace std; class Solution { public: int longestConsecutive(vector<int>& nums) { unordered_set<int> s; ...
ALGO
0.999982
5.999747
{ "github_metadata": { "branch": "master", "commit_count": 27, "repo_created_at": "2024-01-13T04:17:34.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "f6a4d617c...
b6564483-8288-4e37-8e5e-4a85bc2e0adb
tupieurods/CryptoExperiments
CryptoExperiments/AES/AesWithTables.cpp
#include <cstdio> #include "AesWithTables.h" #include "AesNaive.h" #include "Helpers.h" #include <cstring> void CipherWithTables(unsigned char *in, unsigned char *out, unsigned int *w, const AESparam *aesParam) { unsigned int state[4], tmp[4]; for(size_t i = 0; i < aesParam->Nb; i++) { state[i] = in[i * 4 +...
ALGO
0.998562
5.053973
{ "github_metadata": { "branch": "master", "commit_count": 21, "repo_created_at": "2017-08-24T16:52:36.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ac739c3d9...
6011d81d-e1cb-45f7-813d-9421b216776a
ETLCPP/etl
include/etl/private/crc_implementation.h
///\file /****************************************************************************** The MIT License(MIT) Embedded Template Library. https://github.com/ETLCPP/etl https://www.etlcpp.com Copyright(c) 2021 <NAME> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and ass...
ALGO
0.989156
7.381814
{ "github_metadata": { "branch": "master", "commit_count": 5548, "repo_created_at": "2014-10-16T11:12:24.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 2570, "forks": 455, "issues": 39, "pull_requests": 2 }, "file_meta": { "content_id": "2a...
1f38668b-8a88-45ab-b6c6-43ae7a7bb165
dgalaktionov/trippy-gis
ctr/libcds/includes/trees/bp (Case Conflict).h
#ifndef _HEADER_BP_H #define _HEADER_BP_H #include <stdlib.h> #include <trees/Parentheses.h> #include <trees/bp.h> namespace cds_static{ class BP: public Parentheses{ public: /** The bitmap input is in a weird format. The first bit has to be at position 31 instead of at position 0. That is, each bi...
ALGO
0.944112
3.786512
{ "github_metadata": { "branch": "master", "commit_count": 91, "repo_created_at": "2019-03-14T13:28:15.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "0c421e6b4...
7ec1e119-3505-4c99-88a3-7b6ffe05ff5c
hek-git/problem_solving
programmers/Lv. 2/20240220_단체사진 찍기.cpp
#include <iostream> #include <map> #include <string> #include <vector> using namespace std; vector<char> line; vector<int> check; map<char, int> m; string character; int a; bool validation(vector<string>& data) { for (int i = 0; i < data.size(); i++) { int a, b, distance; for (int j = 0; j < 8; j...
ALGO
0.999715
4.038964
{ "github_metadata": { "branch": "main", "commit_count": 205, "repo_created_at": "2023-06-23T11:27:56.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "80ed817c07...
e5d2d1c2-49b0-4660-b6e1-0fb9c4ca942f
solARisOP/Data-Structures-and-Algorithms
sde sheet/105_pre_order_binary_tree.cpp
#include <bits/stdc++.h> using namespace std; #define ll long long #define vi vector<int> #define vvi vector<vi> #define pii pair<int, int> #define vp vector<pii> class Node { public: int val; Node *left; Node *right; Node() : val(0), left(NULL), right(NULL) {} Node(int x) : val(x), left(NULL), r...
ALGO
0.999996
4.84179
{ "github_metadata": { "branch": "master", "commit_count": 80, "repo_created_at": "2022-02-28T12:01:59.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "247009630...
65bf7ed8-5610-43c9-8281-c1a201a3292d
AdamNbz/cf-solutions
1990D.cpp
#include <bits/stdc++.h> #pragma GCC optimize("Ofast") #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,avx2,fma") #pragma GCC optimize("unroll-loops") #define fi first #define se second #define el '\n' #define pb push_back #define io() ios_base::sync_with_stdio(0); cin.tie(NULL); cout.tie(NULL) #defin...
ALGO
0.999726
4.381053
{ "github_metadata": { "branch": "main", "commit_count": 184, "repo_created_at": "2024-08-05T17:28:30.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "432e0b0b13...
aef993bf-f0c7-4cf4-b02c-483e580afc3a
dsakhapo/Advanced-Programming-Projects-CMPS109-
asg1_dc/ubigint.cpp
// $Id: ubigint.cpp,v 1.8 2015-07-03 14:46:41-07 - - $ // Partner: <NAME>(<EMAIL>) // Partner: <NAME> (<EMAIL>) #include <cstdlib> #include <exception> #include <stack> #include <stdexcept> #include<string> using namespace std; #include "ubigint.h" #include "debug.h" ubigint::ubigint(const int& value) { ubig_value...
ALGO
0.969807
4.315176
{ "github_metadata": { "branch": "master", "commit_count": 6, "repo_created_at": "2016-03-19T03:42:44.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "d9dd4cd7af...
96fcd315-33eb-48cd-bc8f-c043fa345053
crosslife/DSAA
DSAA2/Concordance2.cpp
#include <iostream.h> #include <fstream.h> #ifdef unix #include <strstream.h> #else #include <strstrea.h> // <strstream.h> on UNIX machines #endif #include "mystring.h" #include "AvlTree.h" #include "LinkedList.h" struct WordEntry { WordEntry( ) : word( "" ), lines( NULL ) { } bool operator<(...
TOOL
0.978988
4.535276
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2013-11-06T01:14:25.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 5, "forks": 2, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "d5889252c6...
06565dcb-036d-4e51-8d48-33d9b4665d80
GellertAnastasia/LabWork2
include/botTurn.h
/* <NAME> <EMAIL> labwork 2 */ /** * @class BotTurn * @brief Manages the complete AI player turn cycle * * Coordinates: * - Resource allocation * - Character state reset * - AI decision-making logic */ #ifndef BOTTURN_H #define BOTTURN_H #include "aiController.h" class BotTurn { public: Field& field; ...
ALGO
0.903184
5.234757
{ "github_metadata": { "branch": "main", "commit_count": 68, "repo_created_at": "2025-02-21T12:21:39.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 1 }, "file_meta": { "content_id": "58bf94daf8c...
78776cd8-639a-481f-acdb-0283796267ab
uadam12/equation-solver
src/simultaneous_in_3_variables.cpp
#include "solver.h" void solve_simultaneous_in_3_variables() { cout << "Form: a1x + b1y + c1z = d1.\n"; cout << " a2x + b2y + c2z = d2.\n"; cout << " a3x + b3y + c3z = d3.\n"; float a1 = get_number("a1"), b1 = get_number("b1"), c1 = get_number("c1"), d1 = get_number("d1"), ...
ALGO
0.98665
3.9743
{ "github_metadata": { "branch": "main", "commit_count": 6, "repo_created_at": "2023-11-08T13:57:43.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "7fc2a9ee724c...
409c8b16-5b3a-4db4-b87c-e90d34444a4a
moon-holy/data-structure
stackq.cpp
#include <iostream> #include <vector> #define MAXSIZE 100 // 栈的顺序存储 // template<class T> class SqStackClass { T *data; int top; public: SqStackClass(); ~SqStackClass(); bool SqStackisEmpty(); bool Push(T elem); bool Pop(T &elem); bool GetSqStackTop(T &elem); }; template<class T> SqStackClass<T>::SqS...
ALGO
0.992419
3.818538
{ "github_metadata": { "branch": "master", "commit_count": 3, "repo_created_at": "2023-10-20T07:47:32.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "abfb329c04...
a2f4428a-320f-4c7c-aa70-6e4117975a6f
ketansarode17/LeetCode_Problems
Find pairs with given sum in doubly linked list - GFG/find-pairs-with-given-sum-in-doubly-linked-list.cpp
//{ Driver Code Starts //Initial Template for C++ #include <bits/stdc++.h> using namespace std; class Node { public: int data; Node *next, *prev; Node(int val) : data(val), next(NULL), prev(NULL) { } }; // } Driver Code Ends //User function Template for C++ /* Doubly linked list node class clas...
ALGO
0.99972
5.769945
{ "github_metadata": { "branch": "main", "commit_count": 277, "repo_created_at": "2022-12-16T09:17:56.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "73de41d78f...
dc227ee9-17ec-4c51-af39-a0aedbee8bb5
harshitneversettle/DSA
class_35_LinkedList2/Q3.cpp
// LEETCODE (237) ; // Delete Node of LL given only head not tail, Delete(head,target) ; #include<iostream> using namespace std ; class Node{ public: int value ; Node* next ; Node (int value ){ this -> value = value ; this -> next = NULL ; } }; void display( Node *head){ wh...
ALGO
0.99984
4.18286
{ "github_metadata": { "branch": "main", "commit_count": 4, "repo_created_at": "2025-07-23T16:14:52.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "d5d25d5d4408...
125fbc30-47b1-4bb7-999b-608b8d7a5443
pawan-vishwakarma/DSA-Interview
Graph/0-Graph-Represent/G-02-grid-template-dfs-bfs.cpp
// dfs recursive void dfs(int x, int y, vector<vector<int>>& grid, vector<vector<bool>>& visited) { int rows = grid.size(), cols = grid[0].size(); visited[x][y] = true; int dx[] = {-1, 1, 0, 0}; int dy[] = {0, 0, -1, 1}; for (int d = 0; d < 4; ++d) { int nx = x + dx[d], ny = y + dy[d]; ...
ALGO
0.999843
6.005218
{ "github_metadata": { "branch": "main", "commit_count": 72, "repo_created_at": "2025-05-16T08:29:40.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "08d33c13728...
12fcebdb-59bd-4edf-886f-b9aed4a95f1b
umerfayyaz2/C-PlusPlus-Laboratory
Computer_Speed_Programming_2024/Programming_Fundamental_Problems/largest_occurence_array.cpp
#include <iostream> using namespace std; void findLargestElement(int arr[], int size) { // Step 1: Assume the first element is the largest int largest = arr[0]; // Step 2: Loop through the array starting from the second element for (int i = 1; i < size; i++) { // Step 3: Compare each eleme...
ALGO
0.999834
5.713783
{ "github_metadata": { "branch": "main", "commit_count": 180, "repo_created_at": "2024-08-14T10:28:15.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "004e28f94d...
8be2a601-d4a4-446d-9b0c-eb1f8931727d
lballabio/QuantLib
ql/methods/finitedifferences/solvers/fdmhestonhullwhitesolver.hpp
/* -*- mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /* Copyright (C) 2009 <NAME> This file is part of QuantLib, a free-software/open-source library for financial quantitative analysts and developers - http://quantlib.org/ QuantLib is free software: you can redistribute it and/or modif...
ALGO
0.996331
6.883169
{ "github_metadata": { "branch": "master", "commit_count": 17543, "repo_created_at": "2015-12-17T16:29:33.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 6151, "forks": 1964, "issues": 51, "pull_requests": 11 }, "file_meta": { "content_id":...
075ff90c-920e-44fa-a8fe-d29c002622d9
zqy1018/my_leetcode
code/1104.cpp
#include <bits/stdc++.h> #define INF 2000000000 using namespace std; typedef long long ll; int read(){ int f = 1, x = 0; char c = getchar(); while(c < '0' || c > '9'){if(c == '-') f = -f; c = getchar();} while(c >= '0' && c <= '9')x = x * 10 + c - '0', c = getchar(); return f * x; } struct TreeNod...
ALGO
0.999957
3.846914
{ "github_metadata": { "branch": "master", "commit_count": 74, "repo_created_at": "2020-01-08T04:35:33.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 24, "forks": 4, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "69645382...
001c6654-e215-4749-a853-4c88856fca2c
alexgunkel/eulerPlayGround
src/728/circle.test.cpp
#include "circle_of_coins.hpp" #include "gtest/gtest.h" TEST(CircleOfCoins, numberOfPossibleSolutions) { CircleOfCoins circle(20); for (uint64_t i = 1; i <= 20; ++i) { for (uint64_t j = 1; j <= i; ++j) { EXPECT_EQ(circle.reachableStates(i, j, 0).size(), circle.numberOfPossibleSolutions(i, ...
TEST
0.995157
5.831728
{ "github_metadata": { "branch": "mainline", "commit_count": 53, "repo_created_at": "2020-09-05T14:57:23.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b1d471c...
2c9c12d1-3269-4af3-8a2e-7fcc5086117d
wlj961012/LastJunior
数据结构算法/栈的操作/栈的操作/源.cpp
#include<iostream> #include<string> using namespace std; struct node{ int data; node* next; node(int d) { data = d; next = NULL; } }; class Stack { private: node * head; node *tail; public: Stack() { head = new node(0); tail = head; } void push(int d) { node *s; s = new node(d); tail->next = s; ...
ALGO
0.993215
3.776188
{ "github_metadata": { "branch": "master", "commit_count": 4, "repo_created_at": "2018-06-03T03:44:46.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 13, "forks": 5, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "9954caa5f...
ff2d93d0-1bc2-4549-9336-261f580cf4af
itzPEKOS/CU-Grader
ComProg/Dept-Selection.cpp
#include <bits/stdc++.h> #define f first #define s second #define ll long long #define pii pair<int, int> using namespace std; map<string,int> dept; // map<string,vector<string>> select; map<string,string> ans; // vector<pair<double,string>> srt; vector<tuple<double, string, vector<string>>> ns; int main() { io...
ALGO
0.99991
3.799623
{ "github_metadata": { "branch": "main", "commit_count": 79, "repo_created_at": "2024-08-10T06:35:45.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "cc563dd011a...
b8e5b6fa-0eb5-461a-99c6-66c8c1c11aa6
UnnamedOrange/Contests
Source Code/李沿橙 2017-10-2/competition/source/HNSDFZ郑原/wave.cpp
#include <cstdio> #include <algorithm> #include <iostream> using namespace std; const int N = 2e6 + 5; int A[N], n, k, ud; bool check(int a, int b) { if (ud == 1) return b - k >= a; else return a - k >= b; } int main() { freopen("wave.in", "r", stdin); freopen("wave.out", "w", stdout); scanf("%d%d", &n, &k);...
ALGO
0.999982
3.863515
{ "github_metadata": { "branch": "master", "commit_count": 79, "repo_created_at": "2017-11-28T07:28:56.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "5d2df36ee...
f2bdd7ec-b7e5-447c-8453-023742fc5e36
tangziyi001/competitive-programming
STL/BullInAChinaShop.cpp
/* * USACO 2016 US Open Contest, Bronze 2 * Coded by <NAME> * Brute Force and STL */ //#include <bits/stdc++.h> #include <iostream> #include <fstream> #include <cstdio> #include <string> #include <cstring> #include <cstdlib> #include <sstream> #include <cmath> #include <algorithm> #include <list> #include <vector>...
ALGO
0.999745
3.357824
{ "github_metadata": { "branch": "master", "commit_count": 220, "repo_created_at": "2015-09-15T13:45:33.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "55c52883...
d1396993-1819-4fed-a469-103ba2e9e991
georgerapeanu/c-sources
euro.cpp
#include <cstdio> #include <cassert> #include <iostream> #include <set> using namespace std; FILE *f = fopen("euro.in","r"); FILE *g = fopen("euro.out","w"); const long long IS_QUERRY = 1LL << 60; struct linear_function_t{ long long a,b; mutable set<linear_function_t> :: iterator nxt; mutable bool is_last; li...
ALGO
0.999903
3.428349
{ "github_metadata": { "branch": "master", "commit_count": 177, "repo_created_at": "2018-08-15T14:37:53.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 8, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "47d5e28f...
df7fd15b-fc40-45c6-be72-020403610642
ji2468307/Illescas_Jessica_CSC5_46091_Sum2015
HW/Assignment 1/Gaddis_7thEd_CH2_HW#8/main.cpp
/* * File: main.cpp * Author: <NAME> * Created: June 26, 2015, 3:30 PM * Purpose: Total Purchase */ // System Libraries #include <cstdlib> #include <iostream> // I/O Library #include <iomanip> // Set decimal points using namespace std; // Namespace for iostream /* *User Libraries *Global Constants *Func...
TOOL
0.94672
4.046088
{ "github_metadata": { "branch": "master", "commit_count": 7, "repo_created_at": "2015-06-30T21:39:19.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "62384f6211...
110e69b1-9981-4857-8ce2-7bef4003e33d
shamanDevel/IsosurfaceSuperresolution
third-party/include/openvdb/tree/NodeManager.h
/////////////////////////////////////////////////////////////////////////// // // Copyright (c) 2012-2018 DreamWorks Animation LLC // // All rights reserved. This software is distributed under the // Mozilla Public License 2.0 ( http://www.mozilla.org/MPL/2.0/ ) // // Redistributions of source code must retain the abov...
ALGO
0.949715
6.622346
{ "github_metadata": { "branch": "master", "commit_count": 5, "repo_created_at": "2019-10-14T07:20:43.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 8, "forks": 5, "issues": 0, "pull_requests": 4 }, "file_meta": { "content_id": "b03e89ee56...
7272cce0-c58d-445b-9fd6-fbe03192d31c
Aster696/C-DSA
circularLinkedList.cpp
#include <iostream> using namespace std; class Node{ public: int key, data; Node *next; Node() { key = data = 0; next = NULL; } Node(int k, int d) { key = k; data = d; next = NULL; } }; class CircularLinkedList { public: Node *head; C...
ALGO
0.999776
5.714513
{ "github_metadata": { "branch": "main", "commit_count": 45, "repo_created_at": "2024-06-02T04:57:27.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "35b5dc17878...
15c08fa0-501f-4cdb-b6c0-c614cb8bcbfd
minhvpham/codeblock
tinhoc/l.cpp
#include<bits/stdc++.h> using namespace std; #define pb push_back #define ll long long void fastio() { ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0); } int a[505][505], n, m, s=0; void read() { cin >> n >> m; for(int i=1; i<=n; i++) { for(int j=1; j<=m; j++) cin >> a[i][j]; ...
ALGO
0.999894
3.404032
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2022-01-01T20:12:53.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "eb1c5565d57d...
08f10c3b-65c6-44ac-b363-b616e1b23496
potel/DOM
localdom/whit.h
#ifndef _whit #define _whit #include <iostream> #include <cmath> #include <new> using namespace std; /** *\brief Whittaker functions * *calculates Whittaker functions - asymptotic for bound-state with *Coulomb interaction */ class whit { public: whit(int); ~whit(); static double const pi; static dou...
ALGO
0.999486
4.398602
{ "github_metadata": { "branch": "master", "commit_count": 36, "repo_created_at": "2016-11-21T21:55:32.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 2, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "273f2971b...
0a8f1030-5fc7-4b4a-903c-a2ee9b710f79
Rawkush/Coding-practice
Merge Sort - GFG/merge-sort.cpp
//{ Driver Code Starts #include <stdio.h> #include <bits/stdc++.h> using namespace std; /* Function to print an array */ void printArray(int arr[], int size) { int i; for (i=0; i < size; i++) printf("%d ", arr[i]); printf("\n"); } // } Driver Code Ends class Solution { public: void merg...
ALGO
0.999932
6.359315
{ "github_metadata": { "branch": "master", "commit_count": 666, "repo_created_at": "2018-04-12T15:22:18.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "1f36dff2...
0978a722-fce2-4cbd-9071-128885913b31
novikov-ilia-softdev/algorithms_datastructures
hr/ipk/greedy_algorithms/balance_luck/main.cpp
#include <bits/stdc++.h> #include <algorithm> using namespace std; vector<string> split_string(string); int luckBalance(int k, vector<vector<int>> contests) { vector<int> importantContests; vector<int> nonImportantContests; for( int i = 0; i < contests.size(); i++) { if( contests[i][1] ...
ALGO
0.999906
4.618232
{ "github_metadata": { "branch": "master", "commit_count": 298, "repo_created_at": "2018-06-01T19:52:29.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "c75d5ebd...
f891ea9c-58ba-4f42-9a17-4bdb9defbba2
AbelkAntony/stone-paper-scissors
RockPaperScissor/RockPaperScissor/RockPaperScissor.cpp
#include <iostream> #include <cstdlib> using namespace std; int Point(string userSelection, string computerSelection) { int point = 0; if (userSelection == "ROCK") { if (computerSelection == "ROCK") { point += 0; cout << "\nDRAW\n"; } else if (computerSelection == "PAPER") { point -= 5; cout <...
ALGO
0.991085
3.78623
{ "github_metadata": { "branch": "main", "commit_count": 8, "repo_created_at": "2023-01-22T09:04:10.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "6dc11baad139...
51b9bde9-2cec-4e85-8530-955f4810209f
raincross7/code-similarity
codes/train_code/problem236/problem236_327.cpp
#include<stdio.h> #include<iostream> #include<vector> #include<math.h> #include<queue> #include<map> #include<algorithm> #include<string.h> #include<functional> #include<limits.h> #include<stdlib.h> #include<cmath> #include<cstring> #include<set> #include<climits> using namespace std; #define intmax INT_MAX #define lm...
ALGO
0.999948
3.564091
{ "github_metadata": { "branch": "main", "commit_count": 3, "repo_created_at": "2024-03-06T05:07:19.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "00f11336c3df...
f97a2b96-5ba3-46c5-8e26-9620b9afec24
Aadesh-singh/Data-structures-and-algorithm-practice
Binary-Tree/test/check-cousin.cpp
#include <iostream> #include "../BinaryTreeNode.h" #include <queue> using namespace std; BTN<int> *takeInput() { int rootdata; cin >> rootdata; if (rootdata == -1) return NULL; BTN<int> *root = new BTN<int>(rootdata); queue<BTN<int> *> pendingNodes; pendingNodes.push(root); while (!...
ALGO
0.999906
4.535144
{ "github_metadata": { "branch": "main", "commit_count": 109, "repo_created_at": "2022-01-25T06:35:48.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b03a30f844...
cf868f49-dc97-4ce3-be1f-7509b9eb7c73
Yawn-Sean/Daily_CF_Problems
daily_problems/2025/04/0403/personal_submission/cf911e_yawn_sean.cpp
#include <bits/stdc++.h> #pragma GCC optimize("O3,Ofast,unroll-loops") // #include "atcoder/convolution" // #include "atcoder/dsu" // #include "atcoder/fenwicktree" // #include "atcoder/lazysegtree" // #include "atcoder/math" // #include "atcoder/maxflow" // #include "atcoder/mincostflow" // #include "atcoder/modint" /...
ALGO
0.999876
3.826363
{ "github_metadata": { "branch": "main", "commit_count": 20410, "repo_created_at": "2024-02-26T01:04:08.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 478, "forks": 302, "issues": 0, "pull_requests": 7 }, "file_meta": { "content_id": "3905...