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
b94bcdee-4ba2-4682-9433-b0d9c3c3b100
langtuandroid/SuperBaby
Classes/Round011_04.cpp
// // Round011_04.cpp // AbelLLExplorer // // Created by Administrator on 2015/4/9. // // #include "Round011_04.h" #include "StageScene.h" #include "StageData.h" #include "Actor.h" #include "SocialShareNode.h" #include "LeadingActor.h" #include "MyAudioEngine.h" #include "RoundUINode.h" #include "CustomMessage.h" ...
TOOL
0.976099
3.405578
{ "github_metadata": { "branch": "master", "commit_count": 6, "repo_created_at": "2017-08-07T07:25:29.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "dfcc6980a8...
021a766f-308f-4669-87e8-0bb2ebfca02b
Vaa3D/vaa3d_tools
released_plugins/v3d_plugins/bigneuron_siqi_stalker_v3d/lib/ITK_include/itkObjectToObjectMetric.h
/*========================================================================= * * Copyright Insight Software Consortium * * 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 * * ...
ALGO
0.976146
7.185409
{ "github_metadata": { "branch": "master", "commit_count": 7983, "repo_created_at": "2016-01-27T18:19:17.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 110, "forks": 70, "issues": 11, "pull_requests": 12 }, "file_meta": { "content_id": "2a5...
d61d3425-9746-445f-9ca3-361d31e31ea4
alexandraback/datacollection
solutions_2652486_0/C++/mi6091/c.cpp
#include <iostream> #include <cstdio> #include <algorithm> #include <cstring> #include <map> #include <set> #include <vector> using namespace std; //map<int, set<int> > cool; int a[520][10000], b[520]; int res[10000]; vector <int> all; int r, n, m , k; void solve () { cin >> r >> n >> m >> k; int i, j...
ALGO
0.999473
3.389546
{ "github_metadata": { "branch": "master", "commit_count": 58, "repo_created_at": "2017-03-08T11:33:58.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 4, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ae30300cb...
022d2fa7-4748-4eb7-964e-5451fb832e23
hareku/cpp-algorithm
lib/randomized/miller_rabin_primality_test.hpp
#ifndef LIB_RANDOMIZED_MILLER_RABIN_PRIMALITY_TEST_HPP #define LIB_RANDOMIZED_MILLER_RABIN_PRIMALITY_TEST_HPP 1 #include <bits/stdc++.h> #include "../math/mod_pow.hpp" namespace lib::randomized { // O(k log{3} n) bool miller_rabin_primality_test(long long n, int k = 20) { // n must be greater than 3. if(n ==...
ALGO
0.983564
6.105164
{ "github_metadata": { "branch": "master", "commit_count": 209, "repo_created_at": "2020-10-01T11:48: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": "0fa6abf8...
aed6184b-c262-416c-a193-c3e939ce3fa3
zmaker/arduino_cookbook
359-morse-completo/ricevitore2/ricevitore2.ino
#include "morse.h" #include "U8glib.h" U8GLIB_SSD1306_128X64 u8g(U8G_I2C_OPT_NONE|U8G_I2C_OPT_DEV_0); // I2C / TWI //U8GLIB_SSD1306_128X64 u8g(U8G_I2C_OPT_DEV_0|U8G_I2C_OPT_NO_ACK|U8G_I2C_OPT_FAST); // Fast I2C / TWI //U8GLIB_SSD1306_128X64 u8g(U8G_I2C_OPT_NO_ACK); // Display which does not send AC //U8GLIB_SSD130...
TOOL
0.925013
5.518588
{ "github_metadata": { "branch": "master", "commit_count": 409, "repo_created_at": "2018-05-28T19:46:44.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 251, "forks": 126, "issues": 2, "pull_requests": 1 }, "file_meta": { "content_id": "66f5...
94ec6efa-49f2-4d04-b62c-fcc7c9df9b9d
piyush1146115/Competitive-Programming
Atcoder 1/ABC 120 D - Decayed Bridges.cpp
/* * FILE: ABC 120 D - Decayed Bridges.cpp * * @author: <NAME> <piyush123kantidas[at]gmail[dot]com> * * LINK: * * DATE CREATED: 14.08.2019 23:26:32 +06 * * DESCRIPTION: * * DEVELOPMENT HISTORY: * Date Version Description * -------------------------------------------------------------- * 14-08-...
ALGO
0.999991
4.085273
{ "github_metadata": { "branch": "master", "commit_count": 68, "repo_created_at": "2019-09-30T18:09:54.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 5, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "07aaffc5d...
d2fb4339-03c4-46d0-b02f-cfc356485e4c
jiangzhijiangzhi/DataStruct
Linked List/线性表.cpp
#include "stdafx.h" int _tmain(int argc, _TCHAR* argv[]) { return 0; } # include <stdio.h> # include <stdlib.h> /*---------------线性表动态分配顺序存储结构-----------------*/ # define LIST_INIT_SIZE 100 //线性表存储空间初始分配量 # define LISTINCREMENT 10 //线性表存储空间增加量 /*---------------------------------------------------------...
ALGO
0.996742
3.42019
{ "github_metadata": { "branch": "master", "commit_count": 7, "repo_created_at": "2019-10-17T06:23:13.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "9ce54d20c1...
30b126f1-4be1-414d-8f0e-af5e45513b92
kamlesh-it/Graph_Boost
Provisional_Graph_Atom_BGL.cpp
#include <iostream> #include<vector> #include <boost/graph/adjacency_list.hpp> #include <boost/graph/graphviz.hpp> #include<boost/graph/graph_concepts.hpp> class Atom { public: char element; // C for carbon, O for oxygen int index; // C1, O2 double x,y,z; Atom() {} Atom (char e, int i, double x_, do...
ALGO
0.925185
4.188931
{ "github_metadata": { "branch": "Grpah_Boost", "commit_count": 9, "repo_created_at": "2017-03-31T14:44:17.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 1, "issues": 0, "pull_requests": 1 }, "file_meta": { "content_id": "69723...
5ead4102-0916-497f-a182-1009ac6ae0a7
andreimargeloiu/Competitive-programming-problems
JUDETE.cpp
# include <vector> # include <algorithm> # include <fstream> # define NR 150 # define INF 999999999 using namespace std; ifstream f("judete.in"); ofstream g("judete.out"); vector <int> v[NR]; int i,j,n,m,K,x,y; int dp[NR][NR]; // dp[i][j] = marimea maxima T a unui judet din subarborele lui i // astfel incat ...
ALGO
0.999661
3.567028
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2017-09-17T16:24:39.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 67, "forks": 59, "issues": 1, "pull_requests": 0 }, "file_meta": { "content_id": "8e8215cc...
b76d0673-eabc-4dc0-9626-4c88457adfa2
maanaskarwa/cp-sols
narrowartgallery.cpp
/* * Author: <NAME> * It is ok to share my code anonymously for educational purposes * */ #include <bits/stdc++.h> using namespace std; // dp[i][k][r] = max value till row i having left out k rooms, // and including what of this row? r = 0 -> left only, r = 1 -> right only // int dp[200][200][3]; int main() { ...
ALGO
0.999845
3.942678
{ "github_metadata": { "branch": "main", "commit_count": 4, "repo_created_at": "2024-09-04T23:46: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": "da16c02fbcb9...
4d011b6c-cdff-445d-9c06-82f777c639bb
J-woooo/Homework
Algorithm/Week11/BWT.cpp
//2015112128 배진우 #include <iostream> #include <string> #include <cstdlib> #include <vector> #include <algorithm> using namespace std; string** findBWT(string& T); string* stringSort(string*& s); string** sort(string** s, int length); void stringSwap(string& a, string& b); string recoveryString(string** s, int length);...
ALGO
0.999964
3.972681
{ "github_metadata": { "branch": "master", "commit_count": 8, "repo_created_at": "2019-09-23T05:37: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": "eb9ef67a2b...
6c49a3aa-6459-4041-a0d9-9eb76ff1fca8
kamyu104/LeetCode-Solutions
C++/apply-discount-to-prices.cpp
// Time: O(n) // Space: O(1) // string class Solution { public: string discountPrices(string sentence, int discount) { const auto& format = [&](const auto& x) { string result; const auto& integers = to_string(stoll(x) * (100 - discount) / 100); const auto& decimals = to...
ALGO
0.967918
4.889345
{ "github_metadata": { "branch": "master", "commit_count": 19395, "repo_created_at": "2018-10-11T17:38:35.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 4939, "forks": 1616, "issues": 1, "pull_requests": 55 }, "file_meta": { "content_id": ...
9fdc5dfc-83f8-46af-a4bd-9fb7dd43bb5e
edwinho/acm
1091.cpp
#include <iostream> #include <queue> using namespace std; #include <stdio.h> typedef struct point{ int x,y; int count; }point; queue<point>q; int map[9][9]; //棋盘大小 int b_x,b_y; //终点坐标 int move[8][2] = { {1,2},{2,1},{2,-1},{1,-2},{-1,-2},{-2,-1},{-2,1},{-1,2} }; //可能移动的方向 //用广度优先遍历搜索最短路径 int bfs(point s){ map...
ALGO
0.99971
3.960122
{ "github_metadata": { "branch": "master", "commit_count": 36, "repo_created_at": "2012-10-04T11:21:43.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "6054367db...
1d4b8457-9737-442f-be9d-5e2417a2c55b
drlongle/leetcode
algorithms/problem_0265/solution.cpp
/* 265. Paint House II Hard There are a row of n houses, each house can be painted with one of the k colors. The cost of painting each house with a certain color is different. You have to paint all the houses such that no two adjacent houses have the same color. The cost of painting each house with a certain color is...
ALGO
0.999919
6.206613
{ "github_metadata": { "branch": "master", "commit_count": 1430, "repo_created_at": "2017-02-08T14:00: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": "3d536ad...
aa443894-3f15-4c19-b3ff-016904926b19
yftsai/uva-online-judge
contest_volumes/volume_106/10689.cpp
// #cycle_detection #include <iostream> #include <cmath> using namespace std; int main() { uint16_t test_count, m; pair<uint16_t, uint16_t> ab; uint32_t n; for (cin >> test_count; test_count > 0 && cin >> ab.first >> ab.second >> n >> m; --test_count) { const uint16_t d = uint16_t(pow(10, m)); ...
ALGO
0.999534
3.592586
{ "github_metadata": { "branch": "master", "commit_count": 188, "repo_created_at": "2016-01-28T02:37: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": "66ef7dcd...
374d97c1-b04b-4ab4-b4c8-c5f26afa54a4
dubzzz/various-algorithms
websites/topcoder-smartwordtoy/aim.hpp
/* The aim of this topic is: TopCoder: https://community.topcoder.com/stat?c=problem_statement&pm=3935&rd=6532 Problem: The toy company "I Can't Believe It Works!" has hired you to help develop educational toys. The current project is a word toy that displays four letters at all times. Below each l...
ALGO
0.999865
4.742991
{ "github_metadata": { "branch": "main", "commit_count": 389, "repo_created_at": "2016-12-24T18:18:51.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 1, "issues": 1, "pull_requests": 0 }, "file_meta": { "content_id": "c2ce27cd9c...
b244ceac-5acd-4b9a-a3a5-239b84c5ad30
bisonliao/daydayup
acm/matrix01.cpp
/* 给定一个由 0 和 1 组成的矩阵 mat?,请输出一个大小相同的矩阵,其中每一个格子是 mat 中对应位置元素到最近的 0 的距离。 两个相邻元素间的距离为 1 。 例如: 输入:mat = [[0,0,0],[0,1,0],[1,1,1]] 输出:[[0,0,0],[0,1,0],[1,2,1]] */ #include <stdlib.h> #include <string.h> #include <stdio.h> #include <string> #include <vector> #include <map> #include <deque> #include <algorithm> #include <std...
ALGO
0.999982
4.66957
{ "github_metadata": { "branch": "master", "commit_count": 246, "repo_created_at": "2017-02-17T08:32:31.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 2 }, "file_meta": { "content_id": "9b807cfa...
f5595953-56aa-48e1-8ae3-4e96b516a010
faiyazkarim-cse19/190041116-CSE-4302
Lab 12/116_Task3.cpp
#include <bits/stdc++.h> using namespace std; const int MAX = 2; template <typename T> class my_stack { private: T arr[MAX]; int top; public: my_stack() : top(-1) { } class Overflow { }; class Underflow { }; int size() { return top; } void push(...
ALGO
0.970605
4.088375
{ "github_metadata": { "branch": "main", "commit_count": 25, "repo_created_at": "2021-07-03T12:30: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": "df5f3e15879...
81d629c3-8535-425f-a6f5-e3c2c4328224
wetstreet/bunny-renderer
src/common/Utils.cpp
#include "Utils.h" #include <fstream> #define GLM_ENABLE_EXPERIMENTAL #include "glm/gtx/matrix_decompose.hpp" #ifdef __DEVELOPMENT__ std::string RESOURCE_PATH("../../../"); // local resource path #else std::string RESOURCE_PATH(""); // relative resource path #endif std::string GetFileNameFromPath(const std::string& ...
TOOL
0.959075
4.997871
{ "github_metadata": { "branch": "main", "commit_count": 120, "repo_created_at": "2021-07-17T13:48:45.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 7, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "58c0d79f32...
536932c7-2b96-463d-90a8-940d2a24f64b
sadiebean00/GCP-Assignment
Geometry.cpp
#include "Geometry.h" #include "Sphere.h" #include "Ray.h" //Constructor class for Geometry, which will remain empty Geometry::Geometry() { } /* * The calculation uses to find the intersect point in order * for the ray tracer to work */ IntersectData Geometry::currentIntersectionPoint(Ray _ray, std::shared_ptr<Sphe...
ALGO
0.937112
4.200301
{ "github_metadata": { "branch": "main", "commit_count": 2, "repo_created_at": "2023-11-10T10:26: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": "71004b17d590...
89020ccf-d504-461f-b8ff-994063ded31f
shun2029/algorithm
sort/radix_sort.cpp
#include <iostream> #include <new> #include <typeinfo> template<class RandomAccessIterator> void radix_sort(RandomAccessIterator first, RandomAccessIterator last, long long digit = 1) { if (first == last) { return; } auto val = *first; using type = decltype(val); if (typeid(val) != typeid...
ALGO
0.99913
4.312599
{ "github_metadata": { "branch": "master", "commit_count": 29, "repo_created_at": "2019-09-07T14:29:03.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "274ee2f4f...
0e3e5818-e9c2-4b7f-8217-e119af591dd1
bishnumishra98/DSA
Leetcode&Gfg/01. Arrays/MaximumAverageSubarrayI.cpp
// Leetcode: 643. Maximum Average Subarray I ---> You are given an integer array nums consisting of n elements, // and an integer k. // Find a contiguous subarray whose length is equal to k that has the maximum average value and return this value. // Any answer with a calculation error less than 10^-5 will be accep...
ALGO
0.999903
6.857506
{ "github_metadata": { "branch": "main", "commit_count": 1328, "repo_created_at": "2023-09-03T14:09: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": "c27a3566f...
598cda7e-3de4-4783-951c-7c51b39b5e24
facardoso-sudo/2024
CoppeliaSim + ROS/controle_posicao_3D/src/stingelin_ROBOVIS.cpp
#include "ros/ros.h" #include "std_msgs/String.h" #include "geometry_msgs/Twist.h" #include "turtlesim/Pose.h" #include "nav_msgs/Odometry.h" #include <iostream> #include <math.h> #include <tf/tf.h> using namespace std; turtlesim::Pose feedback; turtlesim::Pose _feedback; turtlesim::Pose _feedback_; nav_msgs::Odo...
TOOL
0.914454
3.658152
{ "github_metadata": { "branch": "main", "commit_count": 18, "repo_created_at": "2024-01-10T15:53: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": "0a1e1de344c...
5bc182ed-50fc-48a0-9bd2-f2995065ad75
scribusproject/scribus
scribus/third_party/lib2geom/poly-dk-solve.cpp
#include "poly-dk-solve.h" #include <iterator> /*** implementation of the Durand-Kerner method. seems buggy*/ std::complex<double> evalu(Poly const & p, std::complex<double> x) { std::complex<double> result = 0; std::complex<double> xx = 1; for(unsigned i = 0; i < p.size(); i++) { result += p[i]...
ALGO
0.999885
4.690388
{ "github_metadata": { "branch": "master", "commit_count": 21671, "repo_created_at": "2015-05-09T15:29:34.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 479, "forks": 115, "issues": 44, "pull_requests": 12 }, "file_meta": { "content_id": "0...
d9ef13d2-f548-4bbf-bab3-20fc5f9c981b
Aryanlanghanoja/100_Days_Coding_Challenge
09-30-2024/Set_Matrix_Zero.cpp
#include <bits/stdc++.h> using namespace std; int main() { // your code goes here int n,m; cin>>n>>m; int arr[n][m]; for(int i=0;i<n;i++){ for(int j=0;j<m;j++){ cin>>arr[i][j]; } } int row[n] = {0}; // To mark rows to be zeroed int col[m] = {0}; // To mark columns to be zeroed fo...
ALGO
0.99985
4.142064
{ "github_metadata": { "branch": "main", "commit_count": 140, "repo_created_at": "2024-09-05T12:45: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": "3a6e6b8429...
40b029d7-e910-4e5f-89d8-aaa00110bf9f
newaetech/chipwhisperer
software/chipwhisperer/analyzer/attacks/cpa_algorithms/c_accel/CPAProgressive.cpp
/* Copyright (c) 2015, NewAE Technology Inc All rights reserved. Authors: <NAME> Find this and more at newae.com - this file is part of the chipwhisperer project, http://www.assembla.com/spaces/chipwhisperer This file is part of chipwhisperer. chipwhisperer is free software: you can redistribute it and...
ALGO
0.998124
5.370237
{ "github_metadata": { "branch": "develop", "commit_count": 5625, "repo_created_at": "2014-08-31T13:36:31.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 1266, "forks": 309, "issues": 31, "pull_requests": 8 }, "file_meta": { "content_id": "3...
25006a9c-0470-4de4-b138-d7898c6146ff
iupriser/AugustLeetCodingChallengeCPP
1.1.DetectCapital.cpp
class Solution { public: /* bool detectCapitalUse(string word) { int capCnt = count_if(word.begin(), word.end(), [](char c) { return c <= 'Z'; }); return !capCnt || capCnt == word.size() || (capCnt == 1 && word[0] <= 'Z'); } */ bool detectCapitalUse(string word) { for (int i...
ALGO
0.999873
5.342747
{ "github_metadata": { "branch": "master", "commit_count": 7, "repo_created_at": "2020-08-02T15:02:43.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "22047de8c3...
fba5ea39-0d88-4c49-9c65-8a0f0f6a50b8
ibudiselic/contest-problem-solutions
tc 160+/PermutationSignature.cpp
#include <algorithm> #include <cassert> #include <cstdio> #include <iostream> #include <sstream> #include <string> #include <vector> #include <cstring> using namespace std; class PermutationSignature { public: vector <int> reconstruct(string sig) { int n = sig.size(); bool used[51] = {0}; ve...
ALGO
0.999918
3.996559
{ "github_metadata": { "branch": "master", "commit_count": 75, "repo_created_at": "2011-08-14T11:43:37.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 8, "forks": 4, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "c996c919e...
8eab1045-276c-4040-95cc-dea7ceddb3de
gou4shi1/oj
cf785A.cpp
/************************************************************************ * File Name : cf785A.cpp * Purpose : water * Creation Date : 2017年04月22日 * Last Modified : 2017年04月22日 星期六 15时44分56秒 * Created By : <EMAIL> ************************************************************************/ #include <iostream> #include <cs...
ALGO
0.998648
3.586011
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2018-06-19T03:20: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": "ef8b073364...
bfb0b8ee-befe-471e-8868-728ea0ff4874
kalebgrove/UPC-FIB
1r/PRO1/P7/X41120/X41120.cc
#include <iostream> #include <vector> using namespace std; vector<int> calcula_cims(const vector<int>& v) { vector<int> cims; for(int i = 1; i < v.size() - 1; ++i) { if(v[i] > v[i-1] and v[i] > v[i+1]) cims.push_back(v[i]); } return cims; } int main() { int n; cin >> n; vecto...
ALGO
0.999995
4.005144
{ "github_metadata": { "branch": "main", "commit_count": 81, "repo_created_at": "2024-03-18T18:22:20.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "504d3f2c8ed...
e7b8af48-2ff3-47fb-92ce-3cf7f236d2ae
kimyuuum/algorithm
2020/무제 폴더/4.cpp
#include <iostream> #include <string> #include <vector> using namespace std; vector<int> gift_cards = {5, 4, 5, 4, 5}; vector<int> wants = {1, 2, 3, 5, 4}; const int MAX = 100001; int solution(vector<int> gift_cards, vector<int> wants) { int answer = 0; bool get[MAX] = { false, }; for (int i = 0; i < gif...
ALGO
0.999961
4.605027
{ "github_metadata": { "branch": "master", "commit_count": 247, "repo_created_at": "2019-12-11T02:00: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": "1ff47533...
ae72c852-261f-4a1d-b3ca-0d99ee7b78e7
emilyju0314/gpt_code_plagiarism
dataset/code_content_classifier/allpro_train/0_0_3893.cpp
// C++ program to find the maximum distance between two points #include <bits/stdc++.h> using namespace std; // Function to calculate the distance between two points double calculateDistance(int x1, int y1, int x2, int y2) { return sqrt(pow(x2 - x1, 2) + pow(y2 - y1, 2)); } int main() { int n, k; cin >> n...
ALGO
0.999974
6.010148
{ "github_metadata": { "branch": "main", "commit_count": 50, "repo_created_at": "2024-04-28T03:59: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": "2330a0c08a0...
5f11c767-ede5-4433-8585-2c05b567b9cf
Edgarrrrrr/T2-RELION
src/jaz/optics/magnification_helper.cpp
/*************************************************************************** * * Author: "<NAME>" * MRC Laboratory of Molecular Biology * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; e...
ALGO
0.998845
4.152856
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2025-04-28T08:03: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": "37977f7c88e1...
046ec86c-6244-46e7-bcbb-2ddc60a1b131
AmirhosseinRHT/Parallel-Programming-Course-Projects
CA2 - OpenMP/Q3/main.cpp
#include <iostream> #include <chrono> #include <omp.h> const long long SIDE = 20000; using namespace std; uint64_t micros(){ uint64_t us = chrono::duration_cast<chrono::microseconds>( chrono::high_resolution_clock::now().time_since_epoch()) .count(); return us; } long long calcPiSe...
ALGO
0.999894
5.765039
{ "github_metadata": { "branch": "main", "commit_count": 102, "repo_created_at": "2024-10-13T16:29:16.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "a140fba2f7...
f8019034-5475-4b8a-a389-e4b07463b79b
XyyStudyHard/practice_code
edict_distance.cpp
#include <iostream> #include <vector> #include <string> #include <cstdio> using namespace std; int Min(int a, int b, int c) { if (a > b) { if (b > c) return c; else return b; } else { if (a < c) return a; else return c; } } int edit(string s1, string s2) { int len1 = s1.size(); int len2 ...
ALGO
0.99998
3.897046
{ "github_metadata": { "branch": "master", "commit_count": 74, "repo_created_at": "2013-10-10T02:12:52.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "d158582c9...
b0cc80c6-1170-412c-8512-ad6121fcec81
TheWrecker/GameDev
source/utils/frustrum.cpp
#include "defs_world.h" #include "frustrum.h" //constexpr float SEGMENT_HALF_LENGTH = SEGMENT_LENGTH / 2.0f; Frustrum::Frustrum() :planes() { } Frustrum::~Frustrum() { } void Frustrum::CalculateFrustrum(DirectX::CXMMATRIX viewProjectionMatrix) { using namespace DirectX; XMVECTOR _v = {}; XMFLOAT4X4 _matrix =...
ALGO
0.942926
5.873127
{ "github_metadata": { "branch": "master", "commit_count": 98, "repo_created_at": "2023-02-04T12:33: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": "0d2df4b77...
6fa031f3-fe31-415e-b999-01f4bda4667f
0x1050/at
finished/w3_2fractional_knapsack.cpp
#include <iostream> #include <iomanip> struct Item { double weight; double value; double value_by_weight; Item * next; }; class Priority_Items { private: Item * head; public: Priority_Items() {head = nullptr;} void push(double weight, double value) { //creat...
ALGO
0.999739
4.927752
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2020-09-02T18:35:03.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "e8c3d285ca...
29881567-28dc-4883-8c37-7491c709c129
whutweihuan/leetcode
336PalindromePairs/336PalindromePairs.cpp
/*********************************************** # # Filename: 336PalindromePairs.cpp # # Author: weihuan -<EMAIL> # Create: 2018-11-17 17:05:06 # Last Modified: 2018-11-17 17:05:06 # Link: https://leetcode.com/problems/palindrome-pairs/ # Description: --- # Given a list of unique words,...
ALGO
0.999653
6.018348
{ "github_metadata": { "branch": "master", "commit_count": 24, "repo_created_at": "2018-11-17T04:25: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": "f219d32b7...
35b3617e-43cc-4b8a-96c9-35e7380b3528
xantares/ahmed
Include/matrix.h
/* AHMED -- Another software library on Hierarchical Matrices for Elliptic Differential equations Copyright (c) 2012 <NAME> You should have received a copy of the license along with this software; if not, see AHMED's internet site. */ #ifndef MATRIX_H #define MATRIX_H #include <assert...
ALGO
0.996964
5.670544
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2013-09-10T19:31:14.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 22, "forks": 11, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "dd2354ef...
83d167c1-5ac4-466e-b57f-0131f8abb318
JoseJuanSE/Algorithm_Analysis
HUffman/Comprime.cpp
#include<bits/stdc++.h> #include "Arbol.hpp" using namespace std; string codes[256]; //Recorrido en inorden para obtener el codigo de cada caracter, de tal forma que despues cuando se quiera obtener el camino en el arbol a un caracter, no se recorra el arbol, solo se consulte el arreglo. //Se recibe el arbol a recor...
ALGO
0.999732
4.347621
{ "github_metadata": { "branch": "master", "commit_count": 14, "repo_created_at": "2021-08-27T00:58:54.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "f61e16cfd...
ed8426f5-dd4d-4786-b4f7-8bc764fc049a
khanhbrandy/7-days-Cpp-revision
list.cpp
#include <iostream> #include <list> #include <string> #include <thread> using namespace std; bool isDinhDangSoNguyen(string str) { if (str.length() == 0) { return false; } else { int index = 0; if (str[0] == '-') { index = 1; if (str.length() == 1) { return false; } } for (int i = index; i <...
TOOL
0.961372
3.230834
{ "github_metadata": { "branch": "main", "commit_count": 6, "repo_created_at": "2022-06-12T04:52:36.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "52918f4c8aaa...
d6797576-7789-42ed-a63d-8ed13fa3a145
exopyl/cg
src/cgmesh/extracted_line.h
#ifndef __EXTRACTED_LINE_H__ #define __EXTRACTED_LINE_H__ #include "../cgmath/cgmath.h" class Cextracted_line { friend class Cset_lines; public: enum weight_method { WEIGHT_METHOD_ = 0 }; public: Cextracted_line (Vector3f _pluecker1, Vector3f _pluecker2, Vector3f _begin, Vector3f _end, int _n_v...
ALGO
0.979179
5.679815
{ "github_metadata": { "branch": "main", "commit_count": 82, "repo_created_at": "2022-05-30T13:29: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": "e9dbc4a3642...
0a424cf1-8e85-46f2-8da4-43a840756506
Kitware/VTK
Common/DataModel/vtkBiQuadraticTriangle.cxx
// SPDX-FileCopyrightText: Copyright (c) <NAME>, <NAME>, <NAME> // SPDX-License-Identifier: BSD-3-Clause #include "vtkBiQuadraticTriangle.h" #include "vtkDoubleArray.h" #include "vtkLine.h" #include "vtkMath.h" #include "vtkObjectFactory.h" #include "vtkPoints.h" #include "vtkQuadraticEdge.h" #include "vtkTriangle.h" ...
ALGO
0.998123
4.855149
{ "github_metadata": { "branch": "master", "commit_count": 94968, "repo_created_at": "2010-04-27T15:12:58.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 2910, "forks": 1246, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b...
6c3e524b-803a-4bad-a52f-2265361931bd
bryand1/nqueens
nqueens.cpp
/** * N-Queens * Purpose: Recursion and backtracking exercise * * @author <NAME> * @version 0.1 03/25/2018 * * On an N * N chess board, can you place N queens * on the board so that no queen is under attack? * * Usage: ./nqueens [N] */ #include <iostream> void print_board(int *board, int N) { for (int i =...
ALGO
0.999768
5.239766
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2018-03-26T01:46: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": "1cc266b9a1...
8c88fa6b-1eb7-402b-80d3-913aaff1336c
jakefish18/competitive_programming_algorithms
stress/gen.cpp
#include <bits/stdc++.h> using namespace std; template<typename key> using ve = std::vector<key>; mt19937 rnd(chrono::steady_clock::now().time_since_epoch().count()); typedef long long ll; typedef long double ld; #define int long long ll rand(ll l, ll r){ return l + (rnd() % (r - l + 1)); } signed main(){ ...
ALGO
0.994564
3.637262
{ "github_metadata": { "branch": "main", "commit_count": 2, "repo_created_at": "2024-01-19T03:33:11.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "f7c9bcbfa2ec...
b7164077-3bcf-4f09-846e-3ae37a3c22e0
weaver9651/coding
complete/baekjoon5014.cpp
#include <cstdio> #include <queue> using namespace std; int F, S, G; // F : height, S : start, G : goal int U, D; bool visit[1000001] = {false, }; int counter[1000001] = {0, }; void In() { scanf("%d%d%d%d%d", &F, &S, &G, &U, &D); } bool isInside(int x) { if (x >= 1 && x <= F) return true; else return...
ALGO
0.999912
3.858885
{ "github_metadata": { "branch": "master", "commit_count": 411, "repo_created_at": "2019-02-18T06:27:56.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "a7f215f0...
ed45cf7b-3f28-4bd0-a581-b36479bc2b35
fourfire11/Network_Optimization-C-
cpp file/Dijkstra_dial.cpp
/* This code can be compiled and run ok. purpose: This is to read the network data from txt/sp format, and output 1-ALL shortest paths of source node. input file: test1.sp (there is no negative cycle and the largest length of arc is small) compile: g++ -o h34051178_hw3_2_Dijkstra_dial h340...
ALGO
0.995809
3.763026
{ "github_metadata": { "branch": "master", "commit_count": 6, "repo_created_at": "2020-04-27T02:59: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": "d695eee8b4...
2ea2b3bc-d0e0-40b3-9611-62c26126b786
PASSIONLab/CombBLAS
ReleaseTests/ReduceTest.cpp
/****************************************************************/ /* Parallel Combinatorial BLAS Library (for Graph Computations) */ /* version 1.6 -------------------------------------------------*/ /* date: 11/15/2016 --------------------------------------------*/ /* authors: <NAME>, <NAME>, <NAME> ------------*/ /*...
ALGO
0.998083
5.415222
{ "github_metadata": { "branch": "master", "commit_count": 4785, "repo_created_at": "2020-08-14T05:56:52.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 79, "forks": 29, "issues": 11, "pull_requests": 2 }, "file_meta": { "content_id": "15f0a...
27ad9db7-e1b6-4dbd-8aee-a69c1a32fb91
chat-code/leetcode-everyday
archive/202203/20220324_661/abel.cpp
// Date: Sat Mar 26 11:26:52 2022 #include <cstdio> #include <cstring> #include <cstdlib> #include <cmath> #include <climits> #include <iostream> #include <sstream> #include <string> #include <vector> #include <queue> #include <stack> #include <map> #include <set> #include <algorithm> #include <utility> #include <fun...
ALGO
0.999828
4.526512
{ "github_metadata": { "branch": "master", "commit_count": 1880, "repo_created_at": "2019-12-12T12:17:12.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 9, "forks": 5, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "35a36ec7...
ac8e3a49-1e9d-4648-99a7-f3459097a382
spicydog/CPE610-parallel-and-distributed-processing
Assignment 3 Sobel Edge Detector on CUDA/Image Reader/opencv/main.cpp
// Example showing how to read and write images #include <opencv2/opencv.hpp> #include <opencv2/highgui/highgui.hpp> #include <opencv/cvaux.h> #include <math.h> int threshold = 30; void generateInputFile() { cv::Mat img = cvLoadImage("/Users/spicydog/Desktop/opencv/original.jpg", 1); uint8_t* pixelPtr = ...
TOOL
0.930851
4.158757
{ "github_metadata": { "branch": "origin", "commit_count": 19, "repo_created_at": "2014-09-03T03:36:54.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "3ca562431...
0625bc2b-ba45-4fa0-a76b-a1f281f66782
jldleon/data-structures-algorithms-CIMAT
updatableBinaryHeap.cpp
/* Tarea 1. Updatable Priority Queue Programming and Algorithms 2. CIMAT <NAME> */ #include <iostream> #include <vector> #include <unordered_map> #include <algorithm> #include <sstream> template <class TPriority, class TKey> class UpdatableHeap { private: struct Node { TPriority priori...
ALGO
0.999392
5.544967
{ "github_metadata": { "branch": "main", "commit_count": 2, "repo_created_at": "2024-01-31T21:40: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": "028b383ca3f7...
7a2c39f3-e089-4aae-b531-fa2d3130a786
crevee/baekjoon-cpp
Gold/2098.cpp
//BaekJoon_2098 //외판원 순회 /* * 제한 시간 : 24ms / 1s * 메모리 제한 : 6116KB / 128MB * 정답 비율 : 27.338% */ #include <iostream> #include <algorithm> using namespace std; int n; int w[16][16]; int dp[16][1 << 16]; int TSP(int c, int v) { if (v == (1 << n) - 1) { return w[c][0] == 0 ? 987654321 : w[c][0]; } if (dp[c][v] !=...
ALGO
0.99997
4.540997
{ "github_metadata": { "branch": "main", "commit_count": 1083, "repo_created_at": "2022-06-01T15:57: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": "82910b4dd...
7b08c064-3bea-41d5-a72e-8d106ba116c9
ahtih/photoproc
color-patches-detector.hpp
#include <Magick++.h> class color_patches_detector_t { inline static float color_sum(const Magick::PixelPacket &pp) { return pp.red + pp.green + pp.blue; } struct color_summer_t { Magick::PixelPacket min_color,max_color; double r,g,b; uint count; color_summer_t(void) : min_color(Magick::Color( ...
ALGO
0.974065
6.128788
{ "github_metadata": { "branch": "master", "commit_count": 126, "repo_created_at": "2018-10-20T10:08: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": "653c03bb...
9e438823-3b6e-45a2-8de2-ca41934a2938
dansimina/Fundamental-Algorithms-Labs
Tema2 - Construiere heap si heapsort/main.cpp
/* * <NAME> * Grupa: 2 * * Am implementat build heap bottom-up folosind functia de heapify, heapsort si build heap top-down folosind push heap. * * Heapify functioneaza in felul urmator: * pentru un element dat verifica daca acesta e mai mare decat fiul stang sau fiul drept. * apoi daca unul e mai...
ALGO
0.999783
4.845326
{ "github_metadata": { "branch": "main", "commit_count": 30, "repo_created_at": "2023-12-04T10:30:11.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "43011244369...
6ea25db6-2ef0-4283-a506-cd47ff02ce18
patel-kruti/Leetcodes
Hard_Level_using_Cpp/Arrays/42. Trapping Rain Water.cpp
// Problem - 42. Trapping Rain Water // Link - https://leetcode.com/problems/trapping-rain-water/ // Difficulty - Hard // Topic - Array, Two Pointers, Stack // Time Complexity - O(n) // Space Complexity - O(1) // Solution - Two Pointers class Solution { public: int trap(vector<int>& height) { int waterTrapp...
ALGO
0.999997
7.040497
{ "github_metadata": { "branch": "main", "commit_count": 67, "repo_created_at": "2024-11-25T03:11: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": "e035346d1c8...
77884850-9322-462a-82d7-3f0a0f56e5aa
abhishek18124/PPCPPSept2022
05 - January/Lecture 31/005LinkedList_BubbleSort.cpp
#include<iostream> using namespace std; class ListNode { public: int val; ListNode* next; ListNode(int val) { this->val = val; this->next = NULL; } }; void insertAtHead(ListNode*& head, int val) { ListNode* n = new ListNode(val); n->next = head; head = n; } void printLinkedList(ListNode* head) { ...
ALGO
0.999989
5.157108
{ "github_metadata": { "branch": "main", "commit_count": 59, "repo_created_at": "2022-09-09T01:12:41.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 9, "forks": 8, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b7fdbfc1068...
09df264b-f123-4523-8f8b-e92a05b41aec
webserver3315/Desktop_PS_BOJ
PS_BOJ/BOJ15664.cpp
/* N과 M 10 조합 */ #include <iostream> #include <set> #include <map> #include <deque> #include <vector> #include <queue> #include <array> #include <string> #include <algorithm> #include <cmath> #include <cstdio> #include <ctime> #include <climits> #define endl '\n' //#define X first //#define Y second //typedef pair <in...
ALGO
0.999988
4.33126
{ "github_metadata": { "branch": "master", "commit_count": 63, "repo_created_at": "2020-02-21T12:37: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": "5dc3d9196...
9157bb6a-f928-439f-95b5-a24820864047
xiabinyu/Slam_Cerasus
src/xtrsm.cpp
// // Academic License - for use in teaching, academic research, and meeting // course requirements at degree granting institutions only. Not for // government, commercial, or other organizational use. // File: xtrsm.cpp // // MATLAB Coder version : 4.1 // C/C++ source code generated on : 23-Sep-2019 13:55...
ALGO
0.999768
4.944698
{ "github_metadata": { "branch": "master", "commit_count": 9, "repo_created_at": "2019-08-17T06:03: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": "ed8f480e96...
8a1240eb-5d6c-446a-8565-86634b7858d8
OI-wiki/OI-wiki
docs/basic/code/radix-sort/radix-sort_1.cpp
#include <algorithm> #include <cstdint> #include <stack> #include <tuple> #include <vector> using std::copy; // from <algorithm> using std::make_tuple; using std::stack; using std::tie; using std::tuple; using std::vector; using u32 = uint32_t; using u64 = uint64_t; using u32ptr = u32*; void MSD_radix_sort(u32ptr f...
ALGO
0.999891
4.511135
{ "github_metadata": { "branch": "master", "commit_count": 12101, "repo_created_at": "2018-07-11T03:28:14.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 23612, "forks": 4310, "issues": 112, "pull_requests": 9 }, "file_meta": { "content_id":...
459d0b45-b88b-40c7-bdfd-794d3a81fc9a
shihyu/GraduationProject
HCLib/HCPhysical.cpp
#include "HCPhysical.h" int HCPhysical::Find_Bounding_Box_Poly2D(POLYGON2D_PTR poly, float &min_x, float &max_x, float &min_y, float &max_y) { // this function finds the bounding box of a 2D polygon // and returns the values in the sent vars // is this poly valid? if (poly->num_verts ==...
ALGO
0.974734
5.146947
{ "github_metadata": { "branch": "master", "commit_count": 95, "repo_created_at": "2016-09-19T10:32:43.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ded5de4eb...
5942a45e-2b1a-4b85-94c8-befbf6117658
MireleSCos/LP1
Tiago/Roteiro1/RQ4.cpp
//Questão 4 do primeirop roteiro - <NAME> //<NAME> #include <iostream> #include <cstdlib> #include <time.h> using namespace std; float calcPerc(int votos, int cont){ return ((float)votos * 100) / cont; } int main() { int votos[24] = {}; int voto,i, cont, maisvot, quantvoto; cont = maisvot = 0; ...
ALGO
0.994286
4.114518
{ "github_metadata": { "branch": "master", "commit_count": 35, "repo_created_at": "2019-11-06T18:07:10.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "ea906ff85...
ae1075a3-421e-4654-b684-811bcd9d98ce
yaroslawhan/sorts_Khanewskiy_tm
sort_Khanewskiy_tm/ABCsort_by_Ezhov.cpp
#include "sort_algorithms.h" #include <iostream> #include <string> #include <vector> #include <sstream> #include <clocale> constexpr int alphamin = 0; constexpr int alphamax = 255; char GetNextField(const std::vector<std::string>& data, long record_no, int level) { if (level - 1 < data[record_no].size()) ...
ALGO
0.999982
4.885241
{ "github_metadata": { "branch": "main", "commit_count": 19, "repo_created_at": "2024-10-17T14:26: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": "82a13ac87ed...
ba069b19-5720-4faa-9452-6d93ffaf0d3e
Starbow-Break/Problem-Solving
백준/Platinum/2494. 숫자 맞추기/숫자 맞추기.cc
#include <iostream> #include <algorithm> #include <vector> #include <string> #include <queue> #include <stack> #include <deque> #include <list> #include <map> #include <cmath> #include <iomanip> #define MAX_N 10'000 using namespace std; typedef long long ll; typedef pair<int, int> pii; typedef pair<ll, ll> pll; typede...
ALGO
0.999981
3.345036
{ "github_metadata": { "branch": "main", "commit_count": 1435, "repo_created_at": "2022-11-10T13:00: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": "38ad3601b...
73db5451-b189-414b-b397-f92802393970
alexandraback/datacollection
solutions_5670465267826688_0/C++/alyaxey/c.cpp
#include <cstdlib> #include <cassert> #include <cmath> #include <cstdio> #include <deque> #include <iomanip> #include <iostream> #include <list> #include <numeric> #include <sstream> #include <string> #include <vector> #include <map> #include <set> #include <algorithm> using namespace std; #define sz(X) ((int)(X).siz...
ALGO
0.999986
3.616688
{ "github_metadata": { "branch": "master", "commit_count": 58, "repo_created_at": "2017-03-08T11:33:58.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 4, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "470516884...
c1c63bee-5628-427d-b71a-f66c3647a68a
Technology-maker/DSA-CPP-CODES
practice.cpp
// #include <bits/stdc++.h> // using namespace std; // int main() // { // int n; // cin >> n; // int reverse = 0; // while (n > 0) // { // int id = n % 10; // reverse = (reverse * 10) + id; // n = n / 10; // } // cout << "revnum is = " << reverse; // return 0; // ...
ALGO
0.999584
3.392784
{ "github_metadata": { "branch": "main", "commit_count": 2, "repo_created_at": "2024-11-13T07:00:31.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b136bf0d64d4...
d417677f-2520-46af-a54c-42e2ebc1726f
clawfinger/programming_tasks
route256-codeforces/programmers_pair/programmers_pair/programmers_pair.cpp
#include <iostream> #include <unordered_map> #include <vector> #include <algorithm> #include <queue> void pairsSlow() { int count = 0; std::cin >> count; std::unordered_map<int, std::priority_queue<int, std::vector<int>, std::greater<int> >> programmersStrength; // key - strength, value programmer; st...
ALGO
0.999953
4.076904
{ "github_metadata": { "branch": "master", "commit_count": 49, "repo_created_at": "2023-01-05T07:52: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": "aac9ae120...
026bb927-d908-412e-961b-14724cfddeae
rusucosmin/cplusplus
Zlego/zlego.cpp
#include <fstream> #include <vector> using namespace std; const int maxn = 250005; int height[maxn]; int t, n, pi[maxn]; long long sum[maxn]; int main() { ifstream fin("zlego.in"); ofstream fout("zlego.out"); fin >> t; while(t -- ) { fin >> n; for(int i = 1 ; i <= n ; ++ i) ...
ALGO
0.999949
3.010752
{ "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": "c3843442b...
f9c7d713-8e75-41cf-af9d-e3048cd7b275
jojaeng2/algorithm
C++/BOJ1035.cpp
#include <iostream> #include <cstring> #include <algorithm> #include <queue> #include <string> #include <vector> #define X first #define Y second using namespace std; typedef pair<pair<int, int>, int> piii; typedef pair<int, int> pii; int graph[6][6], dx[4] = {-1, 1, 0, 0}, dy[4] = {0, 0, -1, 1}, psum=0, answer = 1e9, ...
ALGO
0.999813
3.969027
{ "github_metadata": { "branch": "main", "commit_count": 475, "repo_created_at": "2020-12-27T09:19: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": "93be798daa...
47172893-f1c9-42e5-8d49-92ade03a779c
Livinfly/Template-Reflection-in-CP
牛客多校2023-2B-最大权闭合子图+优化建边.cpp
// #pragma GCC optimize(2) #include <bits/stdc++.h> #define fi first #define se second #define mkp(x, y) make_pair((x), (y)) #define all(x) (x).begin(), (x).end() using namespace std; typedef long long LL; typedef double db; typedef pair<int, int> PII; const int N = 1e4+10, NN = 200*N, M = 1e6+10; const int INF = ...
ALGO
0.999926
4.426528
{ "github_metadata": { "branch": "main", "commit_count": 18, "repo_created_at": "2023-05-02T15:04: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": "b733dc60b60...
a50d8d59-1ac2-4a9a-b1bd-6de88a7a2341
HW-Z-2111025/Parallel-Programming-hwk3-
omp_sse.cpp
#include <iostream> #include <nmmintrin.h> #include<math.h> #include<windows.h> #include<random> #include<ctime> #include<time.h> #include<omp.h> #include<fstream> using namespace std; int N = 10; const int numThread = 6; float** matrix; //ʼ void m_reset() { for (int i = 0; i < N; i++) { for (int j ...
ALGO
0.999926
3.511326
{ "github_metadata": { "branch": "main", "commit_count": 11, "repo_created_at": "2024-05-26T13:30: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": "7c9f443f327...
e0c6ae66-473a-4be5-9e80-18dcbf0927aa
AryamannNingombam/DSTP
DP/UglyNumbers/index.cpp
#include <iostream> #include <vector> using namespace std; int ugly_number(int n) { vector<long> values(10000, -1); values[0] = 1; int i2 = 1, i3 = 1, i5 = 1, next_number_two = 2, next_number_three = 3, next_number_five = 5; int next_number; for (int i = 1; i < n; i++) { next_...
ALGO
0.999608
4.842355
{ "github_metadata": { "branch": "master", "commit_count": 3, "repo_created_at": "2021-07-05T16:28: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": "1387b8f68d...
b4c8255e-6c4e-4583-a507-f7a8bebe2c04
Gilpop8663/Altudy
Programmers/문자열압축/Gilpop8663.cpp
#include <bits/stdc++.h> using namespace std; int solution(string s) { int len = s.size(); int answer = len; int n = len/2; for(int i=1;i<=n;i++){ string result =""; string ss = s.substr(0,i); int cnt =1; ...
ALGO
0.999992
4.209942
{ "github_metadata": { "branch": "master", "commit_count": 1719, "repo_created_at": "2022-03-01T10:54:28.000Z", "is_fork": true, "is_org_owned": false, "forked_from": "zerochae/Altudy", "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_i...
b29b1e00-c737-4a45-80a9-f87674941fb9
MichaEiler/tum-mt_benchmarks
src/benchmarks/cfd.cpp
#include "cfd.hpp" #include <fstream> #include <iostream> #include <memory> #include <random> #include <sstream> #include "../clglobal.hpp" #include "../computecontroller.hpp" using namespace benchmarks; using namespace std; static const string CFD_DATASET = "cfd/fvcorr.domn.097K"; static const int ALGORITHM_ITERA...
ALGO
0.984865
3.86938
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2016-01-29T09:59:21.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "a589c6aa4d...
42481517-9ae7-42b9-925d-4fc098adc674
SpurSlicer/University-Coursework
Intro-To-Cpp/Vectors/sumElements.cpp
#include <vector> #include <iostream> using namespace std; /* ALGORITHM It starts by getting a vector, starting index, and ending index It then checks to make sure the indices are valid. If they are, it returns -1 It then checks to make sure that the indices are valid for the given size. If not, it returns -2. If every...
ALGO
0.999279
6.172546
{ "github_metadata": { "branch": "main", "commit_count": 5, "repo_created_at": "2025-02-20T16:55:43.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b93ab6b021f9...
e72b2694-fb66-481f-97c2-c08f39b47d90
ybouret/yttrium
src/core/y/counting/nested-loop.hpp
#ifndef Y_Counting_Nested_Loop_Included #define Y_Counting_Nested_Loop_Included 1 #include "y/counting/schedule.hpp" namespace Yttrium { //__________________________________________________________________________ // // // //! loop (i=1:n,j=i+1:n,k=j+1:n,...) // // //____________...
TOOL
0.902444
5.610884
{ "github_metadata": { "branch": "main", "commit_count": 5725, "repo_created_at": "2023-06-28T20: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": "036d49630...
4e9f6612-811c-486f-9a11-1f18e438ce68
Micuks/code
kb_ans/topic16/t16pn/t16pn.hpp
#ifndef _t16pn_20200710_ #define _t16pn_20200710_ #include <algorithm> #include <assert.h> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <functional> #include <iostream> #include <map> #include <numeric> #include <queue> #include <set> #include <sstream> #include <string> #include <v...
ALGO
0.999638
3.596575
{ "github_metadata": { "branch": "master", "commit_count": 541, "repo_created_at": "2020-11-12T05:37:12.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b2292b86...
7d82d094-3b6a-4757-8490-d93caa8e87c4
raincross7/code-similarity
codes/train_code/problem175/problem175_259.cpp
#include <bits/stdc++.h> using namespace std ; const int MAX = 2e5 + 10 ; long long A[MAX] , B[MAX] ; int n ; int main() { ios_base::sync_with_stdio(0) ; cin.tie(0) ; cin>>n ; long long sum1 = 0 , sum2 = 0 , sum = 0 ; for(int i = 0 ; i < n ; ++i) { cin>>A[i]>>B[i] ; if(A[i] > B[i]) sum1 += A[i] - B[i] ...
ALGO
0.999988
3.569008
{ "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": "d88e7b97e260...
ebd20ee6-88d0-4583-b7e0-2e1e5b19efd9
skrcode/SPOJ-Solutions
KNAPSACK-18988384-src.cpp
/* Author : skrcode */ #include <vector> #include <list> #include <map> #include <set> #include <deque> #include <queue> #include <stack> #include <bitset> #include <algorithm> #include <functional> #include <numeric> #include <utility> #include <sstream> #include <fstream> #include <iostream> #include <iomanip> #i...
ALGO
0.999898
3.191216
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2017-12-12T11: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": "32efc1d4c3...
f1a1a594-7a56-4b52-a130-0f04b5f56869
Shantanu2k19/cpp_DSA_templates
STL/SegTree.cpp
#include<iostream> #include<vector> using namespace std; class segTree { public: int start, end; segTree* left; segTree* right; int sum; segTree(int st, int en) { start = st; end = en; left = NULL; right = NULL; sum=0; } }; segTree* root = NULL;...
ALGO
0.999933
5.196215
{ "github_metadata": { "branch": "master", "commit_count": 22, "repo_created_at": "2022-06-30T06:04:51.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "dc95b71d5...
ca7e932a-2212-45ca-8dcc-67fda8fa2922
arielbertino/Sistema-Bibliotecario
C++ CodeBlock Project/arbolB.cpp
#include "arbolB.h" template <typename elemento> arbolB<elemento>::arbolB() //TERMINADO { cursorAB = 0; } template <typename elemento> arbolB<elemento>::~arbolB() //TERMINADO { if (cursorAB) vaciarArbol(cursorAB); } template <typename elemento> void arbolB<elemento>::agregarAbalanceado(const ele...
ALGO
0.995337
4.268843
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2021-02-04T16:55: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": "6a94544c3f...
16b66b8e-bb5f-4746-82f2-b8b36f649cbd
asmii14/CNS_LAB
sayali.cpp
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; int arr[n]; for (int i = 0; i < n; i++) { cin >> arr[i]; } for (int i = 0; i < n; i++) { int num = arr[i]; int even = 1; int odd = 1; bool has_even = false; // To track if ther...
ALGO
0.999983
5.186277
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2024-11-12T02:39:54.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "3012df39f1...
4061e40b-391c-4909-81e9-e34633171bf2
takoyaki65/kyopro-code
atcoder/abc025/c1.cpp
#include <algorithm> #include <cassert> #include <cmath> #include <cstring> #include <iomanip> #include <iostream> #include <iterator> #include <map> #include <queue> #include <set> #include <stack> #include <vector> #define repeat(i, n) for (int i = 0; (i) < (n); ++(i)) #define repeat_from(i, m, n) for (int i = (m); (...
ALGO
0.999924
4.226141
{ "github_metadata": { "branch": "master", "commit_count": 153, "repo_created_at": "2020-08-16T07:54: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": "2b6d3cdb...
79ea9e56-955e-430b-99e3-08ce95a163f8
jiyeon2781/algorithm-practice
Baekjoon/Silver/2108.cpp
#include <iostream> #include <algorithm> #include <cmath> #include <vector> #include <map> using namespace std; int Average(int sum); int Middle(); int Mode(); int Range(); vector<int> nums; map<int, int> cnt; int main() { ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0); int N, num, sum =...
ALGO
0.999402
4.048331
{ "github_metadata": { "branch": "main", "commit_count": 209, "repo_created_at": "2023-11-15T01:33: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": "01f8665fcc...
bdf6afa7-3687-4cf1-9198-b8773709ee66
fjnkt98/competitive_cpp
practices/careful_selection_100/10.cpp
/* * https://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ALDS1_5_A&lang=ja */ #include <iostream> #include <vector> #include <string> #include <algorithm> int main() { int64_t N; std::cin >> N; std::vector<int64_t> A(N); for (int64_t i = 0; i < N; i++) { std::cin >> A.at(i); } int64_t M; std:...
ALGO
0.999939
4.590876
{ "github_metadata": { "branch": "master", "commit_count": 241, "repo_created_at": "2020-08-13T05:58: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": "1567cb70...
2c79c0ac-c8a8-47ea-8eea-e622ed516533
Valkyrie0410/ULTRA
Question 2/GetData.cpp
#include "../DataStructures/GTFS/Data.h" #include<iostream> #include <fstream> #include <iomanip> #include <vector> #include <string> #include <set> #include <unordered_map> #include "../DataStructures/Container/Map.h" std::vector<std::string> directjourney(const GTFS::Data& gtfsdata, const std::string& sourcestopID, c...
ALGO
0.991061
4.412361
{ "github_metadata": { "branch": "main", "commit_count": 4, "repo_created_at": "2024-03-23T20:31:34.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "f258d471cd6e...
4a689566-91e2-4b4f-b0d7-21ab4bdcc9dc
Smarko1/Drillek
drill10/drill10_5.cpp
#include "std_lib_facilities.h" struct Point { Point(double xcoor, double ycoor) : x(xcoor), y(ycoor) {} double x, y; }; vector<Point> original_points, processed_points; string filename = "mydata.txt"; ofstream outFile{ filename }; ifstream inFile{ filename }; //beolvas a fileba ostream& operator<<(ostream& os,...
TOOL
0.960337
4.768497
{ "github_metadata": { "branch": "main", "commit_count": 21, "repo_created_at": "2020-10-02T16:21: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": "e976ea2c3fd...
da92190b-fe68-4e03-9aa0-bafedcb6af79
Acathignol/TP1_C-
Complex.cpp
// =========================================================================== // Includes // =========================================================================== #include "Complex.h" // =========================================================================== // ...
TOOL
0.911739
4.401784
{ "github_metadata": { "branch": "master", "commit_count": 5, "repo_created_at": "2016-02-01T13:15: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": "42e541e19a...
523e3f4a-2a91-4447-9bd0-44e98a6298ea
VivekYadav98/DSA
Delete all occurrences of a given key in a doubly linked list - GFG/delete-all-occurrences-of-a-given-key-in-a-doubly-linked-list.cpp
//{ Driver Code Starts // Initial Template for C++ #include <bits/stdc++.h> using namespace std; struct Node { int data; struct Node* next; struct Node* prev; }; void push(struct Node** head_ref, int new_data) { struct Node* new_node = (struct Node*)malloc(sizeof(struct Node)); new_node->data = n...
ALGO
0.999877
5.949241
{ "github_metadata": { "branch": "main", "commit_count": 2139, "repo_created_at": "2023-01-14T10:26: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": "c53626ee2...
c5da70ab-648d-4d0d-b02a-5aa6482346a0
Shubham0920/Daily-Leetcode-question
Make Matrix Beautiful - GFG/make-matrix-beautiful.cpp
//{ Driver Code Starts #include <bits/stdc++.h> using namespace std; // } Driver Code Ends class Solution { public: //Function to find minimum number of operations that are required //to make the matrix beautiful. int findMinOpeartion(vector<vector<int> > matrix, int n) { // code here ...
ALGO
0.999969
6.11012
{ "github_metadata": { "branch": "main", "commit_count": 1220, "repo_created_at": "2022-01-13T18:38: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": "62669addd...
50f817ed-6ac7-4416-9de8-d9947da8cb4a
deepcoder007/spoj
LISA.cpp
#include<iostream> #include<cstdio> #include<string> #include<vector> #include<cstring> using namespace std; // a classic int dp[200][200]; // the dp char sym[200]; // the symbols int num[200]; // the numbers inline int max(int i,int j) { if( i>j ) return i; else return j; } inline int min(int i,int j) { ...
ALGO
0.999776
3.559426
{ "github_metadata": { "branch": "master", "commit_count": 104, "repo_created_at": "2014-05-03T11:46:42.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "0409802d...
3a92b7fc-ad2e-40e6-a950-0ecda2a9fac8
MAPF-Competition/Start-Kit
default_planner/heuristics.cpp
#include "heuristics.h" #include <queue> namespace DefaultPlanner{ std::vector<HeuristicTable> global_heuristictable; Neighbors global_neighbors; void init_neighbor(SharedEnvironment* env){ global_neighbors.resize(env->rows * env->cols); for (int row=0; row<env->rows; row++){ for (int col=0; col<env->cols; co...
ALGO
0.996582
4.291547
{ "github_metadata": { "branch": "main", "commit_count": 429, "repo_created_at": "2022-12-13T23:28:33.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 28, "forks": 20, "issues": 9, "pull_requests": 0 }, "file_meta": { "content_id": "723205858...
de23cd15-ae2f-4e95-a528-978db6d88597
Dracaryscode/EDAPROYECTO_2
main.cpp
#include <cstdlib> // Necesario para la función system() y que se reconozca las tildes #include <cstdlib> // Necesario para la función system() y que se reconozca las tildes #include <iostream> #include <string> #include <cstring> #include <limits> #include "HashTable.h" #include "MaxHeap.h" #include "AVLTree.h" #incl...
TOOL
0.974486
3.590833
{ "github_metadata": { "branch": "master", "commit_count": 8, "repo_created_at": "2025-07-05T00:39:46.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 1 }, "file_meta": { "content_id": "b66a715ba0...
cdb60756-594a-4336-88d8-a7002bd48a6d
Shahriar-Seam/Programming
Other OJs/SPOJ/ADAFUROW.cpp
#include <bits/stdc++.h> using namespace std; const int sz = 2e4 + 5; int32_t main() { ios_base::sync_with_stdio(false); cin.tie(NULL); int q, x, y, i; char op; cin >> q; vector <bitset <sz> > v(sz); while (q--) { cin >> op >> x >> y; if (op == '+') { v[x]...
ALGO
0.999828
5.025181
{ "github_metadata": { "branch": "main", "commit_count": 749, "repo_created_at": "2023-09-13T02: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": "c1c7d3049e...
f58fe78e-49a0-4258-af92-694f1195a4aa
lukastojiljkovic/Algorithms-and-Data-Structures
Petlja zadaci/Slozenost izracunavanja/Zbirovi prefiksa i razlike susednih elemenata niza/kruzni_put.cpp
#include <iostream> #include <vector> #include <algorithm> #include <string> #include <cmath> #include <map> #include <queue> #include <iomanip> #include <unordered_map> #include <vector> using namespace std; int main(){ ios_base::sync_with_stdio(false); cin.tie(0); int n; cin >> n; vector<int> l...
ALGO
0.999993
3.78959
{ "github_metadata": { "branch": "main", "commit_count": 29, "repo_created_at": "2023-01-16T18:09:28.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "5f93b77f70c...
3a663fb2-9fc7-4d0e-b18c-cbd8a281f365
skaarf9/courseAutoGeneratedSystem
myTime.cpp
#include "myTime.h" bool myTime::isConflict(const myTime & other_time, WeeklyLesson weeklyLesson) { /*如果A在B结束后开始, 或者A在B开始前结束, 那么A与B就不相交, 我们取反,就是A与B相交的情况*/ if (!(this->startWeek > other_time.endWeek || this->endWeek < other_time.startWeek)) { /*遍历A中的每周课程,如果与weeklyLesson重合那么就会产生冲突*/ for (WeeklyLesson this_one : th...
ALGO
0.941266
3.989727
{ "github_metadata": { "branch": "main", "commit_count": 10, "repo_created_at": "2022-03-01T12:02: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": "19fc72c0600...
6f748d11-8840-4d43-9817-6bed2f1bff74
littlecaca/algorithms
hot100/jump-game-ii.cpp
#include <unordered_map> #include <functional> #include <algorithm> #include <climits> #include <stack> #include <queue> #include <vector> #include <string> using namespace std; typedef pair<int, int> pii; typedef vector<pii> vpii; typedef vector<vpii> vvpii; typedef vector<int> vi; typedef vector<vi> vvi; typedef ve...
ALGO
0.999989
5.226005
{ "github_metadata": { "branch": "master", "commit_count": 14, "repo_created_at": "2024-04-24T09:13: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": "db107a045...
5b5f05c1-ab8d-4c63-9186-d5f1141592bd
DIVYANSHNITJSR/dsa-striver-leetcode
BINARY/SEARCH/binary-tree-level-order-traversal/binary-tree-level-order-traversal.cpp
/** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode() : val(0), left(nullptr), right(nullptr) {} * TreeNode(int x) : val(x), left(nullptr), right(nullptr) {} * TreeNode(int x, TreeNode *left, TreeNode *right) : val(x), l...
ALGO
0.999989
6.012938
{ "github_metadata": { "branch": "ARRAY", "commit_count": 426, "repo_created_at": "2023-06-03T05:14: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": "b3fc90d70...
03f3a84c-e421-4cde-8006-c4d80f087eef
davil2020/Competitive-Programming
cses/Tree_algorithms/tree_diameter.cpp
#include <bits/stdc++.h> using namespace std; #define _ ios_base::sync_with_stdio();cin.tie(0); #define rep(i,a,b) for(int i = a; i <= b; i++) #define f first #define s second #define pb push_back #define MAXN 200010 typedef long long ll; typedef pair<int, int> ii; typedef vector<int> vi; typedef vector<vector<in...
ALGO
0.996307
3.47308
{ "github_metadata": { "branch": "main", "commit_count": 16, "repo_created_at": "2025-03-27T13:44: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": "7c68fafe28e...
68f8dd32-7c0e-4397-badd-d0f92162ae1d
CommitPot/CommitPot-Study
알고리즘/유찬홍/백준/25000/25140.cpp
#include <queue> #include <vector> #include <iostream> #include <unordered_map> using namespace std; int main() { char d[9][5] = {"13", "024", "15", "046", "1357", "248", "37", "468", "57"}; unordered_map<int, int> m; int s = 123456789; m[s] = 1; queue<pair<int, int>> q; q.emplace(s, 8); w...
ALGO
0.999995
4.160122
{ "github_metadata": { "branch": "main", "commit_count": 1695, "repo_created_at": "2022-07-27T14:49:42.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 10, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "9cb192a48...
ec84fcbc-c442-4fa2-97e7-8ae633cf4a03
rabogan/tentativeSolutions
AlgorithmsPackCPP/Sudoku Solver.cpp
int rows[9][9]{0}; int cols[9][9]{0}; int box[3][3][9]{0}; vector<int>emptyRow; vector<int>emptyCol; class Solution { public: void solveSudoku(vector<vector<char>>&board) { memset(rows,0,sizeof(rows)); memset(cols,0,sizeof(cols)); memset(box,0,sizeof(box)); emptyRow.clear(); ...
ALGO
0.99961
6.477762
{ "github_metadata": { "branch": "main", "commit_count": 716, "repo_created_at": "2023-07-18T12:56: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": "52424d5e3d...