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
ca50d537-affc-4d87-ab21-c2307cbd18ea
sagarbhatt0904/Navier-Stokes-Solver
source/NSsolver.cpp
#include <iostream> #include <math.h> #include <stdlib.h> #include <vector> #include "init.h" #include "gridgen.h" #include "metric.h" #include "RHS.h" #include "BC.h" #include "contour.h" using namespace std; int main() { int N= 61; /*Grid size`*/ double st=1; /*Stretching ratio, ch...
ALGO
0.999937
3.601229
{ "github_metadata": { "branch": "master", "commit_count": 7, "repo_created_at": "2016-10-10T02:33: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": "aa5aef096c...
7fde71cf-3e38-44be-a10b-51b101b73339
AnmolDua/codeshala-tree-imp-
codeshala tree(imp)/ZigZagTraversal.cpp
#include <iostream> #include <algorithm> #include <vector> #include <map> #include <queue> #include <stack> using namespace std; #define ll long long int #define f_in(st) freopen(st,"r",stdin); #define f_out(st) freopen(st,"w",stdout); struct node { int data; struct node * left; struct node * right; } * roo...
ALGO
0.999998
4.468001
{ "github_metadata": { "branch": "master", "commit_count": 10, "repo_created_at": "2018-05-07T08:08: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": "aaab2fe44...
52fc2f61-ce69-4453-b538-55ed2cad9438
MD-ALAMIN-HOSSEN/competitive-coding-problem-solving
practice 375/number/changing number base.cpp
#include<bits/stdc++.h> using namespace std; int hexaTodecimal(string a){ int ans =0; int x=1; int s=a.size(); for (int i = s-1; i >=0; i--) { if(a[i]>='0' && a[i]<='9'){ ans+=(a[i]-'0')*x; } if(a[i]>='A'&&a[i]<='E'){ ans+=(a[i]-'A'+10)*x; } x*=16; ...
ALGO
0.999699
4.030173
{ "github_metadata": { "branch": "main", "commit_count": 13, "repo_created_at": "2022-05-07T19:14:44.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "c844909ad4c...
ce51e23d-c0e1-4537-adb4-5812245e9b14
josetruta/programming-problems
DP/two_sets_2.cpp
#include <bits/stdc++.h> #define endl '\n' typedef long long ll; using namespace std; const int MOD = 1e9 + 7; int n; vector<vector<ll>> dp; ll solve(ll idx, ll resto) { if (resto == 0) return 1; if (resto < 0) return 0; if (idx == n) return 0; if (dp[idx][resto] != -1) return dp[idx][resto]; dp[i...
ALGO
0.99999
4.532076
{ "github_metadata": { "branch": "main", "commit_count": 32, "repo_created_at": "2024-07-06T03:36: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": "e26f722d2c1...
26224c6f-03f8-4128-bff9-0d3cfe990dde
shubham21699/My-LeetCode-Solutions
297-serialize-and-deserialize-binary-tree/297-serialize-and-deserialize-binary-tree.cpp
/** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x), left(NULL), right(NULL) {} * }; */ class Codec { TreeNode* deserialize_queue(queue<string>& q) { string s = q.front(); q.pop(); ...
ALGO
0.999584
5.68272
{ "github_metadata": { "branch": "master", "commit_count": 3720, "repo_created_at": "2022-01-07T07:56:24.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "88edbf8...
b1e84c95-2d6b-4cd3-b0ee-1edf56535450
BhargavShekhar/cpp
Phase-2/Graphs/graph.cpp
#include<iostream> #include<list> #include<unordered_map> using namespace std; class Graph { public: unordered_map<int, list<int>> adjList; void addEdge(int u, int v, bool direction) { // direction = 0 -> undirected graph // direction = 1 -> directed graph if(di...
ALGO
0.999436
5.608325
{ "github_metadata": { "branch": "main", "commit_count": 12, "repo_created_at": "2024-08-02T19:50: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": "7c5f903283f...
d1336c61-a2bf-434a-a237-7e31e97e3cc8
dibery/UVa
vol16/1610.cpp
#include<bits/stdc++.h> using namespace std; int main() { for( int size; cin >> size && size; ) { string name[ 1000 ], a, b; for( int i = 0; i < size; ++i ) cin >> name[ i ]; sort( name, name + size ); a = name[ size / 2 - 1 ]; b = name[ size / 2 ]; for( size_t p = 0; p < a.size() && p < b.size(); ++...
ALGO
0.999831
3.484292
{ "github_metadata": { "branch": "master", "commit_count": 149, "repo_created_at": "2014-05-06T07:50:34.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 4, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "a07adf72...
4aac5332-2eeb-423f-a41b-7daadba96ad1
akhi1-s/Obstacle-Avoidance-wheeled-robot
include/follower_robot.h
#include <actionlib/client/simple_action_client.h> #include <fiducial_msgs/FiducialTransformArray.h> #include <geometry_msgs/Twist.h> //for geometry_msgs::Twist #include <nav_msgs/Odometry.h> #include <move_base_msgs/MoveBaseAction.h> #include <tf2/LinearMath/Quaternion.h> #include <tf2_ros/transform_broadcaster.h> #i...
TOOL
0.929801
5.398247
{ "github_metadata": { "branch": "main", "commit_count": 4, "repo_created_at": "2024-10-02T17:28:50.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "eff15399ce25...
1cacd224-40e8-42c8-8aa7-62a5edf01e6d
rCori/RecursiveRaytracer
hw3/hw3/objDefinitions.cpp
#include "objDefinitions.h" #include "HitInfo.h" //return a ray transformed by the inverse of the transform; Ray GeometryObject::TransformRay(Ray ray){ //Get the inverse of the transform glm::mat4 inverseMat = glm::inverse(transform); //Now transform both the origin and direction. //origin has w=1 but direction...
ALGO
0.970669
5.731582
{ "github_metadata": { "branch": "development", "commit_count": 10, "repo_created_at": "2016-01-19T21:04:28.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "cdd7...
b41ae47d-21ce-4e23-a9a2-91252b752fb6
kamal-singh819/Data-Structure-and-Algorithm
TREE/2_BST.cpp
#include <iostream> #include <queue> using namespace std; class node { public: int data; node *left; node *right; node(int data) { this->data = data; this->left = NULL; this->right = NULL; } }; node *insertIntoBST(node *root, int d) { if (root == NULL) { ...
ALGO
0.999965
4.134885
{ "github_metadata": { "branch": "master", "commit_count": 3, "repo_created_at": "2022-11-27T07:22: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": "1a18fd0d05...
e7a8dfc1-5573-4b40-af67-92afd285a80e
Yawn-Sean/Daily_CF_Problems
daily_problems/2024/12/1219/personal_submission/cf82d_retyrn.cpp
int n; void solve() { cin >> n; vector<int> a(n + 1); for (int i = 1; i <= n; i ++) { cin >> a[i]; } // 一定是一个数 加上一段区间 vector<vector<int>> f(n + 1, vector<int>(n + 2, inf)); vector<vector<int>> st(n + 1, vector<int>(n + 2, false)); vector<vector<pii>> to(n + 1, vector<pii>(n + 2,...
ALGO
0.999974
3.482428
{ "github_metadata": { "branch": "main", "commit_count": 20410, "repo_created_at": "2024-02-26T01:04:08.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 478, "forks": 302, "issues": 0, "pull_requests": 7 }, "file_meta": { "content_id": "7d87...
dfe8a030-a8c3-4bd0-ac20-c65d3717e001
ishandutta2007/codeforces-a
alexandr_ts/normal/302/A.cpp
#include <bits/stdc++.h> #define fr(i, n) for (int i = 0; i < n; i++) #define frab(i, a, b) for (int i = a; i < b; i++) #define pb push_back #define mp make_pair using namespace std; typedef pair <long long, long long> pr; typedef long long ll; typedef long double ld; const ll MOD = 1e9 + 7; const ll INF = 2e9; cons...
ALGO
0.999976
3.657889
{ "github_metadata": { "branch": "main", "commit_count": 4, "repo_created_at": "2024-04-11T00:51: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": "b47fefc98a1e...
64f70de5-bdcb-43de-aba7-70f9786d8814
georgek1205/cplusplus
comparison-KIMSEUNGGYU.cpp
#include <iostream> #include <cassert> #include <math.h> #include <stdlib.h> #include <vector> using namespace std; // short integer random number generator from stdlib int rand(void); void merge_sort(vector<int>& mergeArray, int first, int last); void merge(vector<int>& mergeArray, int first, int mid, int last); vo...
ALGO
0.999273
5.244572
{ "github_metadata": { "branch": "main", "commit_count": 32, "repo_created_at": "2023-02-12T10:26: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": "c3e2d4dfab6...
fb2e8bab-6a58-4661-a89c-de0af538d92f
kjlee342/Hw
Cpp/해밍코드/main.cpp
#include <iostream> #include <fstream> #include <cstdlib> #include <cmath> using namespace std; static unsigned int transHamming(unsigned int number); static unsigned int extractHamming(unsigned int number); int main(void){ ifstream inStream; int numTestCases; inStream.open("input.txt"); if(inStr...
ALGO
0.99965
4.237418
{ "github_metadata": { "branch": "master", "commit_count": 7, "repo_created_at": "2018-05-09T07:39: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": "b7a3275eb4...
6f44b03b-191a-4a25-9f40-d0f0f2446e5c
Ram-the-coder/interview-prep
graph/kruskal_mst.cpp
#include<bits/stdc++.h> #define dispv(a) for(int i=0; i<a.size(); ++i) cout << a[i] << ' '; cout << '\n' using namespace std; class Edge { public: int from, to, weight; Edge(int f, int t, int w) : from(f), to(t), weight(w) {} }; class Graph { public: vector<Edge> edges; int num_vertices; Grap...
ALGO
0.999997
5.136895
{ "github_metadata": { "branch": "master", "commit_count": 111, "repo_created_at": "2020-06-23T17:42:46.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "dc60e1ab...
e645b96a-a51e-4684-84b1-846316bd4edb
mugicha101/MARISA-Realtime-Scheduling-Sim
src/schedulers/helper_funcs.cpp
#include "helper_funcs.h" #include <cassert> #include <algorithm> #include <functional> // helper function to assign chosen jobs to cores void assignToCores(const JobSet& active_jobs, CoreState& core_state, std::vector<int> chosen_jobs) { assert(chosen_jobs.size() <= core_state.size()); sort(chosen_jobs.begin...
ALGO
0.992369
6.310576
{ "github_metadata": { "branch": "master", "commit_count": 38, "repo_created_at": "2023-10-17T23:21:47.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "9f553fa1d...
5c565090-67f2-4729-b141-9c2a6ea99629
algorithm004-01/algorithm004-01
Week 08/id_616/LeetCode_8_616.cpp
class Solution { public: int myAtoi(string str) { int res = 0; int i = 0; int flag = 1; while (str[i] == ' ') { i++; } if (str[i] == '-') { flag = -1; } if (str[i] == '+' || str[i] == '-') { i++; } while (i < str.size() && isdigit(str[i])) { int...
ALGO
0.998708
4.895066
{ "github_metadata": { "branch": "master", "commit_count": 2353, "repo_created_at": "2019-09-28T08:15:20.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 974, "forks": 381, "issues": 727, "pull_requests": 20 }, "file_meta": { "content_id": "1...
47f9b7a2-0cd1-46b3-acaa-74daf11976f9
SR-Sunny-Raj/Hacktoberfest2021-DSA
15. Binary Search Tree/search_in_BST.cpp
/* ... Recursive Solution for search in a Binary Search Tree .... */ #include<iostream> using namespace std; struct Node{ int data; Node* left; Node* right; Node(int val){ data=val; left=NULL; right=NULL; } }; Node* searchInBST(Node* root,int val){ if(root==NULL){ return N...
ALGO
0.999999
5.289458
{ "github_metadata": { "branch": "master", "commit_count": 2783, "repo_created_at": "2020-05-08T05:36:07.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 236, "forks": 982, "issues": 3, "pull_requests": 161 }, "file_meta": { "content_id": "5...
2ba20128-a791-4e16-94d8-d751696fd09e
nadal12/PracticasIG
Practica2DoblePendulo/Practica2DoblePendulo.cpp
/*Etapa 2 - <NAME>*/ #include "iostream" #include <GL/glut.h> #include <GL/gl.h> #include <GL/glu.h> #include <chrono> #include <thread> //Constants generals const int W_WIDTH = 500; const int W_HEIGHT = 500; const int wMon = 2; const int hMon = 2; bool traj = false; //Constants Pendul constexpr auto PI = 3.14159265...
ALGO
0.997049
4.592373
{ "github_metadata": { "branch": "master", "commit_count": 104, "repo_created_at": "2020-03-17T18:14:50.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "9d411a72...
f85b6ec4-65d0-40d6-b1cb-34a0e6eff662
edisonhello/competitive_programming
TOJ/AC/9.cpp
#include<bits/stdc++.h> using namespace std; #define ll long long #define ld long double #define PB(x) push_back(x) #define pii pair<int,int> #define rz(x) reserve(x) #define X first #define Y second // #define m (l+r)/2 // #define xm (x1+x2)/2 // #define ym (y1+y2)/2 #define DE cout<<"de"<<endl; #define PQ priority_qu...
ALGO
0.999924
3.394826
{ "github_metadata": { "branch": "master", "commit_count": 843, "repo_created_at": "2016-03-15T14:58:15.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 4, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "8656980e...
e19bbd71-7166-4cfa-9b6c-2b41bc8ca110
karin0/problems
probs/bzoj1086-tree-divide-blocks.cpp
#include <cstdio> const int N = 1005; struct Node { struct Edge *e; int bel; } g[N]; struct Edge { Node *v; Edge *e; Edge (Node *_u, Node *_v) : v(_v), e(_u->e) { _u->e = this; } }; int n, s, bcnt, cent[N], ssz; Node *sta[N]; void dfs(Node *u, Node *f) { int osz = ssz; for (Edge...
ALGO
0.99976
3.476299
{ "github_metadata": { "branch": "master", "commit_count": 225, "repo_created_at": "2017-05-22T16:54:32.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "bf11944e...
93e7bc66-c04f-4a6f-bc23-1916a4c7edde
ey-jang/Algorithm
Project1/Project1/BFS, DFS/9205_맥주 마시면서 걸어가기.cpp
#include <iostream> #include <vector> #include <cstring> #include <cmath> using namespace std; bool c[101][101]; int main() { int t; cin >> t; int n, u, v; vector<pair<int, int>>location; for (int i = 0; i < t; i++) { cin >> n; //집 cin >> u >> v; location.push_back({ u, v }); //편의점 for (int i ...
ALGO
0.999691
3.908047
{ "github_metadata": { "branch": "main", "commit_count": 37, "repo_created_at": "2021-01-23T01:57: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": "3ef5c05654a...
12449189-10d2-47bb-88be-a52a4e08f7ce
kss418/Atcoder
ABC/200/270/278/C.cpp
#include <bits/stdc++.h> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> using namespace __gnu_pbds; #define ordered_set tree<int, null_type, less<int>, rb_tree_tag,tree_order_statistics_node_update> #define fastio cin.tie(0), cout.tie(0), ios::sync_with_stdio(0); #define all(x) (x).begin(...
ALGO
0.999796
5.089846
{ "github_metadata": { "branch": "main", "commit_count": 1312, "repo_created_at": "2024-09-16T15:54:37.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "a39018d4f...
3fcf65b6-ea4a-4a81-8419-2a2cca4b7289
kzamanbd/lightoj-dimik52
Vowel_Consonant.cpp
#include <bits/stdc++.h> using namespace std; bool isVowel(char c) { if (c == 'a' || c == 'e' || c == 'i' || c == 'o' || c == 'u') { return true; } else if (c == 'A' || c == 'E' || c == 'I' || c == 'O' || c == 'U') { return true; } return false; } int main() { int test...
ALGO
0.999879
4.680296
{ "github_metadata": { "branch": "master", "commit_count": 8, "repo_created_at": "2023-12-05T16:29: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": "e584fb829f...
24b2336b-5d05-4442-bf41-ae437d084042
magodo/leetcode_practice
0201_Bitwise_AND_of_Numbers_Range/1_my_stupid_solution/CSolution.cpp
/************************************************************************* Author: <NAME> Created Time: Sat 25 Feb 2017 09:40:16 PM CST Description: ************************************************************************/ #include "CSolution.h" #include "math.h" int CSolution::m_max_msb = 30; int CSolution::ms...
ALGO
0.999755
4.158892
{ "github_metadata": { "branch": "master", "commit_count": 17, "repo_created_at": "2017-05-30T12: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": "7fbdafc58...
c7dded9a-7755-4062-99f2-25c2c7289a26
Ylandolsi/Codeforces
C. Digital Logarithm.cpp
#include <bits/stdc++.h> using namespace std ; #define pb push_back #define SPEED cout.tie(0), cin.tie(0), ios_base::sync_with_stdio(0) #define int long long typedef pair<int,pair<int,int>> tup; typedef pair<int,int> pi; #define endl "\n" #define all(x) x.begin(), x.end() #define sortt(x) sort(all(x)) #define unq(vt)...
ALGO
0.999938
3.847991
{ "github_metadata": { "branch": "main", "commit_count": 120, "repo_created_at": "2024-01-27T18:40: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": "dca2418ee7...
03aeef86-a654-4b23-b90e-21308f54127e
Rainboylvx/pcs
luogu/2149/l1.cpp
/* author: Rainboy email: <EMAIL> time: 2022年 08月 05日 星期五 23:44:59 CST */ #include <bits/stdc++.h> #include "utils/graphviz.hpp" using namespace std; using namespace DOT; typedef long long ll; const int maxn = 1e6+5,maxe = 1e6+5; //点与边的数量 // graphviz<DI> graph; int n,m; int X1,Y1...
ALGO
0.999922
3.817338
{ "github_metadata": { "branch": "master", "commit_count": 89, "repo_created_at": "2019-11-03T09:56:59.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 2 }, "file_meta": { "content_id": "f5d2e47ef...
f926b7fc-2570-4d77-87e7-0b5a27c0c0fc
YMChenLiye/ClySTL
Container/AVLTree.h
#ifndef AVLTree_h #define AVLTree_h template<typename Comparable> class AVLTree{ public: AVLTree(); AVLTree(const AVLTree & rhs); ~AVLTree(); const Comparable& findMin() const; const Comparable& findMax() const; bool contains(const Comparable & x) const; bool isEmpty() const; void printTree() const; ...
ALGO
0.976595
4.878415
{ "github_metadata": { "branch": "master", "commit_count": 14, "repo_created_at": "2016-02-29T06:29:34.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "d0b6030ef...
d16b5220-77a8-4806-be0f-e4b98863a644
7oSkaaa/CP-Templates
Factors.cpp
#include <bits/stdc++.h> using namespace std; #define cin_2d(vec, n, m) for(int i = 0; i < n; i++) for(int j = 0; j < m && cin >> vec[i][j]; j++); #define cout_2d(vec, n, m) for(int i = 0; i < n; i++, cout << "\n") for(int j = 0; j < m && cout << vec[i][j] << " "; j++); #define fixed(n) fixed << setprecision(n) #defi...
ALGO
0.999256
3.308853
{ "github_metadata": { "branch": "main", "commit_count": 510, "repo_created_at": "2021-10-12T21:49:50.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 137, "forks": 31, "issues": 1, "pull_requests": 2 }, "file_meta": { "content_id": "47d8154...
a7a43aa9-fd46-4880-a692-60386ad9c68e
BFDestroyeer/pp_2020_autumn_informatics
modules/task_2/streltsova_y_readers_writers/readers_writers.cpp
// Copyright 2020 <NAME> #include <mpi.h> #include <random> #include <ctime> #include "../../../modules/task_2/streltsova_y_readers_writers/readers_writers.h" void wait(double seconds) { double t1 = MPI_Wtime(); while (MPI_Wtime() - t1 < seconds) {} } int accessData(int count) { int data = 0; // Data are...
ALGO
0.99848
4.386612
{ "github_metadata": { "branch": "master", "commit_count": 1525, "repo_created_at": "2020-10-08T08:09:18.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 69, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "fdf679...
83e8bf87-dda5-48ba-9f9e-da0d8ebbf10b
charles-pku-2013/CodeRes_Cpp
PAT/4-08目录树.cpp
#include <cstdio> #include <cstring> #include <string> #include <cctype> #include <algorithm> #include <vector> #include <set> #include <iostream> using namespace std; enum { TYPE_DIR, TYPE_FILE }; void rstripString( string &str ) { char *start = (char*)(str.c_str()); char *p = start + str.length() - 1; ...
TOOL
0.995025
4.248372
{ "github_metadata": { "branch": "master", "commit_count": 507, "repo_created_at": "2015-10-12T16:10:26.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 6, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "1b38423c...
adfb850f-6897-427c-b7ed-42f6561956ae
DangZhonghua/CodingPractice
backtracing/Medium/Remove Invalid Parentheses.cpp
/* Remove Invalid Parentheses https://www.geeksforgeeks.org/remove-invalid-parentheses/ An expression will be given which can contain open and close parentheses and optionally some characters, No other operator will be there in string. We need to remove minimum number of parentheses to make the input string valid. If ...
ALGO
0.999902
5.713981
{ "github_metadata": { "branch": "master", "commit_count": 774, "repo_created_at": "2018-02-26T08:48:55.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "f250c577...
3b6ad6ae-a811-406b-989d-650728c86015
jaehyunp/stanfordacm
code/ReducedRowEchelonForm.cc
// Reduced row echelon form via Gauss-Jordan elimination // with partial pivoting. This can be used for computing // the rank of a matrix. // // Running time: O(n^3) // // INPUT: a[][] = an nxm matrix // // OUTPUT: rref[][] = an nxm matrix (stored in a[][]) // returns rank of a[][] #include <iostream>...
ALGO
0.999994
5.645512
{ "github_metadata": { "branch": "master", "commit_count": 72, "repo_created_at": "2014-06-19T22:27:46.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1630, "forks": 496, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "a84f...
374eeb49-fb8b-42f7-9f3b-24b896afeb1f
PakinDioxide/Submission
TOI/04/toi4_mountain.cpp
#include <bits/stdc++.h> using namespace std; int main() { vector <vector <char>> a(100, vector <char> (1000, '.')); int n, hh = 0, w = 0; cin >> n; for (int o = 0; o < n; o++) { int p, q; cin >> p >> q; w = max(w, p+2*q-1); hh = max(hh, q-1); int x = p-1, y = 0...
ALGO
0.999854
3.528726
{ "github_metadata": { "branch": "main", "commit_count": 48, "repo_created_at": "2023-11-07T05:54:56.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "8d9a7a9b2cb...
28041f2f-9be1-41a9-9f0a-8e7a5808eaff
budazhapova/RL1
Bandit.cpp
#include <iostream> #include <fstream> #include <algorithm> #include <cmath> #include <chrono> #include "Bandit.h" void Bandit::reset(){ // generator to use with distributions // NOTE: random_device can produce same sequences, depending on compiler(?) std::mt19937 generator(std::time(nullptr)); // get...
ALGO
0.999856
5.756331
{ "github_metadata": { "branch": "main", "commit_count": 6, "repo_created_at": "2020-12-10T22:37: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": "730b9bbdfb95...
0349b07b-a1be-436d-bf1d-ca27a056a3cc
romeorizzi/esami-algo-public
2019-02-26/cats/sol/exp.cpp
// As dp.cpp, but does not memoize partial solutions. #include <iostream> #include <cmath> #define MAXN 1000 using namespace std; int M[MAXN], F[MAXN]; int nM, nF; int score(int posM, int posF) { return abs(M[posM] - F[posF]); } int max_alignment(int posM, int posF) { // Check that we have some remaining ...
ALGO
0.999995
4.631023
{ "github_metadata": { "branch": "master", "commit_count": 42, "repo_created_at": "2020-06-14T08:28:53.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 7, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "da9a4fada...
3f5ec872-564d-4c1d-b847-8bebb6c71eb2
terminal0gr/WebApriori
Python/datasets/Experiments/Goethals Bart/C++/eclat/testeclat.cpp
/*---------------------------------------------------------------------- File : testeclat.cpp Contents: eclat algorithm for finding frequent sets Author : <NAME> Update : 13/5/2005 ----------------------------------------------------------------------*/ #include <iostream> using namespace std; #include <s...
ALGO
0.995804
4.820868
{ "github_metadata": { "branch": "master", "commit_count": 532, "repo_created_at": "2019-10-06T08:45:11.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 2, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "e8517807...
7b7e7bf4-0412-44b0-9685-2e91ebcc96e4
mustafa-qamaruddin/Workspace
the-grid-search/main.cpp
#include <cmath> #include <cstdio> #include <vector> #include <iostream> #include <algorithm> using namespace std; char** grid; char** pattern; void print_matrix(char** m, int r, int c){ for(int i = 0; i < r; i++){ for(int j = 0; j < c; j++){ cout << m[i][j] << " "; } cout << ...
ALGO
0.999512
4.104946
{ "github_metadata": { "branch": "master", "commit_count": 27, "repo_created_at": "2014-11-23T22:48: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": "c390b6ebe...
87baa242-27bc-48a4-8410-58e7b3ffaa9b
Yawn-Sean/Daily_CF_Problems
daily_problems/2024/11/1126/personal_submission/cf223c_lengli.cpp
/* lengli_QAQ Hope there are no bugs!!! */ #include <bits/stdc++.h> #define fastio std::ios::sync_with_stdio(0); std::cin.tie(0); std::cout.tie(0) #define all(x) x.begin(),x.end() #define pb push_back template <unsigned M_> struct ModInt { static constexpr unsigned M = M_; unsigned x; constexpr ModInt() : x(0U) ...
ALGO
0.999938
3.758422
{ "github_metadata": { "branch": "main", "commit_count": 20410, "repo_created_at": "2024-02-26T01:04:08.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 478, "forks": 302, "issues": 0, "pull_requests": 7 }, "file_meta": { "content_id": "c463...
406c5d1c-d6c3-4225-b37d-f523ee4a721b
atatomir/work
_infoarena/---.Plimbare/main.cpp
#include <iostream> #include <cstdio> #include <cstring> #include <vector> #include <algorithm> #include <cmath> #include <stack> using namespace std; #define mp make_pair #define pb push_back #define ll long long #define maxN 111 int n, i, j, x, y, m; bool adj[maxN][maxN]; bool rev[maxN][maxN]; stack<int> S; vecto...
ALGO
0.999996
3.749122
{ "github_metadata": { "branch": "master", "commit_count": 302, "repo_created_at": "2015-03-29T18:54: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": "5043dc01...
f59dabb1-a062-4e92-b5c8-61115fe127ea
RuoAndo/NII-SOCs-admin-tools
clustering/pthread_clustering/init-label.cpp
#include <stdio.h> #include <stdlib.h> #include <stdbool.h> #include <math.h> #include <pthread.h> #include <string> #include <iostream> #include <fstream> #include <eigen3/Eigen/Dense> #include <eigen3/Eigen/Core> #include <eigen3/Eigen/SVD> #include <random> #define THREAD_NUM 15 #define CLUSTER_NUM 20 static int...
DATA
0.903656
3.888336
{ "github_metadata": { "branch": "master", "commit_count": 2367, "repo_created_at": "2016-10-22T03:41:30.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 0, "issues": 0, "pull_requests": 3 }, "file_meta": { "content_id": "02a5525...
fe195a74-9714-424a-8b5c-8fc5ce7485ba
manbolq/DGIIM
2/1_cuatrimestre/ED/practicas/practica3-colas_y_pilas/estudiante/include/maxstack.h
/** * @file maxstack.h * @brief Archivo de especificación del TDA MaxStack * @author */ #include <queue> #include <ostream> using namespace std; /** * @brief Pareja de datos que guarda el valor y el máximo de la cola * @param value Almacena el valor * @param max Almacena el maximo de la estructura */ struc...
ALGO
0.981773
5.319179
{ "github_metadata": { "branch": "main", "commit_count": 14, "repo_created_at": "2023-02-25T20:04: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": "d626cb99936...
e1ccc494-2293-4266-9779-fea465f43d7e
merimaus/prog-zadaci
stringovi/patricia.cpp
#include <iostream> #include <vector> #include <string> using namespace std; class Node { public: string keypart; bool isendofword; vector<Node *> children; Node(const string &part = "") : keypart(part), isendofword(false), children(26, nullptr) {} }; class PatriciaTrie { Node *root; ...
ALGO
0.999791
4.994256
{ "github_metadata": { "branch": "main", "commit_count": 28, "repo_created_at": "2024-10-03T19:14:52.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "0ff4f003298...
968493df-1900-42eb-82eb-af21935232a5
mmikhasenko/wavefitter
src/M3bodyAngularBasis.cc
// Copyright [2016] <NAME> #include <M3bodyAngularBasis.h> #include <TWigner.h> #include "Math/SpecFuncMathMore.h" std::complex<double> Math::ZJMLS(uint J, int M, uint L, uint S, double thetaI, double phiI, double theta, double phi) { int minSJ = (S...
ALGO
0.996988
4.335761
{ "github_metadata": { "branch": "master", "commit_count": 217, "repo_created_at": "2021-11-26T15:41: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": "46941ff0...
3b8ac18a-0873-4daf-bcf7-98b0dc27d49f
chickenchobab/BOJ-problem-solving
3_data_structure/2_tree/1517_버블_소트.cpp
#include <iostream> #include <algorithm> #include <vector> #define fastio ios::sync_with_stdio(false);cin.tie(0);cout.tie(0); using namespace std; class SegmentTree{ private: int size; vector<int> tree; public: SegmentTree(int n){ for (size = 1; size <= n; size *= 2); tree.assign(size * 2, 0); } vo...
ALGO
0.999842
4.299342
{ "github_metadata": { "branch": "main", "commit_count": 82, "repo_created_at": "2023-07-26T09:20: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": "6c6c2526b9a...
874a3c07-0129-4e97-9a67-db86c3e8f653
shoryaagrawal553/DSA
Binary Search/aggressive_cows.cpp
/* from geeksforgeeks.org You are given an array with unique elements of stalls[], which denote the position of a stall. You are also given an integer k which denotes the number of aggressive cows. Your task is to assign stalls to k cows such that the minimum distance between any two of them is the maximum possible....
ALGO
0.999985
5.728217
{ "github_metadata": { "branch": "main", "commit_count": 155, "repo_created_at": "2025-04-09T18:09: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": "317303721d...
0761e6b4-e3ff-4e4c-b846-fe8fc7df5fe4
FangGet/BundleFusion_Ubuntu_Pangolin
include/FreeImage/include/CGAL/Mesh_edge_criteria_3.h
// Copyright (c) 2010 INRIA Sophia-Antipolis (France). // All rights reserved. // // This file is part of CGAL (www.cgal.org). // You can redistribute it and/or modify it under the terms of the GNU // General Public License as published by the Free Software Foundation, // either version 3 of the License, or (at your op...
TOOL
0.921396
4.576336
{ "github_metadata": { "branch": "master", "commit_count": 7, "repo_created_at": "2020-06-29T03:53:38.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 132, "forks": 34, "issues": 6, "pull_requests": 0 }, "file_meta": { "content_id": "f02c402...
24bcff96-26b2-4f7e-898a-96060cfd293e
Mry3ll0w/EDNL
2022/grafos/p8.cpp
#include <iostream> #include <cmath> #include <vector> #include "lib/alg_grafoPMC.h" using namespace std;//Avoid using std:: .... int main(){ return 0; } /** /* El archipiélago de Tombuctú, está formado por un número indeterminado de islas, cada una de las cuales tiene, a su vez, un número indeterminado de ci...
ALGO
0.99961
4.855077
{ "github_metadata": { "branch": "main", "commit_count": 147, "repo_created_at": "2021-03-23T11:31: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": "3976388e31...
0d6d6daf-5ee1-40aa-adb8-41c6ba3e946b
mdsiaofficial/ProblemSolving
LeetCode/35_Search_insert_position.cpp
#include <bits/stdc++.h> #include <iostream> #include <iomanip> #include <cmath> #include <string> #define pi 3.14159 #define forn(i, n) for (int i = 0; i < int(n); i++) #define nl endl #define ll long long #define ld long double #define ull unsigned long long #define mod 90000007 #define fs(n) fixed<<setprecision(in...
ALGO
0.999882
5.741796
{ "github_metadata": { "branch": "master", "commit_count": 1863, "repo_created_at": "2022-06-28T02:10:16.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "2e47da2...
d4bd1676-2237-4b4e-965f-1044953740f0
stonneau/hpp-core
include/hpp/core/problem.hh
// // Copyright (c) 2005, 2006, 2007, 2008, 2009, 2010, 2011 CNRS // Authors: <NAME> // // This file is part of hpp-core // hpp-core is free software: you can redistribute it // and/or modify it under the terms of the GNU Lesser General Public // License as published by the Free Software Foundation, either version // ...
TOOL
0.914957
6.137097
{ "github_metadata": { "branch": "master", "commit_count": 655, "repo_created_at": "2015-06-09T15:44:52.000Z", "is_fork": true, "is_org_owned": false, "forked_from": "humanoid-path-planner/hpp-core", "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { ...
a3e2b623-a77d-4dc1-bd3e-fd6177e13960
ishandutta2007/codeforces-s
smax/normal/1277/D.cpp
#include <bits/stdc++.h> using namespace std; unordered_map<string, int> mp[4]; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); //freopen("input.txt", "r", stdin); //freopen("output.txt", "w", stdout); int t; cin >> t; while (t--) { int n; cin >> n; ...
ALGO
0.999364
3.492298
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2024-10-30T16:07: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": "09ee757d2cf1...
f329cf96-c0ea-4f0c-a302-2c558ab6540c
QuickSorting/a2oj
Div2E/62.cpp
#include <bits/stdc++.h> using namespace std; const int N = 107; char s[N][N]; int cnt[N][N]; pair<int, int> left_corner[N][N]; char get_letter(char a = ' ', char b = ' ', char c = ' '){ char res = 'A'; for(int i = 0; i < 3; i++, res++){ if(res != a && res != b && res != c){ break; } } return res; } ...
ALGO
0.999985
3.021351
{ "github_metadata": { "branch": "master", "commit_count": 27, "repo_created_at": "2018-12-17T18:32: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": "b4cc7c517...
77db6e5b-bd30-4de5-8584-7bcdc7ce9b11
AlanSantos01/Pratica11
exerc-8.cpp
#include <iostream> using namespace std; bool eh_primo(int numero) { if (numero <= 1) { return false; } if (numero <= 3) { return true; } if (numero % 2 == 0 || numero % 3 == 0) { return false; } for (int i = 5; i * i <= numero; i += 6) { ...
ALGO
0.998913
4.986744
{ "github_metadata": { "branch": "main", "commit_count": 2, "repo_created_at": "2023-10-06T13:52:29.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "2df17148b095...
111f779f-4680-4d93-873a-e0b72a0bdbfc
Sanket-Mathur/CrackingTheCodingInterview
4. Trees and Graphs/4.7 Build Order.cpp
#include <iostream> #include <vector> #include <stack> #include "imports/Graph.h" using namespace std; void topoligicalUtil(Graph<int> s, int V, vector<bool> &visited, stack<int> &stack, int curr) { for (int i = 0; i < s.graph[curr].neighbors.size(); ++i) { if (!visited[s.graph[curr].neighbors[i]->data]) {...
ALGO
0.999979
5.418055
{ "github_metadata": { "branch": "main", "commit_count": 63, "repo_created_at": "2022-02-01T11: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": "e6524f5a58f...
4b36883d-693e-4c20-bee1-88c0fab3c758
KienNguyen2021/function_return_anArray
main.cpp
#include<iostream> #include <string> using namespace std; // Pass an array as argument pointer void printArray( int* array, int arraySize) { for (int i = 0; i < arraySize; i++) { cout << array[i] <<" "<< *(array +i) << endl; } } // return of this function is an Array int* reverseOrder(int * array, int arra...
ALGO
0.995534
4.904452
{ "github_metadata": { "branch": "master", "commit_count": 2, "repo_created_at": "2021-04-30T23:44: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": "445d8e183a...
dec355b0-7954-40d3-b234-6e3c4ae1145a
zhouyuhaoat/PAT
1.algorithm/11.advance/2.快乐模拟/A1017-1.cpp
/* * author: zhouyuhao * created: 2023-04-12 21:59:05 * modified: 2023-04-12 23:42:02 * item: Programming Ability Test * site: Shahu */ /* @pintia psid=994805342720868352 pid=994805491530579968 compiler=GXX ProblemSet: PAT (Advanced Level) Practice Title: 1017 Queueing at Bank https://pintia.c...
ALGO
0.999399
4.844128
{ "github_metadata": { "branch": "main", "commit_count": 64, "repo_created_at": "2025-05-20T01:36:17.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "4f0d0cd1eed...
f634e510-02d4-49e4-b3d3-d0fc4afb92f4
eiskaltdcpp/eiskaltdcpp
dht/Utils.cpp
/* * Copyright (C) 2008 <NAME>, http://strongdc.sourceforge.net/ * * 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; either version 2 of the License, or * (at your option) any later version....
TOOL
0.91325
4.426728
{ "github_metadata": { "branch": "master", "commit_count": 5755, "repo_created_at": "2010-10-15T13:22:23.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 392, "forks": 79, "issues": 226, "pull_requests": 3 }, "file_meta": { "content_id": "d40...
d6cb206f-9b4e-4928-a161-d68bafecc24a
k0michi/aoj
ITP1_7_D.cc
#include <iostream> #include <vector> int main() { int n, m, l; std::cin >> n >> m >> l; std::vector<std::vector<int>> A(n, std::vector<int>(m)); std::vector<std::vector<int>> B(m, std::vector<int>(l)); for (int i = 0; i < n; i++) { for (int j = 0; j < m; j++) { std::cin >> A[i][j]; } } ...
ALGO
0.999111
3.618723
{ "github_metadata": { "branch": "main", "commit_count": 274, "repo_created_at": "2021-08-31T13:53: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": "f768e9803a...
c867c5f6-955c-4f16-ae61-ad3a1c2d974d
jaimelay/competitive-programming
Solutions/UVa Online Judge/C++/1220.cpp
#include <bits/stdc++.h> #define MAXN 1010 using namespace std; int vis[MAXN], n; vector<int> g[MAXN]; map<string, int> m; string a, b; void DFS(int v){ vis[v] = 1; for(auto u : g[v]){ if(vis[u] == 0){ DFS(u); if(vis[u] == 1) vis[v] = 2; } } } int main(void){ ...
ALGO
0.999935
3.777012
{ "github_metadata": { "branch": "master", "commit_count": 208, "repo_created_at": "2019-02-27T01:47:27.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 5, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "a285cbaa...
346582cf-1bc5-46a8-8b30-f8d35b2a85cc
pc-hover/DSA-SDE-Sheet
NextPermutation.cpp
#include <bits/stdc++.h> using namespace std; class Solution { public: void display(vector<int> x) { for (int i = 0; i < x.size(); i++) { cout << " " << x[i]; } } void NextPermutation(vector<int> &a) { int n = a.size(); int temp = -1; // s...
ALGO
0.999991
5.380171
{ "github_metadata": { "branch": "main", "commit_count": 52, "repo_created_at": "2023-06-01T06:14:14.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "fec51400bbf...
9fac4b11-4562-466a-9d0e-fcb726218728
nachiketkanore/CP-Trash
August2021/1332C.cpp
/** * Author: <NAME> * Created: Wednesday 11 August 2021 01:28:20 PM IST **/ #include <algorithm> #include <array> #include <cassert> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <iostream> #include <string> #include <vector> #define int int64_t #define sz(x) (int)(x.size(...
ALGO
0.999875
4.373675
{ "github_metadata": { "branch": "main", "commit_count": 370, "repo_created_at": "2021-08-04T18:15:23.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "2e0ba328cb...
8baf324a-4e44-4bf7-baa4-a9d058b844d5
Arseny-Dernovich/Hash_Table
Hash_Table.cpp
#include "My_features.h" #include <cstddef> #include <cstdint> #include <time.h> const int LOAD_FACTOR = 15; struct ListNode { char* key; ListNode* next; }; struct HashTable { ListNode** buckets; size_t size; size_t count; }; uint64_t Hash_djb2(const char* str) { uint64_t hash = 53...
ALGO
0.93989
4.47757
{ "github_metadata": { "branch": "main", "commit_count": 15, "repo_created_at": "2025-04-28T07:24: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": "f59ecdb32bd...
fae85989-9db3-4d7b-b4d0-5e0539da7939
mc275/Semidense_SLAM
src/Tracking.cpp
#include "Tracking.h" #include <opencv2/core/core.hpp> #include <opencv2/features2d/features2d.hpp> #include "ORBmatcher.h" #include "FrameDrawer.h" #include "Converter.h" #include "Map.h" #include "Initializer.h" #include "Optimizer.h" #include "PnPsolver.h" #include <iostream> #include <cmath> #include <mutex>...
TOOL
0.967833
5.239939
{ "github_metadata": { "branch": "master", "commit_count": 3, "repo_created_at": "2017-08-22T05:24:54.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 12, "forks": 2, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "c61d9610e...
32e048f7-ca01-4a9a-a5df-802f5ca85508
Mujahid2923/Uva
Uva459Subgraph.cpp
///...................................*****................................................./// /// <NAME> ( <EMAIL> ) /// /// Department of Ict /// /// Comilla University , Bangladesh. ...
ALGO
0.999804
3.619465
{ "github_metadata": { "branch": "master", "commit_count": 73, "repo_created_at": "2019-02-20T18:52: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": "557077e9f...
34bbbf3b-7048-40d1-9211-7ce34e495f66
smdsniffersd/sorting
quickSort.h
#pragma once #include "quickSort.h" #include "array.h" #include <random> // Генерирует случайное целое число в диапазоне [i, j] size_t rand(size_t i, size_t j) { static std::random_device rd; // Источник энтропии static std::mt19937 gen(rd()); // Генератор Mersenne Twister std::uniform_int_distribution<si...
ALGO
0.99951
5.152063
{ "github_metadata": { "branch": "main", "commit_count": 4, "repo_created_at": "2025-06-10T16:20:59.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "bd048a5208ee...
7ae14db6-b7dd-4255-8195-a9bfa2817fe4
keqhe/leetcode
round2/leetcode64.cpp
class Solution { public: int minPathSum(vector<vector<int>>& grid) { if (grid.empty() || grid[0].empty()) return 0; int m = grid.size(); int n = grid[0].size(); vector<vector<int>> dp(m, vector<int>(n, 0)); for (int i = 0; i < m; i ++) { if (i > 0) ...
ALGO
0.999983
6.037344
{ "github_metadata": { "branch": "master", "commit_count": 267, "repo_created_at": "2015-12-22T02:14: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": "d544f0ba...
026af09b-6bb7-4ff7-8a0d-9d97ac10370e
yjl9903/XCPC
2019CPC/sy/k.cpp
#include <iostream> #include <cstdio> #include <cstring> #include <cmath> #include <algorithm> #include <vector> #include <string> #include <utility> #include <cassert> #define ms(a,b) memset(a,b,sizeof(a)) using namespace std; typedef long long ll; typedef pair<int,int> PII; const int mod = 1e9 + 7; const int inf = 1 ...
ALGO
0.999899
3.694302
{ "github_metadata": { "branch": "main", "commit_count": 2, "repo_created_at": "2022-03-25T19:33:48.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "2de8c0cc7a45...
2a72bd1c-fa49-411f-ad23-211db9fab6cc
SamueleVid/competitive_programming
olinfo/grattacieli/code.cpp
#include <bits/stdc++.h> using namespace std; #define ll long long const int MAXN = 1e5 + 5; vector<pair<int,int>> adj[MAXN]; int d[MAXN]; bool v[MAXN]; ll costruisci(int N, int M, vector<long long>& H, vector<int>& A, vector<int>& B, vector<int>& C) { for (int i = 0; i < M; i ++) { adj[A[i] + 1].push_bac...
ALGO
0.999892
3.936596
{ "github_metadata": { "branch": "main", "commit_count": 355, "repo_created_at": "2023-12-24T09:09:17.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "518c00dcdc...
dae97d56-ec4a-4bbe-abd6-df455862e30b
ishandutta2007/codeforces-r
risujiroh/normal/1307/G.cpp
#include <bits/stdc++.h> using namespace std; #ifdef LOCAL #include "debug.h" #else #define DEBUG(...) #endif template <class U, class C> struct ssp { struct edge { int to; U cap; C cost; }; static constexpr inline U inf = numeric_limits<U>::max(), eps = 1e-10; int n, s, t; vector<edge> es; ve...
ALGO
0.999911
4.173647
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2024-10-30T15:58: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": "cc00b1dcee01...
7b8a9b44-7ba6-4876-8e8f-e9b86e5bf98c
wcatp19891104/Leetcode
nextright/nextright/nextright/Source.cpp
#include<stack> #include<queue> using namespace::std; struct TreeLinkNode { int val; TreeLinkNode *left, *right, *next; TreeLinkNode(int x) : val(x), left(NULL), right(NULL), next(NULL) {} }; class Solution { public: void connect(TreeLinkNode *root) { if (root == NULL) return; if (root->left == NULL) ...
ALGO
0.999988
4.725327
{ "github_metadata": { "branch": "master", "commit_count": 7, "repo_created_at": "2014-10-08T05:26:55.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b4d6c653ef...
4130ac3c-207f-4fa2-a189-e0167a557b50
AnmolShubhamsteam/Contest
Count.cpp
#include <iostream> #include <cassert> using namespace std; void count_zeros_ones(int arr[], int size, int& count_zeros, int& count_ones) { // Write Function Only } // ----------------------------------------Don't Touch-------------------------------------------------------------------- void run_te...
ALGO
0.99846
5.642207
{ "github_metadata": { "branch": "main", "commit_count": 2, "repo_created_at": "2024-01-16T14:25:33.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 2, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "492e915a9d46...
4c5982ac-f1ca-427f-a7cb-291c64ebe209
VaiduryaM/Leetcode150
Maximum Depth of Binary Tree.cpp
//104. Maximum Depth of Binary Tree /** * 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, TreeNo...
ALGO
0.999902
5.8732
{ "github_metadata": { "branch": "main", "commit_count": 23, "repo_created_at": "2023-10-19T19:34: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": "0294fe2ad52...
5e39c117-c5de-4784-89b7-83cb9d8befda
lfsjesus/feup-aed
TP10/Tests/graph.h
// AED 2022/2023 - Aula Pratica 10 // <NAME> (DCC/FCUP) [last update: 27/11/2022] #ifndef _GRAPH_H_ #define _GRAPH_H_ #include <list> #include <vector> #include <iostream> using namespace std; class Graph { struct Edge { int dest; // Destination node int weight; // An integer weight in...
ALGO
0.999157
6.414209
{ "github_metadata": { "branch": "master", "commit_count": 24, "repo_created_at": "2022-09-22T20:07: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": "1ab9b832f...
6ffde499-0ec1-4522-b21f-a3305e0c3e52
Dongubak/C-Prime
C++Prime/10-8.h
#ifndef STACK_H_ #define STACK_H_ #include <iostream> template <class T> void sum(T typeTArray[], int elementCount) { T total{}; for (int i = 0; i < elementCount; i++) { total += typeTArray[i]; } std::cout << "sum of Arr : " << total << '\n'; } template <class T> void sort(T* typeTArray, int elementCount...
ALGO
0.934655
4.579728
{ "github_metadata": { "branch": "master", "commit_count": 14, "repo_created_at": "2023-05-15T12:43: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": "2d1ff7043...
acafa674-57ee-474f-825e-edae0f4d68cd
sam10486/bluestein
include/NTT.h
#ifndef _NTT_H_ #define _NTT_H_ #include <vector> #include <iostream> #include <fstream> #include <NTL/ZZ.h> using namespace NTL; class NTT{ public: unsigned long N; // NTT ponit ZZ N_ZZ; ZZ IN; // inverse of N (mod p) ZZ p; // modulus of NTT // must be a prime ZZ W; // primitive nth root of unity ...
ALGO
0.989048
4.976328
{ "github_metadata": { "branch": "main", "commit_count": 39, "repo_created_at": "2022-12-16T09:07: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": "6bfda82cac9...
f649990c-e127-4d9d-90e5-2460a4e7996a
RobinStar520/LeetCode
Medium/2521-Distinct Prime Factors of Product of Array.cpp
// Given an array of positive integers nums, return the number of distinct prime factors in the product of the elements of nums. // Note that: // A number greater than 1 is called prime if it is divisible by only 1 and itself. // An integer val1 is a factor of another integer val2 if val2 / val1 is an integer. // ...
ALGO
0.999788
7.055723
{ "github_metadata": { "branch": "main", "commit_count": 84, "repo_created_at": "2023-07-22T06:44:58.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "6628065a590...
cf51561a-c186-42d4-9b96-2a20bf3eb28a
mongodb/mongo
src/third_party/mozjs/extract/mfbt/SHA1.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: */ /* This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0...
ALGO
0.981016
6.875832
{ "github_metadata": { "branch": "master", "commit_count": 90314, "repo_created_at": "2009-01-15T16:15:18.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 27329, "forks": 5655, "issues": 0, "pull_requests": 82 }, "file_meta": { "content_id": ...
403d4eb4-5471-4b31-b50b-1da4f4b7b2eb
prongs/interview-preparation
RocketFuel Test/RF1.cpp
// Ideone_Language_Id:1 /* Don't remove the first line! */ #include <iostream> #include <string.h> #include <stdio.h> #include <algorithm> #include <vector> #include <set> #include <map> #include <cmath> #include <set> #include <utility> #include <stack> #include <deque> #include <cmath> #include <cassert> /*more #incl...
ALGO
0.999743
3.719553
{ "github_metadata": { "branch": "master", "commit_count": 6, "repo_created_at": "2012-11-08T08:06:17.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 4, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "c425f757ed...
7d2cf4db-dda7-44c0-8240-c291f49bb833
nb-/ParticleSwarms
newdev2population.cpp
#include "newdev2population.h" #include "randomhelper.h" #include <stdlib.h> #include <vector> #include <utility> #include <algorithm> #include <cmath> NewDev2Population::NewDev2Population(int pointPopSize, int dPopSize, OptimizationFunction *optFunc) :Population(pointPopSize, optFunc), mDSize(dPopSize) { m...
ALGO
0.993154
3.862
{ "github_metadata": { "branch": "master", "commit_count": 12, "repo_created_at": "2013-09-23T19:18:37.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "4c518b30d...
42da3890-b2b8-4400-8855-5ee886539c38
QMCPACK/qmcpack
src/QMCWaveFunctions/Fermion/DelayedUpdate.h
////////////////////////////////////////////////////////////////////////////////////// // This file is distributed under the University of Illinois/NCSA Open Source License. // See LICENSE file in top directory for details. // // Copyright (c) 2019 QMCPACK developers. // // File developed by: <NAME>, <EMAIL>, Argonne N...
TOOL
0.928055
6.668173
{ "github_metadata": { "branch": "develop", "commit_count": 28915, "repo_created_at": "2017-01-11T19:02:29.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 345, "forks": 147, "issues": 438, "pull_requests": 16 }, "file_meta": { "content_id": ...
ce5bc7e1-e44e-42fb-a3b5-06f64a348008
fangding678/OnlineJudge
leetcode/archive/_C0142.h
#include <iostream> using namespace std; //Definition for singly-linked list. struct ListNode { int val; ListNode *next; ListNode(int x) : val(x), next(NULL) {} }; class Solution { public: ListNode *detectCycle(ListNode *head) { ListNode *p = head; ListNode *res = NULL; if (!he...
ALGO
0.999974
5.28832
{ "github_metadata": { "branch": "master", "commit_count": 71, "repo_created_at": "2016-09-11T01: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": "4eb5c285b...
2ff56ce7-2045-401d-a5e9-aba9dcf27f85
AlperSaltabas/OR_Tools_Google_API
documentation/tutorials/cplusplus/chap10/cvrp_solution.h
// Copyright 2011-2014 Google // 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 wri...
ALGO
0.993266
6.330329
{ "github_metadata": { "branch": "master", "commit_count": 3052, "repo_created_at": "2015-03-15T18:40: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": "b2c9c3d...
e779cd15-c79b-4e33-9313-9246d928e722
minSsan/algorithm
baekjoon/이진검색트리/1202-FAILED.cpp
#include <iostream> #include <algorithm> #include <map> #include <queue> //? 명제: 가격이 가장 높은 보석은 무게가 가장 높은 가방에 넣는 것이 이득이다. //* 가격이 높다고 해서 무게가 가볍다는 보장을 할 수 없다. (이 문제에서는 가방에 최대한 알맞는 보석 중 가장 비싼 보석을 넣는 것이 이득) //* 귀류법: 가격이 가장 높은 보석을, (1) 가방에 넣지 않는 것을 가정(~P) //* => 보석 가격을 얻을 수 없으므로, 이득이 될 수 없다(모...
ALGO
0.999939
4.577419
{ "github_metadata": { "branch": "main", "commit_count": 338, "repo_created_at": "2022-01-17T03:33: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": "3a0dc85888...
27833b05-b905-4f41-8ef7-8b90c8ce1fd8
janani23-3/CSA0260-C-Programming-for-Online-PDF-Editor
7. Structure of student having fields.cpp
#include <stdio.h> #include <stdlib.h> #include <string.h> struct Student { int roll_no; char stud_name[50]; int mark1; int mark2; int mark3; int total_marks; float avg_marks; }; int main() { int n, i, j; printf("Enter the number of students: "); scanf("%d", &n); struct Stu...
ALGO
0.99964
4.537694
{ "github_metadata": { "branch": "main", "commit_count": 16, "repo_created_at": "2023-03-29T08:45:36.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b432c8fc010...
49a9e96f-419e-4732-aa8b-00e4972aa14a
ishandutta2007/codeforces-l
lichenkoh/normal/1446/D1.cpp
#ifdef ONLINE_JUDGE #pragma GCC target("sse,sse2,sse3,ssse3,sse4,sse4.1,sse4.2,popcnt,mmx,avx") #pragma GCC optimize("Ofast") #endif #include "bits/stdc++.h" #ifndef ONLINE_JUDGE #pragma GCC target("sse,sse2,sse3,ssse3,sse4,sse4.1,sse4.2,popcnt,mmx,avx") #pragma GCC optimize("Ofast") #endif #include <assert.h> using na...
ALGO
0.999803
3.582617
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2024-04-11T06:17:27.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "7feaa19716ea...
abb679ac-59c8-4f86-b96e-93c27eee4c5b
embiway/Junior_Training
D2/Oulipo.cpp
#include<iostream> #include<string> #include<vector> // #include <ext/pb_ds/assoc_container.hpp> // using namespace __gnu_pbds; using namespace std; typedef long long ll; #define speed ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0) #define mp make_pair #define pb push_back #define ff first #define ss second #defin...
ALGO
0.990567
4.224092
{ "github_metadata": { "branch": "master", "commit_count": 5, "repo_created_at": "2020-08-20T13:53:18.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "2fd625d5f6...
c73f89e8-e085-40b4-95f1-5afb0ebec348
Narotam-Mishra/problem_solving
BinarySearch_problems/KokoEatingBananas.cpp
// Problem link - https://leetcode.com/problems/koko-eating-bananas/description/ #include<bits/stdc++.h> using namespace std; bool canKokoEatAllBananasInMidSpeed(vector<int>& piles, int mid, int h){ // time taken to eat a pile of banans = ceil value of(piles[i]/mid) // where piles[i] is number of bananas in ...
ALGO
0.999875
5.348738
{ "github_metadata": { "branch": "main", "commit_count": 716, "repo_created_at": "2023-12-06T18:31:23.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "0c2f9c5e18...
54b4d6c9-f7b2-40bb-8ae9-ca402209c694
VBsaini/DSA
3141-minimum-size-subarray-in-infinite-array/3141-minimum-size-subarray-in-infinite-array.cpp
class Solution { public: int minSizeSubarray(vector<int>& nums, int target) { int n = nums.size(); int l = 0; int r = 0; int ans = INT_MAX; int sum = 0; long long Tsum = 0; for(auto a : nums){ Tsum += a; } int k = target/Tsum; ...
ALGO
0.999966
5.401988
{ "github_metadata": { "branch": "main", "commit_count": 304, "repo_created_at": "2024-09-09T16:08:21.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 3, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "bb80c3134b...
f8521084-2aad-47c0-8c20-d8a58ac4287c
Fortitude42/CompetitiveProgrammingArchive
Very interesting personalities/NEERC11/A/b.cpp
//by paradox & gege & parasat #include <bits/stdc++.h> //#include <ext/pb_ds/assoc_container.hpp> //#include <ext/pb_ds/tree_policy.hpp> using namespace std; //using namespace __gnu_pbds; //#define int long long //#pragma GCC optimize("Ofast") //#pragma comment(linker, "/s...
ALGO
0.999673
3.420615
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2024-05-08T16:52:20.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "5c24fe64cd41...
e4776ed0-2360-46a9-a886-df4edd886f0b
anishsingh20/LeetCode-Cpp-solutions
Programs/FindDifferenceInStrings.cpp
//most optimal solution to find the different char in both strings using XOR ops. //we can use XOR ops to find the different element in an array. In this case we simply typecast the XORed result to c char. char findTheDifference(string s, string t) { string res = (s+t);//concatenating both strings into ...
ALGO
0.999448
4.567255
{ "github_metadata": { "branch": "master", "commit_count": 90, "repo_created_at": "2018-06-02T07:47:06.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 2, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "b779431d8...
7340c28b-0b2a-461c-b908-96d606a55f02
croft/netgen
Solver/recursive_definitions.h
#ifndef REC_DEF_H #define REC_DEF_H #include "z3++.h" #include "automata.h" using namespace z3; class recursive_definition { public: virtual expr base( const int, const int) const = 0; virtual expr change_rec(const int,const int, const expr) const = 0; virtual expr default_rec(const int,const int, const int)c...
ALGO
0.990984
4.201685
{ "github_metadata": { "branch": "master", "commit_count": 228, "repo_created_at": "2017-10-12T01:18: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": "b57e2172...
93605dae-c811-4da3-ad46-1aebdb62a5c4
MFerreira01/ApplicationTri
projetC++/src/ImageDouble.cpp
#include <iostream> #include <fstream> #include <string> #include <cmath> #include <vector> #include <limits> #include <stack> #include <algorithm> #include "ImageDouble.h" #define PI 3.14159265358979323846 // constructeurs et destructeur CImageDouble::CImageDouble() { this->m_iHauteur = 0; this->m_iLargeur = 0; ...
TOOL
0.963672
4.405419
{ "github_metadata": { "branch": "master", "commit_count": 28, "repo_created_at": "2024-12-04T21:00:36.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "638739894...
622ef339-292e-410d-b291-4d566f1de7c4
sailesh2/CompetitiveCode
2020/lcContest120C.cpp
/** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x), left(NULL), right(NULL) {} * }; */ struct CoinNode{ vector<pair<int,int>> coinsAvailable; vector<pair<int,int>> coinsNeeded; }; bool coinComparator(pa...
ALGO
0.999995
5.565863
{ "github_metadata": { "branch": "master", "commit_count": 7, "repo_created_at": "2018-12-15T06:33: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": "f41132cda4...
637feeda-7708-45cd-b0b2-80051e1565d4
Rushikesh-24/CPP-Programs
Sem_3/LabB/Exp4/D.cpp
#include <cstring> #include <iostream> #include <string> using namespace std; class String { char *s; public: String() { s = new char[100]; } friend istream &operator>>(istream &is, String obj) { is >> obj.s; return is; } friend ostream &operator<<(ostream &os, const String obj) { os << obj....
ALGO
0.985651
4.170621
{ "github_metadata": { "branch": "main", "commit_count": 1, "repo_created_at": "2024-07-06T10:35:01.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 1, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "fbba6780351d...
16a78e18-479f-471f-8b11-b6a0c5255762
w74srm/tsinghua
cppfile/hdoj/1000-1049/1036.cpp
#include <iostream> #include <cmath> using namespace std; int n; double d; int t; int totalTime; bool flag; void input(); void output(); int main() { cin >> n >> d; while (cin >> t) { totalTime = 0; flag = true; input(); output(); } return 0; } void input() { for (int i = 0; i < n; i++) { int tem...
ALGO
0.996163
3.345503
{ "github_metadata": { "branch": "master", "commit_count": 76, "repo_created_at": "2020-04-06T03:34:18.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 0, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "108dd1c91...
91216a2d-63c7-4953-bb35-184e554ba887
priyankjairaj100/Codeforces-Solutions
contest/1230/b/61125789_wrong_answer_1.cpp
//Gear Third #include <bits/stdc++.h> #include <string> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> using namespace std; using namespace __gnu_pbds; #define int long long const int MAX = 1e5 + 5; const int MOD = 1e9 + 7; #define fastio ios_base::sync_with_stdio(false);cin.tie(NULL);c...
ALGO
0.999996
4.297581
{ "github_metadata": { "branch": "master", "commit_count": 1, "repo_created_at": "2020-04-25T03:06: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": "855677f1c0...
c2d3be6a-b1ca-4a3d-80f9-f9a3c52752af
Kitzdev/DS-2ndSemester
Pembahasan_8/prak3-2.cpp
#include <iostream> #include <math.h> #include <stdlib.h> #include <iomanip> using namespace std; class Stack { struct node { int data; node *link = NULL; }; public: node *stackHead = (node *)malloc(sizeof(node)); //Check whether the stack is empty or not. bool IsEmpt...
ALGO
0.998959
4.352723
{ "github_metadata": { "branch": "main", "commit_count": 60, "repo_created_at": "2021-03-29T05:42:12.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 1, "forks": 0, "issues": 0, "pull_requests": 0 }, "file_meta": { "content_id": "f156b6d8522...
87cdc0ac-a3dc-44fa-802d-97936d9f0677
mcostalba/poker
poker.cpp
#include <algorithm> #include <cstdint> #include <cstring> #include <ctype.h> #include <iostream> #include <set> #include <sstream> #include <string> #include "poker.h" using namespace std; namespace { const string Values = "23456789TJQKA"; const string Suites = "dhcs"; const string SO = "so"; // Needed by std::se...
ALGO
0.997563
5.891291
{ "github_metadata": { "branch": "master", "commit_count": 37, "repo_created_at": "2018-03-31T14:20:40.000Z", "is_fork": false, "is_org_owned": false, "forked_from": null, "stars": 28, "forks": 5, "issues": 3, "pull_requests": 1 }, "file_meta": { "content_id": "7d0a6e9d...
53ade1b2-16f0-4c6f-9455-70fae6337ec0
temoto-framework/temoto_action_engine
src/umrf_graph_exec.cpp
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * Copyright 2025 <NAME> * * 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/l...
TOOL
0.949675
7.208743
{ "github_metadata": { "branch": "main", "commit_count": 173, "repo_created_at": "2019-07-11T11:10:24.000Z", "is_fork": false, "is_org_owned": true, "forked_from": null, "stars": 4, "forks": 0, "issues": 3, "pull_requests": 0 }, "file_meta": { "content_id": "7f72a7359cf...
19270e97-2f23-47cf-9ac5-3bcf3ebcd9c9
lpradop/CC-2
lab3/e2.cpp
#include <iostream> using namespace std; void PrintArr(int *arr, size_t size) { for (; size > 0; --size) { cout << *arr << " "; if (size != 1) ++arr; } cout << endl; } void InvertirArrI(int *arr, size_t size) { while (size > 0) { for (size_t i = --size; i > ...
ALGO
0.999771
4.924609
{ "github_metadata": { "branch": "master", "commit_count": 16, "repo_created_at": "2020-04-27T21:26: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": "80fee4df2...