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
fcd60a84-32b4-42e8-a252-7a0420ff00ec
cormoran/CompetitiveProgramming
src/contest/atcoder/abc/abc057/B/main.comp.cpp
#include <bits/stdc++.h> using namespace std; #define rep(i, j) for(int i=0; i < (int)(j); i++) template<class T> bool set_min(T &a, const T &b) { return a > b ? a = b, true : false; } const int INF = 1 << 30; class Solver { public: bool solve() { int N, M; cin >> N >> M; vector<int> A(N), B(N);...
ALGO
0.999993
4.0938
{ "github_metadata": { "branch": "master", "commit_count": 110, "repo_created_at": "2016-08-18T12:24: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": "101d07ff...
9a4c7740-4d01-4ffe-809f-411a72c1462b
aakashbh1/DSA-Notes
IMPORTANT ALGO'S/Moore's Voting Algorithm.cpp
/* Given an array nums of size n, return the majority element. The majority element is the element that appears more than ⌊n / 2⌋ times. You may assume that the majority element always exists in the array. */ // Moore's majority vote algorithm // https://en.wikipedia.org/wiki/Boyer–Moore_majority_vote_algorithm // As...
ALGO
0.999988
6.474472
{ "github_metadata": { "branch": "main", "commit_count": 108, "repo_created_at": "2023-07-28T02:39:17.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "6ce324f379...
c8b20e48-740c-4059-b006-c78162f17ae9
jacobjburton/cs161-assignments
Week4/fallDistance.cpp
/******************************************************************************************************** ** Author: <NAME> ** Date: 01/28/2019 ** Description: Asks user to input a falling time in seconds. Calculates the falling distance ** and returns that distance in meters. *****************************...
TOOL
0.902029
5.249956
{ "github_metadata": { "branch": "master", "commit_count": 11, "repo_created_at": "2019-02-12T07:07: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": "a59eb5fbb...
35c3d569-dadf-40e7-990a-ecaef7595bb6
Muhammad-Subhan456/Leetcode-Problems
1114-binary-search-tree-to-greater-sum-tree/1114-binary-search-tree-to-greater-sum-tree.cpp
/** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode() : val(0), left(nullptr), right(nullptr) {} * TreeNode(int x) : val(x), left(nullptr), right(nullptr) {} * TreeNode(int x, TreeNode *left, TreeNode *right) : val(x), l...
ALGO
0.999983
5.061943
{ "github_metadata": { "branch": "main", "commit_count": 1038, "repo_created_at": "2024-08-17T08:57: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": "2b9daf3b9...
32bb65be-7436-43e7-b1e2-a01deaaaf991
Visible1/Problems-Solutions
Yandex Coderun 2/Супер мега марафон.cpp
#include <bits/stdc++.h> using namespace std; #define mp(a,b) make_pair(a,b) #define ff first #define setp(a) setprecision(a)<<fixed #define ss second #define fori(v) for(int i=0; i<v; i++) #define forj(v) for(int j=0; j<v; j++) #define fork(v) for(int k=0; k<v; k++) #define forl(v) for(int l=0; l<v; l++) #define fort(...
ALGO
0.981809
3.253031
{ "github_metadata": { "branch": "main", "commit_count": 57, "repo_created_at": "2023-03-12T18:35: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": "2569b823e57...
3bf0197a-16c8-4040-a2ca-9dc381621a77
sahadat-11/CodeLibrary
Bit Malupulatiion/Sum_of_bitwise_AND_of_all_possible_subsets.cpp
//In The Name of ALLAH #include <bits/stdc++.h> using namespace std; #define ll long long const int mod = 1e9 + 7; ll binexp(ll a, ll b) { ll ans = 1; while(b) { if(b & 1) {// if b in odd ans = (ans * a) % mod; // type cast for integer overflow } a = (a * a) % mod; b >>= 1; // if ...
ALGO
0.999876
4.386654
{ "github_metadata": { "branch": "main", "commit_count": 88, "repo_created_at": "2023-08-02T16:50: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": "8c1174d2b1e...
4b7322a0-fbf3-433c-9585-e42c46470e57
aphrim/codeforces-workspace
completed/1500/they-are-everywhere.cpp
/* ID: gregper1 TASK: LANG: C++ */ #include <bits/stdc++.h> #define int long long int using namespace std; template<typename T> istream& operator>>(istream& in, vector<T>& a) {for(auto &x : a) in >> x; return in;}; template<typename T> ostream& operator<<(ostream& out, vector<T>& a) {for(auto &x : a) out << x << ' ...
ALGO
0.999992
3.818514
{ "github_metadata": { "branch": "master", "commit_count": 64, "repo_created_at": "2022-04-18T00:42:33.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "79825be1a...
4ddbb8a4-572f-4538-b9c4-dc5a856ddd4c
lbuck92/algorithms
insertion_sort.cpp
//<NAME>... Insertion Sort //3.29.2018, c++ #include <iostream> using namespace std; #define array_size(array) (sizeof((array))/sizeof((array[0]))) void doInsertionSort(int arr[], int sizeOfArray){ int key,j; std::cout << "Initial array: "; for(int i = 0; i < sizeOfArray; i++){ std::cout <<...
ALGO
0.999908
5.040386
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2018-03-29T22:14: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": "d6008a4729...
c1f9868a-ebac-4408-90de-9403a766766d
akash-1107/DSA-Codes
13.Graph/7.ShortestPath/dijkstra'sAlgo.cpp
#include <bits/stdc++.h> using namespace std; class Solution { public: vector<int> dijkstra(int n , vector<vector<int>> adj[], int src) { priority_queue<pair<int, int>, vector<pair<int, int>>, greater<pair<int, int>>> pq; //{dist , neighbour} vector<int> distTo(n , INT_...
ALGO
0.99985
4.725223
{ "github_metadata": { "branch": "main", "commit_count": 5, "repo_created_at": "2024-07-24T04:58: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": "2fcfc39d6e44...
30dbf65e-2921-41e3-8fb2-a4d259d34421
bcgsc/abyss
Assembly/AdjacencyAlgorithm.h
#ifndef ASSEMBLY_ADJACENCYALGORITHM_H #define ASSEMBLY_ADJACENCYALGORITHM_H 1 namespace AssemblyAlgorithms { /** Generate the adjacency information for each sequence in the * collection. */ template <typename Graph> size_t generateAdjacency(Graph* seqCollection) { typedef typename graph_traits<Graph>::vertex_descri...
ALGO
0.957479
6.372056
{ "github_metadata": { "branch": "master", "commit_count": 5566, "repo_created_at": "2012-03-19T23:13:39.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 322, "forks": 110, "issues": 4, "pull_requests": 0 }, "file_meta": { "content_id": "25da...
38625954-a419-4795-a52a-1dd79d1a213b
wu-kan/HPL-AI
src/pauxil/HPLAI_alaswp06T.cc
/* * MIT License * * Copyright (c) 2021 WuK * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, me...
ALGO
0.987627
5.763085
{ "github_metadata": { "branch": "master", "commit_count": 140, "repo_created_at": "2021-02-05T15:50:39.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 27, "forks": 5, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "819fd05...
bd343f06-8be9-4ea3-ac72-51e8135dcbc4
rusucosmin/cplusplus
Segmente/main.cpp
#include <fstream> #include <vector> #include <bitset> #include <map> #include <math.h> #include <string.h> #include <iomanip> using namespace std; const char infile[] = "seg.in"; const char outfile[] = "seg.out"; ifstream fin(infile); ofstream fout(outfile); const int MAXN = 18; const double oo = 1.0*100000; type...
ALGO
0.999527
3.953083
{ "github_metadata": { "branch": "master", "commit_count": 11, "repo_created_at": "2014-02-06T08:06:48.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 7, "forks": 2, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b33e5b28e...
e8d81102-4088-4d02-8f04-6f1385798f88
khushbooagarwal1/algorithms
Dynamic Programming/Candies/candies.cpp
#include <cmath> #include <cstdio> #include <vector> #include <iostream> #include <algorithm> using namespace std; int main() { /* Enter your code here. Read input from STDIN. Print output to STDOUT */ int N; long int temp; cin >> N; vector< long int > student(N); student.reserve(N); for...
ALGO
0.999997
4.023543
{ "github_metadata": { "branch": "master", "commit_count": 145, "repo_created_at": "2017-06-15T13:29: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": "22e5fc78...
1803f4a1-f887-4aa1-818b-8da986922791
AI-YUER/TEST
src/common/include/common/MPC.hpp
#ifndef _MPC_HPP_ #define _MPC_HPP_ // 状态量维度。取2或4,代表pitch和yaw上的位置,或位置与速度 #define _D_STATE_ 2 // 控制量维度。取2即可,代表pitch和yaw的速度 #define _D_CTRL_ 2 #if (_D_STATE_ != 2 && _D_STATE_ != 4) || _D_CTRL_ != 2 #error \ [MPC] The state dimention has not been set to a pres...
TOOL
0.910674
5.922362
{ "github_metadata": { "branch": "main", "commit_count": 2, "repo_created_at": "2025-05-08T02:37: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": "5aa95bc78be5...
0225682d-fd43-4b77-817c-cdd9b84b85a8
hermanumrao/code_templates
cpp/cpp_adv.cpp
/****************************************************************************** * Filename: ${FILENAME} * Author: ${AUTHOR} * Date: ${DATE} * Version: 1.0 * Description: This file contains the main implementation for the ${PROJECT_NAME} * module using C++ features. * * License: [Your Lice...
TOOL
0.994533
5.116075
{ "github_metadata": { "branch": "main", "commit_count": 2, "repo_created_at": "2025-04-14T17:31: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": "851a5e73527f...
dc801012-dcb9-436e-8e1f-a898287357c6
TinSlam/Mewtle
Engine/Mewtle/includes/Mewtle/AI/AI.h
#pragma once namespace Mewtle{ class MapNode{ private : int x = 0, y = 0; float fValue = 0; float gValue = 0; MapNode* parent = nullptr; public : MapNode(int x, int y); int getX(); int getY(); float getFValue(); float getGValue(); MapNode* getParent(); void setFValue(float value); void setG...
ALGO
0.970514
4.545191
{ "github_metadata": { "branch": "master", "commit_count": 5, "repo_created_at": "2019-07-10T07:11: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": "33f13293d0...
eb08ccef-977e-4023-b735-75f5dddaa1a0
bhaveshgawri/codeforces
C/25.cpp
#include <bits/stdc++.h> #define ll long long int #define nl "\n" #define pb push_back #define ppb pop_back #define pf push_front #define ppf pop_front #define sz(x) x.size() #define all(x) x.begin(), x.end() #define Sort(x) sort(all(x)) #define init(x, k) fill(a...
ALGO
0.99995
3.251497
{ "github_metadata": { "branch": "master", "commit_count": 16, "repo_created_at": "2017-01-06T18:31: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": "20f22788b...
bb554137-e5e1-4ed9-a76f-3d69ac48ff3a
Sai-Venky/TraversalWithC
challenges/string/parse-lisp-expression.cpp
// https://leetcode.com/problems/parse-lisp-expression/ // Note the traversal with recursion. IMP question to understand class Solution { public: int evaluate(string expression) { int i = 0; unordered_map<string, int> m; return parse(expression, expression.size(), i, m); } int parse(string& s, int ...
ALGO
0.999313
5.182926
{ "github_metadata": { "branch": "master", "commit_count": 530, "repo_created_at": "2020-05-03T14:48:55.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "78e763e6...
6e14a353-3ff9-4cf4-bdee-448301337da4
zykowicz/passmen
pass.cpp
#include <cryptopp/secblock.h> #include <iostream> #include <string> #include <unordered_map> #include <cryptopp/aes.h> #include <cryptopp/modes.h> #include <cryptopp/filters.h> #include <cryptopp/base64.h> using namespace CryptoPP; std::string encrypt(const std::string& plain, const std::string& key){ std::string ...
TOOL
0.930569
5.961421
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2024-04-14T18:53: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": "4d76f2343825...
3f2c65ae-8242-4933-9a8f-1585ccbd9c6a
openvinotoolkit/openvino
src/frontends/onnx/frontend/src/op/stft.cpp
// Copyright (C) 2018-2025 Intel Corporation // SPDX-License-Identifier: Apache-2.0 // #include "core/null_node.hpp" #include "core/operator_set.hpp" #include "exceptions.hpp" #include "openvino/op/broadcast.hpp" #include "openvino/op/concat.hpp" #include "openvino/op/constant.hpp" #include "openvino/op/multiply.hpp" ...
ALGO
0.943792
7.310431
{ "github_metadata": { "branch": "master", "commit_count": 19551, "repo_created_at": "2018-10-15T10:54:40.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 8597, "forks": 2656, "issues": 303, "pull_requests": 258 }, "file_meta": { "content_id"...
7ddb7816-9f18-4454-942f-14c2902e8684
overIsAC/contest
atc/abc/abc343/d.cpp
#include <bits/stdc++.h> using namespace std; using LL = long long; using PII = pair<int, int>; #define lson (k << 1) #define rson (k << 1 | 1) #if LEMON #define db(x) cout << "function " << __FUNCTION__ << ", line " << __LINE__ << " : " << #x << " " << x << endl; #else #define db(x) #endif const int mod = 7 + 1e9; /...
ALGO
0.999673
3.962688
{ "github_metadata": { "branch": "main", "commit_count": 131, "repo_created_at": "2022-10-30T18:24: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": "908a038103...
9c13df8d-98de-4bd3-b014-ea19369200d7
samkusin/overview
Engine/Controller/NavSystem.cpp
// // NavSystem.cpp // EnginePrototype // // Created by <NAME> on 2/17/16. // // #include "NavSystem.hpp" #include "NavBody.hpp" #include "Engine/Path/NavPath.hpp" #include "Engine/Path/NavPathQuery.hpp" #include "Engine/Path/Pathfinder.hpp" #include "Engine/Debug.hpp" #include <ckm/math.hpp> #include <algorithm>...
ALGO
0.962052
7.001941
{ "github_metadata": { "branch": "master", "commit_count": 333, "repo_created_at": "2016-09-03T20:42:25.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "253eb838...
25fb58c9-2d73-45d6-aba8-c47419853449
chu-in-seon/Algorithm_PS
01_Baekjoon/p1373.cpp
#include <iostream> #include <math.h> #include <string> #include <vector> using namespace std; vector<int> res; int main() { ios::sync_with_stdio(false); string inp; int cal = 0; cin >> inp; for(int i = inp.size() - 1; i >= 0; i--) { int idx = i + 1, num; num = inp[i] - '0'; ...
ALGO
0.999959
3.716218
{ "github_metadata": { "branch": "master", "commit_count": 201, "repo_created_at": "2017-07-25T06:30: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": "211a6110...
073ed418-4ac5-4867-99d4-b1a6204983f9
bkunjesh/Competitive-Coding
competitive code/TUSHAR_KA_B_DAY.cpp
//@ikung #include <bits/stdc++.h> using namespace std; #define int long long #define fast \ ios_base::sync_with_stdio(0); \ cin.tie(0); #define f(i, k) for (int i = 0; i < k; i++) #define F first #define dbg(x) cout << #x << " " << x << endl; #define S second #define endl "\n" #define rep(i...
ALGO
0.999987
4.117198
{ "github_metadata": { "branch": "master", "commit_count": 66, "repo_created_at": "2020-10-14T21:18: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": "ad80ade89...
649c1159-c044-4f0d-9d20-b6b14a810543
Daahae/algo
rkddlsgur983/Programmers/21주차_이진탐색/1_예산.cpp
/* 예산 * 이진탐색 * 2020.01.12 */ #include <algorithm> #include <vector> using namespace std; long sumOfBudget(vector<int> budgets, int max_b) { long sum = 0L; for (auto b: budgets) { if (b <= max_b) sum += b; else sum += max_b; } return sum; } int solution(vector<int> budgets, int M) ...
ALGO
0.999984
5.279435
{ "github_metadata": { "branch": "master", "commit_count": 361, "repo_created_at": "2019-07-18T13:35:17.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 0, "forks": 1, "issues": 3, "pull_requests": 0 }, "file_meta": { "content_id": "8729c1f77...
bb8c5118-6c62-498f-88c6-e7b56f0b7b97
CBICA/CaPTk
src/applications/common_includes/MultiImageOpticalFlowImageFilter.h
/*========================================================================= Program: ALFABIS fast medical image registration programs Language: C++ Website: github.com/pyushkevich/greedy Copyright (c) <NAME>, University of Pennsylvania. All rights reserved. This program is part of ALFABIS: Adaptive Lar...
ALGO
0.96717
7.053409
{ "github_metadata": { "branch": "master", "commit_count": 7846, "repo_created_at": "2018-04-10T13:36:31.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 190, "forks": 65, "issues": 164, "pull_requests": 10 }, "file_meta": { "content_id": "38...
3e8f84fa-caae-48a0-86a2-f1107b041c68
Lorenzo-Bonelli/Plasma-TLBM
src/poisson.cpp
#include "poisson.hpp" #include <vector> #include <mutex> // for call_once #include <algorithm> // for std::fill namespace poisson { static std::vector<double> phi; static std::once_flag poisson_init_flag, fftw_init_flag; // Variables for GS, SOR, 9ps convergence static constexpr size_t maxIter = 5000; static cons...
ALGO
0.999923
5.524548
{ "github_metadata": { "branch": "main", "commit_count": 21, "repo_created_at": "2025-06-27T10:21: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": "41f6988a644...
d5dffd75-9180-431a-9a49-ab544bd6e363
fbghgus123/algorithm
c++/세그먼트트리/10868_최솟값.cpp
// 문제 : https://www.acmicpc.net/problem/10868 #include <stdio.h> #include <string> using namespace std; int N, M, tmpN; int tree[1024 * 512]; int min (int a, int b) { return a < b ? a : b; } void make_tree() { for (int i=tmpN-1; i > 0; i--) { tree[i] = min(tree[i*2], tree[i*2+1]); } } int find_min...
ALGO
0.999997
4.418901
{ "github_metadata": { "branch": "main", "commit_count": 214, "repo_created_at": "2022-01-23T11:55:26.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "9c6dc395d6...
fc47e1c0-7d46-4a2d-90c2-52b578124801
jfaganUK/pii
src/RcppExports.cpp
// Generated by using Rcpp::compileAttributes() -> do not edit by hand // Generator token: <PASSWORD> #include <RcppArmadillo.h> #include <Rcpp.h> using namespace Rcpp; // getEdgeNetworkCalc IntegerMatrix getEdgeNetworkCalc(IntegerMatrix inputEdgeList); RcppExport SEXP pii_getEdgeNetworkCalc(SEXP inputEdgeListSEXP) ...
ALGO
0.994028
6.143049
{ "github_metadata": { "branch": "master", "commit_count": 80, "repo_created_at": "2014-10-08T17:17:13.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "1f03f999d...
41db6e36-1629-492b-a238-42d200315955
Fortitude42/CompetitiveProgrammingArchive
Camps/Ptz41/UPSOLVING/B5/a.cpp
#include <bits/stdc++.h> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> using namespace std; using namespace __gnu_pbds; //#define int long long //#pragma GCC optimize("Ofast") //#pragma comment(linker, "/stack:200000000") //#pragma GCC targe...
ALGO
0.999843
3.55546
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2024-05-08T16:52:20.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "af056855393e...
81321957-868b-47af-ab8e-64e16269a109
menaehab/Codeforces-Solutions
1001 - 2000 problems/O_Catch_Overflow.cpp
#include <iostream> #include <bits/stdc++.h> #include <vector> #include <algorithm> #include <cmath> #include <map> #include <iomanip> #include <string> #include <set> #include <queue> #include <unordered_map> #include <unordered_set> #define ll long long #define el '\n' #define all(arr) arr.begin(), arr.end() #define ...
ALGO
0.998803
4.151712
{ "github_metadata": { "branch": "main", "commit_count": 117, "repo_created_at": "2024-08-24T15:38:58.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "8ed0fee6e7...
556818f2-b8b8-491f-9ad7-bfb29185fc42
sentiers/CSE2017
lab06_doublyLinkedlist/polynomial.cpp
// CSE2017-01 Data Structure // Lab 06 - Doubly Linked List // // Name: <NAME> // StudentID: 2019113581 // Email: <EMAIL> // Date: 2021 April 15 // // polynomial.cpp // :Polynomial program that using doubly liked list #include <iostream> #include <cmath> #include <string> #include "listdbl.cpp" using namespace std; ...
ALGO
0.989006
4.960837
{ "github_metadata": { "branch": "main", "commit_count": 3, "repo_created_at": "2021-10-14T03:28: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": "dd622fbf8fae...
ed8bb799-77e4-4938-a8e9-e92ae4547ee0
kipr/opencv
modules/ocl/src/brute_force_matcher.cpp
/*M/////////////////////////////////////////////////////////////////////////////////////// // // IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING. // // By downloading, copying, installing or using the software you agree to this license. // If you do not agree to this license, do not download, instal...
ALGO
0.905442
4.226703
{ "github_metadata": { "branch": "master", "commit_count": 7094, "repo_created_at": "2013-01-27T01:06:29.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 152, "forks": 340, "issues": 3, "pull_requests": 0 }, "file_meta": { "content_id": "353e...
e5ba9e88-8ca3-4a15-a433-ca0b6c42dd0a
rameshwarikodam/DS
C++/LeetCode/Binary Search Problems/35. Search Insert Position.cpp
/* Given a sorted array of distinct integers and a target value, return the index if the target is found. If not, return the index where it would be if it were inserted in order. You must write an algorithm with O(log n) runtime complexity. Example 1: Input: nums = [1,3,5,6], target = 5 Output: 2 Example 2: Inpu...
ALGO
0.999981
6.13759
{ "github_metadata": { "branch": "main", "commit_count": 30, "repo_created_at": "2022-06-07T18:18: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": "fe9ae1e97f8...
735ac138-795f-4926-b26d-95c2d641889b
Abhisin90/Codes_CC
Data Structures/DS_Assignment_1/hi.cpp
#include<bits/stdc++.h> using namespace std; #define fo(i,o,n) for(int i=0;i<n;i++) #define ro(i,o,n) for(int i=n-1;i>=0;i--) #define fast ios_base::sync_with_stdio(false);cin.tie(NULL); typedef long long int ll; #define MAX 1000 class Stack { public: int top; int a[MAX]; Stack() { top = -1; } bool pu...
ALGO
0.999828
3.144823
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2021-09-25T18:05: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": "2dcb3e2513...
9e72d159-a24b-46d7-a348-b716cda5ea38
ishandutta2007/codeforces-d
dreamoon_love_aa/normal/1179/C.cpp
/*{{{*/ #include<cstdio> #include<cstdlib> #include<cstring> #include<cmath> #include<algorithm> #include<string> #include<iostream> #include<sstream> #include<set> #include<map> #include<queue> #include<bitset> #include<vector> #include<limits.h> #include<assert.h> #define SZ(X) ((int)(X).size()) #define ALL(X) (X).be...
ALGO
0.999964
3.873015
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2024-04-11T01:31: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": "4df1132f49a2...
68646520-486e-4f32-afd4-6c28f1dd773f
AndrewHess/AndrewHessCLinux
357.cpp
/* 357.cpp <NAME> Project Euler problem 357 2/21/2017 */ #include<iostream> #include<vector> #include<algorithm> #include<cmath> using namespace std; vector<bool> p(pow(10, 6) +1); vector<int> primes; void divisors(vector<int> *factors, int ind, long cur, vector<int> *divs, long num) { if (ind >= factors->size...
ALGO
0.999785
3.977079
{ "github_metadata": { "branch": "master", "commit_count": 23, "repo_created_at": "2016-10-27T18:02:12.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "5cb503dd9...
26b4a290-cfcb-4dcd-9427-c0e13280702c
vedavikas06/competetive-programming
Hackerearth/April circuits/Happy segments.cpp
#include <bits/stdc++.h> using namespace std; #define pb push_back #define sf scanf #define pf printf #define f first #define s second #define clr(x,y) memset(x,y,sizeof x) #define LL long long #define L int #define mx 100009 typedef pair<int,int> pii; typedef vector<int> vi; typedef vector<pii> vii; int n,q,...
ALGO
0.999969
3.644857
{ "github_metadata": { "branch": "master", "commit_count": 135, "repo_created_at": "2017-08-19T10:25:17.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "5da34fb5...
560e0aaf-a149-4d9b-b7af-b46d6857ed7f
Nam24-dot/DSA_C-C-
radix_sort.cpp
#include <stdio.h> // Ham lay ra gia tri lon nhat trong mang int getMax(int arr[], int n) { int max = arr[0]; for (int i = 1; i < n; i++) if (arr[i] > max) max = arr[i]; return max; } // Ham sap xep theo chu so cu the void countingSort(int arr[], int n, int exp) { int output[n]; ...
ALGO
0.999973
4.293297
{ "github_metadata": { "branch": "main", "commit_count": 34, "repo_created_at": "2024-08-31T08:19: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": "30ac2fbb942...
e3b81004-2ddc-46b5-a976-d6a66bcaff0e
Zeldacrafter/CompProg-Solutions
Google/Code Jam 2020/Qualification/C.cc
#include <bits/stdc++.h> using namespace std; typedef pair<int, int> ii; typedef vector<int> vi; typedef vector<ii> vii; #define fi first #define se second #define ALL(x) (x).begin(), (x).end() #define endl '\n' #define FOR(a, b, c) for (auto(a) = (b); (a) < (c); ++(a)) #define F0R(a, b) FOR ((a), 0, (b)) void solve(...
ALGO
0.999967
4.280338
{ "github_metadata": { "branch": "master", "commit_count": 581, "repo_created_at": "2019-11-08T15:14:00.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "a0c59b31...
a53d6ca0-e9e8-4a63-b015-7cf308e85659
rachelllxo/internship-problem-solving
Day-2/intersection-of-sets_problem3.cpp
#include <iostream> using namespace std; int main() { int size1, size2; int set1[100], set2[100], intersection[100]; int intersect_size = 0; // Input for Set 1 cout << "Enter number of elements in Set 1: "; cin >> size1; cout << "Enter elements of Set 1:\n"; for (int start_counter = ...
ALGO
0.999712
5.546618
{ "github_metadata": { "branch": "main", "commit_count": 40, "repo_created_at": "2025-06-17T06:33: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": "2999e5ee0e7...
89bcb195-9f26-4fef-abf0-4dbc6b55c3d2
NedicNemanja/TweetOpinionMining
include/utility.hpp
#ifndef UTILITY_HPP #define UTILITY_HPP #include <list> #include <vector> #include <iterator> #include <algorithm> #include <iostream> #include <cmath> #include <numeric> //inner_product #include "myvector.hpp" #include "ErrorCodes.hpp" double ExhaustiveSearch(std::list<myvector> &vlist, myvector &q, double* dist); ...
TOOL
0.926153
4.194927
{ "github_metadata": { "branch": "master", "commit_count": 39, "repo_created_at": "2019-01-11T19:10:32.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "6f2d395a1...
632d9d2f-3f61-41ef-ba66-577cf511f92a
gowin20/CS32
hw2/mazestack.cpp
#include <stack> #include <iostream> using namespace std; const int SOUTH = 1; //useless consts so I don't get confused const int NORTH = -1; const int EAST = 1; const int WEST = -1; class Coord { public: Coord(int rr, int cc) : m_r(rr), m_c(cc) {} int r() const { return m_r; } int c() const { return m_c; } priv...
ALGO
0.999865
4.739165
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2022-01-27T00:10:35.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "c69f9d3057ea...
c9642a8e-1988-40de-a712-796b064d4b32
raincross7/code-similarity
codes/train_code/problem065/problem065_488.cpp
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef long double ld; using Graph = vector<vector<ll>>; using P = pair<int,int>; template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return true; } return false; } template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; ...
ALGO
0.999589
3.214731
{ "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": "c32035f53802...
1287a623-a7c5-440a-a1ab-cba12fee8c79
felikjunvianto/kfile-codeforces-submissions
665D.cpp
#include <cstdio> #include <cstring> #include <algorithm> #include <vector> #include <set> using namespace std; const int LIM = 2000010; int prima[LIM]; int N, satuCnt; set<int> angka; int main() { memset(prima, true, sizeof(prima)); for(int i = 2; i * i <= LIM; i++) if(prima[i]) for(int j = 2; i * j <= LIM; j+...
ALGO
0.999937
3.70731
{ "github_metadata": { "branch": "master", "commit_count": 14, "repo_created_at": "2016-10-06T18:25: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": "c69df4798...
57e90f21-ce29-4a7d-bf1a-3e8a0a56ae72
Sora233/ACM-ICPC
HDU/4400.cpp
#include<map> #include<string> #include<cstring> #include<cstdio> #include<cstdlib> #include<cmath> #include<queue> #include<vector> #include<iostream> #include<algorithm> #include<bitset> #include<climits> #include<list> #include<iomanip> #include<stack> #include<set> #include<ctime> #define pb push_back #define pii p...
ALGO
0.999955
3.504258
{ "github_metadata": { "branch": "ACM-ICPC", "commit_count": 13, "repo_created_at": "2015-11-22T05:20: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": "47b8c36...
bacc36d8-9d2e-4a3a-a777-dbed17aedf08
ThunderMJ2003/DSA
DSA_Striver/A2Z/A2Z_4_2_1.cpp
//{ Driver Code Starts #include <bits/stdc++.h> using namespace std; // } Driver Code Ends class Solution { public: int mySqrt(int x){ int l = 0, h = x; int m; while (l <= h){ m = (l+h)/2; if (((long long)m*m == x) || (((long long)m*m < x) && (((long long)m+1)...
ALGO
0.997451
5.278199
{ "github_metadata": { "branch": "main", "commit_count": 262, "repo_created_at": "2024-08-10T16:48: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": "53e69b553e...
db16c703-cdd1-4846-84e8-5ed0847cd9fd
borglab/gtsam
gtsam/3rdparty/GeographicLib/dotnet/examples/ManagedCPP/example-Geocentric.cpp
using namespace System; using namespace NETGeographicLib; int main(array<System::String ^> ^/*args*/) { try { Geocentric^ earth = gcnew Geocentric( Constants::WGS84::MajorRadius, Constants::WGS84::Flattening); // Alternatively: Geocentric earth = new Ge...
ALGO
0.992177
4.550087
{ "github_metadata": { "branch": "develop", "commit_count": 19360, "repo_created_at": "2017-03-27T17:12:06.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 3002, "forks": 845, "issues": 99, "pull_requests": 25 }, "file_meta": { "content_id": ...
d4c26a1c-3626-468c-a073-074765f20583
tensorflow/tensorflow
third_party/xla/xla/hlo/builder/lib/self_adjoint_eig.cc
/* Copyright 2019 The OpenXLA Authors. 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/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, sof...
ALGO
0.985427
7.091956
{ "github_metadata": { "branch": "master", "commit_count": 182413, "repo_created_at": "2015-11-07T01:19:20.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 190773, "forks": 74758, "issues": 873, "pull_requests": 553 }, "file_meta": { "content...
0bdcbfc4-e55b-4cdc-9c1d-2de059cba009
andrew-yin/competitive-programming
codeforces/1833E.cpp
#include <bits/stdc++.h> using namespace std; #define LL long long void compute(int nc, int i, const vector<unordered_set<int>> &neighbors, vector<bool>& visited, vector<vector<int>>& components) { visited[i] = true; components[nc-1].push_back(i); queue<int> q; q.push(i); while (!q.empty()) { ...
ALGO
0.999756
4.639587
{ "github_metadata": { "branch": "main", "commit_count": 24, "repo_created_at": "2020-08-15T05:19: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": "4ad0e405342...
6272271f-25b6-43c4-ac9a-5c65b56c661d
Wkkkkk/Twitter
Twitter/usergraph_service.cpp
#include <queue> #include "usergraph_service.h" UserGraphService::UserGraphService(LookupService lookup_service) : lookup_service_(lookup_service) { } std::optional<Person> UserGraphService::find_person(int64_t id) { auto person_service = lookup_service_.lookup_person_service(id); return person_service-...
ALGO
0.987397
5.663141
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2020-12-13T14:52: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": "e08518205e...
d697cdf1-1b27-4558-8cfb-c227192c8607
nhdhieuu2/Chuyen_De_De_Quy
Bai_224/Bai_224.cpp
#include <iostream> using namespace std; float TichCot(float[][100], int, int, int); int main() { float a[100][100]; int n, m; cout << "Nhap so hang: "; cin >> n; cout << "Nhap so cot: "; cin >> m; cout << "Nhap cac phan tu cho ma tran: " << endl; for (int i = 0; i < n; i++) { for (int j = 0; j < m; j++) c...
ALGO
0.999971
3.413522
{ "github_metadata": { "branch": "master", "commit_count": 16, "repo_created_at": "2023-04-13T06:26: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": "38ff62d89...
3a60082e-17b1-4594-8b98-1207ecaa6d2c
mahinfah/codeforces_solutions
A. Setting up Camp.cpp
#include<iostream> using namespace std; int main() { int a,b,c; int m ; cin>>m; for(int i = 0 ; i<m ; i++ ) { cin>>a; cin>>b; cin>>c; int sum = b %3; int rum = b/3; int pum = b-(3*rum); // left ones int next = pum +c; int next2 = next%3; in...
ALGO
0.999881
3.278245
{ "github_metadata": { "branch": "main", "commit_count": 154, "repo_created_at": "2023-11-30T19:49:49.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "06f859c6ff...
c37c218e-b228-40b9-9066-9bf1e67b65c9
satyamchaurasia2011/Leet-Codes
61-rotate-list/61-rotate-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 { public: ListNode* rotateRight...
ALGO
0.999935
5.766878
{ "github_metadata": { "branch": "main", "commit_count": 1123, "repo_created_at": "2022-01-17T15:47:02.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "5276b1156...
87ef52b8-a21e-4405-8e71-e58a44482195
gupta-manas6268/learning-C
TLE Eliminators/TLE Eliminators Level-3/Ch-004/0_104_02_Quiz.cpp
// Correct. // This is Mentor's code. // G. Not Very Rude Substring // https://codeforces.com/edu/course/2/lesson/9/3/practice/contest/307094/problem/G #include<bits/stdc++.h> using namespace std; #define endl '\n' #define int long long const int MOD = 1e9 + 7; const int INF = LLO...
ALGO
0.999951
3.72058
{ "github_metadata": { "branch": "main", "commit_count": 569, "repo_created_at": "2023-05-18T17:22:19.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 1 }, "file_meta": { "content_id": "2e00426b72...
fe450ab7-7009-4699-bfad-36eb003caee2
areen-patil/bst-and-graphs
Queue_reconstruction_by_height.cpp
#include <bits/stdc++.h> using namespace std; // class Solution { // public: void update(vector <int>&st,int i,int n){ st[n-1+i]=0; i=n-1+i; while(i>0){ i=(i-1)/2; st[i]=st[2*i+1]+st[2*i+2]; } } int query(vector <int>& st,int k,int n){ int j=0;...
ALGO
0.999994
4.870759
{ "github_metadata": { "branch": "main", "commit_count": 4, "repo_created_at": "2024-03-14T13:18: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": "b95c2f0acef7...
04f1d0d2-5fcb-4560-90b9-f771dd3447cb
cattabiani/googleJam
magicTrick/main.cpp
#include <iostream> #include <vector> using namespace std; vector<int> extLine(int row) { int trash; vector<int> sol(4); for (int i = 0; i<4; ++i) { for (int j = 0; j <4; ++j) { if (row-1 == i) { cin >> sol[j]; } else ...
ALGO
0.999757
4.014575
{ "github_metadata": { "branch": "master", "commit_count": 10, "repo_created_at": "2017-04-18T07:29: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": "e8fe8c84e...
9e9df0fb-e774-41e1-bcd0-84ea7b684829
adnksharp/Robotered
0-control/0-control.ino
#include "pins.h" #include "filter.h" filter ema; int status = 0; short data[6] = {0, 0, 0, 0, 0, 0}; void serialEvent() { if(Serial.available()) { int cmd = Serial.readStringUntil('\n').toInt(); if(cmd == 205 || cmd == 100 || cmd == 423) { Serial3.println(cmd); Serial.println("[MEGA] {" + String(cmd) ...
WEB
0.908588
4.81604
{ "github_metadata": { "branch": "single", "commit_count": 10, "repo_created_at": "2024-04-03T21:09:00.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "cc588a41a...
bb679899-d61a-4707-84b7-22337c34d693
Badger-RL/BadgerRLSystemCodeRelease2023
Src/Modules/Perception/FieldPerceptors/PenaltyMarkClassifier.cpp
/** * @file PenaltyMarkClassifier.cpp * * This file implements a module that detects penalty marks in images with a neural network. * * @author <NAME> * @author <NAME> * @author <NAME> */ #include "PenaltyMarkClassifier.h" #include "Platform/File.h" #include "Tools/Math/InImageSizeCalculations.h" #include "Deb...
ALGO
0.936154
7.356518
{ "github_metadata": { "branch": "main", "commit_count": 260, "repo_created_at": "2023-10-11T06:15:07.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 5, "forks": 2, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "950ce282f5d...
6b5c928b-3f88-4dda-9971-5fa5eb0779a1
maverickreal/leetcode-solutions
650-2-keys-keyboard/650-2-keys-keyboard.cpp
class Solution { typedef long long ll; typedef pair<ll, ll> pi; #define vi(x) vector<x> #define pb push_back const ll mod = 1e9 + 7; const char nl = '\n'; public: ll n; vi(vi(ll))dp; ll func(ll cur, ll copy) { if (cur > n) { return LLONG_MAX; } if (cur == ...
ALGO
0.999986
4.380053
{ "github_metadata": { "branch": "main", "commit_count": 2587, "repo_created_at": "2021-04-04T13:55:22.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 1, "pull_requests": 0 }, "file_meta": { "content_id": "bd9655536...
5f99a8ff-c07f-4f1e-b1fc-14248893f31d
Neilketchum/Compedetive-Programing
Recursion/Excercise/classAssignment.cpp
// In a mathematics class, Teacher ask Alice to find the number of all n digit distinct integers which is formed by the two distinct digits ai and bi but there is a rule to form n digit integer. // Rule: She has to form n digit integer by using two digits ai and bi without consecutive bi. // Alice is very weak in mat...
ALGO
0.999604
3.888782
{ "github_metadata": { "branch": "master", "commit_count": 26, "repo_created_at": "2020-06-05T07:03:29.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "fc8a6bb05...
2a5921ce-969f-4a87-8ced-f0d1f604e465
fyrsta7/LLM_on_ASAC
result_api_backup/en_without_annotation_mzn/deepseek-coder_loop10/Magic_Circle-4.cpp
#include <iostream> #include <vector> #include <algorithm> using namespace std; int main() { int n, m; cin >> n >> m; vector<int> X(m); for (int i = 0; i < m; ++i) { cin >> X[i]; } vector<vector<int>> ans(m, vector<int>(4, 0)); int max_num = m * (m - 1) * (m - 2) * (m - 3) / 24; ...
ALGO
0.999937
3.786803
{ "github_metadata": { "branch": "main", "commit_count": 42, "repo_created_at": "2024-08-11T08:13:46.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "59b3b7813e3...
553150aa-b7df-4063-b00b-d80129147023
quantheory/Project-Euler
src/base/prime.h
#ifndef PRIME_H #define PRIME_H #include <vector> inline bool divisible(const long long &i, const long long &div) { return !(i%div); } class Prime; class PrimeIter; bool operator==(const PrimeIter &lhs, const PrimeIter &rhs); bool operator!=(const PrimeIter &lhs, const PrimeIter &rhs); class PrimeIter : publi...
ALGO
0.967045
4.685289
{ "github_metadata": { "branch": "master", "commit_count": 11, "repo_created_at": "2012-10-03T03:33: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": "8a0841e27...
24e3569f-7dbb-4c2e-b142-98cd132596bb
haru210/atcoder
ABC333/E.cpp
#include <bits/stdc++.h> using namespace std; using ll = long long; using pint = pair<int,int>; using pll = pair<long long, long long>; #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define rep2(i,n) for (int i = 1; i <= (int)(n); i++) #define YesNo(bool) if(bool) cout << "Yes" << endl; else cout << "No" << end...
ALGO
0.999725
3.560675
{ "github_metadata": { "branch": "master", "commit_count": 439, "repo_created_at": "2023-05-18T08:20:41.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "d4151352...
82be3bcf-920a-4170-a6af-c933d291a332
aregularguy/code_dsa
Binary Trees/Level Order Traversal.cpp
// Online C++ compiler to run C++ program online #include <bits/stdc++.h> using namespace std; class Tree { public: int data; Tree * left , *right; Tree(int d) { this->data = d; this->left = nullptr; this->right = nullptr; } }; vector<vector<int>> ans; void levelorder(...
ALGO
0.999969
5.25598
{ "github_metadata": { "branch": "main", "commit_count": 38, "repo_created_at": "2022-07-16T18:31:00.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "9b5bc7c3ca9...
65e40842-ab0c-4d11-a1b9-445b2de95cdf
ajxu2/competitive-programming
Codeforces/1801C.cpp
// created: 07-13-2023 Thu 10:40 AM #include <bits/stdc++.h> using namespace std; using ll = long long; template<class T> using V = vector<T>; template<class T> int sz(const T& a) { return (int)a.size(); } void solve() { int n; cin >> n; V<V<int>> a(n); for (int i = 0; i < n; i++) { int k; cin >>...
ALGO
0.999821
4.735921
{ "github_metadata": { "branch": "main", "commit_count": 458, "repo_created_at": "2020-10-29T19:25:51.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "7ee1b21a06...
68f7dde2-cb8a-4771-b8ca-1e63237ba0cd
kartikeyagup/BTP
experimental/statistics-analysis/src/triangulate.cc
#include "triangulate.h" std::vector<std::vector<cv::Point2f> > detect(cv::Mat &image) { std::vector<std::vector<cv::Point2f> > answer; for (int i = 0; i < 5; i++) { std::vector<cv::Point2f> temp; for (int j = 0; j < 5; j++) { temp.push_back(cv::Point2f(0, 0)); } answer.push_back(temp); } ...
ALGO
0.998136
5.753919
{ "github_metadata": { "branch": "master", "commit_count": 162, "repo_created_at": "2016-08-09T16:07:51.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "bc4459c5...
87966219-a4e8-4f48-8b2d-a89c69165111
ZTL-UwU/OI
blog/SP/test.cc
#include <iostream> #include <cstdio> #include <cstdlib> #include <cmath> #include <cstring> #include <algorithm> #include <queue> #define in(a) a = read() #define REP(i, k, n) for (long long i = k; i <= n; i++) #define MAXN 100010 using namespace std; typedef pair<long long, long long> P; inline long long read() { ...
ALGO
0.999861
3.199913
{ "github_metadata": { "branch": "main", "commit_count": 562, "repo_created_at": "2020-07-18T02:10: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": "0ea75e5a0b...
50aa2f47-ade2-4d52-9a6c-7ab650148ed8
stqp/algorithm
other/problem100/020_binarysearch.cpp
#include <iostream> #include <cmath> #include <algorithm> #include <ctime> #include <functional> #include <vector> #include <stack> #include <queue> #include <map> #include <set> #include <string> #include <tuple> #include <cassert> #include <bitset> using namespace std; #define rep(i, l, r) for(int i = l; i < (int)(r)...
ALGO
0.999965
4.335789
{ "github_metadata": { "branch": "master", "commit_count": 58, "repo_created_at": "2018-07-18T15:26: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": "ed2fd3552...
96039664-6936-46f6-94da-b01c74926456
MrArthor/Console-Based-Cpp-Programs
Lab-Assignments/Data-Structure-Lab/DS/Data Structures/trial.cpp
#include <iostream> #define Max 50 using namespace std; template <class T> class Deque { private: int Front, End, Count, Size; T Data[Max]; public: Deque(int size) { Front = End = -1; Count = 0; Size = size; } bool IsFull(); bool IsEmpty(); void insert_at_beg(T d...
ALGO
0.969974
3.891015
{ "github_metadata": { "branch": "main", "commit_count": 85, "repo_created_at": "2021-01-15T17:58:59.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 5, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "153251616da...
1d7f4d41-ee35-46e4-bb07-afe3bfb28c61
younghoonyou/Algorithm
11559.cpp
//https://www.acmicpc.net/problem/11559 #include <iostream> #include <algorithm> #include <string> #include <queue> #include <vector> using namespace std; char arr[12][6]; bool v[12][6]; const int dx[]={1,0,-1,0}; const int dy[]={0,1,0,-1}; queue<pair<int,int> > color; vector<pair<int,int> > make_blank; int answer = 0;...
ALGO
0.999658
4.154265
{ "github_metadata": { "branch": "main", "commit_count": 244, "repo_created_at": "2021-10-03T06:46: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": "e81f177fe2...
92876668-14e6-4cb3-9639-41474a3ce1dc
LavishGulati/InterviewBit
Linked Lists/ReverseLinkListII.cpp
/** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode(int x) : val(x), next(NULL) {} * }; */ void ReverseLL(ListNode *sp, ListNode **ep){ if(sp == (*ep)) return; ReverseLL(sp->next, ep); (*ep)->next = sp; (*ep) = sp; } ListNod...
ALGO
0.999992
5.527811
{ "github_metadata": { "branch": "master", "commit_count": 17, "repo_created_at": "2019-05-22T16:31:18.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 6, "forks": 2, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "02ff5b568...
1fe380ce-bab0-4f0b-927d-4f9acd2c97ea
MingYanWoo/Leetcode
剑指 Offer 32 - I. 从上到下打印二叉树.cpp
// 剑指 Offer 32 - I. 从上到下打印二叉树 // 从上到下打印出二叉树的每个节点,同一层的节点按照从左到右的顺序打印。 // 例如: // 给定二叉树: [3,9,20,null,null,15,7], // 3 // / \ // 9 20 // / \ // 15 7 // 返回: // [3,9,20,15,7] // 提示: // 节点总数 <= 1000 /** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode...
ALGO
0.999887
5.731633
{ "github_metadata": { "branch": "master", "commit_count": 425, "repo_created_at": "2018-03-14T05:18: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": "891b1f30...
787e13af-2ca9-456f-a05d-aab491a30085
cross034/blatant-problems
8puzzle-Astar/Main.cpp
#include<iostream> #include<vector> #include<list> #include"PuzzleState.h" bool existsInList(std::list<PuzzleState*> stateList, const PuzzleState* state) { for (std::list<PuzzleState*>::iterator it = stateList.begin(); it != stateList.end(); it++) { if (**it == *state) return true; } return false; } std::lis...
ALGO
0.999865
4.298932
{ "github_metadata": { "branch": "master", "commit_count": 7, "repo_created_at": "2020-07-14T12:06:38.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "2355eb4f88...
ef0aa74a-ed13-457c-b909-eeb0a79430d5
zehuichen123/leetcode_solution
leetcode/confusion_number.cpp
// 1. Confusing Number // Given a number N, return true if and only if it is a confusing number, which satisfies the following condition: // We can rotate digits by 180 degrees to form new digits. When 0, 1, 6, 8, 9 are rotated 180 degrees, they become 0, 1, 9, 8, 6 respectively. When 2, 3, 4, 5 and 7 are rotated 180 ...
ALGO
0.999837
5.399566
{ "github_metadata": { "branch": "master", "commit_count": 23, "repo_created_at": "2019-04-20T05:14: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": "81142551b...
3210dca8-8cf2-487e-9b9f-24aa51367284
timothyhollabaugh/notes
Completed/Datastructures/Projects/linked_list/node.h
#ifndef NODE_H #define NODE_H #include <cstdlib> namespace linked_list { class node { public: typedef double value_type; node(const value_type& init_data = value_type(), node* init_link = NULL) { data_field = init_data; link_field = init_link; ...
TOOL
0.948269
4.918818
{ "github_metadata": { "branch": "master", "commit_count": 107, "repo_created_at": "2017-11-10T01:25:55.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b1f1410f...
dbdc68be-d690-4c52-a1eb-3c55c4757bf0
rishitoshsingh/Tic-Tac-Toe-MinMax-vs-Data-
ANALYS~1.CPP
#include<fstream.h> #include<iostream.h> #include<conio.h> void main() { int mv[10]; int i,cnt=0,tot=0,ws=0; clrscr(); ifstream a("0.txt"); while(!a.eof()) { for(i=0;i<10;i++) a>>mv[i]; for(i=0;i<9;i++) { if(mv[i]==-1) cnt++; } if(cnt==4) { tot...
ALGO
0.987167
3.009386
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2018-04-04T18:33:24.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ee95d79152...
359030e8-2b92-4030-bbc6-ef005205d02a
Observer46/MOWNiT
lab4/main.cpp
#include <iostream> #include <cmath> #include <vector> #include <fstream> #include <string> #include "newton.h" #include "lagrange.h" #include "hermite.h" constexpr double PI = 3.141592653589; // Druga funkcja przykladowa z parametrami domyslnymi: k = 3, m = 4 double f(const double& x, const double& k = 3.0, const d...
ALGO
0.999865
5.049181
{ "github_metadata": { "branch": "master", "commit_count": 19, "repo_created_at": "2020-03-23T14:19: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": "8889bb0a4...
b808631e-5ef7-4929-92e0-db85d0988e17
euxhenh/CSES-Solutions
Sorting_and_Searching/josephusproblem1.cpp
#include <bits/stdc++.h> #define ll long long using namespace std; struct child { ll id; child *next, *prev; }; int main() { int n; ll id; child children[200200]; cin >> n; children[0].next = &children[1]; children[0].prev = &children[n - 1]; children[0].id = 0; children[n - ...
ALGO
0.999982
3.78197
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2021-04-13T14:36:00.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "772b317951...
1f44bebd-ab61-4ea3-a7be-a0ca611e1ca2
Zeronfinity/LightOJ-Solutions
1213 - fantasy of summation.cpp
//(a+b)%c*k%c*(n^(k-1)))%c #include <bits/stdc++.h> using namespace std; long long pwr(long long b, long long p, long long m) { if (p == 0) return 1; long long x = pwr(b, p/2, m); if (p%2 == 0) return ((x%m)*(x%m))%m; else return (((x%m)*(x%m))%m*(b%m))%m; } int main () { long lon...
ALGO
0.999749
4.023799
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2017-12-04T08:03:02.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 2, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "73206f5f20...
3f443f35-1b21-4c6b-b847-f9553d4b18e0
zhanglei1949/Leetcode-solutions
13-Roman to Integer/13-Roman to Integer.cpp
#include<iostream> using namespace std; int toInt(char ch) { switch(ch){ case 'I': return 1; case 'V': return 5; case 'X': return 10; case 'L': return 50; case 'C': return 100; case 'D': return 500; case 'M': return 1000; } return 0; } int romanToInt...
ALGO
0.999921
4.399031
{ "github_metadata": { "branch": "master", "commit_count": 4, "repo_created_at": "2017-01-09T09:22:01.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "7a1d21e943...
020b659b-d9e1-4696-8970-eeb8f940e9e4
PaddlePaddle/Paddle
paddle/phi/kernels/funcs/jit/gen/seqpool.h
/* Copyright (c) 2023 PaddlePaddle Authors. All Rights Reserved. * * 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/licenses/LICENSE-2.0 * * Unless required by ...
TOOL
0.983135
6.875769
{ "github_metadata": { "branch": "develop", "commit_count": 54743, "repo_created_at": "2016-08-15T06:59:08.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 23037, "forks": 5770, "issues": 1009, "pull_requests": 823 }, "file_meta": { "content_...
141a8dc9-007f-45cb-812f-f357cf9ad61e
Omer283/CPSubmissions
Codeforces/Educational Codeforces Round 82 (Rated for Div. 2) - (E) Erase Subsequences.cpp
#define _CRT_SECURE_NO_WARNINGS #define fast ios::sync_with_stdio(false); cin.tie(0) #define foru(i, k, n) for (int i = k; i < n; i++) #define ford(i, k, n) for (int i = k; i >= n; i--) #define pb push_back #define mp make_pair #include <iostream> #include <vector> #include <algorithm> #include <string> #include <bits...
ALGO
0.999997
4.208644
{ "github_metadata": { "branch": "main", "commit_count": 10, "repo_created_at": "2022-05-07T13:13: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": "add78a16a67...
474a2b77-ec85-4f8c-a840-ea240e6596ce
arnxxau/PRO1
P6 - Recursion/P22467.cpp
// P22467 Perfect primes // Created by arnxxau on 25/11/21. // #include <iostream> using namespace std; bool is_prime(int n, int d) { // base cases if (n < 2) return false; else if (n%d == 0 and n != d) return false; else if (d*d > n) return true; // general case return is_prime(n, ++d); } i...
ALGO
0.995775
4.325822
{ "github_metadata": { "branch": "master", "commit_count": 62, "repo_created_at": "2021-09-13T15:42: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": "2e5627d35...
f4e0fb91-c317-4693-bcbe-32d0860f54b4
mahirshahriar1/Competitive_Programming
OJ_Submissions/UVa/C++/10419 - Sum-up the Primes.cpp
#include <bits/stdc++.h> using namespace std; const int MAXN = 300; vector<bool> isprime; vector<int> prime; void sieve() { isprime.assign(MAXN + 1, true); isprime[0] = isprime[1] = false; for (int i = 2; i * i <= MAXN; i++) { if (!isprime[i]) continue; for (int j = i * i; j <= MAXN; j +=...
ALGO
0.999976
4.337155
{ "github_metadata": { "branch": "main", "commit_count": 21, "repo_created_at": "2023-07-30T19:17:08.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "37d05e72de2...
66913ec6-2cab-41d8-9270-ff16a3eab144
rndudals/Algorithm_PS
프로그래머스/3/42861. 섬 연결하기/섬 연결하기.cpp
#include <string> #include <vector> #include <algorithm> #include <iostream> using namespace std; class A{ public: int cost; int x; int y; }; int parent[100]; vector<A> v; void init(int n){ for(int i=1;i<=n;i++){ parent[i] = i; } } bool compare(A a, A b){ return a.cost<b.cost; } i...
ALGO
0.999895
4.613982
{ "github_metadata": { "branch": "main", "commit_count": 415, "repo_created_at": "2023-12-29T06:20: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": "f1bfaddd84...
7552bec2-64cb-4c53-81eb-057f6c3acd52
zhedahht/CodingInterviewChinese2
29_PrintMatrix/PrintMatrix.cpp
/******************************************************************* Copyright(c) 2016, <NAME> All rights reserved. Distributed under the BSD license. (See accompanying file LICENSE.txt at https://github.com/zhedahht/CodingInterviewChinese2/blob/master/LICENSE.txt) *****************************************************...
ALGO
0.999731
5.1103
{ "github_metadata": { "branch": "master", "commit_count": 100, "repo_created_at": "2016-11-21T05:04:57.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 5377, "forks": 2163, "issues": 60, "pull_requests": 9 }, "file_meta": { "content_id": "2...
e14032c1-cdf7-4fd9-9d9b-0ef6e32bd404
cpsurfer/usaco-problems
cow_prefix.cpp
#include <bits/stdc++.h> using namespace std; int count(vector<int> v, int x, int y) { int n = v.size(); int c1, c2, c3; c1 = c2 = c3 = 0; for (int i = x - 1; i < y; i++) { if (v[i] == 1) c1++; else if (v[i] == 2) c2++; else c3++; } cout << c1 << " " << c2 << " " << c3 << en...
ALGO
0.999815
4.120294
{ "github_metadata": { "branch": "main", "commit_count": 5, "repo_created_at": "2025-04-06T18:04: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": "8ec80db2dc46...
843769cd-7ada-44c3-b47d-121b0b46c891
rj992/Hello-world
swap.cpp
#include<iostream> using namespace std; class Swap { public: void swap_value(int a,int b) { int temp; temp=a; a=b; b=temp; cout<<"\nAfter swapping:value of a="<<a<<"\nvalue of b="<<b; } void swap_reference(int &x,int &y) { int z; z=x; x=y; y=z; cout<<"\nAfter swapping:value of a="<<x<<"\nvalue of ...
ALGO
0.998965
4.6671
{ "github_metadata": { "branch": "master", "commit_count": 3, "repo_created_at": "2019-02-22T10:35: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": "99d99b627d...
fbe93765-3782-4f82-8866-fc0a2ffcadf0
facebook/hhvm
third-party/tbb/src/examples/parallel_for/tachyon/src/box.cpp
/* Copyright (c) 2005-2018 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/licenses/LICENSE-2.0 Unless required by applicable la...
ALGO
0.964116
5.621361
{ "github_metadata": { "branch": "master", "commit_count": 77511, "repo_created_at": "2010-01-02T01:17:06.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 18449, "forks": 3043, "issues": 407, "pull_requests": 93 }, "file_meta": { "content_id"...
ef7b4698-65b0-479a-a8e3-05265e94aab7
ioii-Chianti/IP-II
HW_03/Matrix/function.cpp
#include <iostream> #include <string> #include "function.h" using namespace std; // 參數預設值只需在宣告時寫出,但定義有註解較佳 Matrix::Matrix(int s /* = 5*/) { size = s; matrix = new int *[size]; for (int i = 0; i < size; i++) matrix[i] = new int[size]; buf = new int[size * size]; } // Copy constructor Matrix::Ma...
TOOL
0.975029
4.1224
{ "github_metadata": { "branch": "main", "commit_count": 20, "repo_created_at": "2021-04-17T23:39: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": "adaaebff320...
2ec9cec8-32b3-4da4-8144-abc19828e575
nishitkshah/My-Codeforces-Submissions
Page-022-sol/004-sol/936B_1_d4.cpp
//01:13 26-04-2019 to 01:23 26-04-2019 and 23:20 31-05-2019 to 23:34 31-05-2019 //08:10 02-06-2019 //08:37 02-06-2019 //08:40 02-06-2019 //08:43 02-06-2019 //08:48 02-06-2019 #include<iostream> #include<vector> #include<algorithm> using namespace std; #define RE(a, b, c) for(int a=(b); a<(c); a++) #define N_ (100 * ...
ALGO
0.999993
3.473403
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2019-08-05T01:51: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": "663d841b40...
ec65d937-e19a-4bd4-9dba-7eeba1f56036
williamblair/advent_of_code_2020
day15/day15part2.cpp
/* * Day 15 - rambunctious recitation */ #include <stdio.h> #include <stdlib.h> #include <string.h> #include <stdint.h> #include <vector> #include <algorithm> #include <map> #if 1 #define INPUT_LEN 6 int64_t input[6] = { 18,11,9,0,5,1 }; #endif #if 0 #define INPUT_LEN 3 int64_t input[3] = { 0,3,6 }; #endif cla...
ALGO
0.999926
4.747183
{ "github_metadata": { "branch": "master", "commit_count": 38, "repo_created_at": "2020-12-02T23:51:37.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "6df96e93a...
ba24e38e-a77f-4a67-bbd3-b14c38c51262
TangZichen0102/cpp_study
吴江青少年科技馆/2022暑假预科班/7/3.cpp
#include <bits/stdc++.h> using namespace std; const int MAXN = 1e5 + 5; struct POANT { int address, data, next; } nodes[MAXN]; int main() { #ifndef ONLINE_JUDGE freopen("3.in", "r", stdin); #endif int h, n, k; cin >> h >> n >> k; for (int i = 0; i < n; i++) { int add, dat, nex; cin ...
ALGO
0.999899
3.505189
{ "github_metadata": { "branch": "main", "commit_count": 436, "repo_created_at": "2022-04-25T08:10:16.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ca18797a01...
7a3f7c1f-5f67-49b5-9847-248fced47843
listenviolet/Lab
acm_code/11-3-2-zengguanglusuanfa-copy.cpp
#include <iostream> #include <cstring> #include <queue> using namespace std; #define maxn 1000 #define INF 0x3F3F3F3F int cap[maxn][maxn], flow[maxn][maxn]; int a[maxn]; int p[maxn]; queue<int> q; int f; int n, m, s, t; void Init() { memset(cap, 0, sizeof(cap)); memset(flow, 0, sizeof(flow)); cout << "...
ALGO
0.999933
3.947777
{ "github_metadata": { "branch": "master", "commit_count": 330, "repo_created_at": "2018-02-07T08:33:49.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b51a85a6...
55f1c22a-9c04-4c7b-a0d2-dd88eab795bb
benoitsteiner/tensorflow-opencl
tensorflow/compiler/xla/service/hlo_cse.cc
/* Copyright 2017 The TensorFlow Authors. All Rights Reserved. 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/licenses/LICENSE-2.0 Unless required by applicable law or a...
ALGO
0.989967
7.73345
{ "github_metadata": { "branch": "master", "commit_count": 23639, "repo_created_at": "2016-06-03T17:03:42.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 477, "forks": 85, "issues": 27, "pull_requests": 6 }, "file_meta": { "content_id": "23...
b925bbe2-4127-4ec1-8dab-5aa4efd7b61e
silvercobraa/competitive-programming
6. String Processing/String Hashing/String Hashing/12604.cpp
#include <iostream> #include <string> #include <vector> #include <unordered_map> using namespace std; string A; unordered_map<char, int> m; void encode(string& source, string& target, int shift) { for (int i = 0; i < source.size(); i++) { target[i] = A[(m[source[i]] + shift) % A.size()]; } } int search(string& ...
ALGO
0.999933
4.252486
{ "github_metadata": { "branch": "master", "commit_count": 322, "repo_created_at": "2018-08-05T00:13: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": "01a1f779...
5961c736-a8a1-439d-a307-557e6cdb9a69
Moneemabdullah/problem_solving_journey
Codeforces Round 975 (Div. 2)/B_All_Pairs_Segments.cpp
/* #### ### # # ##### ##### #### ##### ##### # # # # # # # # # # # ### ##### # # #### AND #### #### #### #### # # # # # # # # # # # #### # # # ##### # # # ##### ##### ...
ALGO
0.999933
4.705742
{ "github_metadata": { "branch": "main", "commit_count": 8, "repo_created_at": "2024-09-21T10:07:17.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "e861acc6819b...
a0a93fb4-8478-48b3-8e2a-5100704c2b51
LosDelDGIIM/LosDelDGIIM.github.io
subjects/SCD/Prácticas/Práctica2/Exámenes/Examen1Ej2.cpp
/** * @file Examen1_Ej2.cpp * @author <NAME> * * @details La descripción, junto con el enunciado, se encuentran en ./ExamenI.md * * https://github.com/LosDelDGIIM/LosDelDGIIM.github.io/blob/main/subjects/SCD/Prácticas/Práctica2/Exámenes/ExamenI.md) */ #include <iostream> #include <cassert> #include <thread>...
TEST
0.918965
5.018722
{ "github_metadata": { "branch": "main", "commit_count": 2333, "repo_created_at": "2023-08-20T22:55:56.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 16, "forks": 6, "issues": 0, "pull_requests": 1 }, "file_meta": { "content_id": "6d4f68162...
7a72152b-fef7-4a89-ac7f-52032115851f
Ahmedkhalid404/codeforces-Solutions
CodeForces/GNU C++20 (64)/1822A | TubeTube Feed/203367933.cpp
#include <bits/stdc++.h> using namespace std; #define ln '\n' typedef long long ll; auto There_are_10_types_of_people_in_the_world_those_who_understand_binary_and_those_who_do_not /* :) */() { ll size , time ; cin >> size >> time; ll t[ size ] , fun[ size ]; for (int...
ALGO
0.999942
4.016533
{ "github_metadata": { "branch": "main", "commit_count": 1024, "repo_created_at": "2023-07-09T21:17: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": "deaebf8fb...