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
9ead7dbf811661ba2dee1828172d33805ab6aa77
C++
AlinCioabla/SQLSystem
/SQLSystem/SQLSystem/Intermediar.h
UTF-8
366
2.640625
3
[]
no_license
#pragma once #include "ICommand.h" class Intermediar : public ICommand { public: Intermediar(IToken* aCommand) :mCommand(aCommand) {}; void SetArguments(IToken* aTableName) override; CommandType GetCommandType() const override; bool ExpectedNext(ICommand* aNextCommand)const override; ~Intermediar(); vector...
true
c48b3cf5a61bae77fda4b17e24e80a432adde3f0
C++
swaphack/CodeLib
/Foundation/Render/Common/Input/MouseManager.h
GB18030
2,349
2.53125
3
[]
no_license
#pragma once #include "system.h" #include "MouseDelegate.h" namespace render { class Node; class MouseManager { public: MouseManager(); ~MouseManager(); public: // ֻɷ void addMouseScrollDelegate(sys::Object* target, Node* node, MOUSE_SCROLL_DELEGATE_HANDLER handler); // Ƴֻɷ void removeMouseScrollDele...
true
1015cce0eb333788d6ec2ba5b09d03fd438bdeca
C++
qiqi789/NurseScheduler
/src/ReadWrite.h
UTF-8
4,490
2.640625
3
[ "MIT" ]
permissive
#ifndef _ReadWrite_h #define _ReadWrite_h #include <algorithm> #include <stdlib.h> #include <iostream> #include <fstream> #include <streambuf> #include <string> #include <vector> #include <time.h> #include <math.h> #include <limits.h> #include "Scenario.h" #include "StochasticSolver.h" using std::string; using std:...
true
bb9a84dad248510d049e42815b962d3037c18292
C++
MacroBull/Reconstructable
/clone_ptr.hpp
UTF-8
1,697
2.875
3
[]
no_license
/* Copyright (c) 2019 Macrobull */ #pragma once #include <utility> //// CloneBase: interface for clone-able container template <typename T> class CloneBase { public: CloneBase() = default; virtual ~CloneBase() = default; CloneBase(const CloneBase&) = default; CloneBase& operator=(const CloneBase&) ...
true
d1780c74a5c550bc8542ed5ff0269b5602d1ee6a
C++
bhavikabadjate901/arrayCPPInterview
/Swap_major_minor_diagonals_of_matrix.cpp
UTF-8
805
3.40625
3
[]
no_license
#include<bits/stdc++.h> using namespace std; #define N 2 // Swap major and minor diagonals of a square matrix // Given a square matrix, swap the element of major and minor diagonals. // Example : // Input : 0 1 2 // 3 4 5 // 6 7 8 // Output : 2 1 0 // 3 4 5 // 8 7 6 int main() ...
true
5e065113ac78abb05e8c4f9be42786883d136b7e
C++
ronleal0/cplus_codes
/lab6.cpp
UTF-8
1,876
4.03125
4
[]
no_license
#include <iostream> #include <string> using namespace std; int main(){ cout << endl << endl; // 1. DECLARING AND PRINTING VARIABLES /*int number = 10; char letter = 'a'; bool result = true; string str = "hello"; cout << "Number = " << number << endl; cout << "Letter = " << letter << endl; cout << "Result = " << ...
true
c6389e85b0957a396b47a02a8d40ca65e38088fb
C++
alexandraback/datacollection
/solutions_5766201229705216_0/C++/zentropy/FullBinaryTree.cpp
UTF-8
2,048
2.734375
3
[]
no_license
#include <stdio.h> #include <vector> #include <string> #include <algorithm> #include <assert.h> using std::vector; using std::string; size_t slove_small(const vector< vector<bool> >& g) { size_t size = g.size(),ans = size + 1; for(unsigned int imask = 0;imask < (1<<size);++imask) { size_t countbit ...
true
f6ce30c15d867efc7b200eed87ec4335a934ea7c
C++
labelette91/Arduino
/OregonPi/Flag.h
UTF-8
975
3.09375
3
[]
no_license
/* =================================================== Flag.h * ==================================================== * Managing internal 16 bits flag with enum * * Created on: 24 june 2015 * Author: * * =================================================== */ #ifndef __FLAG_H__ #define __FLAG_H__ template<class eType>...
true
cbf24d0886b37b5ba68c21caf8aa9366ede84247
C++
tranphuquy19/cpp-projects
/lcm.cpp
UTF-8
375
2.84375
3
[]
no_license
#include <iostream> using namespace std; int gdc(int a, int b) { if (b == 0) return a; return gdc(b, a % b); } int lcm(int a, int b) { return a * b / gdc(a, b); } // gcc lcm.cpp -lstdc++ -o lcm.out && ./lcm.out 42 72 int main(int argc, char const *argv[]) { int a = stoi(argv[1]); int b = stoi(ar...
true
6ac8b61931c703a5395cbcc0fe8e13272adee775
C++
EcutDavid/oj-practices
/codeforces/1156/A.cpp
UTF-8
1,608
2.71875
3
[]
no_license
#include <bits/stdc++.h> using namespace std; typedef double f64; typedef long long i64; typedef int i32; typedef pair<i32, i32> pi32; typedef unsigned long long u64; typedef unsigned int u32; typedef vector<i32> vi32; typedef deque<i32> di32; #define all(c) (c).begin(), (c).end() #define REP(i, a, b) for (auto i = a...
true
3519206abd5ae5cd788a03f557037b23d959ed9c
C++
Gnnnar/search_server
/net/TcpConnection.h
UTF-8
2,119
2.75
3
[]
no_license
#pragma once #include "Callbacks.h" #include "InetAddress.h" #include "Buffer.h" #include "../base/noncopyable.h" #include "Wheel.h" class Channel; class EventLoop; class Socket; class TcpConnection : noncopyable ,public std::enable_shared_from_this<TcpConnection> { public: TcpConnection(EventLoop* loop, ...
true
39e2dd16436a9fb4718fcb7cb1653f0a38efb540
C++
BiPaulEr/3d-Complex-Asset-Representation-by-Hybrid-
/Sources/MeshLoader.h
UTF-8
2,735
2.765625
3
[]
no_license
#ifndef MESH_LOADER_H #define MESH_LOADER_H #include <string> #include <memory> #include "Mesh.h" namespace MeshLoader { //Explaination of the function of each attribute is in Mesh.h // Loads an OFF mesh file. See https://en.wikipedia.org/wiki/OFF_(file_format) void loadOFF (const std::string & filename, std::sha...
true
e28d23a0c965cbac4979f7065bc3846b81357105
C++
FinixLei/leetcode_finix
/src/74_medium_Search2DMatrix.cpp
UTF-8
2,440
4.0625
4
[]
no_license
/* Write an efficient algorithm that searches for a value in an m x n matrix. This matrix has the following properties: Integers in each row are sorted from left to right. The first integer of each row is greater than the last integer of the previous row. */ #include <vector> #include <iostream> #inc...
true
a79ea3a6b66fc37c172d9527d0211a7a5f8be990
C++
JazInimicus/Advanced-Mathematics-2-Summersemester-2021
/4. Praktikum/main.cpp
UTF-8
3,618
3.140625
3
[]
no_license
#include <iostream> #include "CKomplex.h" int main() { int input = 0; std::cout << "1 - Test Addition zweier komplexer Zahlen" << std::endl; std::cout << "2 - Test Multiplikation zweier komplexer Zahlen" << std::endl; std::cout << "3 - Test Multiplikation komplexer Zahlen mit double" << std::endl; std::cout << "...
true
2f5ad92189d866e3738325217610416b5f46815b
C++
fungoshacks/HEXER
/Mutator.cpp
UTF-8
488
2.75
3
[]
no_license
#include "Mutator.h" #include "windows.h" Mutator::Mutator(int cycles) { _cycles = cycles; } string Mutator::random_filename(string name) { static const char values[25] = {'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'n', 'p', 'q', 'r', 's','t', 'u', 'v', 'x', 'y', 'z'}; ...
true
7a57a95ec15143ad9d28e5b35d98402e16746d83
C++
local-projects/ofxOrbbecAstra
/libs/astra/include/AstraUL/streams/Hand.h
UTF-8
5,525
2.671875
3
[]
no_license
#ifndef HAND_H #define HAND_H #include <Astra/Astra.h> #include <stdexcept> #include <AstraUL/astraul_ctypes.h> #include <AstraUL/streams/hand_capi.h> #include <AstraUL/Vector.h> namespace astra { class HandPoint : public astra_handpoint_t { public: HandPoint(std::int32_t trackingId, ...
true
d1a24160aa1bf04c41de00a20f0dfcb5e8e882a6
C++
derek-zr/leetcode
/Solution/376-wiggle-subsequence/wiggle-subsequence.cpp
UTF-8
2,840
3.6875
4
[]
no_license
// A sequence of numbers is called a wiggle sequence if the differences between successive numbers strictly alternate between positive and negative. The first difference (if one exists) may be either positive or negative. A sequence with fewer than two elements is trivially a wiggle sequence. // // For example, [1,7,4,...
true
e110a82481292b68a33ebfdc5af0108c4561863f
C++
Falcone-H/Algorithm
/AcWing/七夕祭.cpp
UTF-8
1,581
2.703125
3
[]
no_license
// https://www.acwing.com/solution/content/9524/ // c[i] = c[i - 1] + a[i] - avg #include<bits/stdc++.h> #define int long long using namespace std; const int N = 1e5 + 5; int n, m, t; int row[N], col[N], tmp[N]; signed main() { cin >> n >> m >> t; for (int i = 1; i <= t; i++) { int x, y; ...
true
058858d3971ef1a34a8a40ec426fe66b70b2b299
C++
STMU-IEEE/Robotics-16-17
/TestComm/TestComm.ino
UTF-8
746
3.234375
3
[ "MIT" ]
permissive
int LED = 13; int state = 0; void setup() { // put your setup code here, to run once: Serial.begin(9600); pinMode(LED, OUTPUT); } void loop() { // put your main code here, to run repeatedly: commands(); } void commands(){ if(Serial.available() > 0){ int input = Serial.read(); switch(input){...
true
51023c0bfb2c5757342ac67d7f673c3dd7da5963
C++
diskursmonger/RNA
/rna.h
UTF-8
1,123
2.609375
3
[]
no_license
#ifndef rna_h #define rna_h //#include <iostream> #pragma once typedef unsigned char Nucleotide; const Nucleotide A = 0b00; const Nucleotide G = 0b01; const Nucleotide C = 0b10; const Nucleotide T = 0b11; class reference; class RNA { friend class reference; int length = 0; int blocks = 1; Nucleotide...
true
9e4d9ea920600fb47460eae38a8374115077ca92
C++
prateekroy/SPOJ
/AGGRCOW.cpp
UTF-8
2,179
2.84375
3
[]
no_license
#include <iostream> #include <string> #include <cstring> #include <cstdio> #include <cstdlib> #include <algorithm> #include <cmath> #include <ctime> #include <vector> #include <queue> #include <deque> #include <stack> #include <set> #include <map> #include "limits.h" #include <time.h> #include <stdio.h> u...
true
b9f8e181a8db84c9f99255fc4b8109d02e5359de
C++
mehtaanuj95/practice_codes
/geeksforgeeks/majority_element.cpp
UTF-8
1,081
4.03125
4
[]
no_license
// Find the majority element //A majority element is an eleemnt which appears more than n/2 times. #include <iostream> #include <stdio.h> using namespace std; int majority_optimised(int a[], int size) { int count = 1, maj_index = 0; for(int i = 1; i < size; i++) { if(a[maj_index] == a[i]) { count++; } el...
true
e2e7cb233f60a99b54fde128edc47f9c85d4699c
C++
mosszhd/Problem-Solutions
/CodeforcesSolutions/490A.Team Olympiad.cpp
UTF-8
638
2.53125
3
[]
no_license
#include <bits/stdc++.h> using namespace std; int main() { ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0); // freopen("input.txt", "r", stdin); // freopen("output.txt", "w", stdout); int n,skill; vector<int> v[4]; cin >> n; for(int i=1;i<=n;i++){ cin >> skill; v[skill].push_...
true
5960bbfec6e08dcccf4bf716f9c6d13e952d8956
C++
dpariag/leetcode
/reverse_vowels.cpp
UTF-8
1,960
3.6875
4
[]
no_license
// Leetcode: https://leetcode.com/problems/reverse-vowels-of-a-string/#/description // Write a function that takes a string as input and reverse only the vowels of a string. // Example: "hello" --> "holle", "leetcode" --> "leotcede". // Brute Force: // Better: #include <vector> #include <string> #include <iostream> #...
true
06d69261b43af57583cf4e43bf6a22ba857c12ab
C++
mirceamt/MPACK
/jni/MPACK/Resources/SDInputFile.cpp
UTF-8
2,630
2.609375
3
[ "Apache-2.0" ]
permissive
#include "SDInputFile.hpp" #include "Log.hpp" namespace MPACK { namespace Core { SDInputFile::SDInputFile(const char* pPath): Resource(pPath), mInputStream(), mBuffer(NULL) { } ReturnValue SDInputFile::Open() { mInputStream.open(mPath, std::ios::in | std::ios::binary); return mInpu...
true
6304440e3f2d8c6919f2a6f45e4e786fb2be47ee
C++
tobytyx/leetcode
/面试题26_树的子结构.cpp
UTF-8
951
3.4375
3
[]
no_license
#include<iostream> #include<vector> #include<deque> #include<algorithm> using namespace std; struct TreeNode { int val; TreeNode *left; TreeNode *right; TreeNode(int x) : val(x), left(NULL), right(NULL) {} }; class Solution { public: bool isSubStructure(TreeNode* A, TreeNode* B) { if(A == ...
true
3dca436bef45c48e444bb4bdd2a6a76b2fecdd41
C++
TimDarcet/MyRayTracer
/Triangle.h
UTF-8
800
3.09375
3
[ "MIT" ]
permissive
#pragma once #include <vector> #include "Vec3.h" #include "Vertex.h" using namespace std; class Triangle { public: vector<int> m_vertices; Triangle(int p0, int p1, int p2) { m_vertices = {p0, p1, p2}; } // Vec3f normal() { // Vec3f p0 = m_vertices[0]->m_p...
true
fa5847fd94965dbac9f5459096ba8ebc1e284209
C++
SimaoAraujo/ScopeMainProcess
/process.cpp
UTF-8
1,366
2.734375
3
[]
no_license
#include "process.h" CProcess* CProcess::instance = nullptr; CProcess* CProcess::getInstance() { if(!instance) instance = new CProcess(); return instance; } CProcess::CProcess() { } CProcess::~CProcess() { } CRecord* CProcess::getCRecord() { static CRecord *oRecord = CRecord::getInstance(); ...
true
22742439eeccd7534aaf657aafaf4a82b2e76096
C++
centuryglass/Pocket-Home-Bismuth
/Source/System/Wifi/LibNM/Wifi_LibNM_SSID.h
UTF-8
4,073
3.15625
3
[]
no_license
#pragma once /** * @file Wifi_LibNM_SSID.h * * @brief Stores a Wifi access point's ID. */ #include "JuceHeader.h" #include <glib.h> namespace Wifi { namespace LibNM { class SSID; } } /** * @brief Represents the ID name of a Wifi network broadcast by a Wifi access * point. * * SSID values are stor...
true
ec092671f8daa57a9e1dc2bae1e0eda571204f9e
C++
IvoStoilov/Raytracer
/source/core/geometry/plane.h
UTF-8
423
2.78125
3
[]
no_license
#pragma once #include "core/geometry/geometry.h" #include "core/math/vec4.h" class Plane : public Geometry { public: Plane(const vec4& normal, float d) : m_Normal(normal), m_D(d) {} virtual bool IntersectsWith(const Ray& r, IntersectionInfo& outInfo) override; virtual vec4 GetNormal(c...
true
032ad355672ccf43ab2124907dd90ec56f479f89
C++
hanseul1795/ElkCraft
/ElkCraft-master/Sources/ElkEngine/ElkGameEngine/include/ElkGameEngine/Objects/GameObject.h
UTF-8
1,829
2.96875
3
[ "MIT" ]
permissive
#pragma once #include <map> #include <unordered_map> #include <memory> #include <iostream> #include <type_traits> #include <typeinfo> #include "ElkGameEngine/export.h" #include "ElkGameEngine/Objects/AObject.h" #include "ElkGameEngine/Objects/Components/AComponent.h" #include "ElkGameEngine/Objects/Components/Trans...
true
8ad67e1dc074348f2f92589a52efe1e2bf133b93
C++
chosungmann/book-examples
/Professional C++, 5th Edition/Code/c08_code/03_SpreadsheetCellThisAmbiguous/SpreadsheetCell.cpp
UTF-8
634
2.8125
3
[]
no_license
module spreadsheet_cell; import <charconv>; using namespace std; void SpreadsheetCell::setValue(double value) { value = value; // Confusing! } double SpreadsheetCell::getValue() const { return value; } void SpreadsheetCell::setString(string_view value) { value = stringToDouble(value); } string SpreadsheetCell:...
true
eeb552b40cbf44b38bf72089acb0f5627dc044e4
C++
dxvidnguyen/csis45
/CSIS 45 STUFF/p57.cpp
UTF-8
2,557
4.34375
4
[]
no_license
// Name: David Nguyen // File: p57.cpp // Date: 10/21/19 - 12/06/2019 // Description: Arrays Min, Max, Average // Ask the user to enter any 7 numbers into an array of float type, in any order. // Show all the entered numbers, then find the Minimum, Maximum, and Average of all the numbers in the array. #include <iost...
true
4828475b510f3bcd4b7b1da76d5aecd1e1237cc5
C++
NirShalmon/Competitive-Programming-Code
/IOI/2010/Quality of Living.cpp
UTF-8
1,326
2.890625
3
[]
no_license
/***************** Competative programming code written by Nir Shalmon IMPORTANT NOTE: This code was written during a time limited competition or for use in competition. THIS CODE IS NOT AN INDICATION OF MY USUAL CODE QUALITY!! ******************/ #include<iostream> #include<algorithm> #include<set> usi...
true
778a9a11e32610cda108a101e851056b10200ca1
C++
LaraGalvan/Ejercicios-Algo2
/Ejercicios_TDA/TDA_TarjetaBaja/tarjeta_baja.h
UTF-8
1,030
3.0625
3
[]
no_license
#ifndef TARJETA_BAJA_H_ #define TARJETA_BAJA_H_ class TarjetaBaja{ private: double saldo; int cant_viajes_colectivo; int cant_viajes_subte; public: //Metodos //PRE: la variable saldo_inicial es positivo //POST: saldo de la tarjeta en la variable saldo_inicial TarjetaBaja(double saldo_inicial); double obtene...
true
03ac526d7c1e3111c695e6b836f4e435e216eddc
C++
RedGreenCode/uDebug
/12455/GenerateInput.cpp
UTF-8
784
2.671875
3
[ "Apache-2.0" ]
permissive
#include <iostream> #include <ctime> using namespace std; int main(int argc, char *argv[]) { srand((unsigned int)time(NULL)); const int numCases = 20; const int maxLen = 1000; const int maxBars = 20; cout << numCases << endl; for (int i = 0; i < numCases; i++) { int bars[maxBars]; int p = (ra...
true
0884aa2c9e77c63e39e05a0db5b7c78543198216
C++
adrian-j-velasco/Tic_Tac_Toe_01
/Tic_Tac_Toe_01_Source.cpp
UTF-8
2,374
3.3125
3
[]
no_license
#include <iostream> #include <string> #include "CheckerBoard.h" using namespace std; void die(const string & msg); bool boardWin(CheckerBoard board); void endGame(char plyr, bool draw); int main() { bool gameFlag = true, draw = false; int holder; CheckerBoard Board; int turn = 0; char plyr; ...
true
0c5bbb2d0806314e6d6193fe32cb97666a48921f
C++
awarirahul365/CSE-2003-Data-Structures-and-Algorithms
/Leetcode 30 Days Solution/Smallest String Starting From Leaf.cpp
UTF-8
1,430
3.234375
3
[]
no_license
/** * 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...
true
71a396ad8589a770d0f877af936f70c2e74d1eb5
C++
moschneider/NLR
/Neurobot_bk.cpp
UTF-8
93,023
2.59375
3
[]
no_license
////////////////////////////////////////////////////////////////// // // // * * * NEURAL LABYRINTH ROBOT * * * // // // // Copyright (c) 2002 Marvin Oliver Sch...
true
1c947a7c6ac3b83bdfbbe000fe70d6ac469c7fcd
C++
sersajur/QPentago
/src/PentagoLib/include/PentagoLib/Board.h
UTF-8
901
2.65625
3
[]
no_license
/* * Board.h * * Created on: 10 лист. 2013 * Author: Gasper */ #ifndef BOARD_H #define BOARD_H #include <PentagoLib/serialization.h> class Board : public IOriginator { public: enum class RotateDirection { Left, Right }; enum class Quadrant { I = 1, II, III, IV, V, VI, VII, VIII, IX }; Board(un...
true
d4622028629eaa02880f4951765d851aa2287614
C++
joiiewang/pa02_cs130a
/minHeap.cpp
UTF-8
6,268
3.25
3
[]
no_license
#include <vector> #include <string> #include "minHeap.h" #include "Node.h" #include <iostream> using namespace std; Node* minHeap::getMin(){ return v[0]; } pair<string,Node*> minHeap::changeMin(string s, int c){ string temp = v[0]->word; v[0]->word = s; v[0]->frequency++; v[0]->counter = c; in...
true
47c0e0605490bc1ec6915825dd2380562f901825
C++
CknightX/Ryugu
/Ryugu/net/Poller.h
UTF-8
1,161
2.578125
3
[]
no_license
/* Poller 抽象系统底层的IO复用机制 */ #pragma once #include <set> #include <atomic> #include <stdint.h> #include "Ryugu/net/Netheaders.h" namespace ryugu { namespace net { class Epoll; class Channel; const int cstMaxChannels = 20; // IO复用器基类 class Poller { public: int64_t id; int lastActive; Po...
true
7a2bc834ccd810a2dce0cb584691fcfda906c113
C++
youoj/Algorithm
/Baekjoon/[5427]불.cpp
UTF-8
2,519
3.265625
3
[]
no_license
/* 5427번 불(DFS/BFS) * https://www.acmicpc.net/problem/5427 */ #define _CRT_SECURE_NO_WARNINGS #include <iostream> #include <string> #include <vector> #include <queue> using namespace std; int inputW = 0, inputH = 0; int dir_x[4] = { 1, 0, -1, 0 }; int dir_y[4] = { 0, 1, 0, -1 }; enum Form { wall, fire, space, perso...
true
54afb76583af641e2196024f8397837aceac368a
C++
A284Philipi/2388_Tacografo_Cpp
/main.cpp
UTF-8
347
2.859375
3
[]
no_license
#include <iostream> using namespace std; int main() { int cont = 0, tempo, velocidade, casos, distancia = 0; cin >> casos; while (cont < casos){ cin >> tempo; cin >> velocidade; distancia = distancia + (velocidade * tempo); cont++; } cout << distancia ...
true
414ae358618cba77d08443b40e0aa2cfa7553cdb
C++
abhishek9897/Data-Structures-And-Algorithms-using-cpp
/Print Subsequences.cpp
UTF-8
472
2.984375
3
[]
no_license
#include<bits/stdc++.h> using namespace std; void printSubsequences(string str,string subseq,int i,int n) { if(i==n) { cout<<subseq<<endl; return; } // include in subsequence printSubsequences(str,subseq+str[i],i+1,n); // not include in subsequence printSubsequences(str,subseq,i+1,n); }...
true
62321dc80124eedbf2a8f277fa72698a2ea9961e
C++
jeongbbn/Algorithm
/BOJ/17025.cpp
UTF-8
1,336
2.546875
3
[]
no_license
#include<bits/stdc++.h> using namespace std; #define INF 1e9 typedef pair<int, int>pi; typedef pair<pair<int, int>, int>pii; typedef long long ll; int n; char arr[1005][1005]; int dx[] = { 1,-1,0,0 }; int dy[] = { 0,0,1,-1}; bool visit[1005][1005]; queue<pii>q; pi ans; bool outrange(int x, int y) { if (x < 0 || y < ...
true
6ea8ad6b29f74d8824d5cca81b6e11d80cf46e53
C++
JPcarbonell/Algoritmos2E2
/Entrega2/Framework/Prueba.h
UTF-8
714
2.5625
3
[]
no_license
#pragma once class Cadena; class ConductorPrueba; class EstadisticaPrueba; #include "Puntero.h" #include "TipoRetorno.h" class Prueba abstract { public: Prueba(); virtual ~Prueba(); void CorrerPrueba(Puntero<ConductorPrueba> conductor); protected: virtual void CorrerPruebaConcreta() abstract;...
true
0078c46ccbac75021a0384c89ce1f4555c167c3f
C++
mengzhangjian/c-_thread_reading
/chapter-02/accumulate.cpp
UTF-8
1,781
3.484375
3
[]
no_license
// // Created by Zhang,Jian(SEC) on 2020/12/3. // #include <thread> #include <iostream> #include <numeric> #include <vector> template<typename Iterator, typename T> struct accumulate_block { void operator()(Iterator it, Iterator last, T& result) { result = std::accumulate(it, last, result); } }; ...
true
77f5304ebe2656d48c6790501b2e527fdf09090b
C++
Astarx1/cluster
/source/worker/network/interfaces/structures/answer.hpp
UTF-8
285
2.875
3
[ "MIT" ]
permissive
#ifndef ANSWER_HPP #define ANSWER_HPP typedef struct Answer { Answer() : status (1) { ; } Answer(int s) : status(s) { ; } Answer(std::string ret) : status(2), data(ret) { ; } int status; // 0 = Not Ok, 1 = Ok without answer, 2 = Ok with answer std::string data; } Answer; #endif
true
90e32dcc7866d54d52959b27e094966eaa875c4c
C++
SonbolYb/Stream-ANCFIS-FeedForward
/inputVector.h
UTF-8
925
2.78125
3
[]
no_license
/* * inputVector.h * * Created on: Jun 10, 2015 * Author: sonbol * * This class is a child class of commandLine. * * It has a member variable that is a reference because we want to use a dataset from main and we want to prevent copying it, so pass it by refrence. * */ #ifndef INPUTVECTOR_H_ #...
true
70a749d33164e22915d976c70db5e2dfebf5bac5
C++
aleksei-glitch/RFReceiver
/RFReceiver.ino
UTF-8
11,001
2.546875
3
[ "MIT" ]
permissive
/* Simple RF receiver and poster to thingspeak.com Receives date from RF transpotter [RFTransmitter.ino] and posts it to thingspeak.com using ethernet. To see debug messages set variable serialInit to true. Will initiate Serial and prinr messages. For standalone mode set serialInit=false; Arduino pinout ----...
true
58caaba80b5a735c0e29bfebadf3a94b6f85e9fb
C++
invor/space-lion
/src/EngineCore/BillboardComponentManager.hpp
UTF-8
1,359
2.65625
3
[]
no_license
#ifndef BillboardComponentManager_hpp #define BillboardComponentManager_hpp #include <mutex> #include <string> #include <unordered_map> #include <vector> #include "BaseSingleInstanceComponentManager.hpp" #include "EntityManager.hpp" // TODO: documentation namespace EngineCore { class WorldState; namespace ...
true
3d0c852960ad5472ed442902e47e2d9ac2ee5f88
C++
FeiZhan/Algo-Collection
/answers/codeforces/534B Covered Path.cpp
UTF-8
794
2.671875
3
[ "MIT" ]
permissive
//@type greedy, DP //@result 12964986 2015-09-11 22:53:08 zetta217 534B - Covered Path GNU C++ Accepted 15 ms 0 KB // I don't use DP #include <iostream> using namespace std; int main() { int begin(0); int end(0); while (cin >> begin >> end) { if (begin > end) { int temp = begin; begin = end; ...
true
ad10953d8bf1dd2b54e385a03f7e7d14f4759c2c
C++
infinityhao/CPP
/sizeof_data_types.cpp
UTF-8
671
3.28125
3
[]
no_license
#include <iostream> using namespace std; char c; int i; float f; double d; bool b; wchar_t w; double s[10]; int main() { cout << "The size of char: " << sizeof(c) << "kb" << endl; cout << "The size of int: " << sizeof(i) << "kb" << endl; cout << "The size of float: " << sizeof(f) << "kb" << endl; c...
true
697a89b783d2a09c58191767c211b5eec6de4c39
C++
chaiyujin/ThreadedDepthCleaner
/src/main.cpp
UTF-8
7,220
2.609375
3
[ "MIT" ]
permissive
// Libraries #include <librealsense2/rs.hpp> // Include RealSense Cross Platform API #include <opencv2/opencv.hpp> // Include OpenCV API #include <opencv2/rgbd.hpp> // OpenCV RGBD Contrib package // STD #include <string> #include <thread> #include <atomic> #include <queue> using namespace cv; #define SCALE_FAC...
true
8890379be2b4aaeb884ad6aa1e57fef186bcd1d0
C++
TanmoyPaul1/CSCI235
/BSTree/BSTree.h
UTF-8
571
2.671875
3
[]
no_license
#pragma once #include <iostream> #include "Node.h" class BSTree{ private: Node *root; public: BSTree(); void insert(int d); int search(int value); void deleteNode(int d); Node *deleteNode(Node *n, int d); int treesum(); int treesumHelper(Node *n); int numNodes(); int numNodesH...
true
0252af8e1f98aa91a26f7b06bc39d3ebf32684e5
C++
sleepy-juan/false-positive-speech-data
/src/fitness/incomprehensibility.hpp
UTF-8
691
2.59375
3
[]
no_license
/* incomprehensibility.hpp - incomprehensibility fitness Created by Sungwoo Jeon Modified by Juan Lee */ #include <string> #include <vector> #include "../wav/wav.hpp" #ifndef __INCOMPREHENSIBILITY_HPP__ #define __INCOMPREHENSIBILITY_HPP__ /* Class incomprehensibility - Wave incomprehensibil...
true
8e0fd819d046f10ecbe643777dad3144f805a7c5
C++
psyzemin/DataStructure
/C/Tree_Array.cpp
UTF-8
377
2.96875
3
[]
no_license
#include "Tree_Array.h" #include<stdio.h> #include<stdlib.h> ATree InitTree(int x) { ATree t = (ATree)malloc(sizeof(struct Tree_Array) + sizeof(struct TreeNode)*x); if (t == NULL) { perror("Out of space!"); } t->nodes = (TNode)malloc(sizeof(TNode)*x); t->num = 0; t->root = 0; t->size = x; return...
true
fa893dba90629fc00105586b2f38f1604b5f2e00
C++
1panpan1/second-filesystem
/project/src/Bitmap.cpp
UTF-8
1,329
2.921875
3
[]
no_license
#include"Bitmap.h" #include"FileSystem.h" #include<cstring> #include<iostream> using namespace std; extern FileSystem g_fileSystem; Bitmap::Bitmap() { bsize = (512 - sizeof(int) * 2) * 8; memset((unsigned char *)bmap, 0, 512 - sizeof(int) * 2); } Bitmap::Bitmap(int _start ,int size) :start(_start) , bsize(size) { ...
true
aab1e6f9fde1cf7f0a8999a5f20e566674117014
C++
zzqboy/algorithm
/src/sort/heap_sort.cc
UTF-8
946
3.578125
4
[]
no_license
//author: zzq //堆排序 #include <iostream> void heapAdjust(int heap[], int length, int p_i) { int temp = heap[p_i]; int min_i = 2 * p_i + 1; while(min_i < length) { if((min_i + 1) < length && heap[min_i] > heap[min_i + 1]) min_i++; if(temp < heap[min_i]) break; heap[p_i] = heap[mi...
true
5ab79f7e2be383756405f6503f9c60cf773de131
C++
BLumia/MidiUtils
/src/MidiHeader.cpp
UTF-8
978
2.53125
3
[ "BSD-2-Clause" ]
permissive
#include <iostream> #include <string> #include <cstring> #include "midiutils/MidiHeader.hpp" #include "midiutils/MidiUtils.hpp" using namespace std; namespace MidiUtils { MidiHeader::MidiHeader() {} int MidiHeader::read(istream& istream) { std::string rawMThd(14, ' '); istrea...
true
5dc43a47e5fdbdbab63bea0e341d85ad8f59fc8b
C++
for-l00p/TestCses
/TestCses/pb_grid_unsolved.cpp
IBM852
2,658
2.859375
3
[]
no_license
#include <iostream> #include <algorithm> #include <string> #include <fstream> #include <vector> #include <set> #include <sstream> #include <chrono> #ifdef MY_INPUT #define FILE_INPUT "input.txt" #define STREAM_IN my_file #define OPEN_IN std::fstream my_file(FILE_INPUT); if (!my_file.good()) { std::cout << "Error openi...
true
77231a83631695a984a603250a40e23c5e6be4d8
C++
swardhan/competetive
/eminence/numberTheory/freeCube.cpp
UTF-8
786
2.765625
3
[]
no_license
#include<bits/stdc++.h> #define MAX 1000000 typedef long long ll; using namespace std; int main(){ int t,tc = 1; cin >> t; //Create Array bool isFreeCube[MAX]; isFreeCube[0] = false; for(int i = 1; i < MAX; i++){ isFreeCube[i] = true; } for(int i = 2; i*i*i < MAX; i++){ if(isFreeCube[i]){ ...
true
593469a09fcc81c9375e417a30136b19e2643d92
C++
yku/Competition
/TopCoder/srm305/MultiRead.cpp
UTF-8
2,287
3.09375
3
[]
no_license
#include <iostream> #include <sstream> #include <cstring> #include <algorithm> #include <string> #include <vector> using namespace std; class MultiRead { public: int minCycles(string trace, int procs) { int clk = 0; int reads = 0; for(int i = 0; i < trace.size(); i++) { if(trace[i] == 'W') { ...
true
789cee6123338ba7848d7c1f84e81ff064503489
C++
Nimmel/x2
/include/Memory.h
UTF-8
10,104
2.703125
3
[]
no_license
#ifndef MemoryManager_h #define MemoryManager_h #include <List.h> #include <Locator.h> #include <def.h> //#include <Kernel.h> #if defined(CODE32) //new & delete AS_MACRO void* operator new(size_t size){return NULL;} AS_MACRO void operator delete(void *p){} //全局方法: placement new和placement delete // Default placement ...
true
14ab951c8906d0a897ca3fbace3c87b3c6797acb
C++
Ruthietta/Infinite-coders-competition
/Task 4/Solution2/fibonacci.cpp
UTF-8
442
3.1875
3
[]
no_license
#include "fibonacci.hpp" long long fibRecursive(int n) { if (n <= 1) return n; return fibRecursive(n - 1) + fibRecursive(n - 2); } long long fibIterative(int n) { if (n <= 1) return n; long long last = 1; long long nextToLast = 1; long long result = 1; for (int i = 2; i < n...
true
0d33f5c64d9d2fadf6e0eaa381bc15b982d61c0f
C++
DosDevs/zoom-zoom
/newfs/Octet.h
UTF-8
444
2.75
3
[ "BSD-3-Clause" ]
permissive
#ifndef OCTET_H__INCLUDED #define OCTET_H__INCLUDED #include <string> namespace NewFs { using std::string; class Octet { private: unsigned char _value; public: Octet(unsigned char value = 0): _value(value) {} operator un...
true
01dedad1a909f4700a4d716638129d1ffc8a3579
C++
sirdyf/ENEV_2_261
/TESTS/NETWORK/client/client/client.cpp
UTF-8
971
2.5625
3
[]
no_license
// client.cpp : Defines the entry point for the console application. // #include <conio.h> #include <iostream> #include "tNetworkClient.h" using namespace std; class tMain : public tINetworkClient{ int FormatDataForSend(char*){return 0;} void ClientReciveData(const char* ,int){;} }; int main(int argc, char* argv[]...
true
984599d728ee676457f1df5550d383ca89ca0256
C++
Nub-Team/Simple_Production
/CUDA_Nub/Image_Processing/src/main.cpp
UTF-8
1,398
2.828125
3
[ "Apache-2.0" ]
permissive
#include <iostream> #include <string> #include "../include/imageProcess.h" int main(int argc, char *argv[]){ if (argc < 3) std::cerr << "Usage: " << argv[0] << " <operation> <inputfile1> [inputfile2]" << std::endl; else{ std::string operation(argv[1]); std::string input_file(ar...
true
5ddd1b31fce660fc9ff0611dbf11cc3fc70b156f
C++
mmorri22/cse20312
/Lecture19/include/Graph1.h
UTF-8
1,033
3.453125
3
[]
no_license
#ifndef GRAPH1_H #define GRAPH1_H #include "Vertex2.h" #include "DynArr.h" #include <iostream> template<class T> class Graph{ private: DynArr< Vertex< T > > vertices; // Adjacency Lisy public: // Constructor Graph( ) : vertices() {} // Add a vertex prior to any edges void add_ver...
true
1fff9b8dc685b2a6f64791a49b5a64af37fddefe
C++
pmdp/P3_1_IG
/Chasis.cpp
UTF-8
11,854
2.875
3
[]
no_license
/* * Chasis.cpp * * Created on: Jan 26, 2016 * Author: pepc */ #include "Chasis.h" Chasis::Chasis() { numTexturas=1; colourMaterial = true; //Crea Malla del Chasis numVertices = 42; numCaras = 27; numNormales = numCaras; vertice = new PV3D*[numVertices]; normal = new PV3D*[numNormales]; ...
true
7eeec0a382b2212f78e6f8b732402ab17f169586
C++
CJHMPower/Fetch_Leetcode
/data/Submission/526 Beautiful Arrangement/Beautiful Arrangement_1.cpp
UTF-8
882
2.765625
3
[]
no_license
//-*- coding:utf-8 -*- // Generated by the Fetch-Leetcode project on the Github // https://github.com/CJHMPower/Fetch-Leetcode/ // 526 Beautiful Arrangement // https://leetcode.com//problems/beautiful-arrangement/description/ // Fetched at 2018-07-24 // Submitted 3 months, 1 week ago // Runtime: 140 ms // This solutio...
true
cbe292282890325691e57a4aa40c7864509bdab4
C++
Nickchooshin/HUGP2_1week
/PC/Project-FW/DataLoader.cpp
UTF-8
2,979
3.1875
3
[]
no_license
#include "DataLoader.h" #include <string> CDataLoader::CDataLoader() : m_pFile(NULL) { } CDataLoader::~CDataLoader() { CloseData() ; } const bool CDataLoader::OpenData(char *filepath) { if(m_pFile!=NULL) return false ; m_pFile = fopen(filepath, "r") ; if(m_pFile==NULL) return false ; return true ; } const...
true
bf1a530b3934fb40fa86dac7bafa2552c6d7b478
C++
jaylenjf34/CS202
/Prog3nHashTable/table.cpp
UTF-8
11,289
3.53125
4
[]
no_license
#include "table.h" table :: table () { hash_table_size = 60001; // set size of hash table hash_table = new node * [hash_table_size]; // allocate hash table for(int i = 0; i < hash_table_size ; ++i) // initialize each element int table to NULL { hash_table[i] = NULL; } } input :: input () { // initiali...
true
aeb4dca2845be54d759a8991edc824b76b5e1478
C++
aft3rthought/ATLGraphics
/flat_textured_renderer.h
UTF-8
4,553
2.53125
3
[]
no_license
#pragma once #include "ATLUtil/math2d.h" #include "ATLUtil/color.h" #include "ATF/ATLGLResource.h" #include "ATF/NomRenderingHeaders.h" #include "ATF/NomFiles.h" namespace atl_graphics_namespace_config { struct application_folder; struct shared_renderer_state; struct flat_textured_vertex { ...
true
a535211f0e3a9af46b00cda76f70cf013440c110
C++
fooofei/leetcode
/cn-058-last-word-len/main.cc
UTF-8
1,140
3
3
[]
no_license
#include <algorithm> #include <array> #include <bitset> #include <chrono> #include <iostream> #include <limits> #include <list> #include <map> #include <stack> #include <string> #include <thread> #include <vector> using namespace std; // 058 https://leetcode-cn.com/problems/length-of-last-word/ class Solution { publ...
true
f365f26ca4dd15df1e074f429c7ba405038da441
C++
tcannon686/gnidEngine
/src/tests/phongshader.cpp
UTF-8
1,493
2.53125
3
[]
no_license
#include "gnid/phongshader.hpp" #include "gnid/gamebase.hpp" #include "gnid/matrix/matrix.hpp" #include <cassert> #include <iostream> using namespace tmat; using namespace std; using namespace gnid; static int t = 0; static shared_ptr<PhongShader> phongShader; static shared_ptr<PhongMaterial> phongMaterial; class T...
true
46bd6719521ab9a4f3c5d0e98aef4b890fc7d4cb
C++
MrEngineerET/roboClean
/Code/Node MCU ESP8266/NodeVrAndVlAndW/NodeVrAndVlAndW.ino
UTF-8
2,973
2.65625
3
[]
no_license
#include <ESP8266WiFi.h> #include <ESP8266WebServer.h> #include<SoftwareSerial.h> SoftwareSerial arduinoSerial(D1,D2); const char* ssid = "RoboClean"; const char* password = "qazwsxedc"; IPAddress local_ip(192,168,1,1); IPAddress gateway(192,168,1,1); IPAddress subnet_mask(255,255,255,0); ESP8266WebServer serv...
true
3c28ba0e2a913ca14568f586cee774f096ee7df7
C++
heretique/cuteboxLegacy
/src/common/genpublicstrings.cpp
UTF-8
2,005
2.734375
3
[]
no_license
#include <QObject> #include "genpublicstrings.h" //Main screen QString GenPublicStrings::STR_TEST = ""; QString GenPublicStrings::STR_WELCOME = ""; QString GenPublicStrings::STR_CHOOSE_DOWNLOAD_FILES = ""; QString GenPublicStrings::STR_CONFIRM_DOWNLOAD_FILES = ""; QString GenPublicStrings::STR_CHOOSE_FILES = ""; QStr...
true
0e81a9ac1512ff045f9edd59eca33eadd9e322ae
C++
felipepiovezan/ine5420
/lib/cg/Viewport.cpp
UTF-8
5,761
2.703125
3
[]
no_license
#include "cg/Viewport.h" #include <iostream> #include <cassert> #include <ctime> namespace CG { Coordinate Viewport::transformCoordinate(const Coordinate& c) const { int width = getWidth(); int height = getHeight(); double x = width * (c.x - _window.xmin()) / (_window.xmax() - _window.xmin()); double y ...
true
dce3f476b69ec6a09ad8f6d937f21ac943a54344
C++
seedChen/leetcode
/restoreIpAddresses/ans.cpp
UTF-8
2,416
3.609375
4
[]
no_license
/** * @file ans.cpp * @brief * Given a string containing only digits, restore it by returning all possible * valid IP address combinations. * * For example: * Given "25525511135", * * return ["255.255.11.135", "255.255.111.35"]. (Order does not matter) * * @version * @date 2015-06-19 09:21 * @author chen_j...
true
7303e9f5c5743de49063706f9b11b7fd373af863
C++
MAMEM/GazeTheWeb
/Browse/Client/src/State/Settings/Settings.h
UTF-8
3,493
2.53125
3
[ "MIT", "Apache-2.0" ]
permissive
//============================================================================ // Distributed under the Apache License, Version 2.0. // Author: Raphael Menges (raphaelmenges@uni-koblenz.de) //============================================================================ // Settings State. #ifndef SETTINGS_H_ #define SET...
true
a7a6cf4659f3a99b70092ec8d44fb29039923bce
C++
zqiu/codefor-----andgiggles
/IEDcode/withoutwirelesstest/withoutwirelesstest.ino
UTF-8
4,089
2.6875
3
[]
no_license
/* code for the microcontroller on the shirt */ #include <avr/sleep.h> #include <Adafruit_GFX.h> #include <Adafruit_SharpMem.h> #define SERIAL_BAUD 115200 #define READDELAY 5 //#of ms to wait between reading sensors #define READSBEFOREPRINT 10 #define TEMPPORT 0 #define RESPORT 1 #define HEARTRATEPOR...
true
730eada5a75ee30f6c2e8cf652696c5cf5b925c7
C++
GonzaloCirilo/UVa
/vol110/11090_GoingInCycle!!.cpp
UTF-8
3,469
2.515625
3
[]
no_license
#include <vector> #include <stdio.h> #include <algorithm> using namespace std; typedef vector<int>vi; typedef pair<int, int> ii; typedef vector<ii> vii; typedef vector<vii> graph; typedef vector<vi> matrix; graph g; vi visited; vector<double> pos; bool dfs(int ind, vi stack) { if (visited[ind] == 1) { retu...
true
e53082f06bde6918a0f35667eae34c56637f8d0f
C++
luisSalher/Sistemas-Distribuidos
/Practica3/Fecha.cpp
UTF-8
2,285
3.328125
3
[]
no_license
#include "Fecha.h" #include <iostream> using namespace std; Fecha::Fecha(int dd, int mm, int aaaa) { mes = mm; dia = dd; anio = aaaa; int cadena[1000000]; } void Fecha::inicializaFecha(int dd, int mm, int aaaa) { Fecha f; if(!f.valida(dd,mm,aaaa)) { ...
true
2ea379e2e666c214d9e1a2102e02a9294414d75d
C++
andrewletskalyuk/Practice_17.08.2019
/Project4/Coordinates.h
UTF-8
196
2.65625
3
[]
no_license
#pragma once class Coordinates { int x; int y; public: Coordinates(); Coordinates(int, int); ~Coordinates(); void setX(int _x); void setY(int _y); int getX() const; int getY() const; };
true
196d1361a83dbc74602b1fdadaa25f2c99548c69
C++
johnli28/data-algorithm
/dynamic-program/LongestCommonSubsequence.h
UTF-8
919
3.109375
3
[]
no_license
#pragma once #include <iostream> #include <string> #include "utils.h" #include <vector> using namespace std; // NOTE: // dynamic programming: split a big problem into small problems // A dynamic programming table, store the states (results) of small problems // Initiate states int lcsDP(char* lStr, ...
true
4fdf4759eebecb07a06618ecf126068e643656a3
C++
tsargs/Physically-based-modeling
/Physically-based modeling 2.0/Vortex.h
UTF-8
716
2.546875
3
[]
no_license
// // Vortex.h // PhysicallyBasedModeling // // Created by Shyam Prathish Sargunam on 10/4/17. // Copyright © 2017 Shyam Prathish Sargunam. All rights reserved. // #ifndef VORTEX #define VORTEX #include <stdio.h> #include <algorithm> #include "Vector3.h" class Vortex { public: Vector3 base_center; ...
true
64bda182e796668a348eadb57fc6e0e86d922743
C++
tatjam/SpaceStation
/SS13++/src/util/FileUtil.h
UTF-8
1,329
2.671875
3
[]
no_license
#pragma once #include <string> #ifdef _WIN32 #include <Windows.h> #endif // The path to the location of our executable extern std::string futil_exePath; // The path from which the program was launched extern std::string futil_runPath; struct FileUtil { // Converts '/' to '\' static std::string windowPath(std:...
true
d0d837919535b01b32ba88ef935ba0eacd9e873f
C++
StefanKubsch/NARC
/Sources/lwmf/lwmf_multithreading.hpp
UTF-8
2,936
2.984375
3
[ "Unlicense", "LicenseRef-scancode-public-domain" ]
permissive
/* *************************************************************** * * * lwmf_multithreading - lightweight media framework * * * * (C) 2019 - present by Stefan Kubsch ...
true
711bf95db9bfe8c36ccbe613f45ef072d6803888
C++
seanjedi/ECS175Project3
/Bresenham.cpp
UTF-8
4,582
3.25
3
[]
no_license
#include "Bresenham.h" #include <math.h> #include <iostream> using namespace std; void makePixel(int x, int y, float* PixelBuffer, int windowSizeX, float Rintensity, float Gintensity, float Bintensity, int mode); inline void max(int& a, int& b, float& c, float& d) { if (a > b) { int temp = a; a = b; b = temp; ...
true
4ed0a202ce00ffdbcc1a1c23f0eb7bd99fe26c0b
C++
highlandear/snail
/GlMainApp/GlMainApp/illuminant.hpp
GB18030
1,752
3.078125
3
[ "MIT" ]
permissive
#pragma once #include <windows.h> #include <gl/GL.h> class GLight { public: GLight(int i) : id(i) {} GLight() : id(0){} int getID() { return id; } void setID(int i) { id = i; } // ùԴλ void GLight::setPosV(const float v[]) { glLightfv(id, GL_POSITION, v); } // û void GLight::setAmbientV(const float...
true
b997e15e41de1677eab0bdaceb5b5241c072b37d
C++
JanKesek/C---C
/min tablicy.cpp
UTF-8
489
3.484375
3
[]
no_license
#include <iostream> using namespace std; int minValue (int a) { int tab[a]; cout << "Wpisz " << a << " elementow" << endl; for (int h=0;h<a;h++) { cin >> tab[h]; } int min=tab[0]; int indxMin =0; for (int i=1;i<a;i++) { if (tab[i] < min) { min = tab[i]; indxMin=i; } } return min; } ...
true
d84eb1b3b5dcc4fab88187bf74e97ac0be35efed
C++
tagoro9/Practicas-ETSII
/SSI/practica_2/cpp/lib/skc/skc.h
UTF-8
675
2.84375
3
[]
no_license
#ifndef SKC_H_ #define SKC_H_ #include <vector> #include <iostream> #include <sstream> #include <string> using namespace std; //Estructura vector de la STL typedef vector<int> Vector; const char BIN = 'B'; const char HEX = 'H'; const char DEC = 'D'; const char DEBUG = 'd'; const char STD = 's'; class Skc { protecte...
true
eb49bd6a767cac8a89dd52111558de68d6f73198
C++
Josedm92/UD2
/ejercicio2.2.cpp
UTF-8
1,006
3.90625
4
[]
no_license
//Ejercicio 2.2 de la pagina 50. #include <iostream> //Incluimos libreria iostream que permite la entrada por teclado y la salida por pantalla. using namespace std; //Sentencia obligatoria. //Declaración e inicialización de variables. int numero=0; //Inicio del programa. int main () { cout << "Introduzca un número:...
true
22b282c6449875cfa7555da67dc30aa3179bb52c
C++
bmegli/HW6
/src/exercise06_02.cpp
UTF-8
1,074
3.078125
3
[]
no_license
#include <Rcpp.h> using namespace Rcpp; //' @title simplifies list of numeric vectors to array if possibles //' @description Task: //' Write your own implementation of the simplify2array() function. Your function should //' expect a list of numeric vectors on input. //' //' @param L list of numeric vectors //' @retur...
true
fd25a954818da94774f7f679ccf15c8d95755291
C++
NPIPHI/v8LoadHttp
/src/http.cpp
UTF-8
1,214
2.6875
3
[]
no_license
// // Created by 16182 on 1/2/2021. // #include "http.h" std::string Http::get(std::string url, int port, std::string subdomain) { Socket socket{url.c_str(), port}; std::string msg = make_header(url.c_str(), port, subdomain.c_str()); socket.write_bytes(msg.begin().base(), msg.end().base()); InputStrea...
true
5b88b9aad7a0814af87f9cc1cd5a4756192df785
C++
vasily-golubev/acinverse
/src/types.cpp
UTF-8
204
2.734375
3
[]
no_license
#include "types.h" float distance (vector3 r1, vector3 r2) { float squared = (r1.x - r2.x) * (r1.x - r2.x) + (r1.y - r2.y) * (r1.y - r2.y) + (r1.z - r2.z) * (r1.z - r2.z); return sqrt(squared); }
true
82cb03a554f17c501729a0344364c43bf61e994f
C++
gittyvarshney/Linked_list
/floyd_cycle.cpp
UTF-8
2,399
3.53125
4
[]
no_license
#include<bits/stdc++.h> using namespace std; #define MAX 100005 //Detect cycle through floyd algorithm which is no coincidence //two pointer p and q increment p ones and increment q twice //to find starting of loop increment the meet node and head node class linkedList { public: int data; linkedList* next; }; voi...
true
85143d69c4be4d67b6320c5b26f767564dc7b89f
C++
GregVanK/PibbliePums
/Game/PibbliePums/PibbliePums/Inventory.h
UTF-8
467
2.921875
3
[]
no_license
#pragma once #include <list> #include "Food.h" /* *@author: Greg VanKampen *@file: Inventory *@description: Special food container class */ namespace GEX { class Inventory { public: Inventory(); Inventory(std::list<Food> inventory); public: void addFood(Food f); Food removeFood(int index); Food getF...
true