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
5badce4e4acc51e192e321503bc690f474f88da3
2665c7424debf7030ffc87ba18401e99cc6bcc1d
green-fox-academy/moharos89
/week-01/day-3/tasks2/main.cpp
C++
cpp
858
no_license
#include <iostream> int main(int argc, char const *argv[]) { std::cout << "Hello, World!" << std::endl; std::string myname = "Bence Moharos"; int myage = 29; float myheight = 1.71; std::cout << myname << std::endl << myage << std::endl << myheight << std::endl << std::endl; int a = 22; i...
7ce13e97d5dfb7ed4a328460e8c79e021d1ba037
fcad99c0c0a28540de72801982d12688a51bef73
vdt/selenium
/webdriver/branches/iphone/jobbie/src/cpp/InternetExplorerDriver/org_openqa_selenium_ie_InternetExplorerDriver.cpp
C++
cpp
11,400
permissive
/* Copyright 2007-2009 WebDriver committers Copyright 2007-2009 Google Inc. Portions copyright 2007 ThoughtWorks, Inc 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...
0047cb58cd42d23df80fc78ab5b7847990cd884a
94c430651124a4ea63ff223194c595fa6aa5e3d1
liwc/LeetCode
/CPP/15_threeSum/15_threeSum.cpp
C++
cpp
1,610
no_license
// 15_threeSum.cpp : 定义控制台应用程序的入口点。 // #include "stdafx.h" #include <iostream> #include <vector> #include <set> #include <map> using namespace std; vector<vector<int>> threeSum(vector<int>& nums) { vector<vector<int>> triplets; vector<set<int>> filters; unsigned int i = 0, j = 0, k = 0, r = 0; f...
dc4d7fb8b2e80ba751ccb087fd105ba10a2f1639
4048258a6d22f3f44a3423f18ec09b2359b38384
daisy20170101/SeisSol
/src/Solver/Interoperability.cpp
C++
cpp
51,183
permissive
/** * @file * This file is part of SeisSol. * * @author Alex Breuer (breuer AT mytum.de, http://www5.in.tum.de/wiki/index.php/Dipl.-Math._Alexander_Breuer) * @author Sebastian Rettenberger (sebastian.rettenberger @ tum.de, http://www5.in.tum.de/wiki/index.php/Sebastian_Rettenberger) * @author Sebastian Wolf (wolf...
ca0156f060e9cb28a46516f3f02358abed9b8afc
dc2f47ee5b60a4ff7f33f1ce9407ca17e680f0e6
FahimSifnatul/oop_with_Fahim
/scope resolution.cpp
C++
cpp
599
no_license
/*bismillahir rahmanir rahim */ #include<bits/stdc++.h> using namespace std; double highcg = 4.00; int main() { double highcg=1.00; /*i will print the value of highcg...what do you think??? kon highcg ta print hobe bol to??? hmm highcg = 1.00 er kotha bolsis to. kn eita bollin kn cg 4.00 pete issa kore...
e8032c217a60381f067d3ca6bc2664d156c74cc7
4c6a396ec7b2666675f60dcf24bb4dced3753caf
marcclintdion/a7_MARC_ANIMATION_B
/cpp/winInit.cpp
C++
cpp
25,303
no_license
int WINAPI WinMain( HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow ) { WNDCLASSEX winClass; MSG uMsg; memset(&uMsg,0,sizeof(uMsg)); winClass.lpszClassName = "MY_WINDOWS_CLASS"; winClass.cbSize = sizeof(WNDCLASSEX); winClass...
51226b7890ff4e41094f79ce010b65c21325be46
c471ffcf9662c662629c6104e0d057fb533cc9f7
dev1600/Cpp-OOPS
/STL/stl_priorty_queue.cpp
C++
cpp
762
no_license
#include <iostream> #include <queue> using namespace std; int main(){ //MAX HEAP-LARGEST ELEMENT at front priority_queue<int>maxi; //MIN HEAP-SMALLEST ELEMENT at front priority_queue<int,vector<int>,greater<int>>min; maxi.push(1); maxi.push(2); maxi.push(3); maxi.push(4); //stor...
2f12a79c2d9516596e293e81990a8748747ac868
e92ebc2061d83f73c92522ca7a4ae1af8da5a9cc
leehosu/coding-test-cpp
/backjoon/training_1/10818.cpp
C++
cpp
311
no_license
#include<iostream> #include<algorithm> using namespace std; int main(){ cin.tie(NULL); ios_base::sync_with_stdio(false); int num; cin >> num; int array[num]; for(int i=0;i<num;i++){ cin >> array[i]; } sort(array,array+num); cout << array[0] << " " << array[num-1] << "\n"; return 0; }
147cd599748784a9973a9a64fffa14cf32f76e33
d8b26bbfea8e428257adab62a3ed980adac58b67
humblesticker/coding
/skiena/robot.cpp
C++
cpp
530
no_license
#include <vector> using namespace std; class robot { public: /* bf: n points, choose n is n! */ /* heur: nearest 1D flags[] cur = 0, d = 0 while(flags not checked) next = find(start); d += (cur - next) cur = next d += (cur - 0) return d ~ n^2 */ void nearest(vector<int>& nums) { } /* ho...
cf914df1476c9f4437379feff889758766cf0d91
f158b1578075e626c311cffec1dd1c119392273b
Charmworks/ExaM2M
/src/NoWarning/partition.hpp
C++
hpp
823
no_license
// ***************************************************************************** /*! \file src/NoWarning/partition.hpp \copyright 2020 Charmworks, Inc. All rights reserved. See the LICENSE file for details. \brief Include brigand/algorithms/partition.hpp with turning off specifi...
5b9a9087f8c5112a68c3c5840931ba43a3370e22
18ff5766d9fa5b0ae4c3be8539621eb62e6e9d09
rishidewan33/Reliable-File-System
/testpart1.cc
C++
cc
5,494
no_license
/* * File: testpart1.cc * Author: rishi * * Created on November 29, 2011, 12:40 AM */ #include "ADisk.h" #include <cstdlib> #include <iostream> #include <cassert> using namespace std; int main(int argc, char** argv) { Disk d; bool format; char choice = 'z'; while (choice != 'y' && choice != '...
0cd2de0dbb35131549ba4a215354571a1a957fc5
e24eb217af4674bdfa291cd7ef162fe1b3e26bac
roccosec/SoT-SDK
/SDK/SoT_BP_CharacterInterface_structs.hpp
C++
hpp
332
no_license
#pragma once // Sea of Thieves (2.0) SDK #ifdef _MSC_VER #pragma pack(push, 0x8) #endif #include "SoT_Basic.hpp" #include "SoT_CoreUObject_classes.hpp" #include "SoT_Animation_classes.hpp" #include "SoT_EIKLimbName_classes.hpp" #include "SoT_BP_Docking_classes.hpp" namespace SDK { } #ifdef _MSC_VER #pragma pack(...
96a1feb2e2187ab969aeffcca6135efb08c585b3
a3f95654fcbcb8aeb7d80cba499aab2ee0f51b53
huningxin/chromium-src
/components/viz/service/surfaces/surface.cc
C++
cc
27,498
permissive
// Copyright 2014 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/viz/service/surfaces/surface.h" #include <stddef.h> #include <stdint.h> #include <algorithm> #include "base/metrics/histogram_func...
b7e5462b6863c1b337ce95f5f22710f0e47c72b0
69b8c651df241761b6afe496e9b64ee87c4f900b
dipak1221/CPP_Ubuntu_files
/CPPlearning/pair.cpp
C++
cpp
860
no_license
#include <iostream> using namespace std; class Man { private: int r; string s; public: int k; void Man1(int r, string s) { this->r = r; this->s = s; } void setMan(int r, string s) { this->r = r; this->s = s; } void getMan() { cout << "...
70da1cc8e5197dab07058653b4ad01f0cee0e0f7
aae1ceb9fb13281c6e8ad9fb7ba7064dacffe1a9
maslaral/cs162
/project4/Vampire.hpp
C++
hpp
831
no_license
/************************************************************* ** Program name: Project 4 ** Author: Alex Maslar ** Date: May 21 2019 ** Description: Vampire implementation - includes attack, defend, and inflict damage functions. In addition, the class contains the variables starting strength, strength, armor,...
67264b2837b4b1add14f01e8859ee1ced023d6a2
12ff69124fd91b6282fd04493023e99be7de21a1
eternity6666/life-in-acm
/practive/ICPC/2018/JiaoZuo/l.cpp
C++
cpp
2,499
no_license
#include <bits/stdc++.h> using namespace std; const int mod = 1000000007; long long n, ans = 0; void dfs(string s); int main() { freopen("in.txt", "r", stdin); int t; cin >> t; while(t--) { ans = 0; cin >> n; dfs(""); cout << ans << endl; } return 0; } void...
6465d26b627553a1399d940370e5c0384ea2366c
744012d95772518a9884647334b3c4acc4a4c081
tonyqd/HPC
/stencils/ViscosityBufferReadStencil.cpp
C++
cpp
4,201
no_license
#include "ViscosityBufferReadStencil.h" ViscosityBufferReadStencil::ViscosityBufferReadStencil( const Parameters & parameters): BoundaryStencil<FlowField>(parameters), localSize(parameters.parallel.localSize) { if(parameters.geometry.dim == 3){ leftViscosityReadBuffer = new FLOAT[(localSize[1]+3) * (localSize[2...
daba859ed40ca92495f76a8a65242431f4121c60
c14e0a5885e7a7cd67198dbe08bc3c28fa24ceea
tsuyosshi/competitive-programming
/Atcoder/ABC/C/One_More_aab_aba_baa.cpp
C++
cpp
886
no_license
#include<bits/stdc++.h> using namespace std; #define int long long #define ALL(x) (x).begin(),(x).end() #define MAX(x) *max_element(ALL(x)) #define MIN(x) *min_element(ALL(x)) typedef pair<int,int> PI; typedef pair<int,pair<int,int>> PII; static const int INF=1010000000000000017LL; static const double eps=1e-12; sta...
6221ad5d040701a14c6b363099615c96a0be86e4
a12889465211418d52f2c8ccd9d0692723061a2d
jahirmj/C---Full-Course--C---Tutorial--Data-Structures---Algorithms
/hello world/Array/2 Dimensional Arrays/Searching_A_Matrix.cpp
C++
cpp
988
no_license
#include "bits/stdc++.h" using namespace std; int main() { system("cls"); // Declare Section---> int n, m; cin >> n >> m; int arr[n][m]; // Input Section----> for (int i = 0; i < n; i++) { for (int j = 0; j < m; j++) { cin >> arr[i][j]; } } ...
c3f009377c11f5f79c4ad096baf50f64fc7372f0
a38fd6463f0b585df6824bc87448e4dd86094588
PTSTS/trident
/rdf3x/src/cts/SemanticAnalysis.cpp
C++
cpp
43,144
permissive
#include <cts/semana/SemanticAnalysis.hpp> #include <cts/parser/SPARQLParser.hpp> #include <cts/infra/QueryGraph.hpp> #include <rts/runtime/QueryDict.hpp> #include <infra/util/Type.hpp> #include <dblayer.hpp> #include <kognac/logs.h> #include <set> #include <cassert> #include <cstdlib> #include <iostream> //--------...
08d1202382926d79aa5c318b3ff6b151ea235470
009a2f5f758d7c705367273752c644c449aed3fa
bblanke/mongoose_timer_test
/src/MongooseTimerID.hpp
C++
hpp
412
permissive
#ifndef TIMER_ID_H #define TIMER_ID_H #include "mgos.h" #include "mgos_timers.h" class MongooseTimerID { private: mgos_timer_id timer_id_; public: MongooseTimerID(): timer_id_(MGOS_INVALID_TIMER_ID) {} mgos_timer_id Get() { return timer_id_; } void Set(mgos_timer_id timer_id) { LOG(LL_INFO, ("Changi...
cacc68d51d60761e806e322da72a36079e7ac732
9ea060be610985c07cda81713af8c23cebe5cc23
Nagashi-A-A/ITMO.Practice.Cpp
/ITMO.Cpp.Yaroshchuk.Exam/ITMO.Cpp.Yaroshchuk.Exam.cpp
C++
cpp
1,429
no_license
// ITMO.Cpp.Yaroshchuk.Exam.cpp : This file contains the 'main' function. Program execution begins and ends there. #include <vector> #include <iostream> #include <string> #include "item.h" #include "trooper.h" #include "itemFactory.h" #include "game.h" #include "enemy.h" #include <vector> #include <array> ...
082708b241076247042e3b619fb5644c3e714e41
62d40731013da3d3420a5d53edb1c0e157f2931a
stephysim/LO21
/CODE/UTProfiler/dialogupdatedeleteuv.cpp
C++
cpp
1,448
no_license
#include "dialogupdatedeleteuv.h" #include "ui_dialogupdatedeleteuv.h" #include "mainutprofiler.h" DialogUpdateDeleteUV::DialogUpdateDeleteUV(QWidget *parent) : QDialog(parent), ui(new Ui::DialogUpdateDeleteUV) { ui->setupUi(this); MainUTProfiler &mainUTProfiler=MainUTProfiler::getUTProfiler(); i...
4268443f9bf373b3b48f9334250cbfee97b776ad
566b906742216f9080d8c88315e90420a0be62aa
KqSMea8/sstd_library
/sstd_boost/sstd/boost/beast/zlib/detail/inflate_stream.hpp
C++
hpp
44,789
permissive
// // Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com) // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // // Official repository: https://github.com/boostorg/beast // // This is a derivat...
e8c9992d9dce0b8af467bcaee38fad1b95c3b705
4a937b8e3902f4bb0541844bfe60151c0aef557e
fcccode/dynamix
/include/dynamix/object_type_info.hpp
C++
hpp
5,115
permissive
// DynaMix // Copyright (c) 2013-2018 Borislav Stanimirov, Zahary Karadjov // // Distributed under the MIT Software License // See accompanying file LICENSE.txt or copy at // https://opensource.org/licenses/MIT // #pragma once /** * \file * Defines internal classes that contain the type information for an object - ...
5fe2a0d809e4ef2538ed0db29ce4e879bf2facc2
d982768d2e80ebb3bbe815d2d99dc62088ba6929
Wshid/linux_system_programming
/02_File_IO/2.7_Lseek/code_2.7.1_overend.cc
C++
cc
850
no_license
/* 파일 오프셋이 파일 끝을 넘어가게 되면 마지막 오프셋과 새로운 오프셋 사이에 공간이 만들어지며 0으로 채워진다. 이를 구멍이라고 하며, 물리적인 디스크 공간을 차지하지 않음 구멍이 생긴 파일을 spare file(성긴 파일)이라고 한다. 구멍에 읽기 요청을 하면 적절한 개수 만큼 0으로 채워진 값을 반환 */ #include<iostream> #include<sys/types.h> #include<unistd.h> #include<fcntl.h> using namespace std; int main(in...
77e76d5f1dfafb7af306c7b28b05649bc43e8a3c
f10bce0afa2a68bb0f7f45092a8ad8285c94832d
kapecp/3dsoftviz
/src/Application/Application.cpp
C++
cpp
1,289
no_license
#include "Application/Application.h" #include <QDebug> #if defined(Q_WS_X11) || defined(Q_OS_LINUX) #include <X11/Xlib.h> #include "fixx11.h" #endif namespace App { Application::Application( int& argc, char** argv ) : QApplication( argc, argv ) { #if defined(Q_WS_X11) || defined(Q_OS_LINUX) this->isEmitting = fal...
1aa3e12c6a1570fbd56390a44c1ecd6687bc5085
43c926f0a74857198a6e0c7ac15b480a51605e0f
ric2b/Vivaldi-browser
/chromium/chrome/browser/ash/arc/instance_throttle/arc_kiosk_mode_throttle_observer_unittest.cc
C++
cc
3,121
permissive
// Copyright 2021 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "chrome/browser/ash/arc/instance_throttle/arc_kiosk_mode_throttle_observer.h" #include "base/bind.h" #include "base/command_line.h" #include "chrome/browser/ash/login/...
ed8d967a8efa8ac9beba718a505ab7c6b4fec13a
248dd770c40517c4964793927ace0cbef836d295
RickyJun/live_plugin
/back/RtmpLivePushSDK/boost/boost/range/algorithm/reverse_copy.hpp
C++
hpp
1,189
permissive
// Copyright Neil Groves 2009. Use, modification and // distribution is subject to the Boost Software License, Version // 1.0. (See accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt) // // // For more information, see http://www.boost.org/libs/range/ // #ifndef BOOST_RANGE_ALGORIT...
ee59a6b037d6ff0cc9632b3c59a7c01b3b5f2f5b
aa30edf72924b71283814ef2c82292c6aac0ed16
bohaoist/LibExcutor
/src/CLMessageDeserializer.cpp
C++
cpp
233
no_license
/* * CLMessageDeserializer.cpp * * Created on: Feb 22, 2016 * Author: haobo */ #include "CLMessageDeserializer.h" CLMessageDeserializer::CLMessageDeserializer() { } CLMessageDeserializer::~CLMessageDeserializer() { }
f2551cc1b01169026f90d107ccf8dcccbfaa5b92
8c9cfb74a8c8eaabd9b8b638cb077ad8e2df8c44
alrightlook/GameFramwork
/Player.cpp
C++
cpp
406
no_license
#include "Player.h" #include "MapEngine.h" Player* Player::m_Instance = 0; Player* Player::Instance() { if(m_Instance == 0) { m_Instance = new Player(); } return m_Instance; } Player::Player() { m_nPosx = -1; m_nPosy = -1; } Player::~Player() { } void Player::GeneratePlayer() { MapEngine::Instance()->QuerySp...
7acad93a14c743b2ff81458b15ea886a743f16a0
97d6c6674330eb10e4f2247aa87fba21a1cbb6c4
Kiids/OJ_Practice
/交错字符串.cpp
C++
cpp
1,413
no_license
/* 给定三个字符串 s1、s2、s3,请你帮忙验证 s3 是否是由 s1 和 s2 交错 组成的。 两个字符串 s 和 t 交错 的定义与过程如下,其中每个字符串都会被分割成若干 非空 子字符串: s = s1 + s2 + ... + sn t = t1 + t2 + ... + tm |n - m| <= 1 交错 是 s1 + t1 + s2 + t2 + s3 + t3 + ... 或者 t1 + s1 + t2 + s2 + t3 + s3 + ... 提示:a + b 意味着字符串 a 和 b 连接。 示例 1: 输入:s1 = "aabcc", s2 = "dbbca", s3 = "aadbbcbcac" 输出:t...
b221edd683e3d2e708b87206cd326ab7d80d85d7
f13800a7e9f38e863d092ba6252b49ecbe21799f
archi144/Algorithms-and-others
/Bubble_sort.cpp
C++
cpp
852
no_license
#include <iostream> #include <array> #include <random> using std::cout; template<size_t T> void bubble_sort(std::array<int,T> &array) { bool sorted = false; // sort flag for (size_t i=0;i<array.size();i++) { sorted = true; for (size_t k=0;k<array.size()-1;k++) ...
6096bf21877eeec84b0105fedef68660215cc1e0
6c408f598a7a521064663be2b592b64ebc6da3b0
cgy1992/cppparser
/src/utils.cpp
C++
cpp
3,050
permissive
/* The MIT License (MIT) Copyright (c) 2018 Satya Das 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 rights to use, copy, ...
3f5c294228f8f920a8dba69273e5a0f639d0cc64
1515e1a982643469b53f506c1b1ec574bd3bb0bd
johanngan/particle_reco
/LambdaCData/analyzers/LambdaPi_histo_y_Pbp/recoData/recoData.cpp
C++
cpp
7,717
no_license
//NOTE: THIS MACRO REQUIRES C++11, AND MUST BE RUN IN ROOT6 //v2 of recoData.cpp. Allows reconstruction on data in multiple files, with results stored in one single file //This is better than merging the input files, since particles from one sample should not be combined with //particles from a different sample. (A pa...
ae5499a1d414f739d18a773b5ba8680065d155da
38c99716068fb2bcdff88a69322dc1b7d68b070a
Kuovane/creator_to_cocos2dx
/HelloWorld/frameworks/runtime-src/Classes/reader/ui/RadioButton.cpp
C++
cpp
9,272
no_license
#include "RadioButton.h" #include "RadioButtonGroup.h" NS_CCR_BEGIN CreatorRadioButton* CreatorRadioButton::create() { CreatorRadioButton* widget = new (std::nothrow) CreatorRadioButton(); if (widget && widget->init()) { widget->autorelease(); return widget; } CC_SAFE_DELETE(widget); return nullptr; } Cr...
bc43764185bfc251344ba5e581276d97eaec090f
36ff86a07cec2e1f094830c6d4aa3c8f7f2bd97b
wqx081/mpr_base
/src/base/strings/stringprintf.cc
C++
cc
4,251
no_license
#include "base/strings/stringprintf.h" #include <errno.h> #include <stdarg.h> // For va_list and related operations #include <stdio.h> // MSVC requires this for _vsnprintf #include <vector> using std::vector; #include <glog/logging.h> #include "base/core/logging-inl.h" #include "base/core/macros.h" namespace base { ...
1fb5713ea4a31649ca2062ddbb5d9cbbbe7b8716
d9a9e7e685a925bdadfe131b34cb304a5327578a
astro-informatics/casacore-1.7.0_patched
/lattices/Lattices/test/tArrayLattice.cc
C++
cc
32,842
no_license
//# tArrayLattice.cc: test ArrayLattices and ArrayLatticeIterators. //# Copyright (C) 1995,1996,1997,1998,1999,2000,2001,2002,2003 //# Associated Universities, Inc. Washington DC, USA. //# //# This program is free software; you can redistribute it and/or modify it //# under the terms of the GNU General Public License a...
b43a5517e9be7e551b17f35646c50df6861e2e00
342eab4e536c3be002235a2f311da46cb2d37036
FangShaoHua94/kattis-Cplusplus
/Thanos the Hero/main.cpp
C++
cpp
637
no_license
#include <iostream> using namespace std; int main() { int n; long total=0; cin>>n; if(n==1){ cout<<0<<endl; }else{ bool flag=true; int arr[n]; for(int i=0;i<n;i++){ cin>>arr[i]; if(arr[i]<i){ flag=false; } ...
b1d171ade24bac4d2be5a446054b13ddf472072e
0bdd0e1c65d9e0f78db55f48d63f2703b186a986
qian99/acm
/problem/贪心/hdu 4803 Poor Warehouse Keeper.cpp
C++
cpp
1,235
no_license
#include<iostream> #include<cstdio> #include<cstring> #include<string> #include<algorithm> #include<map> #include<queue> #include<set> #include<stack> #include<cmath> #include<vector> #define inf 0x3f3f3f3f #define Inf 0x3FFFFFFFFFFFFFFFLL #define eps 1e-9 #define pi acos(-1.0) using namespace std; type...
6fe414346b91b5727b30ac3635ad1edea8427d94
5f1943ba989b2791c6a56fdbda7d36259a54ca8f
Arvolear/Hide_and_Seek
/client/code/game_object/weapon.hpp
C++
hpp
1,564
no_license
#pragma once #include <string> #include <vector> #include <bullet/btBulletCollisionCommon.h> #include <bullet/btBulletDynamicsCommon.h> #include <glm/glm.hpp> using namespace std; using namespace glm; class Weapon : public GameObject { protected: vec3 offset; quat twist; float lastShot...
16d6a230ffd583c8f1397803e4807af6fa69c026
75e5e47e708409982ff77cd30e9af96c2eaf00bf
x1aoo/openvino
/inference-engine/src/mkldnn_plugin/nodes/embedding_segments_sum.cpp
C++
cpp
5,973
permissive
// Copyright (C) 2020 Intel Corporation // SPDX-License-Identifier: Apache-2.0 // #include "embedding_bag_sum.hpp" namespace InferenceEngine { namespace Extensions { namespace Cpu { class EmbeddingSegmentsSumImpl: public MKLDNNEmbeddingBagSum { public: explicit EmbeddingSegmentsSumImpl(const CNNLayer* layer) : ...
ab5e4168e0a05947a200d8b3661c0a4045abd9f0
63ca760c0f46adb30db4f89fb359f1cb45001499
ttyang/sandbox
/sandbox/SOC/2006/misc/tags/final/boost/bimap/views/multimap_view.hpp
C++
hpp
4,023
no_license
// Boost.Bimap // // Copyright (c) 2006 Matias Capeletto // // This code may be used under either of the following two licences: // // 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 ...
bb2002bb6af06c04681ed768cea0a36d181879a3
d77d54d158cd1572b3cd38bedc83c70aa907a74c
miaobeihai/OpenGL_OpenGLLearning
/source/lesson006-MFC-MDI/PropertiesWnd.cpp
C++
cpp
8,752
no_license
#include "stdafx.h" #include "PropertiesWnd.h" #include "Resource.h" #include "MainFrm.h" #include "lesson006-MFC-MDI.h" #ifdef _DEBUG #undef THIS_FILE static char THIS_FILE[]=__FILE__; #define new DEBUG_NEW #endif ///////////////////////////////////////////////////////////////////////////// // CResourceViewBar CP...
a73fd23d0a3ba3d84068b35670bd876b6b8e99b9
3e6a88993150fab940405f237a8cbb1b2311eecc
tangjz/acm-icpc
/self_training/2015-02-11/J.cpp
C++
cpp
873
permissive
#include <queue> #include <cstdio> #include <vector> #include <algorithm> using namespace std; const int maxk = 751; int k, a[maxk], b[maxk], c[maxk], id[maxk]; priority_queue<pair<int, int>, vector<pair<int, int> >, greater<pair<int, int> > > Q; int main() { while(scanf("%d", &k) != EOF) { for(int i = 0; i < k; ++...
4868066711bb0bbda05f0a803e0d30df76234c44
cb68cb01c16b2b178c08bb15b6376197625451a9
IrinaRogacheva/OOP
/lw3/Calculator/Calculator/Calculator.cpp
C++
cpp
5,915
no_license
#include "Calculator.h" #include <iomanip> #include <iostream> #include <algorithm> using namespace std; Calculator::Calculator() : m_actionMap({ { '+', [this](const double leftOperand, const double rightOperand) { return CalculateSum(leftOperand, rightOperand); } }, { '-', [this](const double leftOperand...
792138bdadf9b2db4857cde369b1f10da082012b
7bc2f0354b9fbc6f2a73116f3886f06b44cd66cb
Yueeeeeeee/SLAMParking
/parking/code/path_decomposition/next_goal/src/nextgoal_publisher.cpp
C++
cpp
1,252
no_license
#include <ros/ros.h> #include <cmath> #include <nav_msgs/Path.h> #include <geometry_msgs/PoseStamped.h> class NextGoalPublisher { ros::NodeHandle n; ros::Subscriber path_sub; ros::Publisher nextgoal_pub; geometry_msgs::PoseStamped output_msg; geometry_msgs::PoseStamped temp; void pathCallback...
a807935ba150af63690c038154af231f3db863a4
e584009ea15233a546a789a611bb905f195fe526
evandrix/UVa
/10879.cpp
C++
cpp
463
no_license
#include <bits/stdc++.h> using namespace std; /* 10879 */ void Cal(int n) { int i; printf(" %d = ", n); for (i = 2; i * i <= n; i++) { if (n % i == 0) { printf("%d * %d = ", i, n / i); break; } } for (++i; i * i <= n; i++) { if (n % i == 0) { printf("%d * %d\n", i, n / i); break; } } }...
4f57641b66ca10960b8d274290658ee75c4854b3
6d704cd47e5052fa66509c74a8ebd402b754a47e
polymage-labs/mlirx
/libcxx/test/libcxx/diagnostics/detail.headers/charconv/to_chars_result.module.verify.cpp
C++
cpp
670
permissive
// -*- C++ -*- //===----------------------------------------------------------------------===// // // 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 // //===------------...
8a9a45da6ed9b8642715350b753729f051a5a5de
59c9fc673927dbf64d0dc33e78cbbaa9d6c4e413
sadrulhc/chromium
/chromeos/network/proxy/proxy_config_handler.cc
C++
cc
4,884
permissive
// Copyright (c) 2013 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 "chromeos/network/proxy/proxy_config_handler.h" #include <memory> #include <utility> #include "base/bind.h" #include "base/json/json_writer...
e2bd12f5b8f7e5280817836fc22584e6f468574f
4aa64ad9478aa88d7e1bd44996378c7a5a088671
jrmadsen/CMake
/Source/cmExecProgramCommand.cxx
C++
cxx
9,504
permissive
/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying file Copyright.txt or https://cmake.org/licensing for details. */ #include "cmExecProgramCommand.h" #include "cmsys/Process.h" #include <stdio.h> #include "cmMakefile.h" #include "cmProcessOutput.h" #include "cmSystemTools.h" class cmE...
43b9844ffe132f2273feb219416f13b23743d42a
12ffd9d486d50055ebdf06c3c140adbc4da79130
jgcongdon/Cpp
/zyBooks/03. Variables Assignments/3.05.1: Sphere volume.cpp
C++
cpp
396
no_license
#include <iostream> using namespace std; int main() { double piVal = 3.14159; double sphereVolume = 0.0; double sphereRadius = 0.0; sphereRadius = 1.0; /* Your solution goes here */ sphereVolume = (4.0 / 3.0) * (piVal) * (sphereRadius)* (sphereRadius)* (sphereRadius); /* Your solution ends here...
9c8afb9e654fb6d2e72b3eb036681f231165554e
1280ec55c11b68e930349bb8a16ca2fdf994b990
Forrest-Z/Carbrain
/src/perception/test/contour_classifier_test.cpp
C++
cpp
8,669
no_license
// Copyright 2017 KITcar #include <common/macros.h> THIRD_PARTY_HEADERS_BEGIN #include <gtest/gtest.h> #include <math.h> #include <ros/package.h> #include <boost/filesystem.hpp> THIRD_PARTY_HEADERS_END namespace fs = ::boost::filesystem; #include "../src/road_object_detection/classifiers/contour_classifier.h" #inclu...
8eb4c987d57b04ae5268edf2ab2c9127961d8326
ccd7c62af552e9955c47ed2444b0f0c4e5ff7bd8
RheinhardHye/ACVD
/Common/RenderWindow.cxx
C++
cxx
29,382
permissive
/* --------------------------------------------------------------------- * Copyright (c) CREATIS-LRMN (Centre de Recherche en Imagerie Medicale) * Author : Sebastien Valette * * This software is governed by the CeCILL-B license under French law and * abiding by the rules of distribution of free software. You can u...
2e7408e36d3a6d2236027165b3bae254424b33e7
6a3ffd3f70069f70cd443315a9f4795c2c8141f3
bcsdleweev/mrpt
/libs/vision/src/ba_common.cpp
C++
cpp
12,256
permissive
/* +---------------------------------------------------------------------------+ | Mobile Robot Programming Toolkit (MRPT) | | http://www.mrpt.org/ | | ...
fb0151b4dba3a1c57ec984296f1b8f5be606baee
2d57b64eb95092af329d4e42af42aac68fce8fb3
UnrealLearningProjects/Section_04_BattleTank
/MyBattleTank/Source/MyBattleTank/Private/MyTankAIController.cpp
C++
cpp
606
no_license
// Fill out your copyright notice in the Description page of Project Settings. #include "MyBattleTank.h" #include "Tank.h" #include "MyTankAIController.h" void AMyTankAIController::BeginPlay() { Super::BeginPlay(); } void AMyTankAIController::Tick(float DeltaSeconds) { Super::Tick(DeltaSeconds); auto PlayerTank...
7e09be35ee4328660d2b7a96723734c191aae029
dbcd6b1325356479772d1f015f661e4abc9e55c3
luke-jr/mrustc
/src/hir_expand/annotate_value_usage.cpp
C++
cpp
25,211
permissive
/* * MRustC - Rust Compiler * - By John Hodge (Mutabah/thePowersGang) * * hir_expand/annotate_value_usage.cpp * - Marks _Variable, _Index, _Deref, and _Field nodes with how the result is used */ #include <hir/visitor.hpp> #include <hir/expr.hpp> #include <hir_typeck/static.hpp> #include <algorithm> #include "main...
b50c037236db11828f5db7baeb48900cf13d6940
a87fe18667fe177d5a0e0a0bdfecf2a0f3a19981
ramswami123/arrays-and-strings_stl-cpp
/STRINGS_function_libary.cpp
C++
cpp
1,172
no_license
#include<iostream> #include<string> using namespace std; int main(){ string str="pirla geeta krishna"; //basic function finding lenght cout<<str.length()<<endl; //19 //to add charcter to string at back str.push_back('4'); cout<<str<<endl; //output for above statement //pi...
37f0ceeefcb58548dd0c320d10308e78125d255c
4970738a58a8b6903dbe0a1fcfc8a615d985dca0
shrutiramesh1988/pytorch
/aten/src/ATen/native/cpu/BinaryOpsKernel.cpp
C++
cpp
33,932
permissive
#include <ATen/native/BinaryOps.h> #include <cmath> #include <iostream> #include <ATen/Dispatch.h> #include <ATen/Parallel.h> #include <ATen/cpu/vec256/functional.h> #include <ATen/cpu/vec256/vec256.h> #include <ATen/native/TensorIterator.h> #include <ATen/native/cpu/Loops.h> #include <ATen/native/Math.h> #include <c...
ad22b3a00b21f1692ba410a08df4d45c4828f500
e26ce382503cbfc28118dea6834a8fbc88f620d5
sooxie/skia
/src/utils/SkAnimCodecPlayer.cpp
C++
cpp
5,046
permissive
/* * Copyright 2018 Google Inc. * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #include "include/codec/SkCodec.h" #include "include/core/SkCanvas.h" #include "include/core/SkData.h" #include "include/core/SkImage.h" #include "include/utils/SkAnimCodecPla...
fa3086b68723d57db75d7b60ae06fe289cfc4f63
ef424a56bd7e2cb8b5f2238c3ae8f901b31b1753
JAreina/C-PLUS-PLUS
/35-string-10-reemplazar-substring/main.cpp
C++
cpp
1,161
no_license
#include <stdio.h> #include <string> #include <iostream> using namespace std ; void reemplazar (string& str, unsigned desde, unsigned hasta, const string& nueva); int main(int argc, char **argv) { string palabra; string nueva; unsigned desde; unsigned hasta; cout << "introduce una palabra"<<endl; cin >> palabr...
f5ca6d2f8ed850dde3f10931871f84cd840e7ad6
9ebf64129374cd2bca9ba645989c4e11e5ade885
imdark/chromium
/ui/accessibility/platform/ax_platform_node_auralinux.cc
C++
cc
83,254
permissive
// Copyright 2017 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 "ui/accessibility/platform/ax_platform_node_auralinux.h" #include <stdint.h> #include <algorithm> #include <memory> #include <string> #include ...
d03c4cd4f6f955d7a9db9594f575fe36adf23a4f
c0a20a886e5b5c2c5b9fcb654e89f13d72f72584
haitang17/AlgorithmsHomework
/RBTree/main.cpp
C++
cpp
821
no_license
#include "rb_tree.h" int main() { int A[6] = { 41,38,31,12,19,8 }; RB_Tree tree; tree.RB_Create(A, 6); cout << "按照层次遍历的顺序输出红黑树结构" << endl; tree.LevelOrder_Traverse(); cout << endl; cout << "中序遍历红黑树:"; tree.InOrder_Traverse(); cout << endl; int k; while (1) { cout << "输入要插入红黑树的关键字的值,输入-1表示结束输入:"; cin >...
373b6af6d61cfa72cdf9940ebdc2916810781d63
42fcfa43d60067fc259fbcfd09e2b714df00e029
xrr/mcvr
/ mcvr/mcvr/LookbackCall.cpp
C++
cpp
309
no_license
#include "LookbackCall.h" LookbackCall::LookbackCall(double K){ this->K = K; } LookbackCall::~LookbackCall(void) {} double LookbackCall::operator ()(Trajectory* pT) { double S = K; for (unsigned i=0; i<pT->Size(); i++) S = (S<pT->Get(i))?pT->Get(i):S; //update S? return S-K>0?S-K:0; }
75f64d8d09bb653a73eba4c6f94883624a2f958e
c88c372e74e3ab5dbb7aaa9b3607e8b1640e8343
amac714/Text-Based-Game---CS162-Project
/ChampRoom.cpp
C++
cpp
1,847
no_license
/********************************************************** * Program Name: Final Project ChampRoom.cpp * Author: Alan Macabuhay * Date: 3/16/17 * Description: Implementation for ChampRoom class. ***********************************************************/ #include "ChampRoom.hpp" //constructor ChampRoom::Champ...
f0473894fcdd3281e704c165a68841b51feb44b5
97f01ee52a98db624d2c9a45bf74a69cb1c97efb
anushanandam/AesopFable
/drawHead.cpp
C++
cpp
716
no_license
#include "lab.h" #include <cmath> /*Owner: Anusha*/ /* The head of the wolf is drawn to the graphics window.*/ void drawHead(cairo_t* cr,double x, double y) { //std::cout<< "drawing the head" << std::endl; /*rgba where alpha is amount of transparency */ cairo_set_source_rgb (cr, 0,0,0); // black //std::cout<<"x is...
84ab45c9eb4101d21d53f74c9bc31ef0369c5bed
10f3ce11e0d082583d5d2b2d451549d5ee374bc4
vimal135/MyC-Codes
/Check_Palindrome.cpp
C++
cpp
1,026
no_license
// C++ program to find number is palindrome // or not without using any extra space #include <bits/stdc++.h> using namespace std; bool isPalindrome(int); bool isPalindrome(int n) { // Find the appropriate divisor // to extract the leading digit int divisor = 1; while (n / divisor >= 10) ...
b4a1f1015ec10dc0e7ec79a39cd53bb26cc58b57
ed13e12fa17a114a4a09b343a6bb124d458a10e7
dillonhuff/Halide-to-Hardware
/apps/hardware_benchmarks/tests/conv_1_2/conv_1_2_generator.cpp
C++
cpp
1,540
permissive
#include "Halide.h" namespace { using namespace Halide; class ConvolutionKernel : public Halide::Generator<ConvolutionKernel> { public: Input<Buffer<uint16_t>> input{"input", 2}; Output<Buffer<uint16_t>> output{"output", 2}; void generate() { /* THE ALGORITHM */ Var x("x"), y("y"); ...
ac32f0f4efbc31d6f26fb9ddf3f2209dbb4a8d18
90ecc35ca42d9d4cf6c6ba832df1cc35ba271edf
kolkono/YAPVU
/Лабораторная 1/Лабораторная 1/Лабораторная 1.cpp
C++
cpp
1,569
no_license
#include <cstdio> #include <cstdlib> #include <iostream> using namespace std; class Fraction { protected: long first; unsigned short second; public: Fraction() { first = 0; second = 0; } void init(long f, unsigned short s) { first = f; second = s; } voi...
36e894a6590c0a3e372e97ccd1ceb69bbc88731c
0bf99414f674ebdefdd3aefd7e72e6aa143b752c
LuanBoheng/linux-image-setup
/project_learning_index/convert.cpp
C++
cpp
2,412
no_license
#include <iostream> #include <vector> #include <fstream> #include <algorithm> //--------------------------------------------------------------------------- using namespace std; //--------------------------------------------------------------------------- //4 input: <commend> <mode=float> <input file> <output fil...
95a52c8af39cd0488ab5e1eaf60e980e656ea351
72b5a3e535409491792153bb15f9b485594429fc
swa34/Allen_assignment2
/SortedLinkedList.cpp
C++
cpp
5,169
no_license
#include <iostream> #include "SortedLinkedList.h" using namespace std; SortedLinkedList::SortedLinkedList() { head = nullptr; currentPos = nullptr; lengthValue = 0; } SortedLinkedList::~SortedLinkedList() { ListNode* current; // iterate through the list and delete all the nodes while(head != nullptr) {...
7e61a881f157b43e978d2270385b1bce4aeb4ccf
1f634b2294ca8d2fd71f2d82bc22098bc2df563b
redeff/cmp
/icpc/2013-tap/ProblemaI.cxx
C++
cxx
1,970
no_license
/* * ProblemaI.cxx * * Copyright 2019 Carlos Miguel Soto <reedef@reedef-pc> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any...
a4237c18df65d2216c124cca5200d66971e81a82
0c677c013fde1881d26d8f4fed3c68f5662239fb
lunarpulse/DSMalikCPP
/ex5_04/Source.cpp
C++
cpp
799
no_license
#include <iostream> #include <iomanip> #include <cctype> #include <limits> int main() { std::cout << std::numeric_limits<unsigned char>::max() << std::endl; // Output the column headings std::cout << std::setw(11) << "Character " << std::setw(13) << "Hexadecimal " << std::setw(9) << "Decimal " << std::endl; std::...
408516ab11b6d765f47c10c14841e25c2c7c4093
7f957adb11ae4c22dd2b911d215c6e26acd7408b
festus-onboard/graphics
/src/main/ColorFactory.cpp
C++
cpp
4,335
no_license
#include "ColorFactory.h" #include <cstdlib> // for random numbers #include <iostream> #include "BasicMath.h" /** * This class consists of static methods that perform * coloring tasks to geometry in a scene. * @author Nicholas Dunn * @date February 21, 2009 */ const int ColorFactory::NUM_COM...
7ef7d5b725991be21ba1b3e0d7096cb5639e3751
8fe967c3384578092670ad12fcd4dba11bf325fe
zlayine/cplusplus-42
/d07/ex00/main.cpp
C++
cpp
527
no_license
#include "whatever.hpp" int main( void ) { int a = 2; int b = 3; ::swap(a, b); std::cout << "a = " << a << ", b = " << b << std::endl; std::cout << "min( a, b ) = " << ::min(a, b) << std::endl; std::cout << "max( a, b ) = " << ::max(a, b) << std::endl; std::string c = "chaine1"; std::string d = "chaine2"; ...
8671a5c4f8bb1ecd76981f91a0293bdd83d2d4ae
230f15aa5281d173c046468dce860d0d483b70b1
yosefmaru/libstruct
/TestProject_2017/LibStructMain/LibStructMain/LibStructMain.cpp
C++
cpp
3,713
no_license
#include <stdio.h> // for printf #include <stdlib.h> // for malloc #include <string.h> // for memset #include <libstructural.h> // the structural analysis library // construct simple stoichiometry matrix void GetMatrixFromSomeWhere(double** *oMatrix, int *nRows, int *nCols) { int numCols...
12cc69603fe57801d0736cc111e283a340eccbb2
b7852884d2167ab28355c341f5a5be7b4d25c28e
JianghanLi/LintCode
/Contest 44 Quarter #2/Q7 1461. 会议问题/wisdompeak.cpp
C++
cpp
2,004
no_license
class Solution { public: /** * @param meeting: The meetings * @param pause: The pause time of meetings * @param query: The query * @return: Return the answer of each query */ vector<int> getQuery(vector<vector<int>> &meeting, vector<vector<int>> &pause, vector<int> &query) { ...
a514cf543eecfc7561edec2beb5d4f0d4870cbb5
433457bff71c0994534ad455bc88e2fc752fa333
j1249845202/chromium
/media/capture/video/chromeos/camera_device_delegate.cc
C++
cc
68,551
permissive
// Copyright 2017 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 "media/capture/video/chromeos/camera_device_delegate.h" #include <algorithm> #include <cmath> #include <memory> #include <string> #include <util...
5682be9011c951e0eb2d8bc7dc3fa611097263e7
255b40281627d57299f12826a6289e27f6e547cd
tardis-windows/DoubleLinkedList
/main.cpp
C++
cpp
1,333
no_license
// TESTER PROGRAM #include <iostream> #include <cstdlib> #include <string> #include <cassert> #include <ctime> #include "Node.h" #include "SortedBag.h" #include "Student.h" using namespace std; int main() { srand(time(NULL)); cout << "TESTER PROGRAM" << endl; SortedBag<Student> L1,...
d63dce8933200b3917e5aadbc77291873a668a2d
e2f6cbdcf725d27b49d466f4ace3594345a28900
YanzhaoW/ElossLayer
/include/DetectorConstruction.hh
C++
hh
3,580
no_license
// // ******************************************************************** // * License and Disclaimer * // * * // * The Geant4 software is copyright of the Copyright Holders of * // * the Geant4 Collaboration...
d42301a6bdf03be29a6ce48a810eacae15f477c8
2486cd07040462a186daa0ed00f484b1b455b680
gabrielb09/DetectorSim
/include/DetectorPhysicsList.hh
C++
hh
309
no_license
#ifndef DetectorPhysicsList_h #define DetectorPhysicsList_h 1 #include "G4VModularPhysicsList.hh" class DetectorPhysicsList: public G4VModularPhysicsList { public: DetectorPhysicsList(); virtual ~DetectorPhysicsList(); public: // SetCuts() virtual void SetCuts(); }; #endif
110e9e45e5dc0801d94838e0de6582f6729e72af
0b6bba7bb625b663d1f05224be540ca143980a00
seiichiinoue/hpylm
/src/node.hpp
C++
hpp
13,967
no_license
#pragma once #include <boost/serialization/serialization.hpp> #include <boost/archive/binary_iarchive.hpp> #include <boost/archive/binary_oarchive.hpp> #include <boost/serialization/unordered_map.hpp> #include <boost/serialization/map.hpp> #include <boost/serialization/vector.hpp> #include <unordered_map> #include <str...
e083bf8394bdb49ed354c06601509ce4e9bd621b
953e7a320637a3cf608552ca765067eafc991945
dfinner1/appleseed
/src/appleseed/renderer/modeling/material/disneymaterial.cpp
C++
cpp
30,128
permissive
// // This source file is part of appleseed. // Visit http://appleseedhq.net/ for additional information and resources. // // This software is released under the MIT license. // // Copyright (c) 2014 Esteban Tovagliari, The appleseedhq Organization // // Permission is hereby granted, free of charge, to any person obta...
59d6ff2489c8731f6b8b66e464142bdc1354540e
b4300a27ee5ff81c6361f96f9df0e54717d4abb2
dimitrijevic/KinfuSuperRes
/Tsdf_vis/main.cpp
C++
cpp
44,288
no_license
#include "tsdf_viewer.h" #include "TriangleRenderer.h" #include "DepthViewer3D.h" #include "MeshRayCaster.h" #include "PolyMeshViewer.h" #include "UpScaling.h" #include "BilateralFilterCuda.hpp" #include "ViewPointMapperCuda.h" #include "YangFilteringWrapper.h" #include "my_screenshot_manager.h" #include "MaUtil.h"...
83578b46479c3dda677d3a082bbbc08852827f13
242fe712fb2741bbcf7422a16aa463324dc1cf35
vchiapaikeo/prophet
/venv/lib/python3.7/site-packages/pystan/stan/lib/stan_math/stan/math/opencl/kernels/scalar_mul_diagonal.hpp
C++
hpp
1,297
permissive
#ifndef STAN_MATH_OPENCL_KERNELS_SCALAR_MUL_DIAGONAL_HPP #define STAN_MATH_OPENCL_KERNELS_SCALAR_MUL_DIAGONAL_HPP #ifdef STAN_OPENCL #include <stan/math/opencl/kernel_cl.hpp> namespace stan { namespace math { namespace opencl_kernels { // \cond static const char *scalar_mul_diagonal_kernel_code = STRINGIFY( // \e...
988201cc85b52f539451f7476fb56a8810c4ba7c
e9e58a00e9cda8f7e2a83d24a9a4d2b395d55fc4
phongt/iceoryx
/iceoryx_posh/include/iceoryx_posh/roudi/port_pool.hpp
C++
hpp
9,770
permissive
// Copyright (c) 2020 by Robert Bosch GmbH. All rights reserved. // Copyright (c) 2020 - 2022 by Apex.AI Inc. All rights reserved. // // 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 // // ...
bae0e0dee5a8a967276923030ffbb74da54c0857
261979e6f524740e4fcdcd02f816d6faa84b0388
sirikfoll/Sunwell
/src/server/scripts/Spells/spell_hunter.cpp
C++
cpp
48,807
no_license
/* * Copyright (C) * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the * Free Software Foundation; either version 2 of the License, or (at your * option) any later version. * * This program is distributed in the hope...
5f7fe3b557aefda6e937a2a81797cb48fcf5cbf2
4450561dddf7cbe65856ed954d4ae8cd8119d24a
abarth/sdk
/runtime/vm/flow_graph_compiler_dbc.cc
C++
cc
18,867
permissive
// Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file // for details. All rights reserved. Use of this source code is governed by a // BSD-style license that can be found in the LICENSE file. #include "vm/globals.h" // Needed here to get TARGET_ARCH_DBC. #if defined(TARGET_ARCH_DBC) #include ...
2d11b5f0e17fcfc24ef55f400110562c9ca67471
b9342a2325dd5226e9482e830d0d54620ba74469
kyle-ilantzis/samurai-dash
/Source/FirstPersonCamera.cpp
C++
cpp
2,596
no_license
// // COMP 371 Assignment Framework // // Created by Nicolas Bergeron on 8/7/14. // // Copyright (c) 2014 Concordia University. All rights reserved. // #include "FirstPersonCamera.h" #include "EventManager.h" #include <GLM/glm.hpp> #include <glm/gtc/matrix_transform.hpp> #include <GLFW/glfw3.h> #include <algorithm> ...
fa17e5fb7d1ce3746e9822f4ded4c9e5d603e461
96639305b63da90bb72f5519a4bcb23eed8e938c
wangvei/vasp_ldos
/command_line.hpp
C++
hpp
389
no_license
#pragma once #include <string> #include <vector> class Command_line { public: Command_line(int argc, char* argv[]); bool is_empty() const; bool option_exists(const std::string&) const; const std::string& get_option(const std::string&) const; const std::string& get_option(const std::string&, const std::string& d...
52a4c48b63b27c49af13ddbd83ae167f29727261
201a3de3f3774a2b653189ce3631e40397814683
byte4byte/cloudretro
/chrome/browser/ui/views/location_bar/location_bar_view_browsertest.cc
C++
cc
12,270
permissive
// Copyright 2018 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/ui/views/location_bar/location_bar_view.h" #include "base/bind.h" #include "base/feature_list.h" #include "base/files/file_path....
8d95217228508aacca329c5fde29925b114448f8
40531cee2cbf25c43bec68eb35ed92cb333d4b5e
tyler-lee/ssgx
/mbedtls-SGX/example/tls/m_server.cpp
C++
cpp
4,686
permissive
/* * SSL server demonstration program using pthread for handling multiple * clients. * * Copyright (C) 2006-2015, ARM Limited, All Rights Reserved * SPDX-License-Identifier: Apache-2.0 * * Licensed under the Apache License, Version 2.0 (the "License"); you may * not use this file except in compliance with...
aaf909444fb319de1a429cbb58fbe615443ac599
7a176d260aeebc8c27b0b4239460652de64cf2c2
fengjixuchui/iOS-Reverse
/Obfuscator/Source/tools/clang/lib/Driver/ToolChains/FreeBSD.cpp
C++
cpp
13,975
permissive
//===--- FreeBSD.cpp - FreeBSD ToolChain Implementations --------*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------------...
5af5bb17763048a855b7cce6e24a2e93c126722a
cd7ba229705389e9222632e590dbaeb5408d0a80
rkshkmr800/interviewbit
/backtracking/subset.cpp
C++
cpp
979
no_license
/* Given a set of distinct integers, S, return all possible subsets. Note: Elements in a subset must be in non-descending order. The solution set must not contain duplicate subsets. Also, the subsets should be sorted in ascending ( lexicographic ) order. The list is not necessarily sorted. */ vector<vector<int>> subs...
1007169e4394f99fb8ff96293011842f86901bbf
36427b824cc00ed16da419563497dd2548d12411
PierreTSE/games-factory-jam-9
/src/Utils.cpp
C++
cpp
812
no_license
#include "Utils.h" int Utils::random(int min, int max) { std::random_device rd; static std::default_random_engine eng(rd()); std::uniform_int_distribution<int> distrib(min, max); return distrib(eng); } int Utils::random(int max) { return random(0, max); } void fit(sf::Sprite & s) { const do...
5e79cad8832bad99a35079f5c233788de3dbfc7c
79a53ab1d1fa54f50693b8c0aa5585a52518c69b
AdarshkumarMR/10daysofcoding
/leftshiftarr.cpp
C++
cpp
888
no_license
#include<iostream> using namespace std; int gcd(int d,int n) { if(n==0) { return d; } else { return gcd(n,d%n); } } void leftrotate(int arr[],int d,int n) { d=d%n; int g_c_d = gcd(d,n); for(int i=0; i<g_c_d; i++) { int temp = arr[i]; int j=i; ...
a4fd984caabf72a99bfdc8bbe94b34ba9b82b1a2
a8185e4584211264a410fad32cc12e042fc0bbeb
XrosLiang/taichi
/taichi/transforms/lower_ast.cpp
C++
cpp
14,688
permissive
#include "taichi/ir/ir.h" #include <unordered_set> TLANG_NAMESPACE_BEGIN template <typename T> std::vector<T *> make_raw_pointer_list( const std::vector<std::unique_ptr<T>> &unique_pointers) { std::vector<T *> raw_pointers; for (auto &ptr : unique_pointers) raw_pointers.push_back(ptr.get()); return raw...
b362ed624154ab85f854ee0b463fd4f1da616eb2
f52e2f9e8a643c2af14a5d9bea6f4f80af0a0921
illya06/OS_LAB_11_CHAT
/Chat/mainwindow.cpp
C++
cpp
9,839
no_license
#include "mainwindow.h" #include "ui_mainwindow.h" #include <QGroupBox> #include <QLabel> #include <QMouseEvent> #include "HTTPRequest.h" #include <QJsonArray> #include <QJsonDocument> #include <QJsonObject> #include <Windows.h> #include <QTimer> #include <QScrollBar> #include <QDebug> #include <QMessageBox> #include <...
958245c79313c0943da1bf40cac85c6d009c7a14
1fc3b4a90dee56b2fdea94467e5989bde071d8b9
bullestock/ledcube
/esp32/neomatrix.hpp
C++
hpp
402
no_license
/* * Neomatrix - Copyright (C) 2017 Lars Christensen * MIT Licensed * * Main display code */ #pragma once void neomatrix_init(); void neomatrix_run(); void neomatrix_change_program(const char* name); void neomatrix_next_program(); void neomatrix_set_speed(int fps); void neomatrix_start_autorun(); void neomatrix_...
74acbb49252a105cdad3a5be960e8df396b1807c
555e5b0e27e4477e496c477deebe1a9536108c26
cdut007/screen_share
/屏幕分享例程/web_stream.cpp
C++
cpp
6,021
no_license
#include <WinSock.h> #include <vector> #include <string> #include <setjmp.h> #include <jpeglib.h> #pragma comment(lib,"turbojpeg.lib") using namespace std; #include "web_stream.h" #pragma comment(lib,"ws2_32.lib") const char* boundary = "++&&**boundary--stream-jpeg++"; web_stream::web_stream() { ::InitializeCriti...