blob_id
stringlengths
40
40
language
stringclasses
1 value
repo_name
stringlengths
5
117
path
stringlengths
3
268
src_encoding
stringclasses
34 values
length_bytes
int64
6
4.23M
score
float64
2.52
5.19
int_score
int64
3
5
detected_licenses
listlengths
0
85
license_type
stringclasses
2 values
text
stringlengths
13
4.23M
download_success
bool
1 class
3cb60f0ccb21b9094123afac3e8d82c1dde30964
C++
valiok98/testing
/OpenCV/main.cpp
UTF-8
4,431
2.640625
3
[]
no_license
#include <iostream> #include <vector> #include <opencv2/opencv.hpp> #include <opencv2/core.hpp> #include <opencv2/videoio.hpp> #include <opencv2/imgproc.hpp> #include <opencv2/highgui.hpp> #include <opencv2/opencv_modules.hpp> // Custom header files #include "window.hpp" #include "frame-helper.hpp" #define MODE 0 // T...
true
eca344ce1485c49bb95171dd0f17ac5b7b4b3d48
C++
Ethan0pia/School-Work
/cs162-IntroToCSII/group project/group project/Tool.hpp
UTF-8
541
2.703125
3
[]
no_license
/************************************************************** * Authors: Lindsey Bunte, Ethan Dunham, Bryan Fishback, Marisa Rea, Dean Ohashi, James Whiteley IV, Kyle Wollman * Date: 2/13/2017 * Description: Group Project * Tool.hpp is the Tool class specification file. * *********************************************...
true
cbbe5265abd279180bff1a60a73ac0a6d869115b
C++
wizaral/Chess
/src/menu.cpp
UTF-8
3,177
2.65625
3
[]
no_license
#include "game.hpp" void Game::print_menu(std::array<int, 4> &positions) { bool exit = false; while (m_window.isOpen() && !exit) { sf::Event e; while (m_window.pollEvent(e)) { if (Game::is_exit(e)) { m_window.close(); } if (e.type == sf::Ev...
true
32ecc92bf3943d43654efaf4f32beb6780c237bc
C++
MahmoudOuka/C-console-App.
/main.cpp
UTF-8
7,981
2.9375
3
[]
no_license
#include <bits/stdc++.h> #include "course.h" #include"Student.h" #include"Teacher.h" #include"Doctor.h" #include"TA.h" #include"person.h" #include"System.h" using namespace std; int main(){ System fci(100); //-------------Making Two Objects Of Students , Teacher Assistant , Doctor //------------- Making 2 courses &&...
true
1c419329e32687933ddc64567da26345687e809e
C++
Frankalexej/COMP2113GroupProject
/Map.h
UTF-8
3,729
3.25
3
[]
no_license
#include "Point.h" #include "Initialiser.h" #include "ConfigInitiator.h" #pragma once class Map { // it is basically an array of Point ptrs, with many functions private: Initialiser* initialiser; // this is used mainly for getting fullLife and Fee, sth ConfigInitiator doesn't cover ConfigInitiator* init; /...
true
2d0916d3e78c9a79ae5bd035336f0e8d4fa8dd57
C++
wma1729/simple-n-fast
/http/include/common/headers.h
UTF-8
5,749
2.578125
3
[ "MIT" ]
permissive
#ifndef _SNF_HTTP_CMN_HEADERS_H_ #define _SNF_HTTP_CMN_HEADERS_H_ #include <string> #include <utility> #include <vector> #include <ostream> #include <memory> #include "hval.h" namespace snf { namespace http { const std::string CONTENT_LENGTH("content-length"); const std::string TRANSFER_ENCODING("transfer-encoding")...
true
e3846576142dacd4a95eb58f7d3da266795ca47f
C++
WarlockD/quake-stm32
/old_wgtcc/type.h
UTF-8
12,260
2.59375
3
[ "BSD-2-Clause" ]
permissive
#ifndef _WGTCC_TYPE_H_ #define _WGTCC_TYPE_H_ #include "common.h" #include "mem_pool.h" #include "scope.h" #include <algorithm> #include <cassert> #include <cstdint> #include <list> class Scope; class Token; class Expr; class Type; class QualType; class VoidType; class Identifier; class Object; class Constant; cl...
true
2cc4e287ffcba2ef48e4c86ab259809e66428545
C++
mperez-fomento/3dengine
/test/test.cpp
UTF-8
3,569
3.125
3
[]
no_license
#include <catch2/catch_test_macros.hpp> #include "matrix.hpp" #include "engine3d.hpp" TEST_CASE("Rows can be checked for equality", "[columns]") { matrix::Row<3> c {1, 2, 3}; matrix::Row<3> d {4, 5, 6}; matrix::Row<3> f {1, 2, 3}; REQUIRE(c == c); REQUIRE(c == f); REQUIRE(c != d); } TEST_CASE(...
true
8492038d8a15ef90b4fee3fadccd44d42d8623d5
C++
HaochenLiu/My-Project-Euler
/007.cpp
UTF-8
630
2.75
3
[]
no_license
#include <iostream> #include <math.h> using namespace std; int main() { int N = 200001; bool* flag = new bool[N]; memset(flag, true, sizeof(flag)); flag[0] = false; flag[1] = false; for(int i = 2; i <= sqrt((double)N); i++) { for(int j = 2 * i; j < N; j += i) { flag[j] = fa...
true
91a969474446eae522d478dda47c0c5348a0158e
C++
spade69/strikeoffer
/Binary_01/binary1.cpp
UTF-8
1,096
3.296875
3
[]
no_license
include<iostream> using namespace std; /** *Binary tree *A node has left right and parent pointer *Given a binary tree and a node in it. *Find and return the next node at the order *midOrder traversal *eg : left->root->right * *Author Jason Date 2016/7/1 * */ struct TreeLinkNode{ int val; struct TreeL...
true
b78298dda201d2d56311304c9dd0576b4caf7009
C++
yja938882/CSE
/coding_problem/baekjoon_7568.cpp
UTF-8
343
2.65625
3
[]
no_license
#include <iostream> using namespace std; int main( void ){ int N; cin >> N; int kg[N]; int cm[N]; for( int i=0; i<N; i++ ){ cin >> kg[i] >> cm[i]; } for( int i=0; i< N; i++ ){ int cnt = 1; for( int j=0; j<N; j++ ){ if( j== i ) continue; if( kg[i] < kg[j] && cm[i] < cm[j] ) cnt ++; } cout << cnt ...
true
ee55cfba9c447a84efc4ef56472ecd9bd12a05e8
C++
LiamTyler/Progression
/code/shared/hash.hpp
UTF-8
502
3.015625
3
[ "MIT" ]
permissive
#pragma once #include <functional> #include <string> template <class T> inline void HashCombine( std::size_t& seed, const T& v ) { std::hash<T> hasher; seed ^= hasher( v ) + 0x9e3779b9 + (seed<<6) + (seed>>2); } inline void HashCombine( std::size_t& seed, const char* str ) { std::string s( str ); st...
true
3e36d006493299fa89cf112802eb9efb05aa093f
C++
bhagya314/MKPITS_Bhagyashri_Lalsare_Java_Mar_2021
/C_Programs/330_CalculateTotalPerGrade.cpp
UTF-8
863
3.734375
4
[]
no_license
//create function //a- calculatetotal(int sub1,int sub2,int sub3) //b - calculatepercentage(int total) //c- calculategrade(float per) #include<stdio.h> #include<conio.h> void calculatepercentage(int total); void calculategrade(double per); void calculatetotal(int s1,int s2,int s3) { int total; total=s1+s2+s3; pr...
true
8a15cf96c2dcccefa6d0346bbf9b7b8e9267ef62
C++
PortfolioJohannOstero/Console-Solitaire
/ConsoleRPG/UIContainer.cpp
UTF-8
1,773
2.890625
3
[]
no_license
#include "UIContainer.h" #include "Bounds.h" #include "Vector2.h" #include "View.h" #include "AsciiTexture.h" const rchar UIContainer::BORDER[]{ L"╔╗╚╝═║ " }; // @ Construction UIContainer::UIContainer(const Vector2& position, int width, int height, UIAlignment alignment, bool border, UIComponent* parent) : UICompo...
true
ac74e194d01426214713089f70cdb9265a13d776
C++
Joco223/SVML
/Compiler/src/Lexer.cpp
UTF-8
10,456
2.78125
3
[ "MIT" ]
permissive
#include "Lexer.h" namespace Lexer { const std::string load_file(std::string& file_path) { std::ifstream f(file_path.c_str()); if(!f.good()) { Error_handler::error_out("Error opening file: " + file_path + "."); return ""; } std::string content((std::istreambuf_iterator<char>(f)), (std::istreambuf_i...
true
6966bb6b8c4187ee17a3d793abbd4be32946d953
C++
gtagency/buzzmobile-old
/processors/lane_classifier/include/image.h
UTF-8
2,068
2.71875
3
[]
no_license
#ifndef __IMAGE_H #define __IMAGE_H #include "opencv/cv.h" #include "instance.h" using namespace cv; namespace image { int getCvType(); extern void (*getFeatures)(const Point3_<uchar>* pt, uchar features[2]); Instance makeInstance(uchar imgFeatures[2], int pixelDist, int label); Instance makeInstance(uchar im...
true
0c5626e04f1937d514ff7c244b83483c9997bb36
C++
Mnvjhamb/CodeQuotient-Cpp
/binaryTree/recursive_Inorder_Preorder_Postorder.cpp
UTF-8
541
3.609375
4
[]
no_license
/* struct Node { int data; Node *left, *right; }; The above structure is used for tree node. */ void inorder(Node* root){ if(root == NULL) return; inorder(root->left); cout<<root->data<<" "; inorder(root->right); } void preorder(Node* root){ // Write your code here if(root == NULL) return; cout<<root-...
true
0ed935089e2e123ab3e24bf273fece409d4b35e7
C++
jingweixi233/OnlineJudge_SJTU
/quickSort.cpp
UTF-8
1,005
3.25
3
[]
no_license
#include <stdio.h> #include <iostream> #include <time.h> using namespace std; void quickSort(int a[], int l, int r){ int i, j, x; if(l < r){ i = l; j = r; x = a[l]; while(i < j){ while(i < j && a[j] > x){ j = j - 1; } if(i < j...
true
c1fc7d470605b4a1eb3386cb9b8745ccb66782ab
C++
gari3008ma/Algo-Wiki
/Graph/maxflow.cpp
UTF-8
2,072
2.609375
3
[]
no_license
#include<bits/stdc++.h> using namespace std; bool bfsutil(vector<vector<pair<int,int> > > graph,int parent[],int n) { bool visited[n+1]; int i; memset(visited,false,sizeof(visited)); queue<int> q; q.push(0); visited[0]=true; parent[0]=-1; vector<vector<int,int> > :: iterator it; whil...
true
ba8de9c173c2a32bbf1883ef71d45526c06814a4
C++
Fikridzz/1435
/jpierceLab13/search.cpp
UTF-8
6,698
3.6875
4
[]
no_license
//******************************************************************** //Name: Jp Pierce //Class: COSC 1435.001 //Instructor: Marwa Hassan //Lab 13 Problem 2 //Date: 4/16/2012 //Program description: Search takes a list of of numbers from a file and // makes it into an array. That array is then sorted from acsend...
true
d965cc30573b437103b2e95985644c1826f272ed
C++
sureshyhap/Schaums-Outlines-Data-Structures-with-C-plus-plus
/Second/Chapter 4/Problems/34/thirtyfour.cpp
UTF-8
309
3.390625
3
[]
no_license
#include <iostream> double tangent(double x); double tangent(double x) { if (x > -.005 and x < .005) { return x + (1 / 3) * (x * x * x); } return (2 * tangent(x / 2)) / (1 - (tangent(x / 2) * tangent(x / 2))); } int main(int argc, char* argv[]) { std::cout << tangent(5) << '\n'; return 0; }
true
662d41ce9a4725cfafbd187a91d25f1ca7fb8844
C++
ItemZheng/PAT_Advanced_Level_Answer
/1013.cpp
UTF-8
1,426
3.546875
4
[]
no_license
#include <iostream> #include <vector> // 注意点:只要将lose city去掉之后,然后计算剩下的城市有几个set就可以 using namespace std; class Edge{ public: int v1, v2; public: Edge(int v1, int v2){ this->v1 = v1 - 1; this->v2 = v2 - 1; } }; int root_of(int city_set[], int i){ while (city_set[i] >= 0){ i = cit...
true
d2fcea5d82966dae26f012f8523a28fe33a6f5a8
C++
rvt/bbq-controller
/lib/utils/propertyutils.h
UTF-8
4,273
3.109375
3
[ "MIT" ]
permissive
#pragma once #include <string> #include <stdint.h> #include <map> #include <Stream.h> class Properties; class PropertyValue { private: union { int32_t m_long; float m_float; std::string m_string; bool m_bool; }; friend class Properties; public: enum Type { LON...
true
9ebdb925cbf144a9cbec467b4d8380cddddbc53d
C++
vuonghung2308/CTDL
/contest2/notGreen/ex32.cpp
UTF-8
942
3.03125
3
[]
no_license
#include <bits/stdc++.h> using namespace std; bool isOk(string s) { if(s == "") return false; int x = 0; for(int i = 0; i < s.length(); i++) { if(s[i] == '(') x++; else if(s[i] == ')') x--; if(x < 0) return false; } return x == 0; } void remove(string s, bool &has) { queue<string> q; set<string> visit;...
true
6909ecab21198e91fd4aa9cace762de812d4bb45
C++
Adelost/Ultimate-Coffee
/Source/System_Render/Box.h
UTF-8
7,698
2.859375
3
[]
no_license
#pragma once #include "Vertex.h" namespace Shape { Vector3 BoxPos[8] = { //Index: Vector3( 0.5f, 0.5f, 0.5f), //0 Vector3( 0.5f, -0.5f, 0.5f), //1 Vector3(-0.5f, -0.5f, 0.5f), //2 Vector3(-0.5f, 0.5f, 0.5f), //3 Vector3( 0.5f, 0.5f, -0.5f), //4 Vector3( 0.5f, -0.5f, -0.5f), //5 Vector3...
true
eba8361b028e03de73e2ed33c20dd0e34ed2d452
C++
20twenty/kglSN2
/11try/src/xform.cpp
UTF-8
2,056
2.71875
3
[]
no_license
#include <iostream> #include <string> #include <unistd.h> #include <ios> #include <fstream> #include <stdio.h> #include <stdlib.h> #include "xData.h" using namespace std; void process_mem_usage(double& vm_usage, double& resident_set) { using std::ios_base; using std::ifstream; using std::string; vm_usage...
true
d489710c96aa4eb816be4e3e2dbbdc3fc10924c6
C++
moonps/ProblemSolving
/9328_열쇠/은경.cpp
UTF-8
4,002
2.671875
3
[]
no_license
#include<cstdio> #include<algorithm> #include<queue> #include<cstring> using namespace std; struct DATA {int x,y;}; queue<DATA> q; queue<DATA> door[28]; int dx[]={0,0,1,-1,}, dy[]={1,-1,0,0}; bool check[102][102]; char arr[102][102]; bool key[102]; char keys[102]; int main(void) { int t; scanf("%d", &t); w...
true
b593d0563978d3258a42f4aeb940bba18d2fe4dc
C++
sxs-collaboration/spectre
/tests/Unit/NumericalAlgorithms/LinearOperators/Test_CoefficientTransforms.cpp
UTF-8
10,844
2.59375
3
[ "MIT" ]
permissive
// Distributed under the MIT License. // See LICENSE.txt for details. #include "Framework/TestingFramework.hpp" #include <array> #include <cstddef> #include <vector> #include "DataStructures/ComplexDataVector.hpp" #include "DataStructures/ComplexModalVector.hpp" #include "DataStructures/DataVector.hpp" #include "Dat...
true
8b7090a3bc9e921f2104a98d909247ffb47ae51e
C++
robotil/robil
/C11_OperatorControl/src/arcitem.cpp
UTF-8
4,881
2.65625
3
[]
no_license
#include "arcitem.h" #include <QPainter> #include <QGraphicsScene> #include <math.h> CArcItem::CArcItem(QPointF p,QGraphicsScene* scene) : QGraphicsEllipseItem() { centerPos = p; radius = 160; setStartAngle(60 * 16); setSpanAngle(60 * 16); RightPoint = new CPointItem(GetRightPoint(),scene); scene-...
true
2cc877d1d3ee30d373fa7d7363ee3c073fc1a0ea
C++
brandonwsims/laserharp
/laserHarp.ino
UTF-8
1,814
3
3
[]
no_license
#include <Stepper.h> const int laser = 13; const int stepsPerRevolution = 200; const int numberOfReads = 3; int i = 0; int read = 0; int previousAvg = 0; int reads[numberOfReads] = {0, 0, 0}; int avg = 0; int initial = 0; bool stop = false; bool first = true; // initialize the stepper library on pins 8 through 11: S...
true
8fd19f882706f71c45240112a735a16e6f12ff56
C++
litao91/gsampling
/mcmc_span.h
UTF-8
1,402
2.53125
3
[]
no_license
#include "util.h" #include "reduce_func.h" #include <iostream> using namespace std; //#include "hash.h" //#include <ext/hash_set> #include <vector> #include <set> #ifndef _MCMC_SPAN_H_ #define _MCMC_SPAN_H_ struct CompareSet; using std::set; using std::vector; /** * Type of a pattern, currently implemented as array ...
true
985c6efe1dee8b1adf44aa5e987606b92de94bc5
C++
guiguibubu/MyBotLogic-1
/Strategies/CheckingHiddenDoors.cpp
UTF-8
3,887
2.71875
3
[]
no_license
#include "CheckingHiddenDoors.h" #include "MyBotLogic/BehaviorTree/BT_Noeud.h" #include "MyBotLogic/GameManager.h" #include "MyBotLogic/MapTile.h" #include <string> #include <vector> using std::vector; BT_Noeud::ETAT_ELEMENT CheckingHiddenDoors::execute() noexcept { ProfilerRelease pointeurProfiler{ GameManager:...
true
e650e3251d74386ccb4fd95d6284bbc60ca792d7
C++
amd/libflame
/test/lapacke/LIN/lapacke_gtest_sytrs_3.cc
UTF-8
37,818
2.78125
3
[ "BSD-3-Clause", "LicenseRef-scancode-other-permissive" ]
permissive
#include "gtest/gtest.h" #include "../lapacke_gtest_main.h" #include "../lapacke_gtest_helper.h" #define sytrs_3_free() \ if (ipiv != NULL) free (ipiv); \ if (bref != NULL) free (bref); \ if (b != NULL) free (b ); \ if (a != NULL) free (a ); \ if (aref != NULL) free (aref);...
true
1be821f4c6522e8dc2901ada84f812a1aceddcab
C++
JdeRobot/ThirdParty
/gazebo-5.3.0/gazebo/math/Vector2d.hh
UTF-8
6,275
2.609375
3
[ "Apache-2.0" ]
permissive
/* * Copyright (C) 2012-2015 Open Source Robotics Foundation * * 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...
true
cd21bbcbb2d2a67a1aa17cf835027c972b30215b
C++
mgomezch/Pekomin
/Arrive.cpp
UTF-8
1,604
2.53125
3
[]
no_license
#include <vector> #include "Arrive.hpp" #include "Mobile.hpp" #include "Triple.hpp" //#define DEBUG_ARRIVE #ifdef DEBUG_ARRIVE #include <iostream> #endif Arrive::Arrive(std::string name, Mobile *character, Mobile *target, double maxSpeed, double targetRadius, double slowRadius): DirectKinematicV(name), ...
true
4c4c6f67a07a2f950d2f47aa0bbb56504803c615
C++
marcellfischbach/CobaltSKY
/Editor/imageimporter/imageimporterfactory.cc
UTF-8
878
2.609375
3
[]
no_license
#include <imageimporter/imageimporterfactory.hh> #include <imageimporter/imageimporter.hh> ImageImporterFactory::ImageImporterFactory() { } const std::string ImageImporterFactory::GetName() const { return std::string("Images"); } const std::vector<std::string> ImageImporterFactory::GetExtensions() const { st...
true
1b169c899f79707765a6f9446f6b03bb4b45a252
C++
Monksc/TrieSort
/sort_string_node.cpp
UTF-8
590
3.046875
3
[]
no_license
// // sort_string_node.cpp // TrieSort // // Created by Cameron Monks on 12/21/18. // Copyright © 2018 Cameron Monks. All rights reserved. // #include "sort_string_node.hpp" unsigned SortStringNode::size() const { return 26; } unsigned SortStringNode::maxIndex() const { return (unsigned) str.size() - 1; } u...
true
5fc3b344135f6a98873372be42dc20ce5d49ef9e
C++
viktorkuznietsov1986/algorithms
/Sorting/SearchingTest/BinarySearchSTTest.cpp
UTF-8
870
2.78125
3
[]
no_license
#ifdef WINDOWS #include "stdafx.h" #include "CppUnitTest.h" #include "BinarySearchST.h" #include <string> using namespace Microsoft::VisualStudio::CppUnitTestFramework; namespace SearchingTest { TEST_CLASS(BinarySearchSTTest) { public: TEST_METHOD(BinarySearchST_BasicFlowTest) { // TODO: ...
true
24591017c4dbe4bb0ad26eca6b19e4fa2fa64197
C++
SimonKocurek/Algorithms-and-Fun
/c++/binary-add.cpp
UTF-8
434
3.15625
3
[]
no_license
#include <iostream> using namespace std; int main() { int digit_a[]{1, 1, 0, 1}; int digit_b[]{1, 0, 0, 0}; int result[5]{0}; int carry = 0; for (int i = 3; i >= 0; --i) { result[i + 1] = (digit_a[i] + digit_b[i] + carry) % 2; carry = digit_a[i] + digit_b[i] + carry > 1 ? 1 : 0; ...
true
7094a3382a26e55705ed5b5e1af3412724659817
C++
GondoTheBoo/bak2
/common/textureCube.cpp
UTF-8
2,830
2.65625
3
[]
no_license
#include "textureCube.h" #include "sfml.h" #include <iostream> namespace cg2 { std::shared_ptr<TextureCube> TextureCube::import(std::array< fs::path, 6 > files, const TextureFilter filter, const TextureWrap wrap, const glm::vec4 border) { std::shared_ptr<TextureCube> result(new TextureCube, TextureCube::Deleter(...
true
11dcc7b3dce2784ba5a0bbc3fd80b5eef870c1bf
C++
pepeakaseniordeveloper/SpaceRocks
/space_rocks/scenes/scene_menu.cpp
UTF-8
10,782
2.640625
3
[]
no_license
#include "scene_menu.h" #include "../game.h" #include <SFML/Window/Keyboard.hpp> #include <iostream> #include <vector> #include "system_renderer.h" #include "..\components\components.h" #include <functional> using namespace std; using namespace sf; //Entities std::shared_ptr<Entity> txtTitle; std::shared_ptr<Entity> ...
true
69696b08549ba3396fc1e29ae39fd5af5cb2b9b4
C++
PillowCJY/8PUZZLE
/algorithm.h
UTF-8
10,551
3.453125
3
[]
no_license
/* */ #ifndef __ALGORITHM_H__ #define __ALGORITHM_H__ #include <ctime> #include <string> #include <iostream> #include <algorithm> #include <cstdlib> #include "puzzle.h" #include <vector> #include <set> #include <map> const heuristicFunction HEURISTIC_FUNCTION=manhattanDistance; //Function prototypes string progress...
true
68ba75bdebec33bf5251c3bb04ee7bf782e2e2d1
C++
tylerwinkler/msg-game
/src/Inventory.cpp
UTF-8
230
2.78125
3
[ "MIT" ]
permissive
#include "Inventory.hpp" void Inventory::addItem(std::string item) { m_items.push_back(item); } std::string Inventory::getItemInSlot(int i) { return m_items[i]; } int Inventory::getSize() { return m_items.size(); }
true
068e50f03d4319d9d9cda2bded06bd5d89afbbf6
C++
viveknath93/NavigationSystem
/Ex1_NavigationSystem/NavigationSystem/myCode/NaviSystem/CRoute.h
UTF-8
1,212
2.546875
3
[]
no_license
/*************************************************************************** *============= Copyright by Darmstadt University of Applied Sciences ======= **************************************************************************** * Filename : CROUTE.H * Author : Viveknath Thulasi * Description ...
true
c0dbb00272c60968a4dcc4bcdd8078e38e10f2db
C++
hyrise-mp/hyrise
/src/test/storage/reference_segment_test.cpp
UTF-8
4,840
2.53125
3
[ "MIT" ]
permissive
#include <iostream> #include <map> #include <memory> #include <set> #include <string> #include <utility> #include <vector> #include "base_test.hpp" #include "gtest/gtest.h" #include "operators/abstract_operator.hpp" #include "operators/get_table.hpp" #include "operators/print.hpp" #include "operators/table_scan.hpp" ...
true
645fbbc7eee1d94f81edf4828891808006a5d2c0
C++
Kishwara/JU-admission-Project-cpp-
/JU ADMISSION PROJECT (cpp)/bunit.cpp
UTF-8
579
2.65625
3
[]
no_license
#include <bits/stdc++.h> using namespace std; #include "bunit.h" void bunit :: show_bdepts() { cout<<setw(40)<<"Faculty of Social Science (B unit)"<<endl; cout<<"Total number of seats: 340"<<endl; cout<<"\nDepartments: \n"; cout<<"\n**Economics\n**Geography & Environment\n**Government & Politics\n**An...
true
00e384d58b298b805e0c224b662044816c92b22c
C++
rohitsinghkcodes/DAILY_PROGRAMMING
/2. LearnCodeOnline Challenges/C++ Questions/Challenge30.cpp
UTF-8
820
4
4
[]
no_license
//Challenge 30: #include<iostream> using namespace std; void sum(int a,int b) { cout<<"The sum is: "<<a+b<<endl; } void diff(int a,int b) { if(a>b) { cout<<"The max value is: "<<a<<endl; cout<<"The min value is: "<<b<<endl; cout<<"The difference is: "<<a-b<<endl; } else ...
true
1053ffe44d37be35ac798fc35ce97c0ddf591c0b
C++
drescherjm/QtExamples
/Concurrent/MapAndMapped/BlockingMapMemberFunction.cpp
UTF-8
284
2.765625
3
[]
no_license
#include <QtConcurrentMap> #include <iostream> class MyClass { public: void Test() { std::cout << "Test" << std::endl; } }; int main() { QVector<MyClass> v; MyClass a; v.push_back(a); QtConcurrent::blockingMap(v.begin(), v.end(), &MyClass::Test); return 0; }
true
b2ecdbf253bd5500437e3160d24135677b8a773f
C++
a-kashirin-official/spbspu-labs-2018
/turkin.sergey/A1/rectangle.cpp
UTF-8
924
3.46875
3
[]
no_license
#include <iostream> #include "rectangle.hpp" Rectangle::Rectangle(const double width, const double height, const point_t &pos) : center_(pos) { if (width <= 0 || height <= 0) { std::cerr << "Width and height of the rectangle must be > 0!"; } width_ = width; height_ = height; } Rectangle::Rectangle(doub...
true
e485852a00fb98787f2ae2341542d1b18d262f8b
C++
yiyunalu/DS
/lab/lab6/check1.cpp
UTF-8
2,371
4.1875
4
[]
no_license
#include <vector> #include <iostream> void reverse_vector(std::vector<int>& vec) { int temp; int front; int back; if (vec.size() == 1 || vec.size() == 0) { } else { //odd number of elements.... if ( vec.size()%2 != 0 ) { front = (vec.size() / 2) - 1; back = (vec.size() / 2) + 1; } //even number of...
true
f1d1dbc19c6d8adfd6aef345b75d7a0caf765585
C++
kineticsystem/catkin_ws_robot
/src/add_markers/src/add_markers.cpp
UTF-8
2,407
2.671875
3
[]
no_license
#include <ros/ros.h> #include <visualization_msgs/Marker.h> #include <actionlib/client/simple_action_client.h> #include "pick_objects/OperationStatus.h" static pick_objects::OperationStatus status; // Create a message to display a marget at a given position. visualization_msgs::Marker createAddMarkerMessage(double x...
true
c4bf8d82b8bbaef16f5df4a3971a2c756a67fea9
C++
omerb01/CompetitiveProgramming
/class/uva_10363.cpp
UTF-8
2,170
2.59375
3
[]
no_license
#include <algorithm> #include <bitset> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <deque> #include <functional> #include <iostream> #include <map> #include <queue> #include <set> #include <stack> #include <string> #include <vector> #include <numeric> using namespace std; typedef ...
true
811d329854f09762b6aa48ea06525d1c656314fa
C++
nlarosa/CPlusPlusProgramming
/RationalNumbers/part3/Rational.cpp
UTF-8
6,145
3.84375
4
[]
no_license
// Nicholas LaRosa // CSE 20212, Lab 2 // // Implementation for Rational class // Allows for non-default constructor // Overloads arithmetic operators // #include <iostream> #include "Rational.h" using namespace std; Rational::Rational() // default constructor initializes rational to 1/1 { numerator = 1; deno...
true
79a0f263468bab3a79de0a784b2e49955ddae368
C++
Dawodu-Johnson/Solutions-to-programming-principles-and-practice-by-Bjarne
/chapter 6/main.cpp
UTF-8
11,751
3.59375
4
[]
no_license
#include<iostream> #include<string.h> #include<vector> using namespace std; void error(string s) // for exceptions { throw runtime_error(s); } void error(string s, string m) { throw runtime_error(s+m); } /* class Name_value { // much like Token from 6.3.3 public: Name_value(string n, int s); string nam...
true
42f126627684680629acfb87186e137c7c8a322b
C++
rpbrandau/OSU-Coursework
/162 - Intro pt 2 - Labs/LabH/LabH_iMergesort.cpp
UTF-8
2,098
3.390625
3
[]
no_license
//Source: http://stackoverflow.com/questions/22866585/c-implementation-of-iterative-merge-sort-crashing-at-large-input-sizes-due-to //Notes: this program was not very intuitive for me to use. Especially with defining a global variable, and using namespace std //#include "stdafx.h" #include <iostream> #include <...
true
9f9882a0b0c89b51ce777ef1be1acdb2a084102f
C++
bi3mer/northeastern_game_ai
/a_star/a_star/Map.cpp
UTF-8
2,863
3.03125
3
[]
no_license
#include "Map.h" Map::Map(Json::Value root) { Json::Value matrix = root.get("Map", Json::arrayValue); h = matrix.size(); w = (int) matrix[0].asString().size(); for (int i = 0; i < h; ++i) { std::vector<int> newVector; std::string row = matrix[i].asString(); for (int j = 0; j < w; ++j) { if (row[j] =...
true
15e0d181fc51d58b02bff84c9c823ebde1a0eeb9
C++
thomaspiccolo/Projet-LG
/analyseur/xmlNode.h
UTF-8
381
2.796875
3
[]
no_license
#ifndef XMLNODE_H #define XMLNODE_H #include <string> #include <iostream> /* XML Node : Classe mère de notre structure XML */ class xmlNode { public: /*Constructeur*/ xmlNode(); /*Destructeur*/ virtual ~ xmlNode(); /*Affichage de l'arbre dans le terminal */ virtual void display(); /*Ecriture de l'arbdre ...
true
7a3cc45bc52301a62e09ad9be55619485b1251d6
C++
HarrisonJM/ProtocolDeveloper
/myLibraries/networkCommunication/src/networkCommunication.cpp
UTF-8
7,233
2.796875
3
[]
no_license
/*! * @brief Handles communication * * Deals with outgoing and incoming communication and passes the information * to whatever requires it * * @addtogroup NetworkCommunication Library * @{ * @date March 2018 * * @todo perror needs changing to try catch blocks the use strerror * @todo refactor out setInterfac...
true
ac94fa77ab3639ac5af3d1005cb28fbbf1ff088e
C++
indra215/coding
/geeksforgeeks/stack/Easy string.cpp
UTF-8
801
3.1875
3
[]
no_license
#include <iostream> #include <string> #include <stack> using namespace std; string compress(string inp) { int len = inp.length(), i = 0; stack<char> s; string res = ""; while(i < len){ if(s.empty() || s.top() == tolower(inp[i])){ s.push(tolower(inp[i])); i++; }else{ int count = 0; char ch = s.top(...
true
a824cd3a2e4d0a92551270c48027a8bdf6d4463e
C++
Zmestabrook/CSC150Projects
/pp03/pp03.cpp
UTF-8
2,333
3.671875
4
[]
no_license
/* PP03 - Zackary Estabrook & Brennan Lamoreaux Computer Science 150 10am 09/17/2018 */ #include <iostream> #include <iomanip> #include <cmath> using namespace std; int main() { double sum = 0; double average = 0; double max = 0; double stdDev = 0; double curve = 0; int nu...
true
0a1a4d83f8ecb97d1dc3b30217da3af4a130dcb6
C++
panditprogrammer/CPP
/class5.cpp
UTF-8
538
3.59375
4
[]
no_license
//class and contructor #include <iostream> #include <stdlib.h> using namespace std; //creating class class complex { private: int a,b; public: void setValue(int x,int y) { a = x; b = y; } void getValue() { cout<<" a = "<<a<<"b = "<<b<<endl; } //creating constructo...
true
614fc9816b22cdadc88404d6b92e3b7ae66b4d2e
C++
alexvelea/lot-info-2018-2
/sortall/bc_n3.cc
UTF-8
569
2.578125
3
[]
no_license
#include <bits/stdc++.h> using namespace std; int main() { ifstream cin("sortall.in"); ofstream cout("sortall.out"); int n; cin >> n; vector<int> v(n); for (auto& iter : v) { cin >> iter; } unsigned cost = 0; for (int i = 0; i < n; ++i) { set<int> s; for (in...
true
588f4f9d3bed8b2212affe50a6e05e0bc4702139
C++
Stevethe12/CarteFPGA
/TemplateVector/TemplateVector/myVector.cpp
UTF-8
3,546
3.671875
4
[ "Apache-2.0" ]
permissive
#include "myVector.h" template <typename T> myVector<T> myVector<T>::getObj() { return this->m_vector; } template <typename T> int myVector<T>::getCapacity() { return this->capacity; } template <typename T> bool myVector<T>::clear() { for (int i = 0; i < size; i++) { m_vector[i] = NULL; } r...
true
5371b198c50bf1f003f57cf2601355943b377106
C++
icsfy/some_little_stuff
/c++/ch13/cd.h
UTF-8
1,914
3.296875
3
[]
no_license
#ifndef CD_H #define CD_H class Cd { private: char performers[50]; char label[20]; int selections; double playtime; public: Cd(const char * s1, const char * s2, int n, double x); Cd(const Cd & d); Cd(); virtual ~Cd(); virtual void Report() const; virtual Cd & operator=(const Cd & d); }; #endif #ifn...
true
763490915322ea34de0c83cdb11ffaa31321be91
C++
kkunalguptaaa/codingBlocks
/6-sorting/kthRoot.cpp
UTF-8
614
2.875
3
[]
no_license
#include<iostream> #include<cmath> #include<algorithm> using namespace std; long long kthRoot(long long n,long long k){ long long l=0; long long h=n; long long mid=(l+h)/2; long long ans; while(l<=h){ mid=(l+h)/2; if(pow(mid,k)==n){ return mid; } else if(pow(...
true
ebe21ed5e901b38ee3e99cda0e748347fcadaed5
C++
Rohan7546/Coding_Ninjas_Competitive_Programming
/Dynamic_Programming_2/trader_profit.cpp
UTF-8
2,277
3.390625
3
[]
no_license
/* Trader Profit Send Feedback Mike is a stock trader and makes a profit by buying and selling stocks. He buys a stock at a lower price and sells it at a higher price to book a profit. He has come to know the stock prices of a particular stock for n upcoming days in future and wants to calculate the maximum profit b...
true
05146a06148ecf220fdc93f854bfe0d454bf3422
C++
AsulconS/CompetitiveProgramming
/URI/uri1014.cpp
UTF-8
181
2.671875
3
[]
no_license
#include <cstdio> #include <iostream> using namespace std; int main() { int km; double l; cin >> km >> l; printf("%.3lf km/l\n", (double)km / l); return 0; }
true
f6160b61b21c8ce7f252f5bc383e76d45043fd1f
C++
jbatea/Abstract_Vm
/includes/Lexer.class.hpp
UTF-8
986
2.765625
3
[]
no_license
#ifndef LEXER_CLASS_HPP #define LEXER_CLASS_HPP class Lexer { public: Lexer( void ); // Default constructor Lexer( Lexer const & src ); // Copy constructor ~Lexer( void ); // Destructor Lexer & operator=( Lexer const & rhs );// Assignement void getArg( int ac, char **av ) noexcept(false); std...
true
c54ce77034eaaf9390ec29f9a3e28b8fa29a7c86
C++
dimazilla123/graph-battle
/src/headers/unit.h
UTF-8
1,073
2.609375
3
[]
no_license
#ifndef UNIT_H #define UNIT_H #include <vector> #include "item.h" #ifndef SUCCSES_SHOT #define SUCCSES_SHOT 0 #endif #ifndef FAIL_SHOT #define FAIL_SHOT 1 #endif #ifndef DESTROYED #define DESTROYED 1 #endif #ifndef ALIVE #define ALIVE 0 #endif #ifndef INV_PUSHED #define INV_PUSHED 0 #endif class Unit { public: /* ...
true
66f2c45927390411ca392bbe6a303f055f931aac
C++
chiseungii/HONGIK
/2_1/객체지향프로그래밍/실습/14주차/lab9/1.cpp
UTF-8
471
3.578125
4
[ "MIT" ]
permissive
/* 14주차 lab9 #1 */ #include <iostream> #include "Complex.h" using namespace std; Complex &operator +(Complex &c1, Complex &c2) { double real = c1.getReal() + c2.getReal(); double img = c1.getImg() + c2.getImg(); Complex tmp(real, img); return tmp; } template <class T> T add(T a, T b) { return a + b; } int ma...
true
08217c8d2e32f99665686119f89204105b8a48bc
C++
whodoesntloveramen/Radnaev_Labs
/life.h
UTF-8
811
2.71875
3
[]
no_license
#ifndef LIFE_H #define LIFE_H #include <cstdint> #include <fstream> #include <SFML/Graphics.hpp> class life { int32_t m; int32_t n; std::vector<std::vector<bool>> board; public: life(); life(int32_t rows, int32_t columns); void set(int32_t row, int32_t column, bool value); void DoSteps(...
true
f298580a340247082e89c6095ca0afb7c83a7369
C++
maksmaisak/Engine
/src/engine/utils/Bounds.cpp
UTF-8
3,021
3.203125
3
[ "MIT" ]
permissive
// // Created by Maksym Maisak on 2019-04-04. // #include "Bounds.h" using namespace utils; Bounds::Bounds() : min(0), max(0) {} Bounds::Bounds(const glm::vec3& min, const glm::vec3& max) : min(min), max(max) {} Bounds::Bounds(const Bounds2D& other) : min(other.min.x, 0.f, other.min.y), max(other.max.x, 0.f,...
true
24a05f0472305340b37314d489f422080cfdd893
C++
bryancjd1/trabajo
/Practica 2/10.cpp
UTF-8
380
2.828125
3
[]
no_license
#include <iostream> #include <stdlib.h> #include <time.h> using namespace std; int main() { int arreglo[400000],a; srand (time(NULL)); cout<<"Ingrese numero"<<endl; cin>>a; for(int i=0;i<400000;i++) { arreglo[i]=rand()%100; } for(int i=0;i<400000;i++) { if(arreglo[i]...
true
ce14a7d48418ee7c4ec4545d801bf05d46fc4ccb
C++
angelinelee22/CIS-054
/Test/horoscope.cpp
UTF-8
3,105
3.15625
3
[]
no_license
// File: horoscope.h // Purpose: Implementation file for ZodiacSign, Horoscope, and Person classes. // Author & copyright: Monza Lui // Date: Dec 2, 2019 #include <iostream> #include <string> #include "horoscope.h" using namespace std; // ================= PERSON CLASS ================= Person::Person(string the_name,...
true
727a39815ef84f850feef2a0d3b38bd0552a2193
C++
tunelipt/robosimples
/roboesp32/oem750.h
UTF-8
632
2.703125
3
[ "MIT" ]
permissive
#ifndef _OEM750_H_ #define _OEM750_H_ #define MAX_VEL 50000 #define MAX_ACCEL 50000 class MoveAxis{ public: MoveAxis(int pinstep, int pindir, int vel, int acc); int move(int tostep); int rmove(int nstep); int set_position(int pos=0); int get_position(); int set_velocity(int vel); int get_veloci...
true
b47552bfa1b04476ac77d1bfdad328a949efb31e
C++
shunlqing/DoCode
/algo/Algorithms4/2-Sorting/2.1-ElementarySorts/Test.cc
UTF-8
459
2.9375
3
[]
no_license
#include "BaseSort.h" #include "Selection.h" #include "Insertion.h" #include "Merge.h" #include "Shell.h" #include <string> int main() { Selection<std::string> s; std::string a[10] = { "x", "a", "s", "j", "z", "h", "l", "o", "m", "...
true
05771bd17ac97307b3d3a1fbdfe131f49d15281e
C++
chipstewart/Spanner2
/src/FastaFile.cpp
UTF-8
6,049
2.671875
3
[]
no_license
/* * FastaFile.cpp * * Created by Chip Stewart on 11/5/07. * Copyright 2007 Boston College. All rights reserved. * */ #include "FastaFile.h" struct ToLower { char operator() (char c) const { return std::tolower(c); } }; struct ToUpper { char operator() (char c) const { return std::toupper(c); } }; ...
true
b523477d8338a4588a9b2d7b5548f5c3d377c901
C++
robotpy/robotpy-build
/tests/cpp/rpytest/ft/include/type_caster_nested.h
UTF-8
394
2.609375
3
[ "BSD-3-Clause" ]
permissive
#pragma once #include <functional> #include <vector> struct NestedTypecaster { // only works if pybind11/stl.h and functional.h is included -- our type // caster detection mechanism should include it automatically void callWithList(std::function<void(std::vector<int>)> fn) { std::vector<int> ...
true
5a6e2a73f164f5a9101d3712e4f7fc4d7f1dada4
C++
biug/xNN
/xNN/input_neuron.hpp
WINDOWS-1252
2,301
3.1875
3
[]
no_license
/* * input_neuron.hpp * * Created on: 201663 * Author: Administrator */ #ifndef INPUT_NEURON_HPP_ #define INPUT_NEURON_HPP_ #include <vector> using std::vector; template<typename DType> class InputNeuron { // vector length int m_nEmbeddingLen; int m_nVecLen; // vector z DType * m_pInput; // dLoss / dz ...
true
cd017812389cb391c5f8ab8adb73f19d1571be25
C++
attikis/HiggsAnalysis
/NtupleAnalysis/src/Tools/interface/DirectionalCut.h
UTF-8
3,523
3.34375
3
[]
no_license
// -*- c++ -*- #ifndef Tools_DirectionalCut_h #define Tools_DirectionalCut_h #include <string> #include "Framework/interface/ParameterSet.h" #include "Framework/interface/Exception.h" /// Wrapper for more flexible cutting parameters (cut direction, value pair instead of cut value for fixed direction) template <typena...
true
29a9b90e0aeb0337656a2f6d39910a2ee8b7a169
C++
ss5ssmi/OJ
/codeforce/CF_1481A.cpp
UTF-8
457
2.671875
3
[]
no_license
#include<stdio.h> int main(){ int t; scanf("%d", &t); while(t--){ int x, y, l = 0, r = 0, u = 0, d = 0, flag1 = 0, flag2 = 0; char s[100001]; scanf("%d%d", &x, &y); scanf("%s", &s); for(int i=0;s[i]!='\0';i++){ if(s[i]=='L') l--; else if(s[i]=='R') r++; else if(s[i]=='U') u++; else d--; if(l...
true
77b98dab453f1016d1ab1a69f4bb641f3dcce62e
C++
543877815/algorithm
/leetcode/c++/231. Power of Two.cpp
UTF-8
687
3.390625
3
[]
no_license
// 时间复杂度:O(logn) // 空间复杂度:O(1) bool isPowerOfTwo(int n) { if (n % 2 == 1 && n != 1) return false; long long int ans = 1; while (ans != n) { if (ans > n) return false; ans *= 2; } return true; } // 二进制表示 // 时间复杂度:O(1) // 空间复杂度:O(1) class Solution { public: bool isPowerOfTwo(int ...
true
bab71900c8d1ab03af9d96eedaf0cb9620dbb2ca
C++
czestmyr/dpp
/druhy/src/values/StringValue.h
UTF-8
576
2.78125
3
[]
no_license
#ifndef _ARGLIB_STRING_VALUE_H_ #define _ARGLIB_STRING_VALUE_H_ #include <string> #include "../Value.h" #include "../ValueHandle.h" namespace Arglib { /// Class StringValue encapsulates type string. class StringValue : public Value { public: StringValue(std::string newValue):value(newValue){} ~StringValue() {} ...
true
760a336ec2036ffbfdc03739fa442077977f03a0
C++
Girl-Code-It/Beginner-CPP-Submissions
/Urvashi/milestone-22 (stack)/leetcode stack/easy/remove all adjacent duplicates.cpp
UTF-8
480
3.140625
3
[]
no_license
class Solution { public: string removeDuplicates(string S) { stack<char> s1; for (int i = 0; i < S.size(); i++) { if (!s1.empty() && s1.top() == S[i]) s1.pop(); else s1.push(S[i]); } string temp = ""; while...
true
5b4e06a963629b75e711c58f29e025676376d673
C++
Leo3600Liu/HW_Seaweed_Leo
/src/main.cpp
UTF-8
1,631
3.015625
3
[]
no_license
//Created by Jiteng Liu (Leo) #line 1 "Quiz_2_1_1-2" #include "ofMain.h" class ofApp: public ofBaseApp { public: #line 1 "Quiz_2_1_1-2" ofPolyline polyline; //set up a polyline ofPolyline movePolyline; //set up a polyline void setup() { //to define the basic environment conditions before the pr...
true
01b90a7f6351c637fd06a47400d40f3ad2429697
C++
ArranGravestock/3d-printing-spike-generator
/MyFace.cpp
UTF-8
471
2.78125
3
[]
no_license
#include "MyFace.h" MyFace::MyFace(OSG::Pnt3f centre, std::vector<OSG::Pnt3f> vertices) { faceCentre = centre; faceVertices = vertices; }; MyFace::~MyFace() { }; OSG::Pnt3f MyFace::getFaceCentre() { return faceCentre; }; void MyFace::setFaceCentre(OSG::Pnt3f centre) { faceCentre = centre; }; std::vector<OSG::...
true
258fb46d545cb09467f1f296d72533081ab4fdd2
C++
yoki0805/graphics
/Robots/Robots/GeneticAlgorithm.h
UTF-8
1,971
3.3125
3
[]
no_license
#pragma once #include <vector> #include <algorithm> #include "Utils.h" using namespace std; // create a structure to hold each genome struct Genome { vector<double> weights; double fitness; Genome() : fitness(0) {} Genome(const vector<double>& w, double f): weights(w), fitness(f) {} // overload '<' used for so...
true
41beccd6d985eceb40d1b70be1d63b2fbdb79229
C++
auroraleso/Cpp-course
/examples_theory/teacher/8_designpatterns/iterator/LinkedList.hpp
UTF-8
5,447
3.734375
4
[]
no_license
//#include "LinkedList.h" // *************** LinkedList implementation *************** template <class T> LinkedList<T>::LinkedList() { fNode = lNode = nullptr; } template <class T> LinkedList<T>::~LinkedList() { Node* node = fNode; Node* next; while ( node != nullptr ) { next = node->nNode; delete ...
true
1b6225d48660ad4aa249e37f7773f1dea1307902
C++
Nozomi-Takemura/Cpp_primer_5th_exercises
/6/ex6_23_ref.cpp
UTF-8
254
2.875
3
[]
no_license
#include <iostream> using namespace std; void print(const int (&ia)[2]){ for(auto ele : ia) cout << ele << " "; cout << endl; } int main(){ int i = 0, j[2] = {0,1}; cout << "for i, "; // print(&i); cout << "for j[2], "; print(j); }
true
1e5f6f0c2d90c3ad4026e59248f324874b3b8086
C++
RinokuS/yandex-cpp-belts
/Yellow/Week4/Task10/main.cpp
UTF-8
1,493
3.296875
3
[]
no_license
#include <iterator> #include <set> #include <map> #include <string> #include <vector> #include <iostream> using namespace std; template <typename RandomIt> pair<RandomIt, RandomIt> FindStartsWith( RandomIt range_begin, RandomIt range_end, char prefix){ auto lb = lower_bound(range_begin, range_end,...
true
d060d809a227bc1d3a5d1d3b1b322a2e34ac814a
C++
ddzmitry/CPPLearninig
/oop/Inheritance_DerivedfromExisting/src/Account.h
UTF-8
324
2.53125
3
[]
no_license
/* * Account.h * * Created on: Mar 10, 2020 * Author: dzmitrydubarau */ #ifndef ACCOUNT_H_ #define ACCOUNT_H_ #include <iostream> class Account { public: double balance; std::string name; void withdraw(double amount); void deposit(double amount); Account(); virtual ~Account(); }; #endif /* ACCOUNT_H_...
true
49a2e18fef87f3a3ed9cf0748cde1b0667ef29b8
C++
SgtCoDFish/APG
/src/graphics/Sprite.cpp
UTF-8
1,270
2.96875
3
[]
no_license
#ifndef APG_NO_GL #include <cstdint> #include <memory> #include <string> #include <sstream> #include "APG/graphics/Sprite.hpp" #include "APG/graphics/Texture.hpp" #include "APG/internal/Assert.hpp" namespace APG { Sprite::Sprite(Texture *texture) : Sprite(texture, 0, 0, texture->getWidth(), texture->getHeight())...
true
1eef3586de807949714aeb619cb1686ee45a5be6
C++
shubhgkr/Codechef
/Beginner/TTENIS.cpp
UTF-8
681
3
3
[]
no_license
/* * @author Shubham Kumar Gupta (shubhgkr) * github: http://www.github.com/shubhgkr * Created on 3/18/20. * Problem link: https://www.codechef.com/problems/TTENIS */ #include <iostream> int main() { std::ios_base::sync_with_stdio(false); std::cin.tie(nullptr); int t; std::cin >> t; while (t--) { std::str...
true
9369e1978c8c254e8ffa640e9009aaeec9ca9282
C++
Eaglegor/SchedulerEngine
/Engine/SceneManager/Queries/SceneQueries.h
UTF-8
1,267
2.65625
3
[ "Apache-2.0" ]
permissive
#pragma once #include "OperationStopMappingQuery.h" namespace Scheduler { /** * @ingroup scene_queries * * @brief Interface to perform the scene queries * * @details Scene queries help to extract calculations of some information from the * scene interface keeping it as small as possible. Queries can b...
true
1130121d88b0c368e0e44cd09dbae15cf0f1e5b0
C++
sergey3f0/homework
/10M-2021-spring/959a.cpp
UTF-8
140
2.578125
3
[]
no_license
#include <iostream> int main() { int i; scanf ("%d",&i); if ((i % 2) == 0) { printf ("Mahmoud"); } else { printf ("Ehab"); } }
true
1734ae6849b33db22a92f4586d5f8156dc17fa7d
C++
hyeseonko/Algorithm-Baekjoon
/계단오르기_baekjoon2579.cpp
UTF-8
998
3.359375
3
[]
no_license
/* TITLE: STAIRS BAEKJOON 2579 CATEGORY: DP DATE: 2017-06-01 */ #define _CRT_SECURE_NO_WARNINGS #include <stdio.h> #define bigger(a,b) (a>b?a:b) int stairs[300]; int dp[300]; int main() { int N; scanf("%d", &N); for (int i = 0; i < N; i++) scanf("%d", &stairs[i]); dp[0] = stairs[0]; dp[1] = ...
true
6ae1aae6d9850684b2bd6a20c299e116a5808e35
C++
josedoneguillen/CPP
/practica-funciones-calculo-de-nota/main.cpp
UTF-8
3,650
3.109375
3
[]
no_license
/****************************************************************************** Welcome to GDB Online. GDB online is an online compiler and debugger tool for C, C++, Python, Java, PHP, Ruby, Perl, C#, VB, Swift, Pascal, Fortran, Haskell, Objective-C, Assembly, HTML, CSS, JS, SQLite, Prolog. Code, Compile, Run and Debu...
true
332c7e2c6c95c996dc0180fb6e981a1744980ca0
C++
google-code/algebraic-template-library
/testalt.cpp
UTF-8
1,138
2.859375
3
[]
no_license
// //testalt.cpp // //test program for "alt" // #include <iostream> #include <vector> #include <complex> #include <assert.h> #include "alt/alt.hpp" #include "alt/io.hpp" template<typename EqType> void show_and_solve(const EqType& eq) { std::cout << "Eq:" << eq << std::endl; typename Eq...
true
0229029cde7bb0e30de5d159654a276623e6ee8d
C++
wangxing0608/CtCI
/Trees_and_Graphs/PathsWithSum.cpp
UTF-8
1,598
3.59375
4
[]
no_license
// // Created by wangxing on 19-8-10. // // 给定一颗二叉树,其中每个节点都包含有一个整数值(正数或负数) // 设计算法计算到给定数值的总的路径数,路径不需要从h根或叶子节点开始,但必须向下 #include <unordered_map> #include "tree.h" #include "treetestutils.h" int sumsFrom(const NodePtr<int> &node, int requierdSum, int pathSum, std::unordered_map<int, int> &sums) { if (!node) ...
true
ffaa9bd254fdb4c30c033ad5d16dd9b3a627bd40
C++
sraihan73/Lucene-
/core/src/java/org/apache/lucene/search/DocIdSetIterator.cpp
UTF-8
1,797
2.578125
3
[]
no_license
using namespace std; #include "DocIdSetIterator.h" namespace org::apache::lucene::search { shared_ptr<DocIdSetIterator> DocIdSetIterator::empty() { return make_shared<DocIdSetIteratorAnonymousInnerClass>(); } DocIdSetIterator::DocIdSetIteratorAnonymousInnerClass:: DocIdSetIteratorAnonymousInnerClass() { } in...
true