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
89f6cf7e-109d-4a41-922c-3556950c78c5
ShiJiJS/KinectFusionImpl
include/step/PoseEstimator.h
#include "../DataTypes.h" #include "../Configuration.h" #include <Eigen/Eigen> #include "../Matrix.h" using config::CameraParameters; using config::GlobalConfiguration; using Matf31da = Eigen::Matrix<float, 3, 1, Eigen::DontAlign>; namespace step { class PoseEstimator{ public: PoseEstimator(Camera...
ALGO
0.998484
3.923354
{ "github_metadata": { "branch": "main", "commit_count": 27, "repo_created_at": "2023-05-01T11:26:23.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "cec55415089...
4bbf21b6-584c-40ee-9424-6424d2b361b3
ziogenorwekh/BackJoon
백준/Gold/1456. 거의 소수/거의 소수.cc
#include <iostream> #include <cmath> #include <vector> #include <unordered_set> using namespace std; vector<bool> prime; unordered_set<long long> seen; int main(int argc, char const *argv[]) { ios_base ::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); long long N, M; cin >> N >> M; int ...
ALGO
0.999989
4.979896
{ "github_metadata": { "branch": "main", "commit_count": 85, "repo_created_at": "2025-03-23T06:12: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": "bdc2b25969c...
10c82ce2-9ebe-4596-a2b8-fec93b875347
AdityaGupta03/FileCompression
src/FileCompression.cpp
#include <cstddef> #include <functional> #include <queue> #include <string> #include <cstdlib> #include <iostream> #include <fstream> #include <sstream> #include <unordered_map> #include <utility> #include <vector> #include <cassert> #include "./FileCompression.h" FileCompression::FileCompression(std::string file_nam...
ALGO
0.995349
5.534688
{ "github_metadata": { "branch": "main", "commit_count": 17, "repo_created_at": "2023-07-17T17:59: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": "b0777766133...
02812ea8-98a1-4a9b-851b-3d36f7713059
MansiSMore/Leetcode_Solutions
2586_Count_the_Number_of_Vowel_Strings_in_Range.cpp
/* You are given a 0-indexed array of string words and two integers left and right. A string is called a vowel string if it starts with a vowel character and ends with a vowel character where vowel characters are 'a', 'e', 'i', 'o', and 'u'. Return the number of vowel strings words[i] where i belongs to the inclusive r...
ALGO
0.999852
6.765518
{ "github_metadata": { "branch": "master", "commit_count": 410, "repo_created_at": "2020-08-04T16:29:10.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 4, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "7a6f8f30...
f419c2d3-881c-438b-8985-66443c8ab5a9
ktchow1/alg
alg/04_fundalmental/include/std_alg.h
#pragma once #include<iostream> #include<algorithm> #include<functional> #include<optional> #include<numeric> // std::accumulate is not in <algorithm>, but in <numeric> #include<ranges> // ******************************************* // // *** Naive implementation of std::reduce *** // // *****************************...
ALGO
0.998752
5.999368
{ "github_metadata": { "branch": "master", "commit_count": 172, "repo_created_at": "2025-03-07T12:25:09.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ab60da95...
3ee622aa-2f4b-4990-b65d-57380e74d2db
Kennyarlexy/Competitive-Programming
CONTEST/CODEFORCES/EduRound_128/B.cpp
#include <bits/stdc++.h> using namespace std; typedef long long ll; void fast_io() { ios_base::sync_with_stdio(0); cin.tie(0); } int main() { fast_io(); int T; cin >> T; for (int t = 0; t < T; t++) { int n, m; cin >> n >> m; int firstR = -1; int otherR = INT_MAX; f...
ALGO
0.999843
4.282992
{ "github_metadata": { "branch": "main", "commit_count": 13, "repo_created_at": "2024-08-12T09:13: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": "894579449a5...
1a907ce1-26b7-41aa-8e4c-5a3d86f6a128
tensorflow/tensorflow
third_party/xla/xla/online_topsort.h
/* Copyright 2025 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.999892
7.777478
{ "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...
734080be-af55-42b5-a116-d294cce01fdb
shuoxuanli/USACO
Gold/2021-2022/Jan/drought.cpp
#include <bits/stdc++.h> using namespace std; #define ll long long #define sz(x) (int)(x.size()) const int MOD = 1E9 + 7; int n, a[105], dp[105][1001]; int main() { cin >> n; for (int i = 1; i <= n; i++) { cin >> a[i]; } int mn = *min_element(a + 1, a + n + 1); if (n % 2 == 0) mn = 0; int ans = 0; ...
ALGO
0.999995
4.299838
{ "github_metadata": { "branch": "main", "commit_count": 681, "repo_created_at": "2022-04-14T14:59: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": "1a79be875f...
a216feed-31c4-436a-9142-680e9770810b
kartikeyasm/DSA
DP/minSumPath.cpp
//https://www.naukri.com/code360/problems/minimum-path-sum_985349?utm_source=striver&utm_medium=website&utm_campaign=a_zcoursetuf&leftPanelTabValue=SUBMISSION //Top Down /* #include <bits/stdc++.h> int solve(int i, int j, vector<vector<int>> &grid, vector<vector<int>> &dp){ if(i==0 && j==0){ return grid...
ALGO
0.999964
5.977253
{ "github_metadata": { "branch": "main", "commit_count": 8, "repo_created_at": "2024-06-15T22:46: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": "9d34d1122166...
9191d418-1298-4504-a1d0-9961458e8bd1
Kinvert/CUDA-Stuff
ChatGPT-CUDA_Lessons/060-Matrix-Operations/061-Matrix-Addition/061a-matrix-addition.cpp
#include <iostream> #include <vector> // Matrix type typedef std::vector<std::vector<float>> Matrix; // Matrix addition function Matrix matrixAdd(const Matrix &A, const Matrix &B) { // Check that the matrices have the same size if (A.size() != B.size() || A[0].size() != B[0].size()) { std::cout << "Er...
ALGO
0.997113
6.26821
{ "github_metadata": { "branch": "master", "commit_count": 90, "repo_created_at": "2022-12-28T07:11:13.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 0, "issues": 12, "pull_requests": 0 }, "file_meta": { "content_id": "6be68c36...
67e98ab2-f6a3-44ba-aaa9-96d6e57a00cb
moodboom/Reusable
c++/prtree/include/ami_kdtree.H
// Copyright (C) 2001 <NAME> // // File: ami_kdtree.H // Author: <NAME> <<EMAIL>> // // Blocked kd-tree definition and implementation. // // $Id: ami_kdtree.H,v 1.1 2008/07/28 17:08:01 m Exp $ // #ifndef _AMI_KDTREE_H #define _AMI_KDTREE_H // For strcpy(), strcat(). #include <strings.h> // Get definitions for wor...
ALGO
0.990341
3.239275
{ "github_metadata": { "branch": "master", "commit_count": 360, "repo_created_at": "2016-01-23T19:23:01.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 4, "forks": 3, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "102cb910...
ab3dae20-488c-4e3d-a70b-64b04f68a048
abhishek18124/PPCPPApr2024
Lecture 11/002Arrays_GenerateSubArrays.cpp
#include<iostream> using namespace std; // time : O(n^3) void generateSubarrays(int arr[], int n) { // iterate over the starting indices of subarrays for (int i = 0; i <= n - 1; i++) { // for given i, iterate over all the possible ending indices for (int j = i; j <= n - 1; j++) { // generate the subarr...
ALGO
0.99739
5.268064
{ "github_metadata": { "branch": "main", "commit_count": 44, "repo_created_at": "2024-04-18T20:23:01.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "4ec17701312...
fc3535e2-9f94-4a76-b6ea-4f885e9ed0a2
GPlates/GPlates
src/opengl/GLProjectionUtils.cc
/* $Id$ */ /** * \file * $Revision$ * $Date$ * * Copyright (C) 2010 The University of Sydney, Australia * * This file is part of GPlates. * * GPlates is free software; you can redistribute it and/or modify it under * the terms of the GNU General Public License, version 2, as published by * the Free Softw...
TOOL
0.974842
6.704748
{ "github_metadata": { "branch": "gplates", "commit_count": 4420, "repo_created_at": "2023-08-01T02:33:43.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 126, "forks": 4, "issues": 3, "pull_requests": 0 }, "file_meta": { "content_id": "71b79...
56483802-a38f-47e4-a7c0-d1b98d3d4e6d
vikram-codes-hub/dsa
heaps/insertion.cpp
#include <bits/stdc++.h> using namespace std; class heap{ public: int arr[100]; int size; heap(){ arr[0]=-1; size=0; } void insert(int val){ size=size+1; int index=size; arr[index]=val; while(index>1){ int parent=index/2; ...
ALGO
0.999594
3.963951
{ "github_metadata": { "branch": "main", "commit_count": 13, "repo_created_at": "2024-11-30T12:50:23.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "2b5caed3f7b...
283686f1-541f-4956-8a93-f21302822b63
amit2601rai/competitive-programming
codechef/January Challenge 2015/GCDQ.cpp
/*<NAME>(II<NAME>)*/ #include <bits/stdc++.h> using namespace std; typedef long long LL; typedef long double LD; typedef unsigned long long ULL; typedef pair<int, int> ii; typedef vector<int> vi; typedef vector<ii> vii; typedef map<string, int> msi; typedef map<int, int> mi; typedef set<int> si; typedef priority_que...
ALGO
0.999844
3.740533
{ "github_metadata": { "branch": "main", "commit_count": 11, "repo_created_at": "2021-07-31T10:31: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": "110ac9b0cb1...
0c62a41c-6862-4032-abc5-5058fe492f72
ci2cv/face-analysis-sdk
src/tracker/ATM.hpp
// CSIRO has filed various patents which cover the Software. // CSIRO grants to you a license to any patents granted for inventions // implemented by the Software for academic, research and non-commercial // use only. // CSIRO hereby reserves all rights to its inventions implemented by the // Software and any patent...
ALGO
0.994527
4.973666
{ "github_metadata": { "branch": "master", "commit_count": 23, "repo_created_at": "2013-04-19T05:56:17.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 418, "forks": 208, "issues": 8, "pull_requests": 5 }, "file_meta": { "content_id": "bef3ee...
8191b3cc-d655-48da-9362-2fdbb47b74e7
Rakibul-Hassan-1/Phitron-Modules
Semester - 02 Introduction to Algorithms/Basic Data Structure/Week - 05 Binary Tree/Module - 20 Assignment/insert_in_bst.cpp
#include <bits/stdc++.h> using namespace std; class Node { public: int value; Node *right; Node *left; Node(int value) { this->value = value; this->right = NULL; this->left = NULL; } }; Node *input() { int val; cin >> val; Node *root; if (val == -1) {...
ALGO
0.999967
4.263168
{ "github_metadata": { "branch": "main", "commit_count": 102, "repo_created_at": "2023-04-10T15:28: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": "ce7c10761d...
477127ec-582d-4f73-bee2-5eb4d3622a91
arajajyothibabu/C
sortedLinkedList.cpp
#include<stdio.h> #include<conio.h> #include<stdlib.h> #pragma warning(disable:4996) struct test { char input[30]; int l1; int output[30]; int l; }test[7] = { {"1,2,3,4,5",9,{1,2,3,4,5},5}, {"1,5,2,6,3",9,{1,2,3,5,6},5}, {"100,23,5,67",11,{5,23,67,100},4}, {"0,2,0,2",7,{0,0,2,2},4}, {"-23,-56,-34,12",14,{-56,...
ALGO
0.999555
3.229989
{ "github_metadata": { "branch": "master", "commit_count": 4, "repo_created_at": "2015-06-19T03:50: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": "43e100ada4...
8cb2db04-8fa8-4a22-9476-98abbfcc6c35
dbueno/euforia
src/supp/marco.h
//! Comments taken from the python code in z3 at examples/python/mus/marco.py. //! Implemented by <NAME>. //! //! Enumeration of Minimal Unsatisfiable Cores and Maximal Satisfying Subsets //! This tutorial illustrates how to use Z3 for extracting all minimal //! unsatisfiable cores together with all maximal satisfying ...
ALGO
0.974466
6.638852
{ "github_metadata": { "branch": "main", "commit_count": 16, "repo_created_at": "2021-06-15T17:15:16.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 5, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "8a1e33cb1e0...
95da9b73-462f-4179-a159-16618764b430
Zachary-Rea/CSC-255
P6/p6m.cpp
#include <cstdio> #include <iostream> #include <cstdlib> #include <cmath> #include "p6.h" using namespace std; void part1(iPQ &myPQ) { int i, j; int v; bool rc; //srand(time(NULL)); srand(0); for (i = 0; i < 100; i++) { v = rand() % 1000; rc = myPQ.enq(v); //cout << i << ": enq of " << i ...
TOOL
0.985651
3.716719
{ "github_metadata": { "branch": "main", "commit_count": 159, "repo_created_at": "2023-01-22T06:21: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": "d17b0b873f...
01e1f47f-8c9c-4d94-b8a6-11a147a010ae
CaseyHofland/LightPuzzleBox
Puzzle.h
class Puzzle { public: bool combs[5][5]; Puzzle() {} // Generate a new puzzle. void generate(int _lights) { clearCombs(); lights = _lights; lights = max(lights, 0); lights = min(lights, 5); int l = lights; // Create a matrix of length possible combinations. ...
ALGO
0.932651
5.205105
{ "github_metadata": { "branch": "master", "commit_count": 4, "repo_created_at": "2019-04-05T21:59: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": "33e84bfb78...
fc573c85-714f-4c06-b9ff-cbc3fd86f462
poneciak57/OI-prep-2023-2024
snippets/segment_trees/big_tree.cpp
#include <bits/stdc++.h> #define LL_INF 1000000000000000007 typedef long long ll; typedef std::string str; typedef std::pair<ll, ll> llPair; template <typename T> using vec = std::vector<T>; using namespace std; const int N = 1 << 20; vec<int> seg_tree; // mapa przechowuje indeksy w drzewie dla duzych wartosci uno...
ALGO
0.999405
3.931053
{ "github_metadata": { "branch": "main", "commit_count": 112, "repo_created_at": "2023-09-20T14:57: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": "7922178d4a...
9bf7cdc0-de81-485f-986e-f65f3fd6facd
silverthreadk/leetcode
Cpp/200_Number_of_Islands.cpp
class Solution { public: int numIslands(vector<vector<char>>& grid) { if(grid.empty()) return 0; int result = 0; queue<pair<int,int>> q; int m = grid.size(); int n = grid.back().size(); for(int i=0; i<m; ++i){ for(int j=0; j<n; ++j){ ...
ALGO
0.999972
6.521988
{ "github_metadata": { "branch": "master", "commit_count": 922, "repo_created_at": "2019-05-21T13:10:09.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "e6e4b5ec...
aec57aaf-c556-4e8b-aa62-57c5f8dc6f45
wrench786/wrench786-CP-Library
dummy.cpp
#include <bits/stdc++.h> using namespace std; #define endl "\n" typedef long long int ll; const ll MX = 1e5 + 5, N = 15, Ran = 2e5 + 5; ll n, m, d, k, A[N][MX], dp[N][MX], T[4 * Ran]; vector<ll> res; void update(ll node, ll a, ll b, ll x, ll y) { if (a == b && a == x) { T[node] = y; return; } ...
ALGO
0.999974
3.946583
{ "github_metadata": { "branch": "main", "commit_count": 35, "repo_created_at": "2023-08-17T20:55: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": "6b04b81c6aa...
f22fc2a1-9d5b-4e85-a4cd-0d45aa4374f0
Asmit-Bajaj/DS-AND-ALGO
disjoint_set.cpp
#include<bits/stdc++.h> using namespace std; //finding parent of the current node //(4,3)->(3,2)->(2,1)->(1,1) hence parent of 4 is 1 also setting parent of 4 as 1 so that int find_parent(vector<int>&p,int node){ int curr = node; while(p[node] != node){ node = p[node]; } //dynamic programming ...
ALGO
0.999676
4.093718
{ "github_metadata": { "branch": "master", "commit_count": 4, "repo_created_at": "2020-11-16T10:49: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": "2f4dea85be...
c30f8ddc-bd59-4a6a-b959-b5cd7d7b4763
D-K-E/math3d
include/math3d/math3d.hpp
#ifndef MATH3D_HPP #define MATH3D_HPP #include "core.h" #include "utils.h" namespace math3d { template <typename T> OpResult to_skew_mat(const vecn::VecN<T, 3> &vec, matn::MatN<T, 3, 3> &out) { // T a3; vec(2, a3); T a2; vec(1, a2); T a1; vec(0, a1); matn::MatN<T, 3, 3> m; T ...
ALGO
0.920617
6.856415
{ "github_metadata": { "branch": "master", "commit_count": 12, "repo_created_at": "2023-12-25T13:47: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": "5c1e98fb6...
f67680a8-4559-468c-acf0-2575938f3d01
wasit-shafi/hands-on-DSA-and-CP
c++/Antti_Laaksonen/4-Data structures/unorderedset_orderedset.cpp
#include<iostream> #include<vector> #include<set> #include<unordered_set> using namespace std; int main() { vector<int> vnum; vector<string> vnames; set<int> _set; set<string> _names; unordered_set<int> _uset; unordered_set<string> _unames; // vector vnum.push_back(10); vnum...
TOOL
0.973823
4.76557
{ "github_metadata": { "branch": "master", "commit_count": 41, "repo_created_at": "2019-07-18T20:09:32.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "1b50dda65...
6dc35202-5df3-4ab5-96f9-018d181b3565
simoncblyth/opticks
npy/Ellipse.cpp
/* * Copyright (c) 2019 Opticks Team. All Rights Reserved. * * This file is part of Opticks * (see https://bitbucket.org/simoncblyth/opticks). * * 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 ...
ALGO
0.992795
6.110032
{ "github_metadata": { "branch": "master", "commit_count": 7469, "repo_created_at": "2020-07-03T18:07:26.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 33, "forks": 12, "issues": 1, "pull_requests": 0 }, "file_meta": { "content_id": "72e0f...
134ab95d-bcd6-4864-af2b-0f357e1249da
prajapati-sumit/Competitive-Programming
AtCoder/BeginnerContest195/A.cpp
//CODED BY <NAME> #include <bits/stdc++.h> using namespace std; typedef unsigned long long ull; typedef long long ll; typedef pair<int, int> pii; typedef pair<ll, ll> pl; #define PI 3.1415926535897932384626 #define pb push_back #define mk make_pair #define ff first #define ss second #define trav(v) for(auto &el:v) ...
ALGO
0.999837
3.504366
{ "github_metadata": { "branch": "master", "commit_count": 14, "repo_created_at": "2021-05-21T16:10:49.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "012cb7397...
6455bd39-1dc8-44fe-a984-8cfb8b23915a
LuisNav6/codigos-c-
vectores estáticos y punteros/vectores estáticos y punteros/main.cpp
// // main.cpp // vectores estáticos y punteros // // Created by <NAME> on 18/05/21. // //cualquier vector es en realidad un puntero //por los tanto los vectores pueden sere recibidos en un parametro declarado como una variable tipo apuntador //por lo tanto los vectores pueden ser manipualados con aritmetica de punt...
TOOL
0.98946
3.446536
{ "github_metadata": { "branch": "main", "commit_count": 12, "repo_created_at": "2023-03-17T01:03: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": "eb79c068556...
1e357249-4d23-4023-bb19-1aa8ee81d765
Ashechol/LeetCode
source/1. Array/Two Pointers/Sliding Window/Array_904.cpp
// Created by Ashechol on 2022/9/17. // 904. 水果成篮 // 题目链接:https://leetcode.cn/problems/fruit-into-baskets/ // 题解链接:https://www.wolai.com/ktot9KqKvRKWvcJT5s15D3#3R4ZG7gZn7aoLTrCqjnyYd #include <iostream> #include <vector> #include <unordered_map> using namespace std; int totalFruit(vector<int>& fruits); int main() {...
ALGO
0.999997
5.882448
{ "github_metadata": { "branch": "main", "commit_count": 86, "repo_created_at": "2022-08-23T05:13: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": "b989288f412...
40623175-526f-455e-ac54-f7d031c42504
ujjwald7/C--Templates
GraphHashMap.cpp
#include<bits/stdc++.h> using namespace std; #define int long long int #define ld long double #define F first #define S second #define P pair<int,int> #define V vector #define pb push_back #define mp make_pair #define endl "\n" #define db(...) __f(#__VA_ARGS__, __VA_ARGS__) #define MOD 1000000007 //1e9+7 template <ty...
ALGO
0.999858
4.448384
{ "github_metadata": { "branch": "master", "commit_count": 8, "repo_created_at": "2020-07-04T18:00: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": "90124b0786...
e1730035-7fe6-4665-8ab2-6464ea2e65f8
nraymundo/cmsi371
Assignment-1/assignment1.cpp
/*** assignment1.cpp Assignment-1: Cartoonify Name: <NAME> Collaborators: N/A Project Summary: Using OpenGL and C++ to design a cartoon version of a face of our own choosing. I used Bezier's algorithm to accomplish this task, taking an iterative approach with the drawing of the curve. ***/ #ifdef __APPLE__...
ALGO
0.997705
5.091413
{ "github_metadata": { "branch": "master", "commit_count": 18, "repo_created_at": "2020-02-10T02:59: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": "6c81ab845...
fa2b7260-985c-4aa0-807b-daaded51de0e
ariel-utn/Programacion_I_2024_Cuatrimestre_I_TM
Comision6/Codificacion/Semana05/ejemplo2b.cpp
// Nombre: // Apellido: // Guía: 3 // N° EJ: 13 // Enunciado: #include <iostream> using namespace std; int main() { int x, num, maximoPar, posMax; bool hayPar = false; for (x= 0; x < 10; x++) { cout << "Ingrese #" << x+1 << ": "; cin >> num; if( num%2 == 0 ) { ...
ALGO
0.999724
3.950163
{ "github_metadata": { "branch": "main", "commit_count": 44, "repo_created_at": "2024-03-24T18:37:09.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 6, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "8dd122a8a0c...
a57c964a-a4ac-4d73-9611-6063c539d068
Itzpjscode/60dayschallenge
#day3/separate_even_odd.cpp
#include <iostream> using namespace std; int main() { int even[5], odd[5], a[5], i, j, k,f,s,m; cout << "\nenter the size of array(max.5):"; cin >> m; cout << "\nenter the array:"; for (i = 0; i < m; i++) { cin >> a[i]; } i = 0, j = 0; for (i = 0; i < m; i++) { if (a[i]%2==0) { e...
ALGO
0.99926
3.878365
{ "github_metadata": { "branch": "master", "commit_count": 20, "repo_created_at": "2022-02-03T16:22: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": "de6541ed7...
300ab13d-0d2f-417c-8d11-2d15bdc45dbc
YageShen/CodingTraining
JZ/JZ65.cpp
class Solution { public: /** * 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可 * * * @param matrix char字符型vector<vector<>> * @param word string字符串 * @return bool布尔型 */ bool dfs(vector<vector<char> >& matrix, int r, int c, string& word, int idx) { if(idx == word.size()) ...
ALGO
0.999935
5.91643
{ "github_metadata": { "branch": "main", "commit_count": 17, "repo_created_at": "2021-07-23T02:16: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": "f6ea61c1b1a...
66f1a7da-fd07-4e90-9ac8-58666338cec3
zxing-cpp/zxing-cpp
core/src/pdf417/ZXBigInteger.cpp
/* * Copyright 2016 <NAME> */ // SPDX-License-Identifier: Apache-2.0 #include "ZXBigInteger.h" #include "BitHacks.h" #include "ZXAlgorithms.h" #include <algorithm> #include <cassert> #include <cctype> #include <cstdint> #include <utility> namespace ZXing { using Block = BigInteger::Block; using Magnitude = std::ve...
ALGO
0.998976
6.452256
{ "github_metadata": { "branch": "master", "commit_count": 2489, "repo_created_at": "2016-04-12T22:33:06.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 1571, "forks": 468, "issues": 48, "pull_requests": 10 }, "file_meta": { "content_id": "0...
91d4e3ba-cc38-4f45-8a08-9dcb464dc28e
geshtng/competitive-programming
TOKI/Pemrograman Kompetitif Dasar/1. Perkenalan Pemrograman Kompetitif Dasar/B - Runtuh.cpp
#include <bits/stdc++.h> using namespace std; int main() { int c, r; vector <vector <int>> arr; cin >> c >> r; vector <int> arr_0(r, 0), arr_1(r, 1); for (int i = 0; i < c; i++) { vector <int> temp; for (int j = 0; j < r; j++) { char x; cin >> x; temp.push...
ALGO
0.999952
4.052513
{ "github_metadata": { "branch": "master", "commit_count": 53, "repo_created_at": "2020-05-11T03:45: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": "fd666b205...
3e486a25-8cf0-403e-b5ae-fa92597ddc09
Everyonecanchangetheworld/bj_practice
20200206/max_2562.cpp
//success _ 2562 #include <iostream> //#include <math.h> //#include <cstdlib> //#include <ctime> using namespace std; #include <iostream> using namespace std; int main() { int max=0, index=1; int root[100]; for (int k = 1; k < 10; k++) { cin >> root[k]; if (max < root[k]) { max = root[k]; index = k; ...
ALGO
0.999875
3.382002
{ "github_metadata": { "branch": "master", "commit_count": 17, "repo_created_at": "2020-02-03T19:45: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": "f481e2d37...
73649e7a-208d-4631-81d7-09ecfcc491ae
gnlenfn/DailyProblemSolving
백준/Silver/1012. 유기농 배추/유기농 배추.cc
#include <bits/stdc++.h> using namespace std; int T, n, m, K, x, y; const int dx[] = {1, -1, 0, 0}; const int dy[] = {0, 0, 1, -1}; int arr[51][51]; int visited[51][51]; int ret; void dfs(int row, int col){ visited[row][col] = 1; for(int i = 0; i < 4; i++){ int nx = row + dx[i]; int ny = col +...
ALGO
0.999891
4.504529
{ "github_metadata": { "branch": "main", "commit_count": 593, "repo_created_at": "2022-09-29T05:06: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": "49d5e6cf90...
01fee668-f515-4df4-b629-1d6ccc66f7fa
HariAakash646/CompetitiveProgramming
DynamicProgramming/hanoi_factory.cpp
#include <bits/stdc++.h> using namespace std; #define scd(t) scanf("%d", &t) #define scld(t) scanf("%ld", &t) #define sclld(t) scanf("%lld", &t) #define scc(t) scanf("%c", &t) #define scs(t) scanf("%s", t) #define scf(t) scanf("%f", &t) #define sclf(t) scanf("%lf", &t) #define forr(i, j, k) for (int i = j; i < k; i++...
ALGO
0.999979
3.588841
{ "github_metadata": { "branch": "main", "commit_count": 123, "repo_created_at": "2022-09-08T07:58:23.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "12667dc56d...
9ec0c9fe-5768-454a-91e3-241763ec0c6a
wwhales11/Algorithm_Practice
HW9/hw11.cpp
/* * [2019117662] [박수환] 저는 이 소스 코드를 다른 소스 코드를 복사하지 않고 직접 작성하였습니다. */ #include <iostream> #include <algorithm> #include <queue> #define MAX 256 using namespace std; typedef struct item *item_pointer; typedef struct item { int id; int weight; int profit; float unit_profit; } itemtype; struct compare { // 내림차순...
ALGO
0.999981
4.520899
{ "github_metadata": { "branch": "main", "commit_count": 3, "repo_created_at": "2021-05-25T01:02: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": "5c78f16dcce8...
0b88326c-a869-4ee9-aa8e-76c24f50b62f
BrenoCardelle/AED-2
RestaUm/RestaUm.cpp
#include <iostream> #include <stdlib.h> using namespace std; int P[100], M[100], i, n, pmin, prest; int aux = 1; void Inicializa(){ int i, j; for(i=1; i<=n; i++) P[i] = 0; prest = 0; for (i=1; i<=n; i++){ j = rand()%n+1; if (j <3*n/4){ P[i]=1; prest++; } } ...
ALGO
0.999908
3.568094
{ "github_metadata": { "branch": "master", "commit_count": 13, "repo_created_at": "2019-05-23T11:16: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": "612781ee1...
3044e264-659c-4a2b-938c-b27a7c55562c
yunxiao3/ACM
maze.cpp
#include<iostream> #include<cstring> #include<vector> #include<queue> using namespace std; const int N = 5; int maze[N][N] = {{0,0,0,0,0},{0,1,0,1,0},{0,1,2,1,0},{0,1,1,1,0},{0,0,0,2,1}}; bool inq[N][N] = {false}; struct node{ int x, y; int step; int road[100][2]; }Node; bool test(int x, int y){ if(x >= N...
ALGO
0.999941
3.338886
{ "github_metadata": { "branch": "master", "commit_count": 9, "repo_created_at": "2018-03-25T04:39:28.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "fde9fc5b8a...
53d87c9b-aa0f-4419-b2dd-c958fa4818e6
JatinRathore101/cpp_syntax
3.c++ searching and sorting algorithms/tut123-Binary_Search_with_Duplicates.cpp
#include<bits/stdc++.h> using namespace std; // Binary Search with Duplicates // This program is written to work on ascending list input (duplicates allowed) // Find the first occurence of an integer in the given sorted sequence of integers /* Input: 7 2 4 4 4 7 7 9 4 9 4 5 2 Output: 6 1 -1 0 */ int binary_search(...
ALGO
0.999985
5.289533
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2023-06-01T03:27: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": "cacbea9106...
7634121a-b09f-4510-94c2-a73b7c451079
aliyun/aliyun-openapi-cpp-sdk
vod/src/model/SearchEditingProjectRequest.cc
/* * Copyright 2009-2017 Alibaba Cloud 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.963632
3.872658
{ "github_metadata": { "branch": "master", "commit_count": 2903, "repo_created_at": "2017-12-26T02:53:27.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 104, "forks": 74, "issues": 11, "pull_requests": 2 }, "file_meta": { "content_id": "8868...
e3662a4d-2a80-4779-8fa1-76db21c44d13
ptkila/cowichan
cowichan_openmp/randmat.cpp
/** * \file cowichan_openmp/randmat.cpp * \brief OpenMP randmat implementation. * \see CowichanOpenMP::randmat */ #include "cowichan_openmp.hpp" void CowichanOpenMP::randmat (IntMatrix matrix) { IntVector state = NULL; // initialize first column values try { state = NEW_VECTOR_SZ(INT_TYPE, nr); } c...
ALGO
0.999297
4.468881
{ "github_metadata": { "branch": "master", "commit_count": 319, "repo_created_at": "2015-04-20T09:29:19.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 2, "issues": 8, "pull_requests": 0 }, "file_meta": { "content_id": "c7d3f2dd...
12bd94c9-02a6-48c0-9dd8-8b34de571a5e
DistinctVision/Augmented-Reality-on-Qt
AddedSource/AR/OpticalFlowCalculator.h
#ifndef AR_OPTICALFLOWCALCULATOR #define AR_OPTICALFLOWCALCULATOR #include "Image.h" #include "TMath/TMatrix.h" namespace AR { enum class TrackingResult { Fail, Completed, Uncompleted }; class OpticalFlowCalculator { public: OpticalFlowCalculator(); ~OpticalFlowCalculator(); Point2i cursorS...
ALGO
0.96481
6.951939
{ "github_metadata": { "branch": "master", "commit_count": 4, "repo_created_at": "2015-05-11T11:12:02.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 41, "forks": 11, "issues": 2, "pull_requests": 0 }, "file_meta": { "content_id": "abb42850...
65ed318b-dd28-4cb4-8eaa-c2cb8e6a4501
ishandutta2007/codeforces-y
ytkn/normal/1733/D1.cpp
#include <iostream> #include <algorithm> #include <iomanip> #include <vector> #include <queue> #include <deque> #include <set> #include <map> #include <tuple> #include <cmath> #include <numeric> #include <functional> #include <cassert> #define debug_value(x) cerr << "line" << __LINE__ << ":<" << __func__ << ">:" << #x...
ALGO
0.999708
3.495004
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2024-10-30T16:40: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": "bc1692b8338f...
6b909158-de9a-43d9-a462-0ebef2230a17
HenrikSchumacher/Knoodle
src/OrthoDraw/BendsLP.hpp
private: template<typename I, typename ExtInt> static I Bends_VarCount( mref<PlanarDiagram<ExtInt>> pd ) { return I(2) * static_cast<I>(pd.ArcCount()); } template<typename I, typename ExtInt> static I Bends_ConCount( mref<PlanarDiagram<ExtInt>> pd ) { return static_cast<I>(pd.FaceCount()); } template<typena...
ALGO
0.995145
5.730216
{ "github_metadata": { "branch": "main", "commit_count": 527, "repo_created_at": "2023-03-27T10:59:43.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 1, "issues": 4, "pull_requests": 1 }, "file_meta": { "content_id": "b4fa218d19...
dc62e28d-000f-4d37-bee4-ffb4985f2df5
crag-h4k/Search-Algorithms
Search.h
#include <iostream> #include <fstream> #include <cstdlib> // Provides size_t #include <random> using namespace std; class Search { public: bool sequential_find(int num){ for(int i = 0; i < size; i++){ if (array[i] == num){ return true; } } return false; } bool recursive_binary_find(int nu...
ALGO
0.99382
4.713651
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2018-01-04T23:30: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": "262866b1eb...
e1bd76cc-ba63-469a-8bfc-d2601c285bfd
rgomezer/Coding-Samples
SIMD/P6_SIMD/Vect4D_SIMD.h
#ifndef VECT4D_SIMD_H #define VECT4D_SIMD_H #include <xmmintrin.h> #include <smmintrin.h> class Matrix_SIMD; class Vect4D_SIMD { public: Vect4D_SIMD() :x(0.0f), y(0.0f), z(0.0f), w(0.0f) { }; Vect4D_SIMD(const __m128 &tmp) :m(tmp) { } Vect4D_SIMD(const float tx, const float ty, const float tz, const ...
TOOL
0.967571
3.552734
{ "github_metadata": { "branch": "master", "commit_count": 7, "repo_created_at": "2015-11-05T02:37: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": "1395748a89...
6993ea87-2e66-439e-8631-2af463c83d19
liulanz/Graph
TopologicalSort.cc
//<NAME> /* This file reads a graph file and store graph into a list prints order of vertices after topological sortings, prints "Cycle found" if a cycle is detected */ #include <iostream> #include <fstream> #include <string> #include <sstream> #include <list> #include <iterator> #include "graph.h" #include "vert...
ALGO
0.999465
5.448424
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2019-12-07T04:27: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": "4124e622e9...
ca18c96f-5343-46ea-909e-97de6e0bb28a
pie-12/CompetitveProgramming
OJTRAIN/CONTEST_TRAIN/VKU/KC_MASHUP/4/main.cpp
//CF: pie12 【=◈︿◈=】 #include <bits/stdc++.h> #define io freopen("main.inp","r",stdin); freopen("main.out","w",stdout); #define fast ios::sync_with_stdio(false); cin.tie(nullptr); #define int long long #define float long double #define endl '\n' using namespace std; signed main() { //io fast int t; c...
ALGO
0.999986
4.860357
{ "github_metadata": { "branch": "main", "commit_count": 28, "repo_created_at": "2024-05-08T04:23:04.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "49663b52fcc...
1ab9d129-b7cf-4b40-973f-c9b911544f14
Advaith07/dsa_codes
implement_queue_using_stack.cpp
class MyQueue { public: stack<int>s1; stack<int>s2; MyQueue() { } void push(int x) { s1.push(x); } int pop() { int del; if(s1.size()==0) return -1; else { while(s1.size()!=0) { ...
ALGO
0.999134
5.112468
{ "github_metadata": { "branch": "main", "commit_count": 30, "repo_created_at": "2023-01-16T19:10: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": "36012f073b9...
c094f6b7-9c22-4be5-a4a7-6acece4ecd32
amol1211/DSAWithC-CPP
03.SolvingLeetcodeProblems/Array/FindPivotIndex/ajunek.cpp
#include <iostream> #include <vector> #include <numeric> using namespace std; class solution { public: int pivotIndex(vector<int>& nums) { int totalSum = 0; for (int i = 0; i < nums.size(); i++) { totalSum += nums[i]; } int leftSum = 0; for (int i = 0; i < n...
ALGO
0.99996
6.002045
{ "github_metadata": { "branch": "main", "commit_count": 894, "repo_created_at": "2023-02-25T03:36: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": "dec77d2055...
71382595-f7e1-4038-b016-de8e27b0c38a
wunderfox/wunderfox
gfx/2d/ConvolutionFilterSSE2.cpp
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* vim: set ts=8 sts=2 et sw=2 tw=80: */ // Copyright (c) 2011-2016 Google Inc. // Use of this source code is governed by a BSD-style license that can be // found in the gfx/skia/LICENSE file. #include "SkConvolver.h" #include "mozilla/Att...
ALGO
0.995193
6.340895
{ "github_metadata": { "branch": "main", "commit_count": 19, "repo_created_at": "2024-10-10T15:42:35.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 4, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "5488e21949db...
528b5e89-a81d-44f5-b83b-e5c2ff701462
francescozatelli/Esercizi_LSN_Zatelli
Ex_06/Ex_06_1/ising1D.cpp
#include "ising1D.h" int Ising1D :: Pbc(int i) //Algorithm for periodic boundary conditions { if(i >= m_nspin) i = i - m_nspin; else if(i < 0) i = i + m_nspin; return i; } //Returns the boltzmann weight for a given energy double Ising1D :: BoltzmannWeight(double energy){ return exp(-m_beta*energy); }...
ALGO
0.999769
5.510021
{ "github_metadata": { "branch": "master", "commit_count": 20, "repo_created_at": "2020-04-01T14:54: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": "b1aff3959...
f3909bd7-2bd9-4343-bb46-9f1df3375866
louisfghbvc/Leetcode
Dp/1524. [Like] Number of Sub-arrays With Odd Sum.cpp
// think by myself, dp // cnt zero con. // so when odd need to insert a new value. // O(N). class Solution { public: int mod = 1e9+7; int numOfSubarrays(vector<int>& arr) { for(int &x: arr) x = x%2; long ans = 0, con = 0; vector<int> dp; for(int i = 0; i < arr.size(); ++i){ ...
ALGO
0.999999
5.335485
{ "github_metadata": { "branch": "master", "commit_count": 2084, "repo_created_at": "2019-12-13T14:09:25.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 4, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b530ce6...
fbe94e3f-3a34-48e3-a779-8065393d4bbe
Jeanmilost/Demos
Visual Studio/Others/GJK/GJK_3D/SDK/Geometry/DWF_Sphere.cpp
/**************************************************************************** * ==> DWF_Sphere ----------------------------------------------------------* **************************************************************************** * Description : Geometric sphere * * Devel...
ALGO
0.97952
5.858804
{ "github_metadata": { "branch": "master", "commit_count": 89, "repo_created_at": "2018-11-06T21:08:18.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 4, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "d6c1864fc...
2d9977aa-22ad-4bcd-b827-0686a62c2aa2
Sakshi-2100/Crack-Your-Placement
FindDuplicateNumber.cpp
//Given an array of integers nums containing n + 1 integers where each integer is in the range [1, n] inclusive. // There is only one repeated number in nums, return this repeated number. // You must solve the problem without modifying the array nums and uses only constant extra space. // Example 1: // Input: nums ...
ALGO
0.999944
6.003
{ "github_metadata": { "branch": "main", "commit_count": 43, "repo_created_at": "2022-05-05T14:26: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": "8b00ca625da...
86a6e10c-4dee-4f9e-9abb-20ddcea33ace
804463592/LeetCode
LeetCode/Longest_Substring_Without_Repeating_Characters.cpp
/* Given a string, find the length of the longest substring without repeating characters. Example 1: Input: "abcabcbb" Output: 3 Explanation: The answer is "abc", with the length of 3. */ #include<string> #include<iostream> #include<set> using namespace std; class Solution { int max(int a, int b) { return a >...
ALGO
0.999537
5.105557
{ "github_metadata": { "branch": "master", "commit_count": 66, "repo_created_at": "2019-01-02T07:41: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": "1beddc635...
0bf05cee-c42a-44bf-a35e-4a0123403774
aalavandhan/link-privacy
basicGSQueries/BasicGSQueries.h
class SimpleQueries{ private: GPOs *gpos; ISPOs *spos; Utilities util; map<int, map<int, double>*> social_strength_matrix; map<int, map<int, double>*> diversity_matrix; map<int, map<int, double>*> weighted_frequency_matrix; public: SimpleQueries(GPOs *spatialIndex, ISPOs *socialGraph); ...
ALGO
0.972907
4.836891
{ "github_metadata": { "branch": "master", "commit_count": 657, "repo_created_at": "2017-01-26T02:17: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": "64da4b65...
3c71382e-fa18-48ca-8332-59964416d5c9
CheckHarry/LeetCodeRepo
312. Burst Ballons/maxCoins.cpp
#include <vector> #include <iostream> using namespace std; int maxCoins(vector<int>& nums) { if (nums.size() == 1) return nums[0]; vector<vector<int>> dp(nums.size() , vector<int>(nums.size() , 0)); for (int i = 0 ; i < nums.size() ; i ++) { if (i == 0) dp[i][i] = nums[i] * nums[i + 1]; e...
ALGO
0.999871
4.888474
{ "github_metadata": { "branch": "main", "commit_count": 162, "repo_created_at": "2021-11-23T11:07: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": "6e67039236...
22b6bbdb-73e6-4f96-9910-d9d31e4109e6
chaowei-flexiv/RBDyn
src/parsers/RBDyn/parsers/common.h
/* * Copyright 2012-2020 CNRS-UM LIRMM, CNRS-AIST JRL */ #pragma once #include <RBDyn/Joint.h> #include <RBDyn/MultiBody.h> #include <RBDyn/MultiBodyConfig.h> #include <RBDyn/MultiBodyGraph.h> #include <RBDyn/parsers/api.h> #include <SpaceVecAlg/SpaceVecAlg> #include <boost/variant.hpp> #include <Eigen/Core> #in...
TOOL
0.939867
7.254829
{ "github_metadata": { "branch": "develop", "commit_count": 509, "repo_created_at": "2020-11-06T19:19: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": "4e063e8...
093a3ff8-e3c3-486a-a5fe-cd35d026f888
deangelign/libFL
src/featureExtractor.cpp
// // Created by deangeli on 5/20/17. // #include "featureExtractor.h" //iftImage *iftCompute_ISF_MIX_MEAN_Superpixels(iftImage *img, int nsuperpixels, float alpha, float beta, int niters, int smooth_niters, int *nseeds, int *finalniters) { // iftImage *mask1, *seeds, *label; // iftMImage *mimg; // iftAdj...
ALGO
0.934794
4.779556
{ "github_metadata": { "branch": "master", "commit_count": 41, "repo_created_at": "2017-03-09T14:20:41.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 3, "issues": 0, "pull_requests": 1 }, "file_meta": { "content_id": "5b014a21d...
7cc1a92d-835b-471a-84fd-7e996ebd71b6
anas-harby/Algorithms-DataStructures
src/dp.cpp
#include <bits/stdc++.h> /* * Longest Common Subsequence. */ int lcs(std::string x, std::string y, int n, int m) { if (m == 0 || n == 0) return 0; if (x[n - 1] == y[m - 1]) return 1 + lcs(x, y, n - 1, m - 1); else return std::max(lcs(x, y, n, m - 1), lcs(x, y, n - 1, m)); } /* * Longest Increasing Subsequ...
ALGO
0.999573
5.046917
{ "github_metadata": { "branch": "master", "commit_count": 8, "repo_created_at": "2016-08-10T22:30: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": "6e97eca115...
d5c5aada-b352-42d0-b937-1cddbc3b847c
mdshakebakhtar003/C-plus-plus
pttrn5.cpp
// Online C++ compiler to run C++ program online #include <iostream> using namespace std; int main() { int n,i,j,t,k; cin>>n; int nst=n-1; for(i=1;i<=2*n-1;++i){ if(i<=n){ t=i; for(j=1;j<=i;++j){ cout<<"*"; ...
ALGO
0.999974
4.248935
{ "github_metadata": { "branch": "main", "commit_count": 16, "repo_created_at": "2024-02-18T18:37:39.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "616a48e46f0...
2cdb5c2f-3087-4c41-addc-d5d2c7741d9f
javagovindsharma/leetscode
lcci/04.03.List of Depth/Solution.cpp
/** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x), left(NULL), right(NULL) {} * }; */ /** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode(int x)...
ALGO
0.99993
5.999719
{ "github_metadata": { "branch": "main", "commit_count": 31, "repo_created_at": "2025-01-19T10:47: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": "56127b47d5f...
ce805ef1-8f4f-44a9-9cb3-1d9da5c29f0b
Gongsta/competitive-programming
codeforces/991div3/F.cpp
#include <stdio.h> #include <string.h> #include <algorithm> #include <bitset> #include <cmath> #include <iomanip> #include <iostream> #include <iterator> #include <limits> #include <map> #include <memory> #include <mutex> #include <new> #include <numeric> #include <ostream> #include <queue> #include <set> #include <st...
ALGO
0.999837
4.166176
{ "github_metadata": { "branch": "main", "commit_count": 116, "repo_created_at": "2021-03-06T16:56:23.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "c361809800...
3c33d1b4-f7d9-4046-84a5-1a1e83eb6d55
ahmetYilmaz88/C-plus-plus
Circle.h
/// @author <NAME> /// I pledge my word of honor that I have abided /// by the CSN Academic Integrity Policy while completing /// this assignment. /// @file AhmetYilmazCit133_pa11.cpp /// @version The date is: 2020-06-13 /// @brief The program uses various number of functions /// and two class /// class names a...
TOOL
0.915202
5.086174
{ "github_metadata": { "branch": "main", "commit_count": 11, "repo_created_at": "2020-11-06T00:45: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": "3d540659048...
02beca7d-e8a1-4596-a0f2-36fd13f06451
ttzztztz/leetcodeAlgorithms
线段树/KS. Candies.cpp
#include <iostream> #include <vector> #include <set> #include <climits> using namespace std; int main() { int dataCount = 0; cin >> dataCount; for (int _ = 1; _ <= dataCount; _++) { int N = 0, O = 0, M = 0, L = 0; long long D = 0L, X1 = 0L, X2 = 0L, A = 0L, B = 0L, C = 0L; cin >> ...
ALGO
0.999788
4.190109
{ "github_metadata": { "branch": "master", "commit_count": 872, "repo_created_at": "2019-09-03T06:57:13.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 12, "forks": 2, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "86ea1c9...
a3266808-79ee-4242-b746-ede090184484
humanoid-robotics-htl-leonding/robo-ducks-core
src/brain/Behavior/BallSearchPositionProvider.hpp
#pragma once #include <list> #include <vector> #include "Framework/Module.hpp" #include "Data/BallSearchMap.hpp" #include "Data/BallSearchPosition.hpp" #include "Data/BallState.hpp" #include "Data/BodyPose.hpp" #include "Data/CycleInfo.hpp" #include "Data/FieldDimensions.hpp" #include "Data/GameControllerState.hpp" ...
ALGO
0.998753
7.156935
{ "github_metadata": { "branch": "master", "commit_count": 686, "repo_created_at": "2019-04-13T09:07:29.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 5, "forks": 0, "issues": 21, "pull_requests": 0 }, "file_meta": { "content_id": "6c905d1c...
b5f427e3-c463-41a3-aacf-55e20b9a99c5
mohamedelhaouil/ProblemsSolutions
Codeforces/A. Hayato and School.cpp
/* * by: MEL05 */ #include<bits/stdc++.h> /*#include<unordered_map> #include<unordered_set>*/ using namespace std; void ios_b() { ios_base :: sync_with_stdio(0); cin.tie(NULL); cout.tie(NULL); } void f() { #ifndef ONLINE_JUDGE freopen("input.txt", "r", stdin); freopen("output.txt", "w", stdout); #endif } #...
ALGO
0.999948
3.883299
{ "github_metadata": { "branch": "main", "commit_count": 173, "repo_created_at": "2022-10-14T15:22: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": "5ca6d5f6c0...
369a1835-6ca7-482f-9a63-838b33deb5b4
Xarma123/cp-practice
A_Ezzat_and_Two_Subsequences.cpp
#include <bits/stdc++.h> #define lol long long #define lold long double using namespace std; int main() { lol t; cin >> t; while (t--) { lol n; cin >> n; lold a[n], p[n] = {0}; for (lol i = 0; i < n; i++) { cin >> a[i]; } so...
ALGO
0.999725
4.168318
{ "github_metadata": { "branch": "master", "commit_count": 176, "repo_created_at": "2022-09-18T23:21:39.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "eee3008b...
80b04318-58b7-4470-bef1-7bf019007e2c
BartoszewskiA/2021-Podstawy-Programowania-Inf-Techniczna-Wyklad
w02p02.cpp
#include <iostream> #include <cmath> using namespace std; int main() { int a, b, c; cout << "a= "; cin >> a; cout << "b= "; cin >> b; cout << "c= "; cin >> c; int delta = b * b - 4 * a * c; if (delta > 0) { double x1 = (-b - sqrt(delta)) / (2 * a); double x2 = (...
ALGO
0.999532
3.755215
{ "github_metadata": { "branch": "master", "commit_count": 8, "repo_created_at": "2021-11-01T20:54:39.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "29d039d961...
87e31f7b-108e-4cdb-ab43-e900a5ab268d
francis1992/AlgorithmContest
TopCoder/OkonomiyakiParty.cpp
#include <cstdio> #include <cstring> #include <algorithm> #include <vector> #include <string> #include <map> #include <set> #include <queue> #include <cmath> #include <iostream> #include <cstdlib> #include <sstream> using namespace std; const int mod=(int)1e9+7; int dp[55][55][55][55]; void add(int &a,int b) { a+=b; ...
ALGO
0.99993
4.789519
{ "github_metadata": { "branch": "master", "commit_count": 34, "repo_created_at": "2016-04-04T03:46: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": "15e872300...
1c60a6cd-748c-4c91-8815-0655d29b035a
skjha1/Aditya-verma-youtube-playlist-code
Binary Search/08 Searching in Nearly sorted array.cpp
// https://www.geeksforgeeks.org/search-almost-sorted-array/ int binarySearch(int arr[], int l, int r, int x) { if (r >= l) { int mid = l + (r - l) / 2; // If the element is present at // one of the middle 3 positions if (arr[mid] == x) return mid; if (mid > l && arr[mid - 1] == x) return (mid - 1); ...
ALGO
0.999948
5.169292
{ "github_metadata": { "branch": "main", "commit_count": 68, "repo_created_at": "2021-05-11T18:12:20.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 601, "forks": 313, "issues": 0, "pull_requests": 2 }, "file_meta": { "content_id": "db4fe42...
0ff95130-607c-4363-8d19-ed135a8dde8c
samardzzziska/FINKI
Структурно програмирање/Втор колоквиум/Задачи за вежбање за втор колоквиум испит/zad12.cpp
/* Да се напише рекурзивна функција која ќе го најде бројот на позитивни броеви од целобројна низа. * Функцијата како аргумент ја прима низата, за која се бара бројот на позитивни броеви и вкупниот број на елементи, кои ги има таа низа. Функцијата е зададена со следниот прототип: int BrojPozitivni(int niza[], int n);...
ALGO
0.999986
4.081207
{ "github_metadata": { "branch": "main", "commit_count": 22, "repo_created_at": "2024-02-04T15:22: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": "1d58141c54a...
236f9c3c-d70c-4032-80ab-4732a96cd617
joe-doody262/Wheres-Wally
Assignment 1/Source.cpp
#include <iostream> #include <fstream> #include <string> #include "Base_Image.h" //cluster image header #include "Large_Image.h" //wally image header #include "Reference_Image.h" //reference image header using namespace std; // Reads .txt file representing an image of R rows and C Columns stored in filename // and c...
ALGO
0.983362
3.887877
{ "github_metadata": { "branch": "master", "commit_count": 4, "repo_created_at": "2020-08-02T18:10: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": "8c3aa87d5e...
248b01ce-646e-46f3-bce0-aea7b9cf6b85
RaoJordan/LRU-Cache
main.cpp
#include<bits/stdc++.h> using namespace std; //Node to store the data(Linked list) class Node{ public: string key; int value; Node(string key, int value) { this->key = key; this->value = value; } }; class LRUcache{ public: int maxSize; list<Node> l; unordered_ma...
ALGO
0.999646
4.599467
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2022-07-24T09:44:18.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "cfd39d90682c...
f1bfc933-3569-470d-a4f7-85ab91b5e7bc
Subham-RKB/Sudoku-Game
practice inheritance.cpp
#include<iostream> using namespace std; /*class base{ public: int a; protected:int b; private: int c; public: base(){ cout<<"Base::"<<endl; a=10;b=20;c=30; } base(int a,int b,int c){ this->a =a; this-> b =b; this->c =c; } void print(){ cout<<a<<" "<<b<<" "<<c<<endl; } }; class derived...
ALGO
0.991579
3.186493
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2021-05-24T06:48: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": "700c8a102e98...
d3899ea3-bddd-41b7-a0d8-0e12bf45307f
yian0819/Design-and-Analysis-of-Algorithms-HW4-TSP
bruteForce.cpp
#include <iostream> #include <vector> #include <algorithm> #include <time.h> using namespace std; const int INF = 1e9; // 计算旅行商问题的最短哈密顿回路和其代价 void travelingSalesmanProblem(int n, vector<vector<int>>& graph) { vector<int> path(n); for (int i = 0; i < n; ++i) path[i] = i; int min_cost = INF; v...
ALGO
0.999941
4.88715
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2025-07-04T17:09: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": "39d270bbb56f...
e2a8b90b-6176-47b5-8e01-6e5825e4b5a2
Arg007/first
range-update-range-query-segTree.cpp
#include <bits/stdc++.h> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> #define sf scanf #define pf printf #define pb push_back #define mp make_pair #define PI ( acos(-1.0) ) #define mod 1000000007 #define maxn 100005 #define IN freopen("nocross.in","r",stdin) #define OUT freopen("nocros...
ALGO
0.999935
4.127169
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2018-07-28T07:49: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": "aef01f4886...
f2a8deee-85c8-42c6-9937-5f703c142de8
Nagisa12321/leetcod_cpp
algorithm/solve372.cpp
#include <vector> #include <iostream> using namespace std; class Solution { public: int superPow(int a, vector<int>& b) { if (a == 1) return 1; if (a == 0) return 0; if (b == vector<int>{ 1 }) return a % 1337; vector<int> res; int mod; divide(b, res, mod); in...
ALGO
0.999932
5.363105
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2022-01-22T03:13: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": "4844391cfd...
073c6370-770b-4849-b0e6-159d367667ee
bhelga/university
c++/Labs/Lab5/lab5_try1.cpp
#include <iostream> #include <vector> using namespace std; int main() { int n; double sum = 0, average = 0; cout << "Enter value of Array:\t"; cin >> n; double **A = new double*[n]; // виділяємо рядки for (int i = 0; i < n; i++) A[i] = new double [n]; // виділяємо стовпці ...
ALGO
0.969709
3.784348
{ "github_metadata": { "branch": "main", "commit_count": 6, "repo_created_at": "2021-03-01T11:02:05.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ba4a5cd17f24...
796d4a02-a113-4179-8fb1-ece63573266c
c2research/gdtw
archive/main_old.cpp
/***********************************************************************/ /************************* DISCLAIMER **********************************/ /***********************************************************************/ /** /** **/ /** Unless stated ot...
ALGO
0.999488
4.190796
{ "github_metadata": { "branch": "master", "commit_count": 40, "repo_created_at": "2017-05-28T19:30:35.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b84997f582...
7ba23b68-5180-4da7-b202-5062f4cccb15
SmallPeanutPark/CodeUp-Basic-100
1097 : [기초-2차원배열] 바둑알 십자 뒤집기.cpp
#include <iostream> #include <array> #include <vector> #include <utility> using namespace std; int main() { array<array<int, 19>, 19> arr = {}; // 바둑판 입력 받기 for (int k = 0; k < arr.size(); ++k) { for (int j = 0; j < arr[0].size(); ++j) { cin >> arr[k][j]; } } // 십자 돌리기 횟수 및 x,y 좌표 저장 int n; cin >> n; ...
ALGO
0.999943
4.873267
{ "github_metadata": { "branch": "main", "commit_count": 201, "repo_created_at": "2022-06-28T10:03:06.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "2bc140e6b2...
95419b06-f5c0-43a6-a8f7-243ad777bfae
wannaBpark/BOJ
백준/Gold/2143. 두 배열의 합/두 배열의 합.cc
#include <bits/stdc++.h> using namespace std; using ll = long long; int N,M,T; int A[1010]; int B[1010]; ll pSum1[1010]; ll pSum2[1010]; // map<ll, int> m1; // map<ll, int> m2; vector<ll> v1; vector<ll> v2; void input() { cin >> N; for (int i =1; i<=N; ++i) { cin >> A[i]; pSum1[i] = pSum1[i-1] ...
ALGO
0.999989
3.754768
{ "github_metadata": { "branch": "master", "commit_count": 183, "repo_created_at": "2020-11-02T15:28: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": "e70e0f4c...
1f61ff84-ab4d-4321-b8be-3a325d9a7dd4
wgsylcl/OI-Template
docs/Math/Combine/code/P3200.cpp
#include <bits/stdc++.h> using namespace std; #define int long long const int N = 2e6 + 5; int mp[N], pri[N], cnt[N], mod, num, n; int qpow(int n, int k) { int ans = 1; while (k) { if (k & 1) ans = ans * n % mod; n = n * n % mod; k >>= 1; } return ans; } signed main() { c...
ALGO
0.99998
4.744321
{ "github_metadata": { "branch": "main", "commit_count": 397, "repo_created_at": "2025-02-05T01:38: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": "4adf57328d...
3ccf2067-d0f5-4c91-a976-9710309148ee
jabney/react-native-cpp-pi
cpp/pi.cpp
#include <numeric> #include <thread> #include <vector> #include "pi.h" using namespace std; namespace { /** * Leibniz formula for π: 1 - 1/3 + 1/5 - 1/7 + 1/9 - ... */ double calculate_pi(uint64_t const start, uint64_t const end) { double sum = 0; for (uint64_t i = start; i < end...
ALGO
0.99973
6.779815
{ "github_metadata": { "branch": "master", "commit_count": 39, "repo_created_at": "2021-07-21T19:57: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": "aeb5f057b...
07eb00dc-2c61-4037-8481-efaa31c4764f
tinymrman/ResearchSummer2016
GLDM/itkGrayLevelDifferenceCalculator.h
#ifndef ITK_GRAYLEVELDIFFERENCECALCULATOR_H #define ITK_GRAYLEVELDIFFERENCECALCULATOR_H #include "itkObject.h" #include "itkObjectFactory.h" #include "itkImage.h" #include "itkImageSliceConstIteratorWithIndex.h" #include "itkImageLinearIteratorWithIndex.h" #include "itkConstNeighborhoodIterator.h" #include "itkMinimum...
ALGO
0.990463
7.109131
{ "github_metadata": { "branch": "master", "commit_count": 6, "repo_created_at": "2016-06-28T17:52: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": "de005b1c27...
b325a12a-0627-4af9-9583-dce947bf111e
ravi2320/GFG-POTD
156. Check for BST.cpp
/* Check for BST Difficulty: EasyAccuracy: 25.37%Submissions: 518K+Points: 2 Given the root of a binary tree. Check whether it is a BST or not. Note: We are considering that BSTs can not contain duplicate Nodes. A BST is defined as follows: The left subtree of a node contains only nodes with keys less than the node's ...
ALGO
0.999991
6.972417
{ "github_metadata": { "branch": "main", "commit_count": 463, "repo_created_at": "2024-01-01T10:28: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": "14387fe70b...
906d8c78-f78e-41d6-bdf0-7702b973679c
ddnn55/BodyScanner
Libraries/pcl-1.2-bodyscanner/surface/include/pcl/surface/mls.h
/* * Software License Agreement (BSD License) * * Point Cloud Library (PCL) - www.pointclouds.org * Copyright (c) 2010-2011, <NAME>, Inc. * * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * ...
ALGO
0.998487
6.602301
{ "github_metadata": { "branch": "master", "commit_count": 179, "repo_created_at": "2011-09-19T21:05:14.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 12, "forks": 2, "issues": 8, "pull_requests": 0 }, "file_meta": { "content_id": "f89d267...
89f6c590-cc3c-4549-9791-f36c185953fa
ishandutta2007/codeforces-i
i_love_tigersugar/normal/1198/B.cpp
#include<bits/stdc++.h> #define FOR(i, a, b) for (int i = (a), _b = (b); i <= _b; i++) #define FORD(i, b, a) for (int i = (b), _a = (a); i >= _a; i--) #define REP(i, n) for (int i = 0, _n = (n); i < _n; i++) #define FORE(i, v) for (__typeof((v).begin()) i = (v).begin(); i != (v).end(); i++) #define ALL(v) (v).begin(), ...
ALGO
0.999957
3.719074
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2024-04-11T05:39: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": "73232023fe56...
59d0f7ec-1e33-4299-b275-598d407d7e07
avocado51/Algorithm_PS
Simulation/15558.cpp
#include <iostream> #include <vector> #include <queue> using namespace std; //BOJ https://www.acmicpc.net/problem/15558 int dx[3] = {1, -1, 2}; string lines[2]; int n, k; int visited[2][100001]; typedef pair<int, int> pp; void bfs() { queue<pp> q; q.push(pp(0, 0)); //0은 왼쪽, 1는 오른쪽 int time = 0; //유저가...
ALGO
0.999992
3.794714
{ "github_metadata": { "branch": "master", "commit_count": 98, "repo_created_at": "2020-04-21T09:45:20.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 6, "pull_requests": 0 }, "file_meta": { "content_id": "a44b61cbe...
4bca9fa0-269b-4c71-849a-cb360c1a811e
Wil12Fred/Xcode-OpenGL
Prueba/main.cc
#include <GLUT/glut.h> #include <OpenGL/gl.h> #include <OpenGL/glu.h> #include "grafo.h" #include "delaunay.h" #include "aest.h" #define GLUT_DISABLE_ATEXIT_HACK #include <sstream> #include <fstream> #include <queue> #include <algorithm> #include <vector> #include <string> #include <iostream> #include <math.h> #defi...
ALGO
0.997996
3.453308
{ "github_metadata": { "branch": "master", "commit_count": 4, "repo_created_at": "2016-08-09T08:52: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": "33678ed358...
307828bb-691b-4c1e-8ec6-dc34aa59b7ce
aerimforest/Baekjoon
[3020] 개똥벌레.cpp
// [3020] 개똥벌레 // https://www.acmicpc.net/problem/3020 // 이분 탐색, 정렬 #include <vector> #include <algorithm> // lower_bound() #include <cstdio> using namespace std; int main(void) { /* cnt = 각 구간마다 개똥벌레가 파괴해야 하는 석순 & 종유석 개수 section = 개똥벌레가 지나갈 구간 min = 개똥벌레가 파괴하는 석순 & 종유석 개수의 최솟값 ans = min값을 가지는 구간...
ALGO
0.999961
3.91981
{ "github_metadata": { "branch": "master", "commit_count": 443, "repo_created_at": "2019-07-13T03:19: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": "ff2e0dae...
01b396d6-8619-4094-a719-40a333a0467a
niranjannayak5754/DS-ALGO
validParentheses.cpp
#include <iostream> #include <stack> #include <string> using namespace std; // Use the std namespace bool isBalanced(const string& str) { stack<char> st; for (char c : str) { if (c == '(' || c == '[' || c == '{') { st.push(c); } else if (c == ')' || c == ']' || c == '}') { ...
ALGO
0.991537
7.055623
{ "github_metadata": { "branch": "main", "commit_count": 93, "repo_created_at": "2023-08-25T13:11: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": "a4ab87e62b6...
a1af8cb3-2f9a-469d-9a62-d8faf3a6fe8a
justinfrankel/licecap
WDL/resample.cpp
/* WDL - resample.cpp Copyright (C) 2010 and later Cockos Incorporated This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to anyone to use this sof...
ALGO
0.972397
5.882484
{ "github_metadata": { "branch": "main", "commit_count": 3740, "repo_created_at": "2014-07-21T01:56:39.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 5466, "forks": 457, "issues": 97, "pull_requests": 5 }, "file_meta": { "content_id": "3ad...