blob_id
stringlengths
40
40
content_id
stringlengths
40
40
repo_name
stringlengths
5
114
path
stringlengths
5
318
language
stringclasses
5 values
extension
stringclasses
12 values
length_bytes
int64
200
200k
license_type
stringclasses
2 values
content
stringlengths
143
200k
d2885fb8c54c808dd7deb3d19ee56ba182d1fbf2
468ce3294f2dc5056539bf1d427758d5332043ee
15831944/barry_dev
/src/BackupLog/Testers/BackupLogTester.cpp
C++
cpp
1,276
no_license
//////////////////////////////////////////////////////////////////////////// // // Copyright (C) 2005 // Packet Engineering, Inc. All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification is not permitted unless authorized in writing by a duly // appointed officer of ...
e39ec179d33c53a1323c59ebba2c7e1f5656f78c
40fc96988ab648ba0a9cd33563240ff8fb9b5607
sshockwave/Online-Judge-Solutions
/EZOJ/2002.cpp
C++
cpp
1,974
permissive
#include <iostream> #include <cstdio> #include <cstring> #include <cassert> using namespace std; typedef long long lint; inline bool is_num(char c){ return c>='0'&&c<='9'; } inline int ni(){ int i=0;char c; while(!is_num(c=getchar())); while(i=i*10-'0'+c,is_num(c=getchar())); return i; } inline void apmax(int &a,i...
a2e1d9fa9741d50462635d6cf414f717f7bcd31b
519be8c6f6dd3ed74a2109459b8e70a2e13c6bda
jccarvalhosa/maratona
/codeforces/round188/strings.cpp
C++
cpp
456
no_license
#include <iostream> #include <string> #include <vector> using namespace std; vector<int> h, m; int main() { string s, sub; int i, j, n, H, M; long long ans=0; cin>>s; n = s.size(); for(i=0;i<=n-5;i++) { sub = s.substr(i, 5); if(sub == "heavy") h.push_back(i); else if(sub == "metal") m.push_back(i); } M ...
bf4350f2f6ce678d3a566eee41f9a185a2dd0652
f9e0ad8a26f267b97f42e6ca5baa56f36ca0a5c5
ElementMo/OpenGLAnimation
/Lab4Animation/LabAnimation/OTBox.cpp
C++
cpp
824
no_license
#include "OTBox.h" OTBox::OTBox() { this->x = 0; this->y = 0; this->z = 0; this->w = 1; this->h = 1; this->d = 1; } OTBox::OTBox(float x, float y, float z, float w, float h, float d) { this->x = x; this->y = y; this->z = z; this->w = w; this->h = h; this->d = d; } OTBox::OTBox(OTBox& other) { this->x =...
8de534c292d24900164fde1bc9e94e60d6d9db5c
af0b9cd4b14051b365800d1eb0f21ad88128d23c
leon-m/cool
/externals/xdispatch/tests/dispatch_after_lambda.cpp
C++
cpp
3,109
permissive
/* * dispatch_after_lambda.cpp * * Copyright (c) 2008-2009 Apple Inc. * Copyright (c) 2011-2013 MLBA-Team. * All rights reserved. * * @LICENSE_HEADER_START@ * 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 t...
a9ee2557c45dddd261b2b032a3e561abd3c86512
9986111337f89dbd1bfe4b396568cb5fb6de7d33
CSUF-CPSC120-2019F23-24/labex02-stephanietalley
/prob01/main.cpp
C++
cpp
395
permissive
// Name: // This program displays a diamond pattern to the screen. #include <iostream> int main() { std::cout << " *" << std::endl; std::cout << " ***" << std::endl; std::cout << " *****" << std::endl; std::cout << "*******" << std::endl; std::cout << " *****" << std::endl; std::cout << " ...
445bd7988ea2fd5efd2e7f6681f222a1fa6a906d
ea5df196c980b55fb491a3982127dc04133b7cd8
scottwon/BilliardsAssistantSystemBasedOnLabVIEW
/ProtoCodes/BallPath/BallPath.cpp
C++
cpp
12,042
no_license
#include<iostream> #include<cmath> #include<vector> #include<GL/glut.h> #include<time.h> #include<opencv2/core.hpp> #include<opencv2/imgproc.hpp> #include<opencv2/highgui.hpp> #include<opencv2/features2d.hpp> using namespace std; using namespace cv; const double r=0.05; double min(double a, double b) { return a > b ? ...
4567e8542c9698bf0c89d39f3dcd7e8533fe9c16
feabee61fd8cc26eb1b1c1786f4131a28b364265
oboro-graph/Smart-Grid-Advanced-Metering-Infrastructure-privacy-preserving-protocol-implementation
/src/crypto/TrustedParty.cc
C++
cc
5,886
no_license
#include "TrustedParty.h" #include "UtilityCompany.h" #include "../TTPAdapter.h" #define DEBUG(x,y) if (verbose) out->print(x,y) namespace SMImp { TrustedParty::TrustedParty(Integer i,TTPAdapter* o) : Requester(i) { out = o; init(); verbose = true; } TrustedParty::TrustedParty(Integer i) : Requester...
e5dda31dba2096b50bcbe841ec33a252b1ffcc67
f0c02acdd44d25d42efed32d3b5b2bc90ff935f1
mutour/mozc
/src/rewriter/unicode_rewriter_test.cc
C++
cc
9,603
permissive
// Copyright 2010-2015, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are // met: // // * Redistributions of source code must retain the above copyright // notice, this list of condit...
43bcc4deffe7562fcb56843e1b9849ed9bfe1de1
e86a89bb4f3fd13121d00637c6d72937e3535fa6
ayushsinghal2/Placements
/permutation.cpp
C++
cpp
389
no_license
#include <bits/stdc++.h> using namespace std; int main() { string s,t; cin>>s>>t; int letters[26] ={0}; for(int i=0;i<s.length();i++) { letters[s[i]-'a'] ++; } for (int i = 0; i < t.length(); ++i) { letters[t[i]-'a'] --; } int flag = 0; for (int i = 0; i < 26; ++i) { if(letters[i]!=0) { flag=1; ...
ea0880b38c8f08fac045bcc54fd180e7bd6177b2
1232ebedbf18d05d6f396653058402f2edc700cd
atatomir/work
/_infoarena/---.Nucleul Valoros/knuth.cpp
C++
cpp
1,164
no_license
#include <iostream> #include <cstdio> #include <cstring> #include <vector> #include <algorithm> #include <cmath> using namespace std; #define mp make_pair #define pb push_back #define ll long long #define maxN 3111 int n, i, j; ll v[maxN], sum[maxN]; ll dp[maxN][maxN]; int optim[maxN][maxN]; int main() ...
658e0a04c7a9a91192d768270ee89f66c023e0b7
75304684eb5d88b93914e468ca657c35978a384f
git-Charlie/ARK-SDK
/SDK/ARKSurvivalEvolved_DinoCharacterStatusComponent_BP_SpaceDolphin_functions.cpp
C++
cpp
1,313
permissive
// ARKSurvivalEvolved (329.9) SDK #ifdef _MSC_VER #pragma pack(push, 0x8) #endif #include "ARKSurvivalEvolved_DinoCharacterStatusComponent_BP_SpaceDolphin_parameters.hpp" namespace sdk { //--------------------------------------------------------------------------- //Functions //-------------------------------------...
71a3fc0735cd3354a9d1a48ad61796fc1f7a97aa
96d6fca7193f734e46f4a78127bf609b0771bd99
ygtxr1997/DDACapture
/main.cpp
C++
cpp
687
no_license
#include "DDACaptureManager.h" int main() { DDACAPTUREMANAGER Mgr; Mgr.Init(); CAPTURE_SETTING Setting; Setting.FPS = 1000; Setting.IsDisplay = true; // Setting.WinHandle = FindWindow(NULL, "命令提示符"); Setting.WinHandle = FindWindow(NULL, "新标签页 - Google Chrome"); CAPTURE_FRAMEDATA FrameData; M...
49c25a22ac0170d1d0c772288f167fa6c2aca30c
bfa1dd223b3161c68874bbb13358159731b7d75d
libinotify-kqueue/libinotify-kqueue
/tests/update_flags_dir_test.hh
C++
hh
1,637
permissive
/******************************************************************************* Copyright (c) 2011 Dmitry Matveev <me@dmitrymatveev.co.uk> SPDX-License-Identifier: MIT Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Softwar...
8319e67e9c0fd4146ac854bebd2808ab4d9b8066
4f77f222702546face7f35499190ecac0b3e84ca
fceller/arangodb
/lib/Basics/xxhash.cpp
C++
cpp
30,909
permissive
/* xxHash - Fast Hash algorithm Copyright (C) 2012-2016, Yann Collet BSD 2-Clause License (http://www.opensource.org/licenses/bsd-license.php) Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source cod...
1445f3a19c923567ea30f5b887f5a46c4378d0ac
f5af30587828bc53565c596232d27dfe1cd2fc5b
ystk/debian-fluxbox
/src/ClientMenu.cc
C++
cc
5,101
permissive
// ClientMenu.hh // Copyright (c) 2007 Fluxbox Team (fluxgen at fluxbox dot org) // // Permission is hereby granted, free of charge, to any person obtaining a // copy of this software and associated documentation files (the "Software"), // to deal in the Software without restriction, including without limitation // the...
3cd14de035beab0fd2b5888c5cde7c68fe1119eb
2e25f5790df9f04eb94f64d09389eacafe3110d8
tutuca/terminal-overload
/Engine/source/T3D/sfx/sfx3DWorld.cpp
C++
cpp
9,895
permissive
// Copyright information can be found in the file named COPYING // located in the root directory of this distribution. #include "T3D/sfx/sfx3DWorld.h" #include "T3D/portal.h" #include "T3D/shapeBase.h" #include "ts/tsShapeInstance.h" #include "sfx/sfxSystem.h" #include "math/mBox.h" #include "core/module.h" #include "...
243491ef99665cedbb001f1f16130c3fbe56eba0
f8d937ef39f974ad35a3c581b5e5015419369892
S-Shimotori/swift
/lib/Serialization/Serialization.cpp
C++
cpp
182,440
permissive
//===--- Serialization.cpp - Read and write Swift modules -----------------===// // // This source file is part of the Swift.org open source project // // Copyright (c) 2014 - 2018 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift.org/L...
f5aa247e5bd942472d758cd4f46ca8710e84bdf0
fb5209057794617c21fa12bbebb25fb1d9d952a7
recampbell/nt2
/modules/core/arithmetic/include/nt2/toolbox/arithmetic/functions/container/two_prod.hpp
C++
hpp
3,154
permissive
//============================================================================== // Copyright 2003 - 2011 LASMEA UMR 6602 CNRS/Univ. Clermont II // Copyright 2009 - 2011 LRI UMR 8623 CNRS/Univ Paris Sud XI // // Distributed under the Boost Software License, Version 1.0. // Se...
730f39d58d11dff44cf1de6aaa94ef5326bc3762
4732c6552e9ed4c4a2f3a6d66154953092300c14
sherrychenzhang/LDS
/LDS/Structure.cpp
C++
cpp
64,971
no_license
#include "Structure.h" //======GeneralFunction====== void GeneralFunction::show_lint( lint p ) { printf( lint_fmt, p ); } //======DBLPPreProcessor====== int DBLPPreProcessor::get_node_id( const string &name ) { if( map_id.find( name ) != map_id.end() ) return map_id[name]; fprintf( fout_author_id, "%d&%s\n", n_...
3b05ac64ed8ba4ed264079a2b8494968d7e9e9fa
7f14ac0436039a1d8127edeb109c2b10a6d5f8e1
akotadi/ESCOM
/4o Semestre/Análisis de Algoritmos/Ejercicio 02/C.cpp
C++
cpp
3,844
no_license
// Se tomarán en cuenta como operaciones la comparación en arreglo A, asignaciones mayor1 y mayor2 func Producto2Mayores(A,n){ if (A[1] > A[2]) -> 1 (comparación) { mayor1 = A[1]; -> 1 (asignación) mayor2 = A[2]; -> 1 (asignación) } else{ mayor2 = A[1]; -> 1 (asignación) may...
68ef64294c9384bbd9ab4c6c33048fa10db208bd
b10d0cfe71d332ec0baaddca6ace9f0b236d7243
vmmc2/Competitive-Programming
/Tryhardando BST/Problems/Kth Smallest Element in a BST.cpp
C++
cpp
951
no_license
/** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x), left(NULL), right(NULL) {} * }; */ /* Quando estamos falando em Binary Search Tree (BST) e queremos uma travessia de maneira ordenada ou entao buscamos o K-es...
80ab54ae07cb4ad8e6532150271da5537d92ed02
3726051a3aebfcd1e37d5d2069a7ac76506d0f2e
lucaswerthein/BoomFile
/MPENoCrash/MPEFile/src/swingBall.cpp
C++
cpp
781
no_license
#include "swingBall.h" bool swingBall::loadedImage = false; ofImage swingBall::tball; //-------------------------------------------------------------- void swingBall::loadImage(){ if(!loadedImage) { tball.setImageType(OF_IMAGE_COLOR_ALPHA); tball.loadImage("flamengo.png"); cout << "just loaded Flamengo.png" << ...
6a904ba6107aa88f07297aa3c43bb9aabc885fef
f6cdeb7ebb1b6183122a3cb00641ffe612da19fa
vrvitor/Competitive-Programming
/URI/1445.cpp
C++
cpp
695
no_license
#include <cstdio> #include <vector> using namespace std; typedef vector<int> vi; vector<vi> AdjList; vector<bool> visited; void dfs(int u) { visited[u] = true; for (int j = 0; j < AdjList[u].size(); j++) { int v = AdjList[u][j]; if (!visited[v]) dfs(v); } } int main() { int n; while (scanf("%d", &n), n)...
e6275a72bbcf0c281a5066e5e789023a0e0849aa
d71dc711e8bb4082628a4445dde111d1516d3277
VirenS13117/cracking_the_coding_interview
/coding_blocks/Linked_List/reverseList.cpp
C++
cpp
946
no_license
#include<iostream> using namespace std; class node{ public: int data; node* next; node(int value){ data = value; next = NULL; } }; void insert_at_back(node* &head, int value){ if(head==NULL){ node* new_node = new node(value); head = new_node; return; } node* temp = head; while(temp->next!=NULL){ t...
42a4be68cc269506b3473934d5954af1458925c2
1ae84222435e3e0e4f3e3b44ee813fd842c48493
8bitgentleman/ACIKinect
/kinect_test2/src/ofApp.cpp
C++
cpp
6,521
no_license
#include "ofApp.h" //-------------------------------------------------------------- void ofApp::setup(){ camWidth = 320; camHeight = 240; vidGrabber.setVerbose(true); vidGrabber.setDeviceID(0); vidGrabber.setDesiredFrameRate(30); vidGrabber.initGrabber(camWidth, camHeight, OF_PIXELS_BGRA...
a85628710405ef4998dde6f20b354ea7e1934ebe
994a1add9445455e05f56dd4355a78f470301e3b
imnotkind/Graphics
/assn2/HieraModels.cpp
C++
cpp
4,489
no_license
#include "CGraphics.h" void CGraphics::M_SetupHieraModels(void) { auto p = CShaderManager::getInstance(); for (auto k : p->M_GetPolygonList()) { V_BasicPolygons[k.first] = shared_ptr<CSinglePolygon>(new CSinglePolygon(p->M_GetPolygon(k.first), T4Int(255, 255, 255, 255))); } SHierModelNode body; body.colo...
3530c9dc55c932221578b152fc1a904e272d7e8f
ddbc76fce6eac6f35a40c5e6d7115bd753474514
jaso-r/hifi
/libraries/gpu/src/gpu/Batch.cpp
C++
cpp
5,003
permissive
// // Batch.cpp // interface/src/gpu // // Created by Sam Gateau on 10/14/2014. // Copyright 2014 High Fidelity, Inc. // // Distributed under the Apache License, Version 2.0. // See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // #include "Batch.h" #include <QDebug> #define A...
566c07a4242b7fdb643b1e32f7d12e5a55aad315
388c38f118cbac497c2c61ae2bfdb3343b43779d
maxulan/ClickHouse
/dbms/src/Storages/StorageMySQL.cpp
C++
cpp
8,453
permissive
#include "StorageMySQL.h" #if USE_MYSQL #include <Storages/StorageFactory.h> #include <Storages/transformQueryForExternalDatabase.h> #include <Formats/MySQLBlockInputStream.h> #include <Interpreters/evaluateConstantExpression.h> #include <Core/Settings.h> #include <Interpreters/Context.h> #include <DataStreams/IBlock...
1d9adf8cee6eea674d90072e0346a2dc22ec1897
362bebb4acda35303fb306cf583eab23c8e52bfd
rvishna/flow-shop-scheduler
/src/main.cpp
C++
cpp
670
no_license
#include <iostream> #include <spdlog/spdlog.h> #include "Exception.h" #include "ExecutionController.h" using flow_shop_scheduler::Exception; using flow_shop_scheduler::ExecutionController; int main(int argc, char* argv[]) { try { spdlog::set_level(spdlog::level::off); ExecutionController ex...
9e3fec5d4e6251e81cd4e173314d448a540ae594
6b89fae0f05f3a99d38c04edd74a83c52160c50b
roki0713/directx12_samples
/Chapter5/main.cpp
C++
cpp
23,483
permissive
//テクスチャ貼り付け #include<Windows.h> #include<tchar.h> #include<d3d12.h> #include<dxgi1_6.h> #include<DirectXMath.h> #include<vector> #include<d3dcompiler.h> #include<DirectXTex.h> #ifdef _DEBUG #include<iostream> #endif #pragma comment(lib,"DirectXTex.lib") #pragma comment(lib,"d3d12.lib") #pragma comment(lib,"dxgi.lib"...
4a77e2d25dde36c03f36f8bceafba1fb1728742c
49321e7d6d5748ac9c055babfaa73d35a54bab02
rabedik/hifi
/interface/src/ui/overlays/ModelOverlay.cpp
C++
cpp
5,700
permissive
// // ModelOverlay.cpp // // // Created by Clement on 6/30/14. // Copyright 2014 High Fidelity, Inc. // // Distributed under the Apache License, Version 2.0. // See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html // #include "ModelOverlay.h" #include "EntityRig.h" #include "Appli...
f79f0e7d6c0e703d3bb56c3d71a25d713fc07f2b
7148dc976e5f05c41ba96b9dd27445f1531c9a47
twinkarma/Chaste
/lung/src/ventilation/odes/Swan2012AcinarUnit.cpp
C++
cpp
4,627
permissive
/* Copyright (c) 2005-2018, University of Oxford. All rights reserved. University of Oxford means the Chancellor, Masters and Scholars of the University of Oxford, having an administrative office at Wellington Square, Oxford OX1 2JD, UK. This file is part of Chaste. Redistribution and use in source and binary forms...
db60e9a947fee7e4f72b45102424c94d77b54cb6
9c0c46f7123b6e4c5f1d146a5d3f16e988cc3d3f
thngkaiyuan/chromium
/third_party/WebKit/Source/modules/crypto/CryptoKey.cpp
C++
cpp
8,166
permissive
/* * Copyright (C) 2013 Google Inc. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: * * * Redistributions of source code must retain the above copyright * notice, this list of conditio...
795b8be33745e4b584ed0e7f15be2ebd17ac5852
325e3a3b871dbf895df70a2ba15b1779ddb9c8f7
junxuezheng/chromium
/components/spellcheck/renderer/hunspell_engine.cc
C++
cc
4,311
permissive
// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "components/spellcheck/renderer/hunspell_engine.h" #include <stddef.h> #include <algorithm> #include <iterator> #include <utility> #include...
73e11fce40118e18a4c2f8b9c85082a2f9092b41
a849a3149fe52ebee6e23dfb2e2d694a41f46a15
fg12347/smc
/src/support/pagelocker.cpp
C++
cpp
1,889
permissive
// Copyright (c) 2009-2015 The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include "support/pagelocker.h" #if defined(HAVE_CONFIG_H) #include "config/smc-config.h" #endif #ifdef WIN32 #ifdef _WIN32...
4aceca959a9aa7037fca920c38f70a3b2a5de7ed
2f6b90cad15fa978f34d9340af39e4a6f5d99bc1
BusHero/robotino_api2
/api2/lib/rec/rpc/serialization/rec_rpc_serialization_Pose2D.cpp
C++
cpp
1,947
no_license
/* Copyright (c) 2011, REC Robotics Equipment Corporation GmbH, Planegg, Germany All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - Redistributions of source code must retain the above copyright notice, ...
cca5cc9483ed4ab44f613b861ecf83416aa5a90d
ed3ab7dd7f2ff0fdf705fc22dba785272aaca70a
omarsaidkamel/Problem-Solving
/I - Almost Prime Numbers/main.cpp
C++
cpp
776
no_license
#include <bits/stdc++.h> #define ll long long using namespace std; long long p[100000],x,h,a[1000009]; void isprimes(ll n){ for(ll i = 2 ; i <= n ; i++){ bool b = 1; for(ll j = 2 ; j * j <= n ; j++){ if( i % j == 0 && i != j) b = 0; } if(b){p[x++] = i;} ...
f42e653b72e09070784ef6e298c67debb9001354
83e6fce3749c7cf761fc83b79b9ae78b60246064
Kartonagnick/tools-match
/include/tools/match/regex.hpp
C++
hpp
4,619
permissive
// [2021y-02m-05d] Idrisov Denis R. #pragma once #ifndef dTOOLS_MATCH_REGEX_USED_ #define dTOOLS_MATCH_REGEX_USED_ 100 #include <cassert> #include <string> #include <regex> //============================================================================== //=== declaration ===========================================...
599e3c1a51b4f42147bb7a98e1a2e1e8326a6c3c
f087eafacb2a52f17613c7417639c8d26501e407
tomjiang1987/phonemefeaturedevices
/VirtualMachine/phoneme_feature/jsr211/src/share/core/native/symbian/jsr211_registry_impl.cpp
C++
cpp
20,148
no_license
/* * Copyright 1990-2008 Sun Microsystems, Inc. All Rights Reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License version * 2 only, as published by the Free Sof...
99a9651b6d27ab2758ce8a5c3a7ced7be313b046
00cc2c7f4512e2278d638e2627d418c78abf0a46
average1129/Aditya-266993-
/C++/Workbook2/src/array.cpp
C++
cpp
919
no_license
#include <iostream> #include "/home/adi/LTTS/C++/Workbook2/include/array.h" using namespace std; template<typename T> MyArray<T>::MyArray(): m_arr(NULL),m_len(0){ } template<typename T> MyArray<T>::MyArray(int len): m_len(len){ } template<typename T> MyArray<T>::~MyArray(){} template<typename T> void MyArr...
53090c6c99e22733a77a1407a1b9aac2613b6372
fe4eec2c51f2346317ffa7ee7b5afc91d3acf1c3
FrieAT/cg2019-game
/src/Components/Drawing/Texture/SteveAbstractTexture/SteveArm/SteveArmTexture.cpp
C++
cpp
1,331
no_license
// // SteveArmTexture.cpp // 2019_cg_physics // // Created by Friedrich Schmidt on 11.06.19. // Copyright © 2019 Universität Salzburg. All rights reserved. // #include "SteveArmTexture.hpp" SteveArmTexture::SteveArmTexture() { _points = { // bottom 0.8125f, 0.6875f, 0.75f, 0.6875f, ...
08ac4edf9e0bd95e8f937986d72e3204bd3e2758
7533f43eee65bd7cd097605b11fbadd019466ad5
skepley/DSGRN
/src/DSGRN/_dsgrn/include/Parameter/Network.hpp
C++
hpp
12,305
permissive
/// Network.hpp /// Shaun Harker /// 2015-05-22 #pragma once #ifndef INLINE_IF_HEADER_ONLY #define INLINE_IF_HEADER_ONLY #endif #include "Network.h" INLINE_IF_HEADER_ONLY Network:: Network ( void ) { data_ . reset ( new Network_ ); } INLINE_IF_HEADER_ONLY Network:: Network ( std::string const& s ) { assign(s)...
0b54bc701a98755088d52506b69ca02749365210
13b854ce586e8b64d29245e41372e070e39ce6bd
Jiyoung-h/algorithm
/programmers/두 정수 사이의 합.cpp
C++
cpp
302
no_license
#include <string> #include <vector> using namespace std; long long solution(int a, int b) { long long answer = 0; if(a > b){ int tmp = a; a = b; b = tmp; } else if (a == b) return a; for(int i=a; i<=b; i++){ answer += i; } return answer; }
8a4d5876399d963b2a51eef2cfafacfaecb135db
b2212ab685046cf57e763f7e9880c10a1e0859ab
RGPaul/rest-server-cpp
/src/UriNode.cpp
C++
cpp
6,386
permissive
/* ----------------------------------------------------------------------------------------------------------------------- The MIT License (MIT) Copyright (c) 2020 Ralph-Gordon Paul. All rights reserved. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated ...
6ab0fc6fd48cb337151577587deee52c8f0427e4
a175bb3d87ad21e30da066c69e17dff1e776d8e6
ISSuh/chromium
/chrome/browser/installable/installable_manager_browsertest.cc
C++
cc
74,662
permissive
// Copyright 2016 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "chrome/browser/installable/installable_manager.h" #include <tuple> #include "base/bind.h" #include "base/command_line.h" #include "base/option...
519814da2e6ebbc899198a3b018d24607265e077
44f6e518be14decddd36b93e8b785e0149d59325
jlillest/dewalls
/test/lengthparsingtests.cpp
C++
cpp
1,472
permissive
#include "../lib/catch.hpp" #include "../src/wallsparser.h" using namespace dewalls; typedef UnitizedDouble<Length> ULength; TEST_CASE( "length parsing tests" , "[dewalls, length]" ) { SECTION( "defaultUnit works") { CHECK( WallsParser("2.5").length(Length::m()) == ULength(2.5, Length::m()) ); ...
bd184bddaab1964eb457a29426770082e4efaa07
e16ebc5bcdbb50265bdf16df535e96cdbc3ea297
Svetoslavna/Project-DataBase
/project/DataFileReaderApp.cpp
C++
cpp
3,459
permissive
#include <iostream> #include <fstream> #include <sstream> #include <list> #include "FileLine.h" using namespace std; int getUserInput(); void displayDbs(); void addDbLine(string dbName, int amountOfColumns); list<FileLine> fileLines; //путь к файлу(вида C:\\Users\\user\\) если нет, то файл создается ...
a3d1b7d8739d568499cb02242b21d71cb43e742a
ceee435e0f02af0cf824beab0ae865f8c23bdc32
xpalie42/FIT-Projects
/PDS/chooser.cpp
C++
cpp
1,796
permissive
#include "XMLParser.h" #include <fstream> #include <unistd.h> #include <iostream> #include <string> #include <unordered_map> using namespace std; void printTable(ScanTable &table); unordered_map<uint16_t, string> indexs; int main(int argc, char *argv[]) { int c; string in_file, out_file; while ((c = getopt (argc, ...
19175c2d9c57d658f86f3caf9d27e880c0a999d0
137cf68d59a206ffbf919e4bec275f6ed767dd42
ajphukan/hhvm
/hphp/runtime/ext/curl/ext_curl.cpp
C++
cpp
33,095
permissive
/* +----------------------------------------------------------------------+ | HipHop for PHP | +----------------------------------------------------------------------+ | Copyright (c) 2010-2015 Facebook, Inc. (http://www.facebook.com) | | Copyrigh...
5ca2fc292830a55e082c1e0fe4186d3fd13d48d8
d767246de29e9825b0bfe613d525bb405e6d4349
itsamit/MGMIN
/Source_code/main.cpp
C++
cpp
933
no_license
#include <iostream> #include <vector> #include <string> #include "functions.h" #include "matrix.h" using namespace std; ///////////////////////////////////////////////////// // Main part of this program // For step 1, call met_microbe_coupling // For step 2, call node_node_ABC // For step 3, call printWs ...
3af2f62a6986ef10330e3a46ca78341ee0ec4bd6
065265420a1cd2e46f0a43e754f04c92f78afe4f
lainproliant/Timer
/TimerTest.cpp
C++
cpp
505
no_license
#include <cstdio> #include <iostream> #include <time.h> #include "KernelTimer.hpp" int main (int argc, char* argv[]) { KernelTimer timer; timer.start (KernelTimer::SECOND / 10); while (timer.getFrames () < 30) { if (timer.update ()) { printf ("Frames: %llu, Usec: %llu\n", timer.getFrames (...
fda5ffbee2b2e2261199d621a8c9507f3bace714
80b6293b5e545d0d9b1ac5ba4dc89d8d7ad9edab
RafikFarhad/Code_is_fun
/UVA/10496 - Collecting Beepers.cpp
C++
cpp
3,881
no_license
#include <cstdio> #include <iostream> #include <string> #include <cstring> #include <cmath> #include <ctime> #include <cstdlib> #include <algorithm> #include <new> #include <vector> #include <stack> #include <queue> #include <map> #include <set> #include <iterator> /***********************/ /** Rafik Fa...
564fb315411bde9d9a1865a51f93c9d08f975c04
2d6200fe722d67a29a547389eea73dab8eb2e3e2
KernelPanic-OpenSource/Win2K3_NT_ds
/security/cryptoapi/pkitrust/tools/updcrl/updcrl.cpp
C++
cpp
13,930
no_license
//+------------------------------------------------------------------------- // // Microsoft Windows // // Copyright (C) Microsoft Corporation, 1995 - 1996 // // File: updcrl.cpp // // Contents: Updates CRL in the "CA" store. // // See Usage() for list of options. // // // Functions: main // ...
b968331e8004fe5aecf6a71f8f2d353e9ff191ca
a6141c81b5f1d1014358a7bbde28f5a08d67ffd4
RussellJerome/DeepRockGalacticSDK
/SDK/FSD_WPN_Autocannon_classes.hpp
C++
hpp
3,826
no_license
#pragma once // DeepRockGalactic SDK #ifdef _MSC_VER #pragma pack(push, 0x8) #endif #include "FSD_WPN_Autocannon_structs.hpp" namespace SDK { //--------------------------------------------------------------------------- //Classes //--------------------------------------------------------------------------- // Blu...
21f3685ceec0097da3b5051804cbef51b8955a51
fb7d3e6ad3fa95349c9b6da6355244c3bddc22e2
tasneemria/Codeforces_Solved
/Vitaly and Night.cpp
C++
cpp
401
no_license
#include<bits/stdc++.h> using namespace std; int main() { freopen ("input.txt","r",stdin); freopen ("output.txt","w",stdout); int cnt=0; int n,m; cin>>n>>m; for(int i=0;i<n;i++) { for(int j=0;j<m;j++) { int a,b; cin>>a>>b; if(a==1 || b==...
377f8277252d7589fe26629eb2feffb3c1535058
479a395dc878b6443a8d35a5f9f24de7ef6996c7
rajashekar007/jops
/tll2372.cpp
C++
cpp
532
no_license
#include <bits/stdc++.h> using namespace std; int main() { int n,i,val1,val2; scanf("%d",&n); priority_queue<int,vector<int>,greater<int> > h; for(i=0;i<n;i++) h.push(0); char s[100009]={}; scanf("%s",s); for(i=0;i<strlen(s);i++) { if(s[i]=='1') { val1=h.top();h.pop(); val1++; h.push(val1); } ...
6266199564bcafd359707b9b59a5291df0dd4d6b
b6fd287afe6293062cf00735d28e7174ccf5ead9
neozhangthe1/Nakloid
/score/Note.cpp
C++
cpp
9,592
permissive
#include "Note.h" using namespace std; struct Note::Parameters Note::params; Note::Note(Score *score, long id) :score(score), id(id), self(){} Note::Note(Score *score, long id, long ms_start, unsigned char base_pitch, short base_velocity) :score(score),id(id),self() { this->setStart(ms_start); this->setBas...
553b936b0d85e89f96f72c0a055c466141197f5a
72ede535ace67c712b0dc8015c97dff2beeeff7b
Aardvajk/OPx
/Pc/transform/ExprTransform.cpp
C++
cpp
8,100
no_license
#include "ExprTransform.h" #include "application/Context.h" #include "nodes/IdNode.h" #include "nodes/FuncNode.h" #include "nodes/LiteralNodes.h" #include "nodes/CallNode.h" #include "nodes/ProxyCallNode.h" #include "nodes/ConstructNode.h" #include "nodes/AddrOfNode.h" #include "nodes/DerefNode.h" #include "nodes/Ass...
d75b4da8643722f70f0b99541bbe0732ab1ae01b
399bf68149c8b14364e49cea6d44c403da48ed1a
zhenyatnk/baseex
/core/src/apple/CSystemInfo.cpp
C++
cpp
3,011
no_license
#include <baseex/core/ISystemInfo.hpp> #ifdef __APPLE__ #include <mach/mach_init.h> #include <mach/mach_error.h> #include <mach/mach_host.h> #include <mach/vm_map.h> namespace baseex { namespace core { //----------------------------------------- class CGetterUsageCPU :public IUsageCPU { public: CGetterUsageC...
5e9374cde14ede29a4f26e51c0cf967382acc630
ebcfc54f9f4f23376bb3cff383a6ab168078d27c
Rockroyal305/Practice-Problems
/Painting.cpp
C++
cpp
537
no_license
#include <iostream> #include <fstream> using namespace std; int main() { ifstream fin("paint.in"); ofstream fout("paint.out"); int a, b, c, d; fin >> a >> b >> c >> d; //cin >> a >> b >> c >> d; fin.close(); int amountPainted = 0; for(int i = 0; i < 100; i++) { ...
aed09c9970abde9d7cca7dc8bfef6bd3dbf3410d
461701e208cf5283ead25fc97052eb381556bc85
cookpa/ITK
/Modules/Core/Common/test/itkZeroFluxBoundaryConditionTest.cxx
C++
cxx
8,466
permissive
/*========================================================================= * * Copyright NumFOCUS * * 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 * * https://www.apache.o...
5756a617d8bd7ddc765b91f8be4cdef0a1224770
ea483a960246db2d3ca90b599319b5fa547e9d60
Azi-824/SpaceShooting
/SpaceShooting/Bullet.hpp
C++
hpp
972
no_license
//Bullet.hpp //弾を管理するクラス #pragma once //################# ヘッダファイル読み込み ################# #include "Global.hpp" #include "Animation.hpp" //################## マクロ定義 #################### #define BULLET_SPEED 5 //弾の速度 //################## クラス定義 #################### class Bullet { private: Animation* anim; //弾のアニメーション...
d5d9dcf0a17f7059b7f56be902de9e74a5c81c81
1a1e8375eb898f4bbff6150ddd21d5d54d632b2a
AddmoreMining2020/Addmore
/src/test/timedata_tests.cpp
C++
cpp
1,019
permissive
// Copyright (c) 2011-2015 The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. // #include "timedata.h" #include "test/test_addmore.h" #include <boost/test/unit_test.hpp> using namespace std; BOOST_FIXT...
981d118011dbbd9b1dbeca569134b0a93e00578e
967072045278f1ef815e8d72f8ecb1fffef86776
Kawser-nerd/CLCDSA
/Source Codes/AtCoder/abc054/B/4315511.cpp
C++
cpp
675
no_license
#include <iostream> using namespace std; #include <string> #include <algorithm> int a[10001]; bool com(int a,int b) { return a>b; } int main() { int n,m; cin>>n>>m; char s1[n][n+1]; char s2[m][m+1]; for(int i=0;i<n;i++) { cin>>s1[i]; } for(int i=0;i<m;i++) { cin>>s2[i]; } int flag; for(int i=0;i<n;i++)...
c24d95d953c7f252777f8ff632fc2b7d2808ecee
c4210b458983c76b32398fb662396a2f612a9c5b
hanwen/artisjokke
/visualize/opengl.hh
C++
hh
258
permissive
#ifdef OPENGL #ifndef OPENGL_HH #define OPENGL_HH /* Windows include MUST be before GL includes, otherwise the compiler generates the wrong calling convention (sigh) */ #if defined(_WIN32) #include <windows.h> #endif #include "GL/glut.h" #endif #endif
4f2aff55cc15bd84f9000af93a44fa0f18af88e6
10b9de76b0f87e807280bf8ff460acc22817e442
EnjoyHacking/ChromiumGStreamerBackend
/net/socket/socks5_client_socket.cc
C++
cc
15,980
permissive
// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "net/socket/socks5_client_socket.h" #include "base/callback_helpers.h" #include "base/compiler_specific.h" #include "base/format_macros.h" #...
3cd7fbcada5e7cf2071e759e08dbe4b5f1e26052
b11835c1bd4aed396a5ff5cff2fd1b59f71d2d9e
ddcc/llvm-project
/llvm/unittests/CodeGen/GlobalISel/ConstantFoldingTest.cpp
C++
cpp
9,921
permissive
//===- ConstantFoldingTest.cpp -------------------------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------...
28f993a643aaceb2994394f15b9962e5d9bc52db
0488e9af9a1a5db5ceca1c280e5ad26f9cf249e1
ybdesire/CppPractice
/stl/set/main.cpp
C++
cpp
315
no_license
#include <iostream> #include <set> using namespace std; int main(int argc, char** argv) { set<int> s; s.insert(10); s.insert(20); s.insert(10); s.insert(10); s.insert(30); set<int>::iterator iter; for(iter=s.begin();iter!=s.end();iter++) { cout<<*iter<<endl; } return 0; }
dfd5bfc7142a95f9c9723d7a33be74e80f7ee994
bd4f18f2725476197eea12537c14fd5c5db119d0
FaqiangZhu-nxp/openthread
/src/core/net/dns_client.cpp
C++
cpp
33,752
permissive
/* * Copyright (c) 2017-2021, The OpenThread Authors. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * 1. Redistributions of source code must retain the above copyright * notice, ...
e52915fe15e61d2583eb90153294211f1ed7d2d0
ad94ec55172b44220c6d0cb6accbc91fcba7b601
beldenfox/LLGL
/sources/Renderer/OpenGL/RenderState/GLFence.cpp
C++
cpp
1,665
permissive
/* * GLFence.cpp * * This file is part of the "LLGL" project (Copyright (c) 2015-2019 by Lukas Hermanns) * See "LICENSE.txt" for license information. */ #include "GLFence.h" #include "../GLObjectUtils.h" #include "../Ext/GLExtensions.h" #include "../Ext/GLExtensionRegistry.h" namespace LLGL { GLFence::~GLFen...
88410b545d7d8452a6d0ba77784e03d47e982125
a61f66c526b6e8bc27c8873db34da905945ed994
w2-blockchain-tec/steem
/libraries/protocol/steem_operations.cpp
C++
cpp
19,825
permissive
#include <steemit/protocol/steem_operations.hpp> #include <fc/io/json.hpp> #include <locale> namespace steemit { namespace protocol { /// TODO: after the hardfork, we can rename this method validate_permlink because it is strictily less restrictive than before /// Issue #56 contains the justificiation for all...
d42bafe476d77e0bac431ea2093ff53536877729
531cd751a393efd803ebbe0c295b803287e0316f
Mutiyu/YML
/第8周实验课实验/八MFC一1/八MFC一1/八MFC一1View.cpp
C++
cpp
3,081
no_license
// 八MFC一1View.cpp : C八MFC一1View 类的实现 // #include "stdafx.h" // SHARED_HANDLERS 可以在实现预览、缩略图和搜索筛选器句柄的 // ATL 项目中进行定义,并允许与该项目共享文档代码。 #ifndef SHARED_HANDLERS #include "八MFC一1.h" #endif #include "八MFC一1Doc.h" #include "八MFC一1View.h" #ifdef _DEBUG #define new DEBUG_NEW #endif // C八MFC一1View IMPLEMENT_DYNCREATE(C八MFC一1...
e11b45665f97b783278f3c1d6d39684398e83671
0b518de537f1facacfab29e7280ae69faa052098
markplagge/NeMo2
/test/test_spike_file.cpp
C++
cpp
1,403
permissive
// // Created by Mark Plagge on 6/23/20. // #include "../src/nemo/nemo_io/SpikeFile.h" #include "./catch/catch.hpp" #include "test_utils.h" #include <algorithm> #include <fstream> #include <iomanip> #include <iostream> #include <sstream> #include <string> std::string demo_spike_file("/Users/plaggm/dev/nemo-codes/conf...
6f48ccee783e07dd42728f68a72610b95947a8c6
83b81fbe8fbc2b200c45c4eb2523af829ac0765d
fredlim/GameEngine
/Tools/MaterialBuilder/EntryPoint.cpp
C++
cpp
642
no_license
/** **************************************************************************************************** * \file EntryPoint.cpp * \brief Main procedure for MaterialBuilder project * * \date 1 February 2013 * \author Sherly Yunita \n * Created \n * \n\n ************************************************...
9e8040e2dbd2cfa3b4c65d47ba1aaefdfc07ad0a
41b68ee0a1b8e7fca1a25a674a64fa81b8873e2d
MarcoSpano/RTES-trackingCar
/src/detection.cpp
C++
cpp
5,947
no_license
#include "../lib/car_traker.h" using namespace cv; using namespace std; //------------------------------------------------------------------------------ // This file contains all the functions related to the detection // part of the a frame, to find the target object and its position //---------------------...
48184a368e9037f3fcd43cad4431309ef76cde34
131561bb4bdee75518d9940874a160c34dedfe4e
eaglexmw-gmail/WTLBuilder
/SDK/Event/EventLib.cpp
C++
cpp
18,882
permissive
// Copyright (C) FlatGlobus(wtlbuilder@gmail.com) All rights reserved. // // This file is a part of the WTLBuilder. // The use and distribution terms for this software are covered by the // Microsoft Public License (http://opensource.org/licenses/MS-PL) // which can be found in the file MS-PL.txt at the root folder. #...
8b828987dc5179098d0e4762d18f2ca365bf5f14
8c017b794c0ef68c59bed9f0ed63b94a6f18ad62
yinchengtsinghua/EOSIOChineseCPP
/plugins/net_plugin/include/eosio/net_plugin/protocol.hpp
C++
hpp
8,532
permissive
//此源码被清华学神尹成大魔王专业翻译分析并修改 //尹成QQ77025077 //尹成微信18510341407 //尹成所在QQ群721929980 //尹成邮箱 yinc13@mails.tsinghua.edu.cn //尹成毕业于清华大学,微软区块链领域全球最有价值专家 //https://mvp.microsoft.com/zh-cn/PublicProfile/4033620 /* *@文件 *@eos/license中定义的版权 **/ #pragma once #include <eosio/chain/block.hpp> #include <eosio/chain/types.hpp> #includ...
e8590a07d85ffec3777d0ca7616910672f064e91
fef708e1c154208b88fbf8a9b9a4a362d20c6c29
LiliVeszeli/Graphics
/ShadowMapping/Scene.cpp
C++
cpp
30,657
no_license
//-------------------------------------------------------------------------------------- // Scene geometry and layout preparation // Scene rendering & update //-------------------------------------------------------------------------------------- #include "Scene.h" #include "Mesh.h" #include "Model.h" #include "Camera...
dae57b6d2078cb74f500c322ab52c7990793353b
462c30c6e482f44ca7796dcad006c3301e7fdd5c
prathyusha-shine/abhiyan1.0
/build/rviz-hydro-devel/src/rviz/default_plugin/moc_point_cloud_transformers.cxx
C++
cxx
13,016
no_license
/**************************************************************************** ** Meta object code from reading C++ file 'point_cloud_transformers.h' ** ** Created: Tue May 12 17:16:41 2015 ** by: The Qt Meta Object Compiler version 63 (Qt 4.8.1) ** ** WARNING! All changes made in this file will be lost! **********...
2021cffd1570ce2deedf2d54831db1938bfd487f
e6e30ffd8f5ac2cba5003def14e95a84500c5fca
josermarinr/Play--CodeGen
/tests/LogicTest.cpp
C++
cpp
1,491
permissive
#include "LogicTest.h" #include "MemStream.h" CLogicTest::CLogicTest(uint32 value1, bool constant1, uint32 value2, bool constant2) : m_value1(value1) , m_constant1(constant1) , m_value2(value2) , m_constant2(constant2) { } void CLogicTest::Run() { memset(&m_context, 0, sizeof(m_context)); m_context.op1 = m_value1...
5b549964f4ff6109c7e653955dc0c26497a6dc81
fc48e409d2494bc0d68ecc5825b750ac49b686f2
f-fathurrahman/KuliahCpp
/Modul_03/pass_by_ref.cpp
C++
cpp
468
no_license
#include <iostream> using namespace std; void func1(int a, int b); void func2(int& a, int& b); int main() { int a = 1, b = 3; cout << "a = " << a << endl; cout << "b = " << b << endl; func1(a, b); cout << "a = " << a << endl; cout << "b = " << b << endl; func2(a, b); cout << "a = " << a << endl; ...
2e9259ac7c2b8befd193bbb255cc7ed2f296d35a
3d71a578deeaf090ee4ecc19a8f5f4782e66db64
ClaireLC/drake
/geometry/query_object.cc
C++
cc
6,739
permissive
#include "drake/geometry/query_object.h" #include "drake/common/default_scalars.h" #include "drake/common/drake_assert.h" #include "drake/geometry/scene_graph.h" namespace drake { namespace geometry { using math::RigidTransform; using math::RigidTransformd; using render::ColorRenderCamera; using render::DepthRenderC...
4e89b997aa65436ab4bd2bf8a595b07af3e2cb2e
1d9f86094c0e6a5ced8d8320c9763614789af059
svn2github/OpenMPT
/trunk/OpenMPT/mptrack/View_smp.cpp
C++
cpp
103,830
permissive
/* * view_smp.cpp * ------------ * Purpose: Sample tab, lower panel. * Notes : (currently none) * Authors: Olivier Lapicque * OpenMPT Devs * The OpenMPT source code is released under the BSD license. Read LICENSE for more details. */ #include "stdafx.h" #include "Mptrack.h" #include "Mainfrm.h" #inc...
bd2d31ddf5daa0a827a5f3771451aed47d000620
d2f0b222b6252f3965551c7805358c14849279ff
wsj2681/Anger_Control_Disoder
/함범호/Lab1/LabProject/BoxerObjectsShader.cpp
C++
cpp
1,742
no_license
#include "stdafx.h" #include "BoxerObjectsShader.h" #include "Object.h" #include "ModelInfo.h" #include "AnimationController.h" #include "AnimationSet.h" #include "AnimationTrack.h" #include "BoxerObject.h" BoxerObjectsShader::BoxerObjectsShader() { } BoxerObjectsShader::~BoxerObjectsShader() { } void BoxerObjectsS...
1a0795a978e37453057b95b597b680db91704340
82ac5cd38dc7a6241f84a179e105009dd25bc772
javpicorel/memory_tool
/components/PrefetchBuffer/PrefetchBufferImpl.cpp
C++
cpp
33,389
no_license
// DO-NOT-REMOVE begin-copyright-block // // Redistributions of any form whatsoever must retain and/or include the // following acknowledgment, notices and disclaimer: // // Thi...
9dc1beb5e9cdc68d9638139f81eded7adf2ecb04
176d0a608446ad816194003e6ed076a5a0ea9d54
StHamish/various-algorithms
/algorithms/bit-manipulation/less-significant-bit/main.cpp
C++
cpp
1,156
permissive
#include "gtest/gtest.h" #include <rapidcheck/gtest.h> #include SPECIFIC_HEADER // Running tests TEST(TEST_NAME, Zero) { ASSERT_EQ(0, less_significant(0)); } TEST(TEST_NAME, PowerOfTwo) { ASSERT_EQ(128, less_significant(128)); } TEST(TEST_NAME, Nine) { ASSERT_EQ(1, less_significant(9)); } RC_GTEST_PROP(TEST...
9105753ef663f8e22b0d61ba6f35bfba71f4b228
b4c12cfc0706ad0f051498765ce22367b0f0353a
sdecoder/algorithm
/CountUnivalueSubtrees.cc
C++
cc
1,259
no_license
#include <stdio.h> #include <stdlib.h> #include <memory.h> #include <sstream> #include <iostream> #include <stack> #include <vector> #include <iterator> #include <numeric> #include <set> #include <map> #include <unordered_map> #include <unordered_set> using namespace std; /* Given a binary tree, count the number of ...
b6a2496a98084795ec8c7f0049cd034234d05f46
939ed19e5889adb4f31d2d945513335b8ff9e476
zH4x-SDK/zARKSotF-SDK
/SDK/PrimalItemArmor_GigantSaddle_functions.cpp
C++
cpp
1,086
no_license
#include "../SDK.h" // Name: ARKSotF, Version: 178.8.0 #ifdef _MSC_VER #pragma pack(push, 0x8) #endif namespace SDK { //--------------------------------------------------------------------------- // Functions //--------------------------------------------------------------------------- // Function PrimalItemArmor...
835171db3fee1f48a1595c4905faab5dec2ef22d
71f507cffd4a59344c59d37db4ede267a00044eb
dmlys/netlib
/include/ext/net/bsdsock_streambuf.hpp
C++
hpp
29,208
permissive
#pragma once // author: Dmitry Lysachenko // date: Saturday 20 april 2016 // license: boost software license // http://www.boost.org/LICENSE_1_0.txt #include <cstdint> #include <memory> #include <atomic> #include <utility> #include <string> #include <chrono> #include <system_error> #include <ext/openssl.hpp...
60897d3e5487efd14bbc2a8a7a26805d838aab4e
4926c1bb36d7c674436e312a86cbee9622ec40f4
wy91092/code
/0424_MyComplex_MyVector/testexplicit.cpp
C++
cpp
433
no_license
/************************************************************************* > File Name: testexplicit.cpp > Author: Comst > Mail:750145240@qq.com > Created Time: Thu 24 Apr 2014 05:48:10 PM CST ************************************************************************/ #include<iostream> #include "MyComplex.h" usin...
be202865f310bbc6978c4f156dbace564d174a2d
13a79811aa2894c93dcfe5f698342b4ee99e0563
claremacrae/Clara
/include/clara.hpp
C++
hpp
31,243
permissive
// v1.0-develop.2 // See https://github.com/philsquared/Clara #ifndef CLARA_HPP_INCLUDED #define CLARA_HPP_INCLUDED #ifndef CLARA_CONFIG_CONSOLE_WIDTH #define CLARA_CONFIG_CONSOLE_WIDTH 80 #endif #ifndef CLARA_TEXTFLOW_CONFIG_CONSOLE_WIDTH #define CLARA_TEXTFLOW_CONFIG_CONSOLE_WIDTH CLARA_CONFIG_CONSOLE_WIDTH #endif...
1092a8525b1e1b97ecee098c52c37ebef32ccb6a
dbc352ce0719ebf1f06e245e3224fbf9593f26e4
piklock/qynocoin
/src/qt/paymentserver.cpp
C++
cpp
25,011
permissive
// Copyright (c) 2011-2014 The Bitcoin developers // Copyright (c) 2014-2015 The Dash developers // Copyright (c) 2015-2017 The PIVX developers // Copyright (c) 2017-2018 The Qyno Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mi...
f57c3c4b896f65ff35d3c766b4257307a91a0b88
d032823910c3a2a0f607558299492177f8d6ad8b
MadCreeper/_Beep_
/NOIP Code(c++)/road.cpp
C++
cpp
916
no_license
#include<bits/stdc++.h> #define maxn 10010 using namespace std; int n,m; int bg,ed; vector<int> g[2][maxn]; bool vis[maxn]={0}; int tag[maxn]={0}; int dfs(int s,int e) { vis[s]=1; for(int i=0;i<g[1][s].size();i++) { if(vis[g[1][i]]) continue; dfs(i,e); } } struct node { int v,step; ...
ac6841643bc2a41932feeb1188947d691113351c
fcce1a37a5df5aaa22e3cbb1a373e23b36cdb803
stryku/icyus
/sources/inc/internals/input/IInputHandler.hpp
C++
hpp
452
no_license
#pragma once #include <string> namespace Icyus { namespace Input { class IInputHandler abstract { public: ~IInputHandler() = default; virtual void chooseFile() = 0; virtual void send() = 0; virtual void connect() = 0; virtual...
3e57743ffcaec058e9578043648f50a1242b6938
ee993954c7945bc864aeb930e69cfdec0f0cf478
imran1995/tiktok
/bfs.cpp
C++
cpp
893
no_license
#include<bits/stdc++.h> using namespace std; int t,st,n,m; #define mx 1010 vector<int>g[mx]; int d[mx]; void bfs(int s) { d[s]=0; queue<int>q; q.push(s); while(!q.empty()) { int u=q.front(); q.pop(); for(int i=0;i<g[u].size();i++){ int v=g[u][i]; ...
c4de7c60f20377fff9d67292f1c7ddc7a2925b82
f7d1f1d28daa7babfcb2ca5fd222c8908999e4b2
Anish-Saxena/aqua_rowhammer_mitigation
/gem5/src/mem/cache/replacement_policies/lru_rp.cc
C++
cc
3,259
permissive
/** * Copyright (c) 2018 Inria * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: redistributions of source code must retain the above copyright * notice, this list of conditions and the fol...
f3a0d4b8f6037d7907d92c2db3fdce81bcc5c9a0
c5d716642301ccf70c22994db3bc0f6db3af9947
zenoalbisser/chromium
/third_party/skia/gm/filterindiabox.cpp
C++
cpp
3,582
permissive
/* * Copyright 2011 Google Inc. * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #include "gm.h" #include "Resources.h" #include "SkBitmapProcState.h" #include "SkBitmapScaler.h" #include "SkGradientShader.h" #include "SkImageDecoder.h" #include "SkImageE...
2a523fc23962bdda7b09817d1c7f171a42a6dba5
751a4b06ac17373762e4926b5e114b7247e7c7ef
Drasky-Vanderhoff/emojicode
/Compiler/Generation/ReificationContext.hpp
C++
hpp
890
permissive
// // Created by Theo Weidmann on 25.12.17. // #ifndef EMOJICODE_REIFICATIONCONTEXT_HPP #define EMOJICODE_REIFICATIONCONTEXT_HPP #include "Types/Generic.hpp" #include "Types/Type.hpp" #include <map> namespace EmojicodeCompiler { class ReificationContext { public: template <typename T, typename E> explicit R...
62c9d4e8dffbce469cce8143cebd1c6205de824a
408b6fe3d672b792c3e3aef5fcb12028bd12c989
ORNL-CEES/kokkos
/core/unit_test/UnitTestMainInit.cpp
C++
cpp
2,223
permissive
/* //@HEADER // ************************************************************************ // // Kokkos v. 2.0 // Copyright (2014) Sandia Corporation // // Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation, // the U.S. Government retains certain rights in this softw...