uuid
string
repo_name
string
relative_path
string
content
string
category
string
algo_rel_score
float64
quality_score
float64
88c2dec4-255c-4969-a6cb-7911b5f7fd09
skylicht-lab/skylicht-engine
Projects/Bullet3/src/BulletCollision/CollisionShapes/btSdfCollisionShape.cpp
#include "btSdfCollisionShape.h" #include "btMiniSDF.h" #include "LinearMath/btAabbUtil2.h" ATTRIBUTE_ALIGNED16(struct) btSdfCollisionShapeInternalData { BT_DECLARE_ALIGNED_ALLOCATOR(); btVector3 m_localScaling; btScalar m_margin; btMiniSDF m_sdf; btSdfCollisionShapeInternalData() : m_localScaling(1, 1, 1), ...
ALGO
0.943586
7.036384
517a32c8-3c7b-4540-9db5-250bd9bec06b
GlaucoMasi/CompetitiveProgramming
AdventOfCode/2023/Day5Pt2.cpp
#include <bits/stdc++.h> using namespace std; ifstream fin("input.txt"); ofstream fout("output.txt"); vector<vector<array<long long, 3>>> v; long long conv(string t){ long long ans = 0; for(auto c : t) ans = 10*ans+(c-'0'); return ans; } int main() { queue<pair<long long, long long>> seeds; string a; fin >...
ALGO
0.999244
4.018415
1d16a721-cb67-4a95-bd29-21ddf347041b
OpenTreeOfLife/otcetera
tools/solver/build.cpp
#include "build.h" #include "rollback.h" using std::vector; using std::list; using std::optional; using std::shared_ptr; vector<int> indices; template <typename T> bool sort_cmp(const vector<T>& v1, const vector<T>& v2) { if (v1.size() != v2.size()) return false; auto w1 = v1; std::sort(w1.begin(), w1.end(...
ALGO
0.999647
5.684813
09f4e6e4-f54e-4096-abd1-4942961b3c64
numba/llvm-mirror
lib/Support/Process.cpp
#include "llvm/ADT/StringExtras.h" #include "llvm/Config/config.h" #include "llvm/Support/ErrorHandling.h" #include "llvm/Support/FileSystem.h" #include "llvm/Support/Process.h" #include "llvm/Support/Program.h" using namespace llvm; using namespace sys; //===----------------------------------------------------------...
TOOL
0.895584
4.371686
b776c39e-b133-465d-8ab3-b672d6bbf0d7
ishandutta2007/codeforces
xay5421/normal/1709/F.cpp
#include<bits/stdc++.h> #ifdef xay5421 #define D(...) fprintf(stderr,__VA_ARGS__) #define DD(...) D(#__VA_ARGS__ "="),debug_helper::debug(__VA_ARGS__),D("\n") #include"/home/xay5421/debug.hpp" #else #define D(...) ((void)0) #define DD(...) ((void)0) #endif #define pb push_back #define eb emplace_back #define SZ(x) ((in...
ALGO
0.999924
3.66873
c50e2f78-0c98-4a3f-9071-e4e17891a64b
Mohit44790/Saralweb
Q2_1.cpp
#include <iostream> #include <fstream> #include <sstream> #include <regex> #include <unordered_map> #include <vector> #include <algorithm> using namespace std; void parseLogFile(const string &filePath, const string &targetDate, unordered_map<string, int> &ipCounts) { ifstream file(filePath); if (!file.is_open...
DATA
0.998915
6.861337
676b7623-50ca-4627-9b43-7c5cc47bfdca
giri69/StriverSheet-solutions
Arrays/SetMatrixZeros.cpp
#include<bits/stdc++.h> using namespace std; class Solution { public: void setZeroes(vector<vector<int>>& matrix) { int n=matrix.size(); int m=matrix[0].size(); vector<int>row(n,0); vector<int>col(m,0); for(int i=0;i<n;i++) { for(int j=0;j<m;j++) ...
ALGO
0.999557
5.521396
5750b963-7862-45d0-8295-7fbc535be1d7
raincross7/code-similarity
codes/train_code/problem162/problem162_107.cpp
#include<iostream> using namespace std; void Check(int a, int b); int main(){ int a, b; cin >> a; cin >> b; Check(a, b); return 0; } void Check(int a, int b){ if(a > b) cout << "a > b" << endl; else if(a < b) cout << "a < b" << endl; else if(a == b) cout << "a == b" << endl;...
ALGO
0.999842
3.290963
80d2a3ea-3ceb-4d7c-abbc-c5f07072f3a7
DendyTheElephant/VisuProject
eigen/doc/examples/QuickStart_example2_fixed.cpp
#include <iostream> #include <Eigen/Dense> using namespace Eigen; using namespace std; int main() { Matrix3d m = Matrix3d::Random(); m = (m + Matrix3d::Constant(1.2)) * 50; cout << "m =" << endl << m << endl; Vector3d v(1,2,3); cout << "m * v =" << endl << m * v << endl; }
ALGO
0.997351
3.375595
8ef2e843-dfea-42fc-941d-0f545d49fd35
abhi-glitchhg/leetcode_prep
1014-best-sightseeing-pair/1014-best-sightseeing-pair.cpp
class Solution { public: int maxScoreSightseeingPair(vector<int>& values) { int res; int cur; cur=0;res=0; for (auto i : values){ // prev best candidate was kept tracked; and then update it acc; res = max(cur+i, res); cur = max(...
ALGO
0.999971
6.458769
a9d0d15b-5b16-401b-90b9-36c41f9aa1c1
ishandutta2007/codeforces
froggyzhang/normal/1525/A.cpp
#include<bits/stdc++.h> using namespace std; typedef long long ll; inline ll read(){ ll x=0,f=1; char c=getchar(); while(c<'0'||c>'9'){ if(c=='-')f=-1; c=getchar(); } while(c>='0'&&c<='9'){ x=(x<<1)+(x<<3)+c-'0'; c=getchar(); } return x*f; } int T; int main(){ T=read(); while(T--){ int k=read();...
ALGO
0.997873
3.69532
fe7e361a-3756-4ce8-bf93-148cf7488009
mehedi-shafi/URI
URI 1217.cpp
#include <iostream> #include <string> #include <string.h> #include <cstdio> #include <iomanip> using namespace std; int main() { int t; double amount, avgamount, total_amount=0, cost, total_cost=0, avgcost; char a[20000]; cin >> t; for (int i = 1; i<= t; ++i){ cin >> cost; getchar();...
ALGO
0.98817
3.254925
15f22b1f-2100-4672-b6f1-7edc2f448895
sa8tyajeet46/dsa
Linked_List/iLinkedList.cpp
#include <bits/stdc++.h> using namespace std; class Node{ public: int data; Node* next; }; void readLinkedList(Node* head){ Node* temp=head; while(temp!=NULL){ cout<<temp->data<<" "; temp=temp->next; } } int main(){ Node* head=NULL; Node* second=NULL; Node* third=NULL; Node* four=NULL; four=new No...
ALGO
0.99963
3.866458
8d1eb186-dc96-4ea4-ba2e-00015d0ee576
ofAlpaca/SFBA-py
cpp/SFBA/Tree.cpp
// // Created by misclicked on 2020/6/21. // #include <cstdlib> #include <iostream> #include <random> #include "Tree.h" std::vector<std::vector<int>> Tree::Generate(int n) { std::mt19937 gen; std::uniform_int_distribution<> r_node(0, n - 1); Dij se; se.Initialize(n); std::vector<std::vector<int>>...
ALGO
0.996977
5.073542
e4be0c55-e078-413d-af2e-f7660c1a8beb
springer126/C-World
c++/ecnu/ECNU/1056.cpp
#include <iostream> using namespace std; int extended_euclid(int a,int b,int & x,int & y) { if (b==0) {x=1,y=0;return a;} else { int res=extended_euclid(b,a%b,x,y); int t=x;x=y;y=t-(a/b)*y; return res; } } int a,b,m; int main() { int i,j,k; int d; int x,y; while (cin>>a>>b>>m) { d=extended_euclid(a...
ALGO
0.999981
4.022931
ec84f285-c65a-4de6-b907-c5148369bb76
ltriess/hackerrank-interview-preparation
01_warm_up_challenges/02_counting_valleys.cpp
/* Example 1: Input: 8 UDDDUDUU Output: 1 Example 2: Input: 12 DDUUDDUDUUUD Output: 2 */ #include <bits/stdc++.h> #include <iostream> using namespace std; // Complete the countingValleys function below. int countingValleys(int n, string s) { int...
ALGO
0.999994
5.793303
a0c59c9c-ce05-489f-9254-826f29d778d3
Vishal-S-Hayyal/CPP
Shit practise/elab2.cpp
#include <iostream> using namespace std; int main() { int n; cin>>n; int arr[n]; int res = 10000; for(int i=0; i<n; i++){ cin>>arr[i]; } for(int i=0; i<n; i++){ for(int j=i+1; j<n; j++){ if(arr[i]>arr[j]){ res = min(res, arr[i]-arr[j]); } } } cout<<res; return 0; }
ALGO
0.999991
3.541676
bd67faf9-1a19-4818-a9a1-b373a75a8344
BlueBrain/libsonata
src/edge_index.cpp
#include "edge_index.h" #include <bbp/sonata/common.h> #include <array> #include <cstdint> #include <set> #include <unordered_map> #include <vector> #include "read_bulk.hpp" namespace bbp { namespace sonata { namespace edge_index { namespace { using RawIndex = std::vector<std::array<uint64_t, 2>>; const char* co...
DATA
0.981619
7.455044
b2fc1a03-f904-43eb-9683-a5c678d9da81
maximyuss/LeeCode
code/cpp/921.cpp
// https://leetcode.com/problems/minimum-add-to-make-parentheses-valid/ class Solution { public: int minAddToMakeValid(string s) { size_t count_open = 0, unbalanced = 0; for (char ch : s) { if (ch == '(') count_open++; else count_open--; ...
ALGO
0.999612
6.563179
430af1dc-94c6-4a06-80bc-9fc91c264476
GuoJaw/caffe-ssd-mobilenet
src/caffe/util/io.cpp
#include <boost/algorithm/string/classification.hpp> #include <boost/algorithm/string/split.hpp> #include <boost/filesystem.hpp> #include <boost/foreach.hpp> #include <boost/property_tree/json_parser.hpp> #include <boost/property_tree/ptree.hpp> #include <boost/property_tree/xml_parser.hpp> #include <fcntl.h> #include ...
TOOL
0.961818
7.1029
2c33d33a-884b-48a3-9e1f-9136430e62f1
james98k/acmicpc
9000/9012.cpp
#include <iostream> #include <vector> using namespace std; int main(){ int inputCount = 0; std::cin>>inputCount; std::vector<char> stack; std::string results[inputCount]; for(int i = 0; i < inputCount; i++){ } for(int i = 0; i < inputCount; i++){ results[i] = "YES"; std::string inputString = ...
ALGO
0.999829
4.817556
436ae364-9b33-4f1b-ae59-ca5b92527403
ReDesignIT-Dev/SPOJ-CPP
JWSPLIN-CPP/JWSPLIN-CPP.cpp
// JWSPLIN-CPP.cpp : This file contains the 'main' function. Program execution begins and ends there. // #include <iostream> using namespace std; int main() { int tests; double x[3]; double y[3]; double a1, a2, b1, b2; cin >> tests; for (int i = 0; i < tests; i++) { for (int j = 0; j < ...
ALGO
0.998494
5.307613
2ad29cc3-d72e-41ba-a17b-4dea5562dd52
DRobinson4105/competitive-programming
UCFHSPT/song.cpp
#include <iostream> #include <vector> #include <string> using namespace std; int main() { int t; cin >> t; //Run the program for t times for (int i = 0; i < t; i++) { //make a string vector to store the phrase //have the vector store "This song’s gonna get stuck inside yo’" ...
ALGO
0.996447
3.421838
91e76aef-1c9d-4db7-9f10-e2c1b6b383e0
AjajAlam1399/data-structure_and_algorithms
Recursion/question/12-46. Permutations-method 2 (without using extra space).cpp
#include <bits/stdc++.h> using namespace std; class Solution { public: public: void fun(vector<int> arr, int ind, vector<vector<int>> &result) { if (ind == arr.size()) { result.push_back(arr); return; } for (int i = ind; i < arr.size(); i++) { ...
ALGO
0.999983
5.892021
2125db86-6c59-40e9-8388-cc61b31d793d
rathi062/codes
spoj_codes/FACTCG2_2.cpp
#include<stdio.h> using namespace std; #define MAX 10000000 int prime[MAX+1]; void sieve(){ prime[1]=1; for(long long int i=2;i<=MAX;i+=2) prime[i]=2; for(long long int i=3;i<=MAX;i+=2){ if(!prime[i]){ prime[i]=i; for(long long int j=i*i,d=i<<1;j<=MAX;j+=d){ if(!prime[j])prime[j]=i; } } ...
ALGO
0.999961
3.567971
6f987fe5-89c0-4221-9b7b-8ddd8656a6ed
JadirJunior/LeetCode
2024/Treino/Binary/number_of_1_bits.cpp
#include <bits/stdc++.h> using namespace std; #define _ ios_base::sync_with_stdio(0);cin.tie(0); //n usar printf junto com cout //^comentar _ para degubar código #define endl '\n' /* macro aleatorias #define pb push_back #define pii pair<int, int> #define vi vector<int> */ /* macro para trabalhar com pair #define f...
ALGO
0.99995
4.984144
679739fc-6a49-47c5-b42b-f4271bb7467d
Skaidus/p2_AC_2021_22
src/p2/psoa.cpp
#include "Parsing/Parsing.cpp" #include "./Simulators/SoaSimulator.cpp" #include <iostream> #include <fstream> using namespace std; int main(int argc, char **argv) { // Abriendo archivos fstream init, final; init.open("final_config.txt", ios::out); final.open("init_config.txt", ios::out); // Pars...
TOOL
0.933034
4.551288
3c8b976c-ec09-42db-bd2f-b16b184cbfee
WiseCoinDev1/illum-1.-0
src/rpc/mining.cpp
#include "base58.h" #include "amount.h" #include "chain.h" #include "chainparams.h" #include "consensus/consensus.h" #include "consensus/params.h" #include "consensus/validation.h" #include "core_io.h" #include "init.h" #include "validation.h" #include "miner.h" #include "net.h" #include "pow.h" #include "rpc/server.h"...
WEB
0.99195
5.736386
566c87ba-cfea-4b0b-b5cd-12647339a3b2
vikasadhe/vikasadhe
22.A (LCM using while and if)C Program to Find LCM of two Numbers.cpp
#include <stdio.h> int main() { int n1, n2, max; printf("Enter two positive integers: "); scanf("%d %d", &n1, &n2); // maximum number between n1 and n2 is stored in max max = (n1 > n2) ? n1 : n2; while (1) { if ((max % n1 == 0) && (max % n2 == 0)) { printf("The LCM of %d...
ALGO
0.999526
4.708285
3935288d-fc9a-4c83-b058-1746c14da309
capchitts/Coding
Trees/BST/ReplaceNodeWithSumOfAllNodesGreaterThanEqualToIT.cpp
void replaceHelper(BinaryTreeNode<int>* root, int& sum) { if(!root) return; if(!root->left && !root->right) { //update sum sum += root->data; //update node root->data = sum; return; } //go first to right as there are larger or equal elements present ...
ALGO
0.999995
5.498054
68037ee8-ecab-4e76-8824-c8d8d54a3b95
Krzychulec21/grafika
lab9/FiboTree.cpp
#include <stdio.h> int f(int n) { if (n == 0 || n == 1) { return 1; } return f(n-1) + f(n-2); } int fibo(int n) { static int wywolanie; wywolanie++; printf("fibo%d(%d) = %d\n", wywolanie, n, f(n)); if (n == 0 || n == 1) { return 1; } return ...
ALGO
0.996854
5.489142
cf2f2649-26c1-4a20-ae4e-bf49441b7524
MaxSally/Competitive_Programming
Codeforces/brain_network.cpp
//https://codeforces.com/problemset/problem/690/C2 /* * Author : MaxSally */ /******** All Required Header Files ********/ #include<bits/stdc++.h> using namespace std; /******* All Required define Pre-Processors and typedef Constants *******/ #define SCD(t) scanf("%d",&t) #define SCLD(t) scanf("%ld",&t) #define SCLL...
ALGO
0.999045
4.092051
0e720329-fb62-492f-89f9-3eec0b5673a1
KushanChoudhury/Leetcode_Answers
Number_Complement.cpp
class Solution { public: string num2bin(int num){ string res=""; while(num>0){ res=to_string(num%2)+res; num/=2; } return res.empty()?"0":res; } int binary2num(string& bin) { int res = 0; int len = bin.length(); for (int i = 0;...
ALGO
0.999991
6.002462
cf508132-643c-4e77-a20e-d06103980cbb
bharatr21/leetcode-problems
2306-create-binary-tree-from-descriptions/2306-create-binary-tree-from-descriptions.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.999823
6.839058
ae865d04-3171-4b36-880a-6ce7e79ffbf2
Bissiatti/ray_tracing_cpp
main.cpp
#include <iostream> #include <cmath> #include <random> using namespace std; #include "linalg.h" #include "ray.h" #include "sphere.h" #include "cam.h" #include "util.h" #include "film.h" #include "light.h" #include <vector> std::default_random_engine generator; // Cria um gerador de números aleatórios // Cacula a cor ...
ALGO
0.97944
5.557943
0038b7f3-4c09-43a7-9497-7c9557f97b23
ShimshonDan/computationalMethods
sistemLinearEq/Sistem_linear_equation.cpp
#include <iostream> #include <fstream> #include <cmath> int max_element(double** arr, int index, int size){ //поиск максимального элемента в столбце double max_elent = arr[index][index]; int max_index = index; for(int i = index; i < size; ++i) if(std::abs(max_elent) < std::abs(arr[i][index])) ...
ALGO
0.999941
3.369262
10093acb-9084-4265-b583-1860b2ed366b
ChunxiaoIanLi/RL_reset
cadical/cadical_ucb/src/external.cpp
#include "internal.hpp" #include <cstdint> namespace CaDiCaL { External::External (Internal *i) : internal (i), max_var (0), vsize (0), extended (false), concluded (false), terminator (0), learner (0), propagator (0), solution (0), vars (max_var) { assert (internal); assert (!internal->external); ...
ALGO
0.959854
4.507242
b1489679-472c-4e37-aa9a-4448bd909950
EmptyDust/Algorithm-Codes-and-writeups
codes/0x10_data_structure/0x13_vector/lc2148.cpp
#include <bits/stdc++.h> using namespace std; class Solution { public: int countElements(vector<int>& nums) { int n=nums.size(); if(n==0)return 0; int a=*max_element(nums.begin(), nums.end()); int b=*min_element(nums.begin(), nums.end()); if(a==b)return 0; int k1=cou...
ALGO
0.999885
5.372905
bb54a974-0904-4221-a3d3-314b4614fae5
CORRECT-1024/code
CCPC/2022_Weihai/G.cpp
#include <bits/stdc++.h> using namespace std; typedef long long LL; typedef unsigned long long ULL; void work() { LL x, n; cin >> x >> n; LL y = 1; while (y <= x) { y <<= 1; } if (x == 1) { while (n --) { LL l, r; cin >> l >> r; cout << r - l ...
ALGO
0.999726
3.579576
980589d7-801a-468b-a5e7-24e62fb6bae2
ritik6207/Cpp-Programming
18. STL/1. Vector/2. Iterators/4_cbegin_cend.cpp
// Return value A const_iterator to the begining of the sequence. // Vector :: cbegin/cend #include <iostream> #include <vector> using namespace std; int main() { vector<int> MyVec = {12, 45, 23, 40}; cout << "contains: "; for (auto it = MyVec.cbegin(); it != MyVec.cend(); ++it) { cout << " " ...
TOOL
0.925162
3.260388
0d7fba74-34ff-4556-9327-79b94664e089
liaojh1998/Competitive-Programming
USACO/Section 2/2.4/comehome.cpp
/* ID: liaojh11 PROG: comehome LANG: C++ */ //Title: comehome //Type: Shortest Path //Solution: All nonnegative weighted edges, all connected, start from source 'Z'. --> Dijkstra's algorithm. // Since 'z' was 122 in char, originally had 123-sized arrays but somehow signalled MLE? Changed to 52-sized and used functio...
ALGO
0.998229
3.616674
a1a0b50c-5e6b-4719-816e-944354eabda3
TanvirSojal/LightOJ
1087 - Diablo.cpp
#include<bits/stdc++.h> using namespace std; #define MX 200000+50000+5 int n, q, A[100005]; int tree[4*MX]; int tree_val[4*MX]; void build(int node, int L, int R){ if (L == R){ if (L <= n){ tree[node] = 1; tree_val[node] = A[L]; } else{ tree[node] = 0;...
ALGO
0.999688
4.214328
e710465d-d4cd-4a0e-96d0-56e6b9a69be7
chenshao5264/c2d_client_socket
Classes/libs/libCryptoPP/include/xtr.cpp
// xtr.cpp - written and placed in the public domain by Wei Dai #include "pch.h" #include "xtr.h" #include "nbtheory.h" #include "integer.h" #include "algebra.h" #include "modarith.h" #include "algebra.cpp" NAMESPACE_BEGIN(CryptoPP) const GFP2Element & GFP2Element::Zero() { return Singleton<GFP2Element>().Ref(); }...
ALGO
0.999609
4.242188
2ec2c0aa-64fe-4217-833f-d356a79f4064
Hitanshu1512/Dsa
DP/33-MCM_memoization.cpp
#include <iostream> #include <algorithm> #include <cstring> #include <limits.h> using namespace std; int static t[101][101]; // depends on constraints i and j....100 & 100 int solve(int arr[], int i, int j) { // initialize dp matrix bool flag = true; if(flag){ memset(t, -1, sizeof(t)); ...
ALGO
0.999985
3.820846
28beed8f-08ef-45ce-9c4f-1d72a89745e3
kaiotcp1/Algoritmos
exec10/main.cpp
#include <iostream> /* run this program using the console pauser or add your own getch, system("pause") or input loop */ // Calculo fatorial int fatorial(int valor, int fact) { printf("\n Escreva um numero >>>"); scanf("%d", &valor); printf("\n Digite valor referencia faltorial"); scanf("%d", &fact); for(int...
ALGO
0.995194
3.656332
983c584f-ca94-4dd7-941e-28fb398e622c
akorchyn/cpp-pool
d07/ex01/iter.cpp
#include <iostream> template<class A, class B> void iter(A *array, B length, void (*func)(A &)) { for (B i = 0; i < length; i++) func(array[i]); } template <class A> void print(A c) { std::cout << c; } int main() { const char gavno[] = "abcde"; const int tab[] = {5, 4, 3, 2, 1, 0}; iter(gavno, sizeof(gavno...
ALGO
0.941625
5.223253
88d6e8f7-38f7-41fa-81a4-bdca8bb2d89a
DavidChicharro/Estructuras-de-Datos
Problemas/relacion3/ejercicio13.cpp
/* Ejercicio 13 */ #include <iostream> #include <string> #include <list> using namespace std; template <typename T> list<T> lista_posiciones(const list<T> &l, const list<T> &li){ list<T> res; if(l.size() >= li.size()){ typename list<T>::const_iterator it; typename list<T>::const_iterator it_li = li.begin(); i...
ALGO
0.998647
3.70372
ba446a26-4868-49de-abf9-d23314ff5a11
rrosinha/cpp
repeated_words.cpp
#include "std_lib_facilities.h" int main() { int number_of_words = 0; //initialize a counter for the words string previous = " "; // initialize previous to not a word" string current; while (cin >> current) { ++number_of_words; if (previous == current) { cout <<...
ALGO
0.992628
5.243131
18198dc5-ad65-4775-a1ca-83cb8f7c7c72
HarenKei/BOJ_Solved
Bronze/28444.cpp
#include <bits/stdc++.h> using namespace std; int h, i, a, r, c; int main(){ ios::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL); cin >> h >> i >> a >> r >> c; cout << (h * i) - (a * r * c) << "\n"; return 0; }
ALGO
0.972058
3.095254
ab33d63a-764d-4ed2-be09-04daf678312e
medit-jooyonglee/nerve-segmentation3d
tools/binding22/meshlibs/libs/eigen339/doc/examples/TutorialLinAlgExSolveColPivHouseholderQR.cpp
#include <iostream> #include <Eigen/Dense> using namespace std; using namespace Eigen; int main() { Matrix3f A; Vector3f b; A << 1,2,3, 4,5,6, 7,8,10; b << 3, 3, 4; cout << "Here is the matrix A:\n" << A << endl; cout << "Here is the vector b:\n" << b << endl; Vector3f x = A.colPivHouseholderQr...
ALGO
0.999942
3.356631
7ab3c4a6-64c2-42b5-8437-6c44783b635d
shahid-ms10/CPLUSPLUS
Code1/no_name.cpp
#include <iostream> using namespace std; int main() { int n; cin>>n; int arr[n]; int k=1; for(int i=0 ;i<=((n-1)/2);i++){ arr[i]=k; k+=2; } if(n%2==0){ k=n; for(int i=(((n-1)/2)+1) ;i<n;i++){ arr[i]=k; k-=2; } } else{ ...
ALGO
0.999921
4.022318
8e7c52de-58ff-473d-90e5-2c204988e654
purvasingh96/My-Leetcode-Solutions
0783-minimum-distance-between-bst-nodes/0783-minimum-distance-between-bst-nodes.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.999993
6.693395
164c3288-d61b-44e2-8076-71ac89054b49
tinkalkumar007/DSA
substring.cpp
#include<iostream> #include<cstring> using namespace std; int main(){ string s1; cin>>s1; int l1=s1.length(); cout<<l1<<endl; for(int i=0;i<l1;i++){ for(int j=0;j<=l1;j++){ for(int k=i;k<j;k++){ cout<<s1[k]<<","; } cout<<endl; } } return 0; }
ALGO
0.998678
3.354435
b59c8b7b-9c33-436d-8933-204e02be98e0
TravisZhang/cpp_test
thread_test/example_14.cpp
#include <iostream> #include <string> #include <thread> void printName(std::string name, int waitTime) { std::this_thread::sleep_for(std::chrono::milliseconds(waitTime)); std::cout << "Name (from Thread) = " << name << std::endl; } int main() { std::string name1 = "MyThread1"; std::string name2 = "MyThread2";...
TOOL
0.959098
6.088875
9c5fdecd-00c1-4107-9fd6-83907c5fc5d3
flyingSnow-hu/games202
4/lut-gen/Eavg_MC.cpp
#include <iostream> #include <vector> #include <algorithm> #include <cmath> #include <sstream> #include <fstream> #include <random> #include "vec.h" #define STB_IMAGE_WRITE_IMPLEMENTATION #include "stb_image_write.h" #define STB_IMAGE_IMPLEMENTATION #include "stb_image.h" int resolution = 128; int channel = 3; type...
ALGO
0.982398
3.941565
ffde8d29-c314-4d3e-97cd-f5db5385adbd
ashib11/Sub_Zero_
B_Piano_3.cpp
#include <bits/stdc++.h> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> using namespace std; using namespace __gnu_pbds; template <typename T> #define ll long long #define pi acos(-1.0) #define ull unsigned long long #define endl "\n" #define all(v) v.begin(), v.end() #define allr(v) v.r...
ALGO
0.99949
4.00141
9df32b76-ed71-4a83-8770-4a9c1992d5cf
keisuke90/AtCoder
practice/abc154-d.cpp
#include <bits/stdc++.h> #define rep(i, start, end) for(int i = start; i < end; i++) using namespace std; int main(){ int n, k; cin >> n >> k; vector<int> p(n); rep(i, 0, n) cin >> p[i]; rep(i, 0, n) p[i]++; int mx = 0; int s = 0; queue<int> q; rep(i, 0, n) { s += p[i]; ...
ALGO
0.999824
3.493374
7af6dcae-9baf-492e-8512-7b52f8a7bdfe
Cosmoneural/codetree-TILs
250202/1부터의 합/sum-from-the-one.cpp
#include <iostream> using namespace std; int main() { // Please write your code here. int a; cin>>a; int sum=0; for(int i=1;i<=100;i++){ sum+=i; if(sum>=a){ cout<<i; break; } } return 0; }
ALGO
0.999797
3.545728
c985f11a-1c96-4208-abd4-1a583c2c7d17
ChettriBishal/CP
Coding Blocks/DP/Wines_Top_Down.cpp
/* Wines Problem Top Down Recursive */ #include<iostream> #include<algorithm> using namespace std; // i -> starting index // j -> ending index // y -> current year int maxprice(int* prices,int dp[][100],int i,int j,int y) { // base case; no bottle left if(i> j){ return 0; } if(dp[i][j]){ ...
ALGO
0.999525
4.32558
0859fb35-daff-473a-b5f7-3f017e2e6cdc
LeHuyHongNhat/Data-Structures-Algorithms
sap_xep_cong_viec_1.cpp
#include <bits/stdc++.h> using namespace std; bool cmp(pair<int, int> a, pair<int, int> b) { return a.second < b.second; } int main() { int t; cin >> t; while (t--) { int n; cin >> n; vector<pair<int, int>> v(n); for (int i = 0; i < n; i++) { ci...
ALGO
0.999937
4.13021
a8fd5757-7ba4-4974-86ce-2113f8659b80
113bommy/deepmind_codecontests_refine
cpp_gold_filter_file/cpp_train_2528_10.cpp
#include <bits/stdc++.h> using namespace std; const int maxn = 100010; int n, m, fa[maxn], ans; bool v[maxn]; pair<pair<int, int>, int> P[maxn]; int getanc(int x) { return fa[x] < 0 ? x : fa[x] = getanc(fa[x]); } inline void merge(int x, int y) { fa[x] = getanc(y); } int main() { cin.sync_with_stdio(false); cout.sy...
ALGO
0.999992
3.573351
6a629a51-e4e6-4179-9ec8-50633b7ce698
chasseneige109/PS
백준_단계별/그리디알고리즘/소스3.cpp
#include <iostream> #include <vector> using namespace std; int cnt = 0; vector<vector<bool>> paper(128, vector<bool>(128)); void DQ(int x, int y, int length) { if (length == 1) { cnt++; return; } for (int i = 0; i < length; ++i) { for (int j = 0; j < length; ++j) {...
ALGO
0.999813
5.219184
3e8a78ee-eacc-4e42-964c-494a75f02f9b
vinay030901/Algorithms
Striver/Tree/24aConstructBinaryTreeFromPreorderAndInorder.cpp
/* Given two integer arrays preorder and inorder where preorder is the preorder traversal of a binary tree and inorder is the inorder traversal of the same tree, construct and return the binary tree. Example 1: https://assets.leetcode.com/uploads/2021/02/19/tree.jpg Input: preorder = [3,9,20,15,7], inorder = [9,3,15,2...
ALGO
0.999968
6.702277
356a75a8-7f9e-40a6-bf7f-f2fc1ab41638
Zielon/3DScanning
Exercises/Exercise3/libs/Eigen/doc/examples/Tutorial_ArrayClass_interop_matrix.cpp
#include <Eigen/Dense> #include <iostream> using namespace Eigen; using namespace std; int main() { MatrixXf m(2,2); MatrixXf n(2,2); MatrixXf result(2,2); m << 1,2, 3,4; n << 5,6, 7,8; result = m * n; cout << "-- Matrix m*n: --" << endl << result << endl << endl; result = m.array() * ...
ALGO
0.995757
4.306757
aaee6830-f944-46d8-bd74-5ab4d11abd2c
oxygen-hunter/Flashboom
data/leetcode_cpp/validate-binary-search-tree.cpp
// Time: O(n) // Space: O(1) /** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x), left(NULL), right(NULL) {} * }; */ // Morris Traversal class Solution { public: bool isValidBST(TreeNode* root) { ...
ALGO
0.999968
7.205693
0cad3773-f8f4-473f-b99c-483df41782ff
gulabchan/leetcode-c-challenges
0020-valid-parentheses/0020-valid-parentheses.cpp
class Solution { public: bool isValid(string s) { stack<char>st; for(auto c:s){ if(st.empty()){ st.push(c); } else if((st.top() == '(' && c == ')') || (st.top() == '{' && c == '}') || (st.top() == '[' && c == ']'...
ALGO
0.999152
6.292784
590789b6-a522-4e2e-a667-fdf10de3e28b
igorjaniszewski78552/gitrepo1A
cpp/sredniaatyrtmetyczna.cpp
#include <iostream> #include <cstdio> using namespace std; void pobierzOceny(int t[], int r){ cout << "podaj oceny: "<< endl; int i; for(i=0; i<r;i++){ cin >> t[i]; } } void DrukujTab(int t[], int r){ int i; for(i=0; i<r;i++){ cout << t[i]<< ", "; } } void srednia(int t[], int r){ float...
ALGO
0.963302
3.742876
3fcdbe47-a85e-494c-92c4-25682c683273
siddharth94/competitive
Spoj/ctrick.cpp
#include <bits/stdc++.h> using namespace std; #define R(i,a,b) for(int i=a;i<b;i++) #define RE(i,a,b) for(int i=a;i<=b;i++) #define RR(i,a,b) for(int i=a;i>b;i--) #define RRE(i,a,b) for(int i=a;i>=b;i--) #define F(i,n) for(int i=0;i<n;i++) #define FE(i,n) for(int i=0;i<=n;i++) #define FR(i,n) for(int i=n;i>0;i--) #def...
ALGO
0.999917
3.269216
fe855004-4eb0-4f68-b04a-13d58678cb29
y-bhakta/DSA-Web
C++/lec-19/prog2.cpp
#include<iostream> using namespace std; class calculator{ int c,d; public: int add(int a, int b){ this->c=a; this->d=b; cout << "Addition: " << c+d << endl; } }; int main(){ calculator c; int e,f; cout << "Enter First numbers: "; cin >> e; ...
TOOL
0.962472
4.610361
c3909f12-b2c6-4a3a-a401-24d21da5537b
antoine-chan-lock/PolarInterpolants
CommonLibraries/libigl/include/igl/is_delaunay.cpp
template < typename DerivedV, typename DerivedF, typename DerivedD> IGL_INLINE void igl::is_delaunay( const Eigen::MatrixBase<DerivedV> & V, const Eigen::MatrixBase<DerivedF> & F, Eigen::PlainObjectBase<DerivedD> & D) { typedef typename DerivedV::Scalar Scalar; // Should use Shewchuk's predicates instea...
ALGO
0.980863
7.194934
63a52de0-0a7d-44eb-82d8-528a384c8f55
jeppung/bloc_counter
windows/runner/utils.cpp
#include "utils.h" #include <flutter_windows.h> #include <io.h> #include <stdio.h> #include <windows.h> #include <iostream> void CreateAndAttachConsole() { if (::AllocConsole()) { FILE *unused; if (freopen_s(&unused, "CONOUT$", "w", stdout)) { _dup2(_fileno(stdout), 1); } if (freopen_s(&unuse...
TOOL
0.9988
6.76073
ca70778b-6899-439d-8e30-83a02f3a9832
RobotCrazy/20181X-Software-2019
src/utility/mathUtil.cpp
#include "mathUtil.h" #include <cmath> #include <algorithm> #include "debug/logger.hpp" const double PI = atan(1) * 4.0; double degreeToRadian(double degrees) { return degrees * (PI / 180.0); } double radianToDegree(double radians) { return radians * (180.0 / PI); } double distance(double x1, double y1, double ...
TOOL
0.972642
6.270054
d4db6cc9-e999-4f3f-a473-4aaf2505305c
ReloadedOS/frameworks_av
media/libeffects/lvm/lib/Common/src/LVC_Core_MixSoft_1St_2i_D16C31_WRA.cpp
/********************************************************************************** INCLUDE FILES ***********************************************************************************/ #include "LVC_Mixer_Private.h" #include "LVM_Macros.h" #include "ScalarArithmetic.h" static inline LVM_FLOAT ADD2_SAT_FLOAT(LVM_FLOAT...
ALGO
0.997332
5.816474
d310aa3a-7447-475a-9348-a6a0e2033b71
astrophysicist87/HBT_vs_multiplicity
EBE-Node/photonEmission/src/Arsenal.cpp
#include<iostream> #include<sstream> #include<fstream> #include<cmath> #include<cstdlib> #include<iomanip> #include "Arsenal.h" double Simpson_sum(double* array, int num, double h_step) { double sum=0; for(int j=0;j<num-2;j+=2) sum += array[j]*1 + array[j+1]*4 + array[j+2]*1; sum = sum*h_st...
ALGO
0.979762
3.320577
06f2c315-336a-4457-9aa3-4abd996b9308
AnoonaNasrin/Aero-qgcontrol
libs/eigen/doc/examples/Tutorial_BlockOperations_block_assignment.cpp
#include <Eigen/Dense> #include <iostream> using namespace std; using namespace Eigen; int main() { Array22f m; m << 1,2, 3,4; Array44f a = Array44f::Constant(0.6); cout << "Here is the array a:" << endl << a << endl << endl; a.block<2,2>(1,1) = m; cout << "Here is now a with m copied into its cent...
ALGO
0.973785
3.304946
61cf830b-3723-4057-b98a-8337ac774d4a
Xrysnow/cocos-x-external
bullet/BulletCollision/BroadphaseCollision/btDbvt.cpp
///btDbvt implementation by Nathanael Presson #include "btDbvt.h" // typedef btAlignedObjectArray<btDbvtNode*> tNodeArray; typedef btAlignedObjectArray<const btDbvtNode*> tConstNodeArray; // struct btDbvtNodeEnumerator : btDbvt::ICollide { tConstNodeArray nodes; void Process(const btDbvtNode* n) { nodes.push_back(...
ALGO
0.996826
6.318747
c9b66f85-077d-4ee8-9e1b-ebdebaea8f8e
ShikharS1411/Leetcode
2024. Maximize the Confusion of an Exam.cpp
class Solution { public: bool check(int mid,int k,string& a){ unordered_map<char,int>mp; int i=0,j=0; while(j<a.size()){ mp[a[j]]++; if((j-i+1)==mid){ if(mp['T']+k>=mid || mp['F']+k>=mid)return true; mp[a[i]]--; i++;...
ALGO
0.999824
6.253085
71ce4d92-29ee-4613-ad00-a746a7a29d89
Utkarsh-Dyundi/Competitive-Programming
Chef_in_Heaven_.cpp
#include<bits/stdc++.h> using namespace std; #define tr(c,it) for(typeof(c.begin()) it=c.begin();it!=c.end();++it) #define all(c) c.begin(),c.end() #define mod 1000000007 #define itor(c) typeof(c.begin()) #define ll long long #define vi vector<int> #define si set<int> #define msi multiset<int> #define ii pair<int,int> ...
ALGO
0.999985
3.677972
1b6c8a7f-b458-4e6d-88e0-1b952ea8f98c
Tiger1994/LeetCode
Q15.cpp
#include<vector> #include<algorithm> using namespace std; class Solution { public: vector<vector<int>> threeSum_1(vector<int>& nums) { vector<vector<int>> result; int lens = nums.size(); if (lens < 3) return result; sort(nums.begin(), nums.end()); for (int i = 0; i < lens-2; i++){ for (int j = i + 1; ...
ALGO
0.999983
5.020529
31271c3a-f6ce-4d41-b7c6-8ee02cc663b0
AdityaJha003/Flutter
cartapp/windows/runner/utils.cpp
#include "utils.h" #include <flutter_windows.h> #include <io.h> #include <stdio.h> #include <windows.h> #include <iostream> void CreateAndAttachConsole() { if (::AllocConsole()) { FILE *unused; if (freopen_s(&unused, "CONOUT$", "w", stdout)) { _dup2(_fileno(stdout), 1); } if (freopen_s(&unuse...
TOOL
0.997544
6.76073
acc2938f-a3b7-420f-a813-49772be12408
graefjk/AssemblyGraphVisualization-AssembleThemAll
simulation/externals/libigl/include/igl/find_zero.cpp
#include "find_zero.h" #include "for_each.h" #include "any.h" template <typename AType, typename DerivedI> IGL_INLINE void igl::find_zero( const Eigen::SparseMatrix<AType> & A, const int dim, Eigen::PlainObjectBase<DerivedI> & I) { assert((dim == 1 || dim == 2) && "dim must be 2 or 1"); // Get size of input ...
ALGO
0.998854
5.917986
96cb1e0a-6c91-44e6-a63c-7118bd761461
snclucas/myos
lib/net/retranstimeoutcalc.cpp
//#define RTO_DEBUG #define INITIAL_RTO (3 * HZ) // cannot return to 3 secs on data phase, so start with it #define MIN_RTO (1 * HZ) #define MAX_RTO (120 * HZ) #define CLEAR_SRTT_AFTER 3 // retransmissions #define ALPHA 8 #define BETA 4 #define K 4 #define G 1 // timer granularity in 1 HZ #ifdef RTO_...
ALGO
0.985137
6.817378
77efb9cf-8a66-4860-9913-b46340a195e1
ping-72/DSA-Sheet-Algozenith
B_378_QAQ_and_Mocha_s_Array.cpp
#include <bits/stdc++.h> using namespace std; void solve() { int n; cin >> n; vector<int> arr(n); for (int i = 0; i < n; i++) { cin >> arr[i]; } sort(arr.begin(), arr.end()); vector<int> arr1; vector<bool> isdiv(n, true); int a = arr[0]; for (int i = 0; i < n; i++...
ALGO
0.999853
4.975914
b642e16c-9d10-456f-a7f1-7beab9fb7f9c
Jh-jaehyuk/BOJ
BOJ/00000++/5000~/5615.cpp
// // 5615.cpp // BOJ // // Created by J213h on 10/19/23. // #include <bits/stdc++.h> using namespace std; static unsigned long long MR[3] = { 2, 7, 61 }; unsigned long long npow(unsigned long long a, unsigned long long b, unsigned long long mod); bool Miller_Rabin(unsigned long long x, unsigned long long a); i...
ALGO
0.999948
4.570953
b466cbbe-bd8a-47cc-b84b-5e2e00072af2
SirPseudocode/Competitive-Programming
VJudge/OSDIUM/Warming Up OSP/B_ADDING_REVERSED_NUMBERS.cpp
#include <bits/stdc++.h> #include <numeric> #define ll long long #define ull unsigned long long #define unset unordered_set #define mset multiset #define v vector #define fi first #define se second #define pb push_back using namespace std; const int mod = 1e9 + 7; ll reverse(ll n){ string str = to_string(n); r...
ALGO
0.99963
5.614488
a61d928a-78ae-4a4d-94b4-0f7f00c112a5
souleimaneelqodsi/donnees-libres
mariage-complet-3.cpp
/** @file **/ #include <fstream> #include <iostream> #include <vector> #include <string> #include "tableau-lecture.hpp" #include "tableau-donnees.hpp" #include "tableau-donnees-avance.hpp" using namespace std; /** Affiche : * - le nombre total de mariages * - le nombre moyen de mariages célébrés par an * - l'année ...
DATA
0.937412
3.175913
5199b96b-fcbb-4279-8041-06c1ddf18678
donghuna/Expert
BigInt Calc/긴 자리 곱셈 2/Solution1.cpp
#ifndef _CRT_SECURE_NO_WARNINGS #define _CRT_SECURE_NO_WARNINGS #endif /* 29_ڸ_ver01 1ڸ ó : naive function */ #include <cstdio> #define rint register int using LL = unsigned long long; const int BASE = 10; const int LM = 2005; char as[LM], bs[LM]; inline int max(int a, int b) { return a > b ? a : b; } inline int str...
ALGO
0.999885
3.930605
43992387-eb78-46c1-aedf-e1b3ee8ed6b1
LeoParadox10/CodingPractice
1207-delete-nodes-and-return-forest/delete-nodes-and-return-forest.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.999913
6.034642
282fb4f6-cc72-4221-b24c-dbc0a6586227
ankitkumar0624/DSA
122-best-time-to-buy-and-sell-stock-ii/122-best-time-to-buy-and-sell-stock-ii.cpp
class Solution { public: int maxProfit(vector<int>& prices) { int profit=0; for(int i=0 ;i<prices.size()-1;i++){ if(prices[i+1]>prices[i])profit+=prices[i+1]-prices[i]; } return profit; } };
ALGO
0.99971
5.900776
ec0b5544-7a50-41de-8c99-1bfd27039108
CaptnErlking/CodeHere
C++/GFG/Recursion/CutTheRope.cpp
#include<iostream> using namespace std; int maxi(int x, int y, int z){ if (x>=y && x>=z) return x; else if (y>=x && y>=z) return y; else return z; } int CutTheRope(int rope, int a, int b, int c){ if (rope==0) return 0 ; if (rope<0) return -1 ; int res = maxi(CutTheRope(rope-a,a,b,c),CutTheRope(r...
ALGO
0.999735
4.222063
d49f3e53-2b99-4531-9402-63da4f5156d7
Vickyy2525/ITSA_OOP
AC/Arr2_OOP/Arr2_72.cpp
#include<iostream> using namespace std; int main() { int num, full, half, dollar; cin >> num; // # of for loop for(int i = 0; i < num; i++){ cin >> full >> half; // #adult #child dollar = full * 250 + half * 175; // compute cout << dollar << endl; // output total dollar ...
ALGO
0.999295
4.558599
db1fcd9a-72f7-4f09-a0ea-6d63b8129307
TareqNewazShahriar/my-cpp-works-with-uva-problems-solution
more-memories/contest--solved-unsolved/2006.09.21 Amir Kabir University 3H [08.00PM]/B Nails.cpp
#include<stdio.h> #include<math.h> #define SIZE 105 #define CON 5000000000 #define ERR 0.0001 /****************************Global Variables***************************/ int rib,nail; double dist; class Type { public: double x,y; } xy[SIZE]; /*************************User Defined Functions************************ / b...
ALGO
0.999895
4.000447
dc7ec2a5-0247-4ca4-be08-66b199fdb71e
ShahNawaz2323/c---practices
code14practice.cpp
#include <iostream> #include <cstdlib> #include <string> #include <vector> #include <sstream > #include <limits> using namespace std ; void table_fun(int x){ for (int i=1; i<=10; i++ ) { cout << x*i <<endl; } } int main () { cout <<"give valuse which you want table: " ; int y ; cin >> y ; table_fu...
ALGO
0.982582
3.678866
13edac67-3d08-4c4b-ba82-881064fc6ff4
saisaran868/weather_app
windows/runner/utils.cpp
#include "utils.h" #include <flutter_windows.h> #include <io.h> #include <stdio.h> #include <windows.h> #include <iostream> void CreateAndAttachConsole() { if (::AllocConsole()) { FILE *unused; if (freopen_s(&unused, "CONOUT$", "w", stdout)) { _dup2(_fileno(stdout), 1); } if (freopen_s(&unuse...
TOOL
0.998733
6.76775
1afd6e2d-6af3-4b9c-acd0-7c0150b71d47
tprk77/trollauncher
trollauncher/java_detector.cpp
#include "trollauncher/java_detector.hpp" #include <optional> #include <regex> #include <vector> // Work around for Boost on MSYS2 #ifdef _WIN32 #ifndef __kernel_entry #define __kernel_entry #endif #endif #include <boost/process.hpp> #include "trollauncher/utils.hpp" #ifndef ITS_A_UNIX_SYSTEM #ifndef _WIN32 #defin...
TOOL
0.963388
7.936215
98efdd85-71e9-48fb-999c-a66b3177b7bb
DanielMarchand/progtech2
exercise/in_depth/linkage_of_static/01_local.cpp
// Local static variables #include <iostream> int foo() { static int x = 0; // initial value ++x; return x; } int main() { for(int i = 0; i < 5; ++i) std::cout << foo() << " "; return 0; }
ALGO
0.965794
3.975352
246214df-3814-4cc3-a095-e092a4bf7834
llislex/ru_draughts_cpp
src/rules/board.cpp
#include "board.h" #include "bit_op.h" BoardStat::BoardStat(const BoardBin& b, const BoardGeometry& g, BoardBitmap marker) : b(b), g(g), marker(marker), own_units(bitcount(b.own)), own_dams(bitcount(b.own & b.dam)), enemy_units(bitcount(b.enemy)), enemy_dams(bitcount(b.enemy & b.dam)) { } char BoardSt...
ALGO
0.984338
6.676735
f01496bc-5bb8-4b0a-9d5a-c635af65300d
kyoush/atcoder
2019/abc121/a.cpp
#include <bits/stdc++.h> using namespace std; int main(void) { int H, W, h, w; cin >> H >> W; cin >> h >> w; cout << (H - h) * (W - w) << endl; return 0; }
ALGO
0.998179
3.854448
503be3a4-b95a-49cb-9f69-c5d16058eede
Lukehututu/leetcode_practice
11_16_PathSum/11_16_PathSum/test.cpp
#define _CRT_SECURE_NO_WARNINGS 1 using namespace std; #include<iostream> struct TreeNode { int val; struct TreeNode* left; struct TreeNode* right; }; int DFS(struct TreeNode* root, int sum) { if (root == NULL && sum == 0)//ûsumΪ0ʱ ʱҵ· return 1; else if (root == NULL && sum != 0) ...
ALGO
0.999932
5.043545
a73e3026-f3e8-4dff-b0b9-7d2d57ca5686
TomClabault/HIPRT-Path-Tracer
src/Scene/SceneParser.cpp
#include "Image/Image.h" #include "Scene/SceneParser.h" #include "Threads/ThreadFunctions.h" #include "Threads/ThreadManager.h" #include "Threads/ThreadState.h" #include "UI/ImGui/ImGuiLogger.h" #include "Utils/CommandlineArguments.h" #define GLM_ENABLE_EXPERIMENTAL #include "glm/gtx/matrix_decompose.hpp" #include <c...
TOOL
0.886987
6.137568