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
dc0bde8f612e121613514fdfcd5f8078da171d26
dca01bb0e7509a30a6f50636f7d65d42a27443bc
zyex1108/OPS
/apps/c/CloverLeaf_3D_HDF5/OpenACC/advec_mom_kernel2_z_openacc_kernel.cpp
C++
cpp
8,610
no_license
// // auto-generated by ops.py // #include "./OpenACC/clover_leaf_common.h" #define OPS_GPU extern int xdim0_advec_mom_kernel2_z; int xdim0_advec_mom_kernel2_z_h = -1; extern int ydim0_advec_mom_kernel2_z; int ydim0_advec_mom_kernel2_z_h = -1; extern int xdim1_advec_mom_kernel2_z; int xdim1_advec_mom_kernel2_z_h = -1...
0fb1998d83bff3b09dcb6e1e035ed59d5d1b31ab
5f263353107be6fddc6086113b6e7fc8e7246ce3
supersegafan/ttt
/ttt/BASE64_API.cpp
C++
cpp
4,857
no_license
#pragma once #include "stdafx.h" #include "BASE64_API.h" static const CHAR* DATA_BIN2ASCII = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; INT BASE64_Encode( const BYTE* inputBuffer, INT inputCount, TCHAR* outputBuffer ) { INT i; BYTE b0, b1, b2; if( (inputBuffer == NULL) || (input...
c6ec3eb315fc590cd59c484b4853ee7e6833a8d3
164a571b3407398875d00607c16bfbdc4c2f9365
mitache2000/OOP
/OOP/Crypto/Zad1.cpp
C++
cpp
307
no_license
#include<iostream> #include "Crypto.h" int main() { Crypto crypto1; crypto1.setName("Name"); crypto1.setCurrentPrice(100); crypto1.setLastPrice(50); crypto1.print(); std::cout << "The price difference is: " << crypto1.priceDifference() << "%" << std::endl;; }
2bb0c0167270f440129de92284156d38d1494221
c11b7f0706e2f66aa568f7d57669845fd6fa4c85
4k1k0/estructuras-datos-cpp-ipn
/MetodosOrdenamiento/seleccion.cpp
C++
cpp
964
no_license
#include<iostream> using namespace std; class seleccion{ private: char r = 'S'; int temporal, minimo; int numeros[5]; public: void loop(); }; int main(){ seleccion b; b.loop(); return 0; } void seleccion::loop(){ while(r != 'N'){ system("cls"); for(int i = 0; i < 5; i++){ c...
7bd8b4be3a2005de3f6b3de8aea5eab860a5ce92
dd765f5d31d65564fea858ae05da832d991c04d2
gems-uff/oceano
/core/src/test/resources/CPP/neopz/Material/TPZMulticamadaOrtho.cpp
C++
cpp
16,057
permissive
/** * \file * @brief Contains implementations of the TPZMulticamadaOrthotropic methods. */ #include "TPZPlacaOrthotropic.h" #include "TPZMulticamadaOrtho.h" #include "pzmatorthotropic.h" #include "pzgmesh.h" #include "pzintel.h" #include "pzgeoel.h" #include "pzbctension.h" //#include "pztempmat.h" #include "pzanal...
11407c9636c602c6b861443135230a13a4857b8c
03eeed9b340891234184edb38b8b0b3f1ef01963
bgin/lrose-core
/codebase/apps/radar/src/TsPrint/TsPrint.cc
C++
cc
62,778
permissive
// *=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=* // ** Copyright UCAR (c) 1990 - 2016 // ** University Corporation for Atmospheric Research (UCAR) // ** National Center for Atmospheric Research (NCAR) // ** Bo...
80035f6f01c16a8e6e141ce6b02787dd5d2e037b
87fef4b34d5b453785a4a7289838351793cb137f
KqSMea8/sstd_library
/sstd_boost/sstd/libs/log/test/run/form_date_time.cpp
C++
cpp
8,403
permissive
/* * Copyright Andrey Semashev 2007 - 2015. * 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) */ /*! * \file form_date_time.cpp * \author Andrey Semashev * \date 07.02.2009 * * \bri...
33914b4683b0cf475794ba79b6830ae457a2b05c
0f7b0d4222c507e8dbe647894e22bfbfee3eef16
ai-sf/perugia
/_site/ROOT/readTree.cpp
C++
cpp
1,012
permissive
void T(){ //in questo caso ho un flle.root che contiene un Tree (nome: SFS Data) // il tree è composto da 1 branch(nome branch: SFS - N) e 2 leaf struct dato { float x; float errx; }; dato dx,dy; auto infile = TFile::Open("/Users/...
85c99b11ccf243f0b87483f6c28b571b736eeeb1
49c5060e762fe9f5b4b648f0b7fe88f5ea7cb26f
kvv81/dsb
/dsb_console_visual.cpp
C++
cpp
1,025
no_license
#include <iostream> // for std:cout #include "common/all.h" #include "algo/api/dsb_algo_api.h" void dsb_console_visual_show_next_shot(const PlacementInfo& field, const DSBAlgoGenricData& gdata, bool is_combined, const FieldCoords* coords = NULL) { for (int i=0; i<FIELD_SIZE*2+2; ++i) { std::cout << "="; } std:...
80c9bfcb28eeaa33a50c008c7098a93e09743023
96a4fc2107c90c20deb1a0aaca031c35b89e61cb
cumtmiao/Algrithm
/2017xiaozhao/codeM2018/shijiebei.cpp
C++
cpp
4,778
no_license
/* 世界杯就要开始啦!真真正正的战斗从淘汰赛开始,现在我们给出球队之间的胜负概率,来预测每支球队夺冠的可能性。 在接下来的篇幅中,我们将简单介绍淘汰赛阶段的规则。 淘汰赛阶段的90分钟常规时间内(含补时阶段)进球多的球队取胜,如果参赛双方在90分钟内(含补时阶段)无法决出胜负,将进行上下半场各15分钟的加时赛。加时赛阶段,如果两队仍未分出胜负,则通过点球大战决出胜者。也就是说,每场比赛,有且仅有一个队能够晋级到下一轮。 淘汰赛共有16支球队参加(小组赛阶段共分8个小组,每组前两名晋级),对阵安排如下。 1/8决赛 A组第一对阵B组第二=胜者1 B组第一对阵A组第二=胜者2 C组第一对阵D组第二=胜者3 D组第一对阵C组第二=胜者4...
156a346c943c4824daa7a1c6e26991471cf4bf28
c45faf28b095ceb88002afd79e13bff3915b62fd
syouzen/sample_server2
/src/client/sample_client.cc
C++
cc
1,125
no_license
#include "client/sample_client.h" #include <sys/socket.h> #include <sys/types.h> #include <sys/un.h> #include <fcntl.h> #include <unistd.h> #include <cstdio> #include <cstring> namespace Client { const int BUFF_SIZE = 1024; static const char* SOCKET_PATH = "/tmp/sample_server2.socket"; SampleClient::SampleClient()...
10d1e75ed800877b4c29b8f65a6254510be1efd8
cb2106a809322edd47ba4bd4f22ced0a8a36e6f6
rjianwang/SimpleCV
/cn_vehicle_plate_recognition/src/core/proj_cut.cpp
C++
cpp
1,901
no_license
#include <stdlib.h> #include "../../include/core/proj_cut.h" namespace pr { int detectionChange(cv::Mat& mat1, cv::Mat& mat2, int number) { IplImage pI_1 = mat1, pI_2; cv::Scalar s1, s2; int width = mat1.rows; int height = mat1.cols; int sum = 0, sum_2 = 0, width_1 = 0, width_2 = 0; int i, j; for(i = 0; i < w...
18e1a4bc55662d55ed761295f493674d2b721aaf
64418dbb8cccdfe9abe4af383ac5cd3260adae9d
DestructionCatalyst/Lab_1_sem3
/Lab_1_sem3/Timer.cpp
C++
cpp
293
no_license
#include "Timer.h" void Timer::Start() { if (!running) { startTime = clock(); running = true; } } void Timer::Pause() { if (running) { clocks += clock() - startTime; running = false; } } int Timer::GetMS() { if (running) clocks += clock() - startTime; return clocks; }
be7bc0282d69060d1df7660ea72845cff2338d16
e0ac9de29cff7ebef46ad24a001ffdd93ce84f49
fayazsk25/polycube
/src/polycubed/src/cube_tc.cpp
C++
cpp
7,471
permissive
/* * Copyright 2016 PLUMgrid * Copyright 2017 The Polycube Authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required...
beee8f358cf50a30fe66eb7fa4085b8cba83cbaf
f16cf5458aa19f3bb05b09bcb563259bebb317c0
pdxcodemonkey/geode-native
/clicache/src/PoolFactory.hpp
C++
hpp
17,585
permissive
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may ...
745cf77b81127787c73941451454480667128466
06a9749753d67b8b215d3adb80777b7bec53fdb6
Kawser-nerd/CLCDSA
/Source Codes/CodeJamData/15/01/19.cpp
C++
cpp
766
no_license
#include <stdio.h> using namespace std; #define MAXN 1005 int cas, n, l, r, mid, ans; char ch[MAXN]; int a[MAXN]; bool solve(int x) { int res = x; for (int i = 0; i <= n; i ++) if (a[i] > 0) if (res >= i) res += a[i]; else return false; return true; } int main() { freopen("...
2760b42726ea9cf0874b031ef412344325b6d9b5
0249f930a7256f0e2e3c978e2a1f7ba7acdf6d03
ScarlettDixon/2-UoL-2nd-Year
/OOProgramming/Work7/Work7/Work7/Task3.cpp
C++
cpp
340
no_license
#include <iostream> #include <string> #include "Task3.h" using namespace std; Messenger::Messenger() { } Messenger::Messenger(string a) { def = a; } Messenger::~Messenger() { } void Messenger::print() { cout << def << endl; } void Messenger::print(string b) { cout << def << endl; c...
f7d2c19b59efb252587683f26bd227772f5eaa44
82cb3ffa7d4d5cb99f1592ac0379f02871531697
KZ137onethe/Project
/机房预约系统/机房预约系统/main.cpp
C++
cpp
1,390
no_license
#include"public.h" #include"globalFile.h" int main() { start:Main_menu();////主菜单 char select[2]; while (1) { int c = getch(); if (c ==13) break; } InputBox(select, 2, "请输入选项:"); int s = (int)select[0]; while (!(48 == s || 49 == s || 50 == s || 51 == s)) { InputBox(select, 2...
2e6fba2702e4490d701b2ff36cdc0988fefd5389
525da172f0cd358c628b93ffcf63ed16e5fadf5f
bittorrent/aws-sdk-cpp
/aws-cpp-sdk-ec2/source/model/VpcPeeringConnectionVpcInfo.cpp
C++
cpp
3,142
permissive
/* * Copyright 2010-2016 Amazon.com, Inc. or its affiliates. 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. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file...
df9578cdd4f7ff3e22fbcf01d381b0f0b58b31e6
dbaedcfb8c0e4417bccd64f25f0ab5cc61c9aea1
the-stranded-alien/Competitive_Programming_CPP
/13_Graph/07_Shortest_Paths/01_Single_Source_Shortest_Path_Unweighted.cc
C++
cc
1,575
no_license
#include<bits/stdc++.h> #define ll long long int #define ld long long double #define pb push_back #define F first #define S second #define P pair<int, int> #define MOD 1000000007 #define FIO ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL) using namespace std; // Single Source Shortest Path (SSSP) Using...
be998275ae5820832eafdb6981bbe6316761d2ce
3c13973e34cbdba8cd9d2db69dca8035864f5712
rrd0627/BaekJoon
/11048.cpp
C++
cpp
361
no_license
#include<iostream> #include<vector> #include<algorithm> using namespace std; int main() { int N, M; cin >> N >> M; int arr[1001] = { 0, }; int temp; for (int i = 1; i <= N; i++) { for (int j = 1; j <= M; j++) { cin >> temp; arr[j] = max(arr[j - 1]+temp, temp + arr[j]); ...
9e871330c4d2eedcb784d0be75cd35e7dbf751b7
dc81ad30bb12acd51612e4f6da6be26fca92a688
SymbianSource/oss.FCL.sf.os.bt
/bluetooth/btstack/rfcomm/rfcommflow.cpp
C++
cpp
15,987
no_license
// Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies). // All rights reserved. // This component and the accompanying materials are made available // under the terms of "Eclipse Public License v1.0" // which accompanies this distribution, and is available // at the URL "http://www.eclipse.org/legal/e...
0a2645add55660282bd1fbfe44ea5bc5beec49c9
0a25456af49f6e920b7879cd1c04d70fed57f983
babennettdev/ece488_senior_design_asee_robot
/Retriever_Library/Retriever.cpp
C++
cpp
1,906
no_license
#include "Retriever.h" /* * * Retriever Constructor * * takes in an array as pins for the 5 servos on the module * * Lever Left Servo * Lever Right Servo * Rotate Left Servo * Rotate Right Servo * Gripper Servo * */ Retriever::Retriever(int pins[5]) { retrieverPins.lever_right = pins[0]; retrieverPins.lev...
d7a45f74ac1e7052d1dd20813e27e5576b52996c
674118b7491da615b2ecdae646cc51b8baa6e423
zhongzw/skia-sdl
/src/gpu/gl/GrGLUniformManager.cpp
C++
cpp
12,773
permissive
/* * Copyright 2012 Google Inc. * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #include "gl/GrGLShaderBuilder.h" #include "gl/GrGLProgram.h" #include "gl/GrGLUniformHandle.h" #include "gl/GrGpuGL.h" #include "SkMatrix.h" #define ASSERT_ARRAY_UPLOAD_IN_B...
63e6517a08de85bc5cff6f72c61162d359832299
76dcbd16a4ca0fd6774bd177c3378be34adb8c00
Blackstate/Sot-SDK
/SDK/BP_Audio_Play_Wwise_Event_functions.cpp
C++
cpp
2,116
no_license
// Name: SoT, Version: 2.1.0.1 #include "../SDK.h" /*!!DEFINE!!*/ /*!!HELPER_DEF!!*/ /*!!HELPER_INC!!*/ #ifdef _MSC_VER #pragma pack(push, 0x01) #endif namespace CG { //--------------------------------------------------------------------------- // Functions //----------------------------------------------------...
329460d2928efe681b5666de2f031ca05d98a8ef
cd90861ba38c3ce90a0a15909e9d006de394e770
DDan1l232/SoT-SDK
/SDK/SoT_BP_PetPreview_Parrot_parameters.hpp
C++
hpp
375
no_license
#pragma once // Sea of Thieves (2.0.17) SDK #ifdef _MSC_VER #pragma pack(push, 0x8) #endif #include "SoT_BP_PetPreview_Parrot_classes.hpp" namespace SDK { //--------------------------------------------------------------------------- //Parameters //-------------------------------------------------------------------...
45eebdc0e10e16caa94d3c3c0bcdf84c391ce47a
971a62da08533ddd65bec6035a56a543ce24dd72
FHB369/androidNDKPlayground
/app/src/main/cpp/name-generator-lib.cpp
C++
cpp
576
no_license
// // Created by fhb36 on 06-Sep-20. // #include "name-generator-lib.h" #include <jni.h> #include <string> using namespace std; extern "C" JNIEXPORT jstring JNICALL Java_com_spectrum_androidndkplayground_MainActivity_generateRandomName( JNIEnv *env, jobject /* this */, jint age) { string ...
58d05c9b3a177af94edcd15264f6f57714341708
1266a878b93468c45ce892e2f3fc89a8f9fc8ba9
smessmer/ctpc
/test/parsers/integer_test.cpp
C++
cpp
2,962
no_license
#include "parsers/integer.h" #include <gtest/gtest.h> using namespace ctpc; namespace { namespace test_numeric_type { static_assert(std::is_same<std::remove_cv_t<std::remove_reference_t<decltype(numeric()(std::declval<Input>()).result())>>, char>::value); } namespace test_numeric_failure { constexpr auto par...
e5b28487679f34de2c48c53aca70374dd5ceb7f4
0f534ff281804d19acd073a439df981786d9e14d
liyoung1992/mediasoup-sfu-cpp
/deps/boost/include/boost/spirit/home/karma/directive/as.hpp
C++
hpp
5,741
permissive
// Copyright (c) 2001-2011 Hartmut Kaiser // Copyright (c) 2010 Bryce Lelbach // // 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) #ifndef BOOST_SPIRIT_KARMA_DIRECTIVE_AS_HPP #define BOOST_SPIRIT_KARM...
b68a624df286fc0a54894a5ffcfc7d3d33244ff9
a763dcafa2c70fbc99e83088ca81c336d2cec4e0
jmservera/IoTHubDemo
/IoTSensors/DHTReader/DHTReaderClass.cpp
C++
cpp
4,595
permissive
#include "pch.h" #include "DHTReaderClass.h" #include "SensorData.h" using namespace DHTReader; using namespace Platform; using namespace Windows::Devices::Gpio; void DHTReader::Dht11::Init(GpioPin^ Pin) { // Use InputPullUp if supported, otherwise fall back to Input (floating) this->inputDriveMode = Pin->IsDri...
d89cb637391f5d6da49c7485a2fd583ce061b6d5
aecd7b99adde57bf5aae792781fa50d5281aeae5
luizalbertocviana/data-structures-cpp
/tests/matrix.cpp
C++
cpp
1,282
no_license
#include <cassert> #include <matrix.hpp> void test_matrix(){ Matrix<bool> m {3, 4}; m.at(0,0) = false; m.at(1,1) = true; assert(m.at(0,0) == false); assert(m.at(1,1) == true); } void test_square_matrix(){ SquareMatrix<bool> m {4}; m = true; m.at(0,0) = false; m.at(3,2) = false; assert(m.at(0...
5e313b37d22003dd7069279edaf97e16312db94d
31e0288b24a54fff4bbbe432768723f75981eba0
moviepasscoin/moviepass
/src/kernel.cpp
C++
cpp
16,343
permissive
// Copyright (c) 2012-2013 The PPCoin developers // Copyright (c) 2014 The MoviePass developers // Distributed under the MIT/X11 software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include <boost/assign/list_of.hpp> #include "kernel.h" #include "txdb....
c52e4a2d9149d4cdcdf3a8d2403c71695e654501
b120bb86160f06961063924a3f5e8b6aa4b51064
trangnt2304/cwe_checker_juliet_suite
/testcases/CWE321_Hard_Coded_Cryptographic_Key/main.cpp
C++
cpp
29,437
permissive
/* NOTE - eventually this file will be automatically updated using a Perl script that understand * the naming of test case files, functions, and namespaces. */ #include <time.h> /* for time() */ #include <stdlib.h> /* for srand() */ #include "std_testcase.h" #include "testcases.h" int main(int argc, char * argv[...
663bcecf632581e5e14b898c61623be2fe4b5de1
77b27f8e7531eea18ed3aa504cf5172bb2b75428
sytu/cpp_primer
/ch07/7_3_usemember.cpp
C++
cpp
754
no_license
#include "Sales_data.h" #include <iostream> #include <string> using namespace std; int main(void) { Sales_data total; if (cin >> total.bookNo >> total.units_sold >> total.revenue) { Sales_data trans; while (cin >> trans.bookNo >> trans.units_sold >> trans.revenue) { if (trans.isbn() == total.isbn()) { tot...
71d01ae5478cb42b44a7bf9ed3970f5382be80de
5e765401028c21abb16a60509d74fdf87501c515
wilsjame/misc-algos
/atcoder/ABC/078/C-HSI.cpp
C++
cpp
310
no_license
#include <iostream> using namespace std; int main() { int N, M; cin >> N >> M; // one try int time = 1900 * M + 100 * (N - M); // each M takes two tries because of the 1/2 probability for (int i = 0; i < M; i++) { time *= 2; } cout << time << endl; return 0; }
7685c5e3d22585247292ce6105c0b0ec7de3500a
2c85f4586a3259703465b08fdccaa1a840b26af2
kkribakaran/cs170
/phash1.cc
C++
cc
4,873
no_license
#include <iostream> #include "phash.h" LinkedHashEntry:: LinkedHashEntry(int key, int value) { this->key = key; this->value = value; this->next = NULL; } int LinkedHashEntry:: getKey() { return key; } int LinkedHashEntry:: getValue() { ret...
36c89aa1e14b293293f3368c72a95dbdad9b5a7f
f695c1b7a7fdff5f7d92e7d552354b35ba4737d8
microplc/Interrupted
/msp430g2553/timer.cpp
C++
cpp
524
permissive
#include <Energia.h> #include "atomic.h" #include "device.h" #include "timer.h" static Device *d; #pragma vector=TIMER1_A0_VECTOR __interrupt void timer1_a0(void) { if (d) d->ready(); __bic_SR_register_on_exit(LPM1_bits | GIE); } bool Timer::begin() { d = this; return false; } voi...
4018df3d7ed4019028da349fb124f6231f3afeb9
c02b64b3ab1988816481a5821ce405871a426636
j201/word-game
/src/game.cpp
C++
cpp
4,251
no_license
#include <fstream> #include <iostream> #include <algorithm> #include <stdexcept> #include <stdlib.h> #include "game.h" Dictionary::Dictionary(std::string filepath) { std::ifstream ifs; ifs.open(filepath); for (std::string line; std::getline(ifs, line);) { words.push_back(line); } if (words.size() == 0) { std:...
28d903b5296daca4470534a5b39c2abfb6230ed0
0c63a9ef7b8ed36b2b28645115de0bfe2db561a1
Adam5Wu/ZWUtils-CPP
/main/src/cpp/SvcGuest/ServiceCtrl.cpp
C++
cpp
23,481
permissive
// [AdvUtils] Generic System Service Interface #include "Misc/Global.h" #ifdef WINDOWS #include "ServiceMain.h" #include "Misc/Timing.h" #include "Debug/Logging.h" #include "Debug/Exception.h" #include "Debug/SysError.h" #include "Memory/Resource.h" #include <Windows.h> #include <ktmw32.h> ...
c4f28cf5ac856700a9ce666e29f8e64cb77b05ad
a958f7f27faf8ef8b5ab5774d2d2841ddad675d2
M4573R/UVa-Online-Judge-1
/12172 - Matchsticks/12172 - Matchsticks.cpp
C++
cpp
2,123
no_license
//****************************************************************** // Author: Huynh Nhat Minh // Problem Name: 12172 - Matchsticks // Verdict: //****************************************************************** #include <iostream> #include <iomanip> #include <cstdio> #include <algorithm> #include <cstring> #include...
466915600e271fac3102d55a0851ea2ed1702fc1
751dcf8ca332cee4989acc9f3521c2a32660f78a
LiuLiC/LeetCodePractice
/algorithm/31.next-permutation.cpp
C++
cpp
1,335
no_license
/* * @lc app=leetcode id=31 lang=cpp * * [31] Next Permutation * * https://leetcode.com/problems/next-permutation/description/ * * algorithms * Medium (30.12%) * Total Accepted: 220K * Total Submissions: 730.2K * Testcase Example: '[1,2,3]' * * Implement next permutation, which rearranges numbers into ...
44f9f1c3aa9c1023a09134d916f1abe42296fd37
fb34529666fd1e82170dda5a080194bd61836c6b
cbarnson/codeforces-cpp
/accepted/268A.cc
C++
cc
605
permissive
// Problem # : 268A // Created on : 2018-10-14 15:54:57 #include <bits/stdc++.h> #define FR(i, n) for (int i = 0; i < (n); ++i) using namespace std; typedef long long ll; typedef pair<int, int> ii; typedef vector<int> vi; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); ...
3736c5147ef83570149ef3847da72a3c084a3d8e
74b3526101400972171ac684558b2287061667d7
Daniil-KOT/Geekbrains_OOP
/OOP_HW3/OOP_HW3.cpp
C++
cpp
9,996
no_license
#include <iostream> #include <string> #include <cassert> using namespace std; //================EX.1================ //Создать абстрактный класс Figure(фигура).Его наследниками являются классы Parallelogram(параллелограмм) и Circle(круг). //Класс Parallelogram — базовый для классов Rectangle(прямоугольник), Square(к...
073884dc20c93d7a4b64b963e0b2adc30e86525a
44ed8bfd3532ac2395d4054d1780677700cf80e5
aydemir/PrototypeRenderer
/src/renderer/VkSwapchain.cpp
C++
cpp
3,472
no_license
// PrototypeRenderer Source Code // Copyright (c) 2014-2016, Daemon Developers // 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 copy...
6d94a975297077d84c453292eed3e35817ed6158
08f99770934bcddaa5366fd8612eb8e101f6624f
eval1749/evm
/test/CgTest/CgFunctorTest.cpp
C++
cpp
3,159
no_license
#include "precomp.h" // @(#)$Id$ // // Evita Char Test // // Copyright (C) 2010 by Project Vogue. // Written by Yoshifumi "VOGUE" INOUE. (yosi@msn.com) #include "./CgTest.h" #include <ostream> #include "Cg/CgFunctor.h" namespace CgTest { using namespace Il::Cg; class CgFunctorTest : public ::testing::Test { }; cl...
6642e361a2c9145f8cb5bb9a22a7afab51671f9c
aac2b9d5acff62cd77ff1e20ed933ee2938b6256
EdgarH90/FinalProject
/FinalProject/blackMarket.cpp
C++
cpp
1,082
no_license
/******************************************************************************* ** Author: Edgar Hernandez ** Date: 12/1/2019 ** Description: This program contains the implementation of the black market class. ** This class is derived from the base Space class. ******************************************...
287c37f90a8da2e1649f7d9244997bf0fb7651cd
e9c9522d1e130737ce9fc057e3c611343916c08b
pmdiano/shuati
/cpp/074-Search-a-2D-Matrix/solution.cpp
C++
cpp
650
no_license
class Solution { public: bool searchMatrix(vector<vector<int>>& matrix, int target) { if (matrix.empty() || matrix[0].empty()) return false; int m = matrix.size(); int n = matrix[0].size(); int start = 0; int end = m*n - 1; int mid; ...
e4298b2d066c4ea6ea69be4ba700f4efba1db386
c977bf3e40678e613024c9332342a97f8d9549c7
valentina-kustikova/practice1-devtools
/src/filters_factory.cpp
C++
cpp
433
no_license
#include "filters.hpp" Filters* createFiltersOpenCV(); // Declare your implementation here // Filters* createFiltersYourName(); Filters* createFilters(FILTERS_IMPLEMENTATIONS impl) { switch (impl) { case OPENCV: return createFiltersOpenCV(); // Add case for your implementation ...
d041e3931911343e85ab49d63530491e8f8f2b80
230b0338dcc9b49bf583889124a11ff29903ed91
OperaBed/TMSWIFT
/src/read_file.cpp
C++
cpp
435
no_license
void read_ofile(std::string file_name, std::vector<double> *vec) { std::string line; std::fstream infile; infile.open(file_name.c_str()); while (std::getline(infile, line)) { std::istringstream iss(line); double a; if ((iss >> a)) ...
d57ec2c1c3d5b9bc324581ec4a3cf021f0aca694
cbc45702f37ff6191825f771afd1e27533365730
afishbeck/eclide
/eclide/ChildAttributeFrame.cpp
C++
cpp
20,905
permissive
#include "StdAfx.h" #include "..\en_us\resource.h" #include "ChildAttributeFrame.h" #include "WtlMDIChildFrame.h" #include "ChildEclFrame.h" #include "MainFrm.h" #include "Repository.h" #include "attribute.h" #include "HistoryView.h" #include "attributehistory.h" #include "TabbedChildWindowEx.h" #include <preferencedl...
8aa34fabccfb68fdea04c5abc11a8cdc4b29a1b9
8640861df866ed375752ddf431d36ede47bb16f4
kai6424/Gasyori100knock
/Tutorial/plot.cpp
C++
cpp
206
permissive
#include <matplotlib-cpp/matplotlibcpp.h> namespace plt = matplotlibcpp; int main() { plt::plot({1, 3, 2, 4}); // output(jpgでエラーになる) plt::save("plot.png"); return 0; }
fb80d229d0d31c064bafd3f24b4cc481b2edf272
e1d42eab77e1e6d7c162d66c9498268b02082bba
Mayavan/dog_fetch_machine
/src/include/ModeManager.hpp
C++
hpp
1,312
permissive
/** * @file ModeManager.hpp * @brief RRT Planner - Class to manage map image information and plot the planned path * @author RajendraMayavan, Kathelyn Zelaya * @copyright MIT License * Copyright (c) 2020 Mayavan Kathelyn * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this ...
12f0d42ebbb299aa901dda8c7f6516acbf06a03e
a760934382a32cba12beff9c010d750afc7e33b8
mkurdej/boost.simd
/test/function/simd/split/arithmetic.low.cpp
C++
cpp
1,500
permissive
//================================================================================================== /** Copyright 2016 NumScale SAS Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt) **/ //====================================...
4419eda9a66fbebb17f9a8380f1b7099441edf8a
f44e00f85601a12880d1faaac77fda1999d9ca5c
ilaplace/hashtable
/src/undered.cpp
C++
cpp
1,235
no_license
/*unordered map is used to implement hash tables. It store key, value pairs. For every key value, a hash function is computed and value is stored at that hash entry. params: key type, mapped value*/ #include <iostream> #include <unordered_map> using namespace std; struct Person { string first, last; Person...
3660ccde62d5677be57ea2028c62e3229abec6c5
1aa0314a5dab54e1cf94323d7d88de9763e427c5
kmjp/procon
/yuki/0001-1000/301-400/329.cpp
C++
cpp
1,320
no_license
#include <bits/stdc++.h> using namespace std; typedef signed long long ll; #undef _P #define _P(...) (void)printf(__VA_ARGS__) #define FOR(x,to) for(x=0;x<(to);x++) #define FORR(x,arr) for(auto& x:arr) #define ITR(x,c) for(__typeof(c.begin()) x=c.begin();x!=c.end();x++) #define ALL(a) (a.begin()),(a.end()) #...
4a2cc62b96bb9dc1522e37ec4482bdc91f583641
4655c65742ef030031f73041adaadb7dad0f56b5
wsxst/MyNachos4.1
/code/threads/thread.cc
C++
cc
22,135
permissive
// thread.cc // Routines to manage threads. These are the main operations: // // Fork -- create a thread to run a procedure concurrently // with the caller (this is done in two steps -- first // allocate the Thread object, then call Fork on it) // Begin -- called when the forked procedure starts up, to turn // inte...
269d34837e3c09cc0043bdd40463f2268b12ade5
6f4ac29928a48fa6bdb07fec593e1ee284c4e77e
nitrogendragon/C-SDL2
/SDL2_Game_Engine/GameObject.cpp
C++
cpp
1,331
permissive
#include "GameObject.h" #include"TextureManager.h" // creates and renders our gameobject based off the texturesheet, positions, and given dimensions / scaling based off of source dimensions GameObject::GameObject(const char* texturesheet, int x, int y, int srcRectH, int srcRectW, float hScale, float wScale) { objText...
731d9cb02a1d256f2c92bea5da60e6f074852a04
1c2df174b5d5a4fde12fe1334e44a00644a07980
kmjp/procon
/srm/661-680/670/Drbalance.cpp
C++
cpp
2,361
no_license
#include <bits/stdc++.h> using namespace std; typedef signed long long ll; #undef _P #define _P(...) (void)printf(__VA_ARGS__) #define FOR(x,to) for(x=0;x<to;x++) #define FORR(x,arr) for(auto& x:arr) #define ITR(x,c) for(__typeof(c.begin()) x=c.begin();x!=c.end();x++) #define ZERO(a) memset(a,0,sizeof(a)) #d...
8dd5719b84d58eca0df9b8e582f81296e37400da
660596b12e245a32ec0121dd81fcdcbb9f78e6e9
hhyc2/Baekjoon
/11051.cpp
C++
cpp
346
no_license
#include<stdio.h> #pragma warning(disable:4996) int DP[1001][1001]; int main() { int N, K; scanf("%d %d", &N, &K); for (int i = 0; i <= N; i++) { for (int j = 0; j <= i; j++) { if (i == 0 || i == j) DP[i][j] = 1; else DP[i][j] = (DP[i - 1][j - 1] + DP[i - 1][j]) % 10007 ; } } ...
6a3f7e91c62d948d71d23657d86b72c018b86dc2
570e3caa0559f29a3741632ede0ffeebe8047c92
BugBiteSquared/vk_renderer
/vk_renderer/FinalPass.cpp
C++
cpp
6,389
no_license
#include "FinalPass.h" #include <array> #include "Scene.h" #include "VkPool.h" void FinalPass::initAttachments() { colorAttachment = {}; colorAttachment.format = VkEngine::getEngine().getSwapchainFormat(); colorAttachment.samples = VK_SAMPLE_COUNT_1_BIT; colorAttachment.loadOp = VK_ATTACHMENT_LOAD_OP_CLEAR; co...
f38fd5a95cd5d1ec807adfe7c937a888f238d0ee
5aa8214e48d2ada4653a8b621ae20fe198dd69d7
cylcq/myProject
/chengyang/pptSwtich/pptSwtichDoor/kcentralwidget.cpp
C++
cpp
3,008
no_license
#include "kcentralwidget.h" #include "ksliderpptlist.h" #include "kswitchview.h" #include "kdoor.h" #include "kprestige.h" #include <QColor> #include <QColorDialog> #include <QLabel> #include <QDoubleSpinBox> #include <QPainter> #include <QPaintEvent> KCentralWidget::KCentralWidget(QWidget *parent) : QWidget(parent) ...
da949ba2cfddf8d52508b6a64f559bb1ad26e203
cffa0f3c4b6cf8afd9366bb1f3988b44a81eae7d
theJones00/tink
/cc/hybrid/hybrid_decrypt_wrapper.cc
C++
cc
4,130
permissive
// Copyright 2017 Google 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.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in ...
55431f28fe99fbe5e03b1b8e2900c177f9e2c964
22cb1e4942a82ed034487d17c21002e8953092f1
bornunez/SMSM
/Src/MotorEngine/ResourcesManager/ResourcesManager.cpp
C++
cpp
463
no_license
#include "ResourcesManager.h" ResourcesManager* ResourcesManager::instance = 0; ResourcesManager* ResourcesManager::GetInstance() { if (instance == 0) { instance = new ResourcesManager(); } return instance; } ResourcesManager::ResourcesManager() : localizationManager_(LocalizationManager()) ...
f4583df0b9aedd566959b59ef876fa20ca58e3d0
e44fed870593ec8f7393f25c797407a0a2f58f54
fjiaqi/pylith
/tests/libtests/faults/data/CohesiveKinDataQuad4e.hh
C++
hh
3,516
permissive
// -*- C++ -*- // // ====================================================================== // // Brad T. Aagaard, U.S. Geological Survey // Charles A. Williams, GNS Science // Matthew G. Knepley, University at Buffalo // // This code was developed as part of the Computational Infrastructure // for Geodynamics (http://...
b96868aa6271aa40562dec04ea63812e87002fb9
7985f3e2a84a19fef438781c280f875510d7ad35
Snouzle/Phase-E-Robot-Name
/Phase_D/controllers/Phase_D/RemoteMapBuilder.cpp
C++
cpp
987
no_license
#include "RemoteMapBuilder.hpp" RemoteMapBuilder::RemoteMapBuilder(std::unique_ptr<Robot> &robot): MapBuilder{robot} {} char RemoteMapBuilder::getNextMotion() { Keyboard *keyboard = getKeyboard(); int key {keyboard->getKey()}; while (step() != -1) { if (key == 'W' && !isWall((int)Wall::FRONT)) ...
6e83efb076f16007fbb978b665243f4f31f3576f
4d7291399c1ba07e14a167976877c8900e4307ba
khangsile/algorithms_prime_numbers
/main.cpp
C++
cpp
9,278
no_license
/* * File: main.cpp * Author: KhangSiLe * * Created on September 24, 2012, 10:10 PM */ #include <cstdlib> #include <vector> #include <iostream> #include <sstream> #include <cmath> #include <sys/time.h> using namespace std; void subtract(vector<int> bin1, vector<int> bin2, vector<int>& difference); void divid...
266e37d7cb70543b8f611caff63ecedcb8c8cc41
2775dc78f62336e3774977adde12a3a15bb09047
koson/Oscilloscope_STM32F746
/touchgfx/framework/source/touchgfx/containers/clock/AnalogClock.cpp
C++
cpp
8,144
no_license
/****************************************************************************** * * @brief This file is part of the TouchGFX 4.7.0 evaluation distribution. * * @author Draupner Graphics A/S <http://www.touchgfx.com> * ****************************************************************************** * * @sec...
44fb55e99f22c7d2b0892234b170269a1737a900
98323980d46d2f63cc56cf4fc811f83045d59b86
ComputerStudyBoard/chromiumos-platform2
/chromeos-dbus-bindings/adaptor_generator_test.cc
C++
cc
12,625
permissive
// Copyright 2014 The Chromium OS 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-dbus-bindings/adaptor_generator.h" #include <string> #include <vector> #include <base/files/file_path.h> #include <base/files/file...
696e0fd934b3d9b74c534383cc07f3fa982382be
7c543118db536ff6829a6d9fa661d8e4e74a06a1
bodokat/EPROG
/serie11/fractionVector.cpp
C++
cpp
1,930
no_license
#include "fractionVector.hpp" FractionVector::FractionVector () { len = 0; coeff = (Fraction*) 0; } FractionVector::FractionVector (int len, Fraction fill) { assert(len >= 0); this->len = len; if (len > 0) { coeff = new Fraction[len]; for (int i = 0; i < len; i++) { coeff[i] = fill; } } }...
128fcba9fc2027b08cbc62a1379be64a6d53f8f5
eec70012f4864224dfc0d2fe0e6bca02575cc7ba
imfht/chromium
/chrome/browser/chromeos/login/existing_user_controller.cc
C++
cc
71,636
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 "chrome/browser/chromeos/login/existing_user_controller.h" #include <memory> #include <utility> #include <vector> #include "base/barrier_cl...
ab6fe7db328babe3c923f666757016af55aa18c7
fd9937037b89155af0051878a25b8fdf15eb83a3
dycforever/program
/cpp_prog/efficiency/lock.cpp
C++
cpp
1,166
no_license
#include<stdlib.h> #include<stdio.h> #include<unistd.h> #include<pthread.h> typedef struct ct_sum { int sum; pthread_mutex_t lock; }ct_sum; void * add1(void * cnt) { pthread_mutex_lock(&(((ct_sum*)cnt)->lock)); int i; while (1) { // for( i=0;i<50;i++) // { // while (1) // (*(ct_su...
23162584ee1b19deb1fe7194321992614dbbbede
9234a9fcc7f290c9a53d4f7ba12b0f57a81ffdfe
aws/aws-sdk-cpp
/src/aws-cpp-sdk-s3-encryption/source/s3-encryption/modules/CryptoModule.cpp
C++
cpp
27,562
permissive
/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #include <aws/s3-encryption/modules/CryptoModule.h> #include <aws/core/utils/logging/LogMacros.h> #include <aws/core/utils/HashingUtils.h> #include <aws/core/utils/crypto/CryptoStream.h> #include <aws/c...
18cb86c1f42a876fa1fbd3385ea9735d151836ce
033ef071e36cfe90b3ddee7421f9b361c5ceddbc
MartinMosqueira/Computacion-2018-MartinMosqueira
/Sources/Trabajo practico 06/Consigna 2/main/src/Apilar.cpp
C++
cpp
1,130
no_license
/* * Apilar.cpp * * Created on: 11 jun. 2018 * Author: Martin Mosqueiraa */ #include "Apilar.h" #include "nodo.h" #include <iostream> using namespace std; Apilar::Apilar() { superior=NULL; } nodo* Apilar::getsuperior(){ return superior; } void Apilar::setsuperior(nodo*superior){ this->superior=superior;...
bd1e5b8661d8d3a84faaddee086075dbd71a9b19
d2ccfbc252f479686fd02ffab036b7097f5c342d
brunolauze/openpegasus-providers
/src/Providers/UNIXProviders/IPXConnectivityNetwork/UNIX_IPXConnectivityNetwork_VMS.hxx
C++
hxx
1,827
permissive
//%LICENSE//////////////////////////////////////////////////////////////// // // Licensed to The Open Group (TOG) under one or more contributor license // agreements. Refer to the OpenPegasusNOTICE.txt file distributed with // this work for additional information regarding copyright ownership. // Each contributor lice...
df37f63ce997fb8aa1d18da102c6a596749599df
ff08bfd2e10d965704a077151982bc3bfc2d99a5
tstack/lnav
/src/vtab_module.hh
C++
hh
26,283
permissive
/** * Copyright (c) 2017, Timothy Stack * * 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 condi...
3de3d94a4e7289c6e8d227ba2423cd15bf741b4a
7091675deaeb460856adcd10965379d1e5c71ced
Destrega/greenworks
/src/greenworks_async_workers.cc
C++
cc
6,735
permissive
// Copyright (c) 2014 Greenheart Games Pty. Ltd. All rights reserved. // Use of this source code is governed by the MIT license that can be // found in the LICENSE file. #include "greenworks_async_workers.h" #include "nan.h" #include "steam/steam_api.h" #include "v8.h" #include "greenworks_unzip.h" #include "greenwo...
6e1b14e6267d88f2202a5f9c4a3868bfa93e45c3
8aae9f9a77dc2ccb68508d48e91cf77ad1873cae
gilbeckers/PoseMatch
/app/src/main/cpp/native-lib.cpp
C++
cpp
264
no_license
#include <jni.h> #include <string> extern "C" JNIEXPORT jstring JNICALL Java_com_gil_posematch_MainActivity_stringFromJNI( JNIEnv* env, jobject /* this */) { std::string hello = "Hello from C++"; return env->NewStringUTF(hello.c_str()); }
f178a3b81b1ddff4e8c5b2750b7e622fd322626f
b42bd2ddb68f1dc7c44869f880084ac4c767a07c
chief1983/Imperial-Alliance
/CODE/RENDER/3dlaser.cpp
C++
cpp
21,056
no_license
/* * Copyright (C) Volition, Inc. 1999. All rights reserved. * * All source code herein is the property of Volition, Inc. You may not sell * or otherwise commercially exploit the source or things you created based on the * source. * */ /* * $Logfile: /Freespace2/code/Render/3dLaser.cpp $ * $Revis...
15471d8e4f68bf2889fac0356c085d91ac316665
6194ab8211d3c6fc01cda484af3333d5412542c9
vxl/vxl
/core/vrel/examples/robust_line_fit.cxx
C++
cxx
7,753
no_license
//: // \file // \brief Program demonstrating use the Robust Estimation library in line fitting // // \author Chuck Stewart // \author Bess Lee // Modifications: Oct 2001 Amitha Perera: added comments. #include <iostream> #include <vector> #ifdef _MSC_VER # include "vcl_msvc_warnings.h" #endif #include "vnl/vnl_vector...
3897085dcb6abf66026d4466d05da01fce7354a6
bd7a2e90c7d9335b64e64743ae28d8e55ab824ca
etra0/sapeaob-bench
/src/sapeaob-benchmark.cpp
C++
cpp
7,910
no_license
#ifdef _WIN32 #pragma comment(lib, "Shlwapi.lib") #ifdef _DEBUG #pragma comment(lib, "benchmarkd.lib") #else #pragma comment(lib, "benchmark.lib") #endif #endif #ifndef PROJECT_BASEDIR #error "Project basedir is not defined" #else #define DATA_DIR PROJECT_BASEDIR "/data/output.bin" #endif #include <Patterns.h> #incl...
7be2fedca973934b428ad107d322ab2ea750aa65
078f5525e36c870706bae6a85edc6997c0ed5917
krunt/projects
/misccode/bookbirdsview/d3lib/HashIndex.cpp
C++
cpp
4,269
no_license
/* =========================================================================== Doom 3 BFG Edition GPL Source Code Copyright (C) 1993-2012 id Software LLC, a ZeniMax Media company. This file is part of the Doom 3 BFG Edition GPL Source Code ("Doom 3 BFG Edition Source Code"). Doom 3 BFG Edition Source Code is free...
51a72b2b7c6595801a46b100938834799a11bcd9
d68509de6ba9ee646666b9552e21ae040a5364b0
jscslg/Competitive-Programming
/practice/cses_trees/distance_queries.cpp
C++
cpp
2,047
no_license
/* ~~~JsCode~~~ */ #include <bits/stdc++.h> using namespace std; #define ll long long #define ldb long double #define pb push_back #define F first #define S second #define all(v) (v).begin(),(v).end() #define tr(i,a) for(auto& i:(a)) #define fr(i,a,b) for(int i=(a);i<(b);++i) #define frv(i,a,b) for(int i=(a);i>=(b);--i...
27c583ea360020078348a1cb39258ee2e99e0fd8
f7670c9824755d34c80198d93bd4dbe2ac2835c9
AnitAggarwal01/CodingPractice
/trees/BSTToGreaterSumTree.cpp
C++
cpp
1,289
no_license
/** * https://leetcode.com/problems/binary-search-tree-to-greater-sum-tree/ * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode() : val(0), left(nullptr), right(nullptr) {} * TreeNode(int x) : val(x), left(nullptr), right(nullpt...
b96687635a72b50db3c7e3d419e53e9097e35c4e
a16304a042d42ab6178ea56157ad465541d08d58
ashutosh0gupta/llvm_bmc
/examples/litmus/c/run-scripts/tmp_1/WWC+poacquirerelease+ctrlonceonce+Once.c.cbmc.cpp
C++
cpp
36,726
no_license
// 0:vars:2 // 2:atom_1_X0_2:1 // 3:atom_2_X0_1:1 // 4:thr0:1 // 5:thr1:1 // 6:thr2:1 #define ADDRSIZE 7 #define NPROC 4 #define NCONTEXT 1 #define ASSUME(stmt) __CPROVER_assume(stmt) #define ASSERT(stmt) __CPROVER_assert(stmt, "error") #define max(a,b) (a>b?a:b) char __get_rng(); char get_rng( char from, char to ) ...
ce93a58e83ac58b649b002c8a4bac42d2be2cb9a
fd2986bf347ee0ebc092a24f4a61c28cae62b0c2
zhouyan/MCKL
/include/mckl/random/internal/threefry_generic_16x64.hpp
C++
hpp
18,017
permissive
//============================================================================ // MCKL/include/mckl/random/internal/threefry_generic_16x64.hpp //---------------------------------------------------------------------------- // MCKL: Monte Carlo Kernel Library //------------------------------------------------------------...
066a42b50788d1c08532190bc213258f14cca491
548ab0e26ac2cfb8f0ec7d89099614a3786c7dd5
UCSFVisionResearch/p4Repo2
/eyetracker/dev/sequencing/source/app/EyeTracking.cpp
C++
cpp
5,735
no_license
/** * @file EyeTracking.cpp * @brief Defines the class behaviors for the application. */ /***************************************************************************** * Includes *****************************************************************************/ #include "stdafx.h" #include "AppCore.h" #include "EyeT...
dd16b2845d079507e7b66c150623f54d0a01ea0b
0fec6da6cc42a27916bf72d19108d5875d916bac
Royzon/EKF-Self-driving-car
/src/kalman_filter.cpp
C++
cpp
1,785
permissive
#include "kalman_filter.h" #include<iostream> using Eigen::MatrixXd; using Eigen::VectorXd; using namespace std; /* * Please note that the Eigen library does not initialize * VectorXd or MatrixXd objects with zeros upon creation. */ VectorXd x_; MatrixXd P_, F_, H_, R_, Q_; KalmanFilter::KalmanFilter() {} K...
0bdfadbd87c6fbe52dca681d8247b18bb5675531
dcb9c68a3e1c7f800fc0439f2c71ca97d26bd16a
roboticslab-uc3m/WBPCwaiter
/programs/testCap53a/main.cpp
C++
cpp
1,219
no_license
// -*- mode:C++; tab-width:4; c-basic-offset:4; indent-tabs-mode:nil -*- /** * * @ingroup TestCap53a_programs * \defgroup TestCap53a TestCap51 * * @brief Creates an instance of roboticslab::WaiterExecManip. * * @section TestCap53a Legal * * Copyright: 2019 (C) Universidad Carlos III de Madrid * * Author:Jua...
4aaa6457341f5177f567f5ec1d8e94db7a1aed82
01425c9840cc4c4411fc15908c04efe134d1ee49
mudpi/nanpy-firmware
/Nanpy/ServoClass.cpp
C++
cpp
1,325
permissive
#include "cfg_all.h" #if USE_Servo #include <Arduino.h> #include <Servo.h> #include "ServoClass.h" #include <stdlib.h> const char* nanpy::ServoClass::get_firmware_id() { return "Servo"; } void nanpy::ServoClass::elaborate( nanpy::MethodDescriptor* m ) { ObjectsManager<Servo>::elaborate(m); if (...
3d01b6a7e3190c64cd04121b21dcf9dcbaf2b1b3
58276208eb43ed9cf67b1172971c6d30491bd164
yusuf-quddus/BinarySearchTree
/Data Object/person.cpp
C++
cpp
2,715
no_license
#include <iostream> #include <string> #include <fstream> #include "Person.h" Person::Person() { name = ""; birthday = ""; value = ""; }; Person::Person(std::string n) { name = n; } Person::Person(std::string n, std::string b, std::string v) { name = n; birthday = b; value = v; } /* setName set name of pers...
00e58a73155c19ce67a39e792c21d26aef9a0c82
0e1731d7d844b305439e38cb9111dd03ddc2ce54
rdowavic/souffle
/src/ram/transform/IndexedInequality.cpp
C++
cpp
9,959
permissive
/* * Souffle - A Datalog Compiler * Copyright (c) 2018, The Souffle Developers. All rights reserved * Licensed under the Universal Permissive License v 1.0 as shown at: * - https://opensource.org/licenses/UPL * - <souffle root>/licenses/SOUFFLE-UPL.txt */ /********************************************************...
e9e8287425b969fb21633c86cf56d6789e078f35
bdfc3ffce7017d66e104c18977323cfc4af87f46
dipankar08/codestudioV2
/StlExamples.cpp
C++
cpp
5,517
no_license
/*************************************************** * Title : * Author: Dipankar Dutta ****************************************************/ #include <algorithm> #include <iostream> #include <string> #include <vector> using namespace std; class Student { string name; int mark; public: Student(string name, in...
9a48fe030e973b1599b99285f899c724cef12cff
003147a0a539bb8f3c23a75a88c834b07f8a6322
vladimir-rangelov/ubreader-ios
/src/commands/get_book_list.hpp
C++
hpp
781
no_license
#ifndef commands_GetBookList_included_hpp #define commands_GetBookList_included_hpp #include <string> #include <vector> #include <utility> #include "src/dal/book.hpp" namespace commands{ struct GetBookList { typedef void result_type; soci::session& sql_; std::string search_; dal::Book::SortOrder...
4396da0a885754e85e5f50e14cf3924eac22c33a
7b86f2d900a5e5091e7bd042dbe9a97801351edf
Hawstein/leetcode
/populating_next_right_pointers_in_each_node.cc
C++
cc
1,869
no_license
#include <iostream> #include <queue> using namespace std; /** * Definition for binary tree with next pointer. * struct TreeLinkNode { * int val; * TreeLinkNode *left, *right, *next; * TreeLinkNode(int x) : val(x), left(NULL), right(NULL), next(NULL) {} * }; */ class Solution { public: struct TreeLinkNode...
9efc6a5ec6f5c47c6407d2b641850559064c797b
b004ab35a25866f484675d34d5af3e4d622c95cc
angeloaroni/ejerciciosCpp
/punteros/punteroInicio.cpp
C++
cpp
370
no_license
#include<iostream> using namespace std; int main(int argc, char const *argv[]) { int numero; int *punteroNumero; numero = 80; punteroNumero = &numero; cout << &numero << " corresponde a: " << numero << endl; *punteroNumero = 100; cout << "puntero: " << *punteroNumero << endl; cout << "...
5ac98220630d5431f367ab6ba4e9f38ba487036d
35a5989228496b51ad170af188e17c19f0c871d6
frc5885/2019-BotCode
/ImportedPowerUp/2018FRCP0werUp/src/main/cpp/Commands/UnlockArm.cpp
C++
cpp
1,584
no_license
// RobotBuilder Version: 2.0 // // This file was generated by RobotBuilder. It contains sections of // code that are automatically generated and assigned by robotbuilder. // These sections will be updated in the future when you export to // C++ from RobotBuilder. Do not put any code or make any change in // the blocks ...
11274333c32f35c5d45a8099654acd9fb8e0f10b
2244d3a3daf748366d258fb36209b2e3d760d7ec
aukdata/gb7avr
/firmware/src/priority_queue.hpp
C++
hpp
3,228
no_license
#ifndef PRIORITY_QUEUE_HPP #define PRIORITY_QUEUE_HPP #include <stddef.h> #include "vector.hpp" namespace gb7 { template<class T, size_t N = 16> class priority_queue { struct item { T data; uint32_t id = 0; }; vector<item, N> arr; uint32_t co...
67cb0259f35c9a089d8535ac3c9d65e898e410b7
2457bec276dda78f95d4f5629161c9d05320eff8
ziyasal/utopia
/Utopia/StatsCollector.cpp
C++
cpp
1,463
permissive
#include <iostream> #include "StatsCollector.h" #include "Constants.h" StatsCollector::StatsCollector() { this->total = nullptr; } StatsCollector::~StatsCollector() { delete total; for (int i = 0; i < MAX_RESPONSE_SIZE_IN_MS; ++i) { if (responseTimeArray[i] != nullptr) delete responseTimeArray[i]...
086ad52ec8a74a9899582ac6bb9d32bee92df0a6
b3a69707c4ee80cb796c42333f919c27d0cf4cc4
Bitinum/bitinum
/src/qt/addressbookpage.cpp
C++
cpp
12,777
permissive
#include "addressbookpage.h" #include "ui_addressbookpage.h" #include "addresstablemodel.h" #include "optionsmodel.h" #include "bitcoingui.h" #include "editaddressdialog.h" #include "csvmodelwriter.h" #include "guiutil.h" #ifdef USE_QRCODE #include "qrcodedialog.h" #endif #include <QSortFilterProxyModel> #include <Q...
09b9abb86795b2ae333af4c48eabfbf875c98564
34381e7cef4235bf3914d1c1f096e9ba29a99af4
umairsheikh/MVCCART
/CorrectnessTests/MainTest.cpp
C++
cpp
3,959
no_license
#include <iostream> #include <boost/test/unit_test.hpp> #include <boost/lexical_cast.hpp> #include "mvcc/mvcc.hpp" #include "ART/ARTFULCpp.h" #include "Transactions/UpdateIntensiveTemplates.h" using namespace std; auto ARTable1 = new ARTTupleContainer(); void RESET_AND_DELETE(ARTTupleContainer& ART ) { ART....