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
23c1416bec785a7f92d64ea49e83d35068286799
a23e38896e2b6acdfa009c57634904a4b7234b97
AarooneyFarr/MegaProject
/MegaProject/Model/IntNodeArray.hpp
C++
hpp
467
no_license
// // IntNodeArray.hpp // MegaProject // // Created by Farr, Aaron on 2/8/17. // Copyright © 2017 Farr, Aaron. All rights reserved. // #ifndef IntNodeArray_hpp #define IntNodeArray_hpp #include "../Model/IntNode.hpp" class IntNodeArray { private: IntNode * head; int size; public: IntNodeArray(int big...
a8e989bc6fb81d8643714a5572d7073cc958a4dc
7a11f4fe1113ad9b9c1066d61b7d3a7b14c3acdf
yoggi56/hexapod
/src/dynamixel_control/src/dynamixel_read.cpp
C++
cpp
5,834
no_license
#include <ros/ros.h> //#include "std_msgs/Float64.h" #include <hexy_msgs/LegCurJoints.h> #include <dynamixel_msgs/JointState.h> #include <hexy_lib/hexy_lib.h> //#define LEG_L1 0 //#define LEG_L2 1 //#define LEG_L3 2 //#define LEG_R1 3 //#define LEG_R2 4 //#define LEG_R3 5 //#define COXA 0 //#define FEMUR 1 //#define...
4ad09285cd5d5e995e67e60afbc9330e27c648b4
6f413307a0b183ebb82be403c6d3e50cecb0ac7c
ashishkej/caffe
/src/caffe/util/math_blas_2.cpp
C++
cpp
3,190
permissive
#include <boost/math/special_functions/next.hpp> #include <boost/random.hpp> #include <limits> #include "caffe/common.hpp" #include "caffe/util/math_functions.hpp" #include "caffe/util/rng.hpp" namespace caffe { template<typename Dtype> void caffe_gemv(const CBLAS_TRANSPOSE trans_A, const int_tp M, ...
42d053eb5788b2cd746d86aeaec9ace18178c5c4
0eba22ce85fa7c1f2170549f9f21fab90a34abfb
woodinnis/LearnCPP
/09_x-SectionQuiz/9_x-SectionQuiz-Q3.cpp
C++
cpp
2,268
no_license
// 9_x-SectionQuiz.cpp : Defines the entry point for the console application. // #include "stdafx.h" // 3) Write your own integer array class named IntArray from scratch (do not use std::array or std::vector). // Users should pass in the size of the array when it is created, and the array should be dynamically alloca...
b9b9e70471546f1c5b4e1fb20190bfae061022ea
6d81c243cdb738d339d22e69bce26069c066f79e
aecio/RI-TP1
/src/UrlIdentifier.cpp
C++
cpp
2,620
no_license
#include <iostream> #include <fstream> #include <string> #include <vector> #include <algorithm> #include <sstream> #include <map> #include <iterator> #include <cmath> #include "util/SequenceFile.h" #include "index/Doc.h" using namespace std; void mapURL(); void gerarFilesID(); bool ProcessArgs(const int argc, const ...
44f6dcea4fe40a2d978ce4e09803692cb7965cb9
32856ad24892c29eadef197bd7f2c7a77f9912cb
hyoseok0604/Codeforces-old
/Codeforces Round #700 (Div. 2)/106750097.cpp
C++
cpp
1,436
no_license
/* Contest Name : Codeforces Round #700 (Div. 2) Problem Title : A - Yet Another String Game Problem Url : https://codeforces.com/contest/1480/problem/A Verdict : Accepted Time : 31 ms Memory : 0 KB */ #include<bits/stdc++.h> using namespace std; #define lli long long #define TC int TC;c...
eef7eb0c0b12242417d013ddf06da52044182cc6
307b1c1c8a4e0ca38b1ec82417a30da9964b6768
hanhuiwen/libqi
/tests/type/test_event.cpp
C++
cpp
6,964
no_license
/* ** ** Copyright (C) 2012 Aldebaran Robotics */ #include <map> #include <boost/algorithm/string.hpp> #include <gtest/gtest.h> #include <qi/application.hpp> #include <qi/anyobject.hpp> #include <qi/type/dynamicobjectbuilder.hpp> #include <qi/type/detail/traceanalyzer.hpp> qiLogCategory("test"); static int lastPa...
67fe3a1f0e3a85bce3ba9829e3856c9451ec55ef
910cb7edc5c6c36496b31c379a6f2ab51935682e
c-ber/cber
/vscode/wg/sdk/UParticleModuleSpawnBase.hpp
C++
hpp
1,744
no_license
#pragma once #include "UParticleModule.hpp" #ifdef _MSC_VER #pragma pack(push, 1) #endif namespace PUBGSDK { struct alignas(1) UParticleModuleSpawnBase // Size: 0x40 : public UParticleModule // Size: 0x38 { private: typedef UParticleModuleSpawnBase t_struct; typedef ExternalPtr<t_struct> t_struct...
9ca9062a04111036f23559b34637b993e3a66bd0
64c7ab2c6d128ff5901c19dc5032ff5c29ce1e6e
m-nny/Codeforces
/traning/205954/a/a.cpp
C++
cpp
2,135
no_license
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef unsigned long long ull; typedef map <int, int> mii; typedef pair <int, int> pii; typedef pair <ll, ll> pll; int const maxn = int(3e5) + 17; int const maxb = int(2e6 + 12); int const inf = int(1e9 + 7); ll const linf = ll(1e18 + 12); double...
979684ce1b445ec297f752aafac3d2a6fd21eafb
85f7f3c11041070cf653ad452e1fbecca3607470
thoughtworksarts/Dual_Brains
/drafts/quickSpectrogram_2/libraries/liblsl/external/lslboost/asio/detail/signal_handler.hpp
C++
hpp
2,763
permissive
// // detail/signal_handler.hpp // ~~~~~~~~~~~~~~~~~~~~~~~~~ // // Copyright (c) 2003-2013 Christopher M. Kohlhoff (chris at kohlhoff dot com) // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.lslboost.org/LICENSE_1_0.txt) // #ifn...
78df2740a94cef7c76edf91b1a572df1c5f64540
3abaa9b9a0e06f7d731590572d36830a6a1b96c3
jlb226/tesseract
/src/ccutil/unicharcompress.cpp
C++
cpp
15,883
permissive
/////////////////////////////////////////////////////////////////////// // File: unicharcompress.cpp // Description: Unicode re-encoding using a sequence of smaller numbers in // place of a single large code for CJK, similarly for Indic, // and dissection of ligatures for other scripts....
57c1c4d19af75159c271fa0958a14495aee940c0
56634e0929dcdc1f72ad4a304fc25c3613f9b416
Amogh-Dasture/kpart
/src/cluster/hcluster.cpp
C++
cpp
19,646
permissive
/** $lic$ * Copyright (C) 2015-2016 by Massachusetts Institute of Technology * * This file is part of Whirltool. * * Whirltool 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 3 of the Lic...
1398ce7bb50a5614e09d1a0b0acdd85807c39ca2
a06a3a8ab02b24a04f80de827845bcf1ddd910fb
hashtagdeveloper96/30-Days-of-Code
/Day 26.cpp
C++
cpp
505
no_license
#include <cmath> #include <cstdio> #include <vector> #include <iostream> #include <algorithm> using namespace std; int main() { /* Enter your code here. Read input from STDIN. Print output to STDOUT */ int d1,m1,y1,d2,m2,y2; cin>>d1>>m1>>y1>>d2>>m2>>y2; int fine = 0; if(y1>y2) fine =...
d96bfbfdbce4c5678455042fd8b93a0e723e9e54
183425e7576255c173849e20336b57b69191297a
Sharkar96/Clikky
/ModelMain.cpp
C++
cpp
575
no_license
// // Created by Andrea Righetti on 02/05/2020. // #include "ModelMain.h" void ModelMain::addObserver(Observer* ob) { observers.emplace_back(ob); } void ModelMain::notify() { for(auto i:observers) i->update(); } void ModelMain::removeObserver(Observer* ob) { observers.remove(ob); } void ModelMa...
8a4cfe9dfe342fb5437a9e213784d275de19e90a
b635d495898dcecb5ab7af62f5071fffb457bc8b
chromium/chromium
/chromecast/base/cast_features_internal.cc
C++
cc
351
permissive
// Copyright 2018 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include <vector> #include "base/feature_list.h" namespace chromecast { std::vector<const base::Feature*> GetInternalFeatures() { return std::vector<const base::Feature*>()...
805f94f273477cfc756152ccffb8168cf160f938
8f10fe9b4836710582b8c3f1773fa6b4b2212a24
sunavar/Data-Structures-
/stack using linked list.cpp
C++
cpp
3,290
no_license
#include <stdio.h> #include <stdlib.h> struct node { int info; struct node *ptr; }*top,*top1,*temp; int topelement(); void push(int data); void pop(); void empty(); void display(); void destroy(); void stack_count(); void create(); int count = 0; int main() { int no, ch, e; ...
a7f28118d789062474ac0bd3ee2e250752c3aa82
8db1dcc752c1c5aeaba152184bd9c9be55078270
sdwfrost/ig_graph
/tests/TestFastaParser.cpp
C++
cpp
1,755
no_license
#include "catch.hpp" #include <stdlib.h> #include <utility> #include <string> #include <utility> #include <string> #include <ostream> #include "prettyprint.hpp" #include "file_io/FastaParser.hpp" #include "file_io/FastaRefID.hpp" using namespace std; TEST_CASE("test FastaParser parse smAb FASTA ", "[parse]") { ...
9f811ab1161384e708757e0701179f8243af405b
1510a3aa645be2f7abaeb71d18b01e87584ceee8
SlipperyPete/opera-presto
/modules/libssl/debug/tstdump2.cpp
C++
cpp
1,212
no_license
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- ** ** Copyright (C) 2000-2008 Opera Software AS. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** ** Yngve Pettersen ** */ #include "core/pch.h" #i...
520e55d8428b9c60d3543e7b36bc070921556049
3886b1f5bdc389a0546c63d08e490f753ccc956a
yunjaena/CSE_Study
/algorithm_c:c++/.vscode/BOJ15916.cpp
C++
cpp
666
no_license
#include <iostream> #include <algorithm> #include <cmath> #include <queue> #define fastio \ ios_base ::sync_with_stdio(false); \ cin.tie(NULL); \ cout.tie(NULL); using namespace std; int main(){ int n; cin >> n; double minValue = INT32_MAX; doub...
8be671f325e5a6b39263126b435db4d1c7b422fb
1b62ab89dc96ddbef47ae48e6a843f7d3ce367d2
danmohd/tree_approx
/src/treeapprox_binsearch_test.cc
C++
cc
13,214
permissive
#include "treeapprox_binsearch.h" #include <vector> #include "gtest/gtest.h" #include "test_helpers.h" using std::vector; using treeapprox::binsearch_options; using treeapprox::treeapprox_binsearch; void RunAlgo(const vector<double>& x, size_t d, size_t k_low, size_t k_high, ...
4dca44efe3be72bd0cb09811babd2f542701de78
ef81ca6a26a0ee1ac1495a6a304bc295cb488da2
TencentCloud/tencentcloud-sdk-cpp
/tem/src/v20210701/model/RestartApplicationPodRequest.cpp
C++
cpp
5,741
permissive
/* * Copyright (c) 2017-2019 THL A29 Limited, a Tencent company. 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 * * http://www.apache.org/licenses/LICENSE-2.0 ...
ebdc17ec05f9c2a4d6e6b6a06f55c7016add5bda
8ab8eba3ebdfae5f5b65ef853692684b4578f281
niuxu18/logTracker-old
/second/download/rsync/gumtree/rsync_repos_function_120_rsync-2.0.18.cpp
C++
cpp
1,174
no_license
int local_child(int argc, char **argv,int *f_in,int *f_out) { int pid; int to_child_pipe[2]; int from_child_pipe[2]; if (pipe(to_child_pipe) < 0 || pipe(from_child_pipe) < 0) { rprintf(FERROR,"pipe: %s\n",strerror(errno)); exit_cleanup(1); } pid = do_fork(); if (pid < 0) { rprintf(FERROR,"fork: %s\...
4ecb2b7450bb0f6f89c16a8ea6a542e13d00af2e
587778b9b28186d5b7e13c3c6537e9dc809b5c61
cbodley/nexus
/src/client.cc
C++
cc
3,930
permissive
#include <nexus/h3/client.hpp> #include <nexus/h3/stream.hpp> #include <nexus/quic/connection.hpp> #include <lsquic.h> namespace nexus { namespace quic { client::client(const executor_type& ex, const udp::endpoint& endpoint, ssl::context& ctx) : engine(ex, &socket, nullptr, 0), socket(engine,...
2787fc91d4769c92b4ee653b4b2d1a4f4c027356
c8be055f38f2eb06bb4b4c1fde86b75f21fc39f2
EnricoCorsaro/PeakBagging
/source/PeakTestBackgroundModel.cpp
C++
cpp
1,970
permissive
#include "PeakTestBackgroundModel.h" // PeakTestBackgroundModel::PeakTestBackgroundModel() // // PURPOSE: // Constructor. Initializes model computation. // // INPUT: // covariates: one-dimensional array containing the values // of the independent variable. // b...
7cc7ba6d920f7a00b37b62ec1289c10b703b3ac0
5c874117a49763d364d00fb7b7893b051a23133e
karlgluck/Evidyon
/Source/shared/world/tools/terrainmaplayer.cpp
C++
cpp
5,057
permissive
//---------------------------------------------------------------------------// // This file is part of Evidyon, a 3d multiplayer online role-playing game // // Copyright © 2008 - 2013 Karl Gluck // // // ...
efad7510d245bbb1268eb72a29184e6a7467c6d2
d404e0b2a289d66b3f7188905c3798ef2f050458
Xinghan/rocksdb
/table/table_test.cc
C++
cc
37,541
permissive
// Copyright (c) 2013, Facebook, Inc. All rights reserved. // This source code is licensed under the BSD-style license found in the // LICENSE file in the root directory of this source tree. An additional grant // of patent rights can be found in the PATENTS file in the same directory. // // Copyright (c) 2011 The...
d78a60d3ee7af74d4e55c2b22093b4567112dd43
b7b2e0ecaddde7752ee8026611b49d554ac8dd15
AndrasKovacs84/Stratego
/CardScout.hpp
C++
hpp
872
no_license
#pragma once #include "Card.hpp" #include "CardType.h" class CardScout: public Card { public: explicit CardScout(Color color) : Card(color) {} const CardType getType() const override { return TYPE; } unsigned char getMoveDistance() const override { return moveDistance; } boo...
bf2eaa4319c50fc3d3d339cc4390119a740fd7d6
a1517f5122e277f90f42094d20d1ca9ca10892a8
smsolivier/conduction
/2d/cpp_library/VectorMath.hh
C++
hh
1,113
no_license
#ifndef __MATRIX_VECTOR_PRODUCT_HH__ #define __MATRIX_VECTOR_PRODUCT_HH__ #include <vector> using namespace std; // CPU // --- addition --- // vector vector vector<double> operator+(const vector<double> &A, const vector<double> &B); // matrix matrix vector<vector<double>> operator+(vector<vector<double>> &A, ve...
0673a2085df130d9777fe8d1bfad9942da8bae71
3671f1210a9ff4292043d070b7c6d1c46fe94dd1
khoshino/sirikata
/libmesh/plugins/nvtt/CompressTexturesFilter.cpp
C++
cpp
5,442
permissive
/* Sirikata * CompressTexturesFilter.cpp * * Copyright (c) 2010, Ewen Cheslack-Postava * 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 re...
f75a8358a308cf3d2abc4e9ff6ee64b78175e954
47161fdf1746084540d1a9d4703a4421e0380c66
chiaminchuang/Leetcode
/Medium/498-Diagonal Traverse/498.cpp
C++
cpp
951
no_license
class Solution { public: vector<int> findDiagonalOrder(vector<vector<int>>& matrix) { vector<int> ans; if(matrix.size() == 0) return ans; int flag = 0, i = 0, j = 0; int m = matrix.size(), n = matrix[0].size(); int dire[2][2] = { {-1, 1}, {1, -1}...
6f1449d893f0317b1e18f158beea28adbefb3bf0
74348f480b626678f09fcf7e30747765e3ccc98f
zenoalbisser/chromium
/chromecast/crash/linux/crash_util.cc
C++
cc
3,634
permissive
// Copyright 2015 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 "chromecast/crash/linux/crash_util.h" #include "base/bind.h" #include "base/files/file_path.h" #include "base/files/file_util.h" #include "base/...
a94d7950bf285621b96975b765c8b3412f603d40
3342c667fece2bbbf8d14a67d1fa2c4ceac4c0fa
zhjiang22/CAS_SpMV
/SpMV/.history/v4/Csrsparse_20210614160314.hpp
C++
hpp
1,918
no_license
#include<iostream> #include <hip/hip_runtime_api.h> // hipMalloc, hipMemcpy, etc. #include <stdio.h> // printf #include <stdlib.h> // EXIT_FAILURE #include <hip/hip_runtime.h> #define MIN((a), (b)) ((a) < (b) ? (a) : (b)) enum sparse_operation {operation_none=0,operation_transpose=1} ; __global...
b383a849e315e9a20972404abfc8e3a33429a0e5
ad2eaa0bd3c5be5646e32c0777ac57ea7f0ba9a7
leoheck/albert
/src/lib/albert/src/offlineindex/fuzzysearch.cpp
C++
cpp
9,816
no_license
// albert - a simple application launcher for linux // Copyright (C) 2014-2016 Manuel Schneider // // 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 3 of the License, or // (at y...
a8b9773253fd2d0e9f6f6b0d3f2fa55c2a309eee
d157b934a109220d3c76aa3ed3c5b32948c33127
astr0mfly/atom
/dfx/meta/TestBase.cpp
C++
cpp
459
permissive
#include <tlp/test/Test.hpp> #include <tlp/base/EmptyType.h> #include <tlp/base/NullType.h> #include <tlp/base/algo/Valid.h> FIXTURE(TestBase) { TEST("null type should not be valid") { ASSERT_FALSE(__valid_type(__null_type())); }; TEST("empty type should be valid") { ASSERT_TRUE(__...
cc08ba62fe61f4379e156beeee3083351880aaa9
bbb9b494326cfb6dd15a397a2801bdbb9508f74e
kaichenhong/Coding_Practice
/LeetCode/0025_Reverse_Nodes_in_k-Group_Hard/0025_Reverse_Nodes_in_k-Group_Hard_01.cpp
C++
cpp
1,370
no_license
/* * Results: AC (11 ms [97.03%]; 11.3 MB [95.66%]) */ /** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode() : val(0), next(nullptr) {} * ListNode(int x) : val(x), next(nullptr) {} * ListNode(int x, ListNode *next) : val(x), next(next)...
b59a3647959b4953829424bbe4a32b0e4d05f79d
a335a09856a3c84169475cac92c24de7aa26f8b7
sdecoder/geeksforgeeks
/array/find-subarray-with-given-sum.cc
C++
cc
1,251
no_license
/* An efficient program to print subarray with sum as given sum */ #include <stdio.h> /* Returns true if the there is a subarray of arr[] with sum equal to 'sum' otherwise returns false. Also, prints the result */ int subArraySum(int arr[], int n, int sum) { /* Initialize curr_sum as value of first element ...
61a66443a943f7d7ce95c8988cffabdd7e53e9aa
46ca6265c1ed18f20d4c5e1e22fddbd11966330c
emiliocantu20/Lab5_UtPod
/UtPodDriver.cpp
C++
cpp
5,549
no_license
// // Created by Emilio Cantu on 23/10/2019. // #include "Song.h" #include "UtPod.h" #include <fstream> #include <iostream> #include <iomanip> #include <sstream> #include <stddef.h> using namespace std; void inputSong( Song &Tune); void inputSong1( Song &Tune); void inputSong2( Song &Tune); void inputSong3(Song &Tune...
346fd5b1ecc38748fc5e33bdf8afb2b5056d6ea8
5179dceca9c63c18fe6210847d4a560d167f18ba
vaibhav1865/Leetcode-During-Placement-2022
/200.number-of-islands.cpp
C++
cpp
828
no_license
/* * @lc app=leetcode id=200 lang=cpp * * [200] Number of Islands */ // @lc code=start class Solution { public: int numIslands(vector<vector<char>>& grid) { int n = grid.size(); int m = grid[0].size(); int res=0; for(int i=0;i<n;i++){ for(int j=0;j<m;j++){ ...
751f3a055c85d8dd9e6819ba701e41806b365358
4b63cb878b96dd7660f2dff70f5984de17e3b8fb
kushuu/competitive_programming_all
/leetCode/count-good-nodes-in-binary-tree/Accepted/8-18-2021, 2_29_37 PM/Solution.cpp
C++
cpp
803
no_license
// https://leetcode.com/problems/count-good-nodes-in-binary-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(nullptr) {} ...
d5c8491669954e41cc83a5ddf33aa33384707c52
c1ec10077c6767c05f77b74b2ed93fd0a4c18813
youtube/cobalt
/third_party/icu/source/i18n/msgfmt.cpp
C++
cpp
71,673
permissive
// © 2016 and later: Unicode, Inc. and others. // License & terms of use: http://www.unicode.org/copyright.html /******************************************************************** * COPYRIGHT: * Copyright (c) 1997-2015, International Business Machines Corporation and * others. All Rights Reserved. ***************...
40ca3faaee55bd834142a6e6391ab99acda549bd
cb3ba0ffc80e5c8781af149399a2a0ffb6b6a0a0
saaf-water/Saaf-water-Hardware
/libraries/ArduinoJson/extras/tests/Cpp11/nullptr.cpp
C++
cpp
818
permissive
#include <ArduinoJson.h> #include <catch.hpp> #if !ARDUINOJSON_HAS_NULLPTR # error ARDUINOJSON_HAS_NULLPTR must be set to 1 #endif TEST_CASE("nullptr") { DynamicJsonDocument doc(4096); JsonVariant variant = doc.to<JsonVariant>(); SECTION("JsonVariant == nullptr") { REQUIRE((variant == nullptr)); REQU...
028ad8e5942d97064605c09e71e9401d35b7da62
183e1c1cda6bb6b0bc62240e410aecf0e0768372
Javibu5/POO
/Practica 1/adivina/adivinarnum.cc
C++
cc
549
no_license
//guess.cc //Un programa que adivina un numero #include <iostream> #include <cstdlib> #include <ctime> int main(){ srand(time(NULL)); int a , b; std::cout<<"Dime un numero\n"; std::cin>>a; b = rand()%10 + 1; while(a!=b){ if(a<b){ std::cout<<"Tu numero es menor\n"; std::cout<<"introduce un n...
a7b5d85aa4ac50679b9a27001d25386dbbcbaf69
e4a70d04b0b1b4616b20999960cac35a49e41ac3
calmackenzie/VG1819
/ability/ability/Mucus.cpp
C++
cpp
1,414
no_license
#pragma once #include "ability/ability/Ability.h" #include "unit/Unit.h" #include "board/tile/TileInfo.h" //Rock namespace ability { void Mucus::applyStatus(AbilityInfoPackage * p_info, unit::Unit* p_unit) { //reduce target MV to 1 //apply Status_Temp_Change to target ability::Status* se = ability::StatusMana...
26160fa973457c5b241a0b5b91a92ff2a9ed19a1
58060a7e5a6a5f9c20de135f08d41e03aa6d1f6e
caustin3/COSC_2030_LAB_4
/VectorDriver.cpp
C++
cpp
1,536
no_license
//Chase Austin //date8/oct/2018 //COSC 2030 //lab_4 #include "VectorDriver.h" int main() { cout << " ..:: B E G I N S A M P L E C O D E ::.." << endl << endl; vector<short> sample_vector(5); cout << "new vector: "; print(sample_vector); cout << endl; fill_vector(sample_vector); cout << "fil...
852bdd126462fdfebd83ecb5799fe146b50849aa
929cb369ed5fc252536088808dbd739e679aa4f2
LucidSigma/Daily-Coding-Problems
/Days 001 - 010/Day 09/MaxSumOfNonAdjacentNumbers.cpp
C++
cpp
748
permissive
#include <algorithm> #include <iostream> #include <vector> int FindMaxNonAdjacentSum(const std::vector<int>& numbers) { int sumWithPrevious = numbers[0]; int sumWithoutPrevious = 0; for (unsigned int i = 1; i < numbers.size(); i++) { T sumWithoutPreviousNew = std::max(sumWithPrevious, sumWithoutPrevious); su...
1f82acdc3e2758858586e16e586c8b1bb1f21919
6c02b38c1e9d786f68dfcfa17ccf7ec008da3002
mydeveloperday/llvm-project
/llvm/lib/Transforms/Scalar/SROA.cpp
C++
cpp
190,548
permissive
//===- SROA.cpp - Scalar Replacement Of Aggregates ------------------------===// // // 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 // //===---------------------------...
914a31b537f07d24a32b377b2579066971cb8cd7
ca6881e0a8f1a2236581ceef65239384097ef5fb
KM-Rob/MuxLine
/MuxLine.cpp
C++
cpp
587
no_license
#include "MuxLine.h" MuxLine::begin(int Lines, int IN, int A, int B, int C, int max, int delau) { num = Lines; lmax = max; del = delau; for(int i=0; i<num; i++) mux[i].begin(IN+i, A, B, C, max, delau); Reset(); } MuxLine::Reset(void) { for(int i=0; i<num; i++) mux[i].Reset(); in_NO = ...
c54d9c847b16dbacfa508c8a42ef59bdd7a80cda
1e41085db8894dd8ea79a8e07e3084df89cf4abe
vulyhoang96/Cplusplus
/Baitap7.cpp
C++
cpp
406
no_license
#include <iostream> using namespace std; int main() { int n; cout << "Nhap n: "; cin >> n; cout << endl << "Cac so nguyen to tu 1 den " << n << " la: "; int Check = true; int i, j = 2; for (i = 2; i <= n; i++) { for (j = 2; j <= i - 1; j++) { if (i % j == 0) { Check = false; } } if (Check...
96403ceb5db3547bda2cc1ceb733b149bdbe33c9
940c16fc4667ac558d0c24cb4a2f575d46ed921e
santiagoom/leetcode
/solution/cpp/145_BinaryTreePostorderTraversal.cpp
C++
cpp
933
no_license
#include <iostream> #include <vector> #include <cppUtils.h> using namespace std; class Solution { public: vector<int> postorderTraversal(TreeNode *root) { vector<int> res; postorderTraversalUtils(root, res); return res; } private: void postorderTraversalUtils(TreeNode *root, vecto...
f36ec1bc086d2e59e18e634892a39c3f50fca0cc
d2b3f6577df9d53b7264376c7d14a681ff5f2d33
JohnnySunkel/BlueSky
/Basics/hr_maps.cpp
C++
cpp
531
no_license
#include <cmath> #include <cstdio> #include <vector> #include <iostream> #include <set> #include <map> #include <algorithm> using namespace std; int main() { int q, type; cin >> q; map <string, int> clas; string name; for (int i = 0, mark; i < q; i++) { cin >> type >> name; if (typ...
5aac96c2111f57d3c19acd21511a100dcaf95a24
a1e726257ea5af825444b59687b1b7cf9828e655
shchauha/Timing
/TimingAnalyzer/macros/HLTDump.cc
C++
cc
11,340
no_license
#include "HLTDump.hh" #include "TString.h" #include "TColor.h" #include <vector> #include <iostream> HLTDump::HLTDump(const TString infile, const TString outdir, const Bool_t isoph, const Bool_t isidL, const Bool_t iser, const Bool_t isjetpt, const Int_t psfactor) : fIsoPh(isoph), fIsIdL(isidL), fIsER(iser), fIsJet...
11dacf9723b2e9aa042dcefcf41f0bb9142f7458
e1fb56e875089cb814d69ae37059e9bc47806902
MindGuerrillas/MarioStylePlatformer
/CState.cpp
C++
cpp
447
no_license
#include "CState.h" CState::CState() { } void CState::WriteText(SDL_Surface* Surf_Dest, const char* text, TTF_Font* font, SDL_Color color) { int X, Y; SDL_Surface* fontsurface = TTF_RenderText_Blended(font, text, color); X = (WINDOW_WIDTH / 2) - (fontsurface->w / 2); Y = (WINDOW_HEIGHT ...
cc4485e4fbcd046ba4a99f4cb09f7811af3031ef
274e50d172bd7ed7d4339c517eae6aaec1b528b5
fngtrade/firstcoin
/src/uint256.cpp
C++
cpp
2,351
permissive
// Copyright (c) 2009-2010 Satoshi Nakamoto // Copyright (c) 2009-2015 The Bitcоin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include "uint256.h" #include "utilstrencodings.h" #include <stdio.h> #include ...
a9af72aa90ac0046c3f7bb13acd74ba04473b341
97c452ebf64db236aa7e215ebdd60ab01d0c71c5
SREERAGI18/chromium
/components/variations/synthetic_trial_registry_unittest.cc
C++
cc
10,010
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 "components/variations/synthetic_trial_registry.h" #include <string> #include "base/containers/contains.h" #include "base/metrics/field_trial.h...
e9d1c1e78f990531752db6fbeb9398b0e6baaa58
246f9728dc71d853fb75cf50818c85ca21bb0c16
lzy0505/Lex-Yacc
/Lex/Lex/DFAMinimization.cpp
C++
cpp
3,226
no_license
#include "stdafx.h" #include "structs.h" using std::vector; using std::pair; using std::unordered_map; static bool scan(const vector<DFAstate> &); static void split_to_sets(const DFA & dfa); static unordered_map<int,int> statesSetsMap; static vector<unordered_set<int> > statesSetsVec; static int count = 0; void dfa...
6162d296de9bdab8919bcd05488e1cec640c0908
6253441e57f4580cb85a73c81b80d0fe5b90faa1
omer571-sys/Naomi-Browser
/src/sources/NaomiTabManager.cpp
C++
cpp
751
permissive
#include "../headers/NaomiTabManager.h" #include "../headers/NaomiWebView.h" #include <QTabWidget> #include <iostream> NaomiTabManager::NaomiTabManager(QWidget* parent) : QTabWidget(parent) { setTabsClosable(true); }; void NaomiTabManager::createPage(QUrl url, QString title) { NaomiWebView* page = new NaomiWebView(...
6cade51a2dec61c90dfee1e8127a5da33b4134bf
3198e1f39eaf8ad45fa1e95b82ad81cddba7fc25
zhcet19/LPNMSUMMERS19
/Lecture-13/Ways.cpp
C++
cpp
270
no_license
#include <iostream> using namespace std; int Ways(int n,int m){ // Base case if(n==0&&m==0){ return 1; } if(n<0||m<0){ return 0; } // Recursive case return Ways(n-1,m)+Ways(n,m-1); } int main(){ int n,m; cin>>n>>m; cout<<Ways(n,m)<<endl; return 0; }
8e3976713602bb8cbe04d47619d34c691675f7b5
1d28970fc8e0958bb0586bd510a0fa1d3169594d
pdpdds/yuzaos
/corelib/yuzalib/io/InputList.cpp
C++
cpp
5,109
no_license
/** * file List.h * date 2009/02/23 * author kkamagui * Copyright(c)2008 All rights reserved by kkamagui * brief 리스트에 관련된 함수를 정의한 소스 파일 */ #include "InputList.h" /** * 리스트를 초기화 */ void kInitializeList( LIST* pstList ) { pstList->iItemCount = 0; pstList->pvHeader = NULL; ps...
cdcecc3d9483ea18d01cc31e854eea90406610b8
9c3fb241d51c8f2397354002f400d63e7df2200f
hhYanGG/vscodeworke
/game/GameLobby/CrittterFarm.cpp
C++
cpp
1,247
no_license
//critter farm //demostrates object containment #include <iostream> #include <string> #include <vector> using namespace std; class Critter { public: Critter(const string& name = ""); string GetName()const; private: string m_Name; }; Critter::Critter(const string& name):m_Name(name) {} inline string Critte...
3b683aef4f2b2faf5db52cd8c767ce01e63351bc
db50255bce6e1dee60e1d13a1c9859c3442d2be9
neenad99/leetcode-september-challenge
/day 7/word pattern.cpp
C++
cpp
1,738
no_license
/* Given a pattern and a string str, find if str follows the same pattern. Here follow means a full match, such that there is a bijection between a letter in pattern and a non-empty word in str. Example 1: Input: pattern = "abba", str = "dog cat cat dog" Output: true Example 2: Input:pattern = "abba", str = "dog ca...
b7d65d4f6d68875e21dc21c91dfb582e41af5fb7
d91d75749ce1caedffae9b37c021375870b951fe
microsoft/Extensible-Storage-Engine
/test/ese/src/devlibtest/oslayer/oslayerunit/IoStatsSuite.cxx
C++
cxx
19,539
permissive
// Copyright (c) Microsoft Corporation. // Licensed under the MIT License. #include "osunitstd.hxx" // // Helper Routines and constants // // start update 30 min in future to ensure we'll grab the lock const TICK g_dtickOffsetToGuaranteeUpdate = 30 * 60 * 1000; #define PrintStatsBasicPercentages( piostats ) ...
b0dc5691ecbe21d5a467f3dedf3ba2252cb81f75
7af27303600de14102931a952826c2674658516c
LukaszKk/C-Cpp
/09 Graf/Graf/QPrior.cpp
C++
cpp
2,776
no_license
#include <stdio.h> #include <stdlib.h> #include <malloc.h> #include "QPrior.h" void UpdateDown( PQueue*, int l, int p ); void UpdateUp( PQueue*, int l, int p ); PQueue* PQInit( int nSize ) { PQueue* p = (PQueue*)calloc( 1, sizeof(PQueue) ); if( !p ) { printf( "Memory not allocated" ); return 0;...
3c1642df6c288e3fbf04f69f77e2edb876171395
e676c7aba4ed445e3924ad9e137619fb5a272f5a
Mari-Jun/Win32-API-Project
/Code/Enemy_Bitmap.cpp
C++
cpp
3,760
no_license
#include <Windows.h> #include <iostream> #include <tchar.h> #include "Source.h" #include "File.h" #include "Game_Progress.h" #include "Enemy_Bitmap.h" Enemy_Bitmap::~Enemy_Bitmap() { for (int type = 0; type < 30; type++) for (int direction = 0; direction < 8; direction++) for (int index = 0; index <...
67e1a5151168ad56573e647ef6ee13a4e7fb89ec
285eb7f156fb4f670bb39d2652d079320f660e24
eglowacki/yaget_legacy
/projects/yaget/branch/conversion/Research/swap_buffers/rendering/Renderer.cpp
C++
cpp
4,870
no_license
//--------------------------------------------------------------------------------------------------------------------// // RENDERER BASE CLASS // // 04/05/02, Mythos ...
cc1a9139ddc0fb7fab15d17be2bc977a0da46bd2
de00644e231c82a8d911c5abd145a56285bd68fa
spelteam/spel
/src/tests/spel/spelHelper_angle_dist_tests.cpp
C++
cpp
4,181
no_license
// SPEL definitions #include "predef.hpp" #include <gtest/gtest.h> #include "spelHelper.hpp" using namespace cv; namespace SPEL { class spelHelperTest : public testing::Test{ protected: //init virtual void SetUp(){ //test data p[0] = Point2f(0.0, 0.0); p[1] = Point2f(1.0, 1.0); p[...
0e23da6b376163ebde12a25e40333e6f350b4456
0ed5eedff5727da45592d14f2964f155f167b8ef
AmoCat/leetcode
/Tree/144. Binary Tree Preorder Traversal.cpp
C++
cpp
1,297
no_license
//栈 public: vector<int> preorderTraversal(TreeNode* root) { stack <const TreeNode *> s; vector <int> res; res.clear(); if(root != nullptr) s.push(root); while(!s.empty()){ const TreeNode *p = s.top(); s.pop(); res.push_back(p->val); if(p->left!=nullptr) ...
604634eee627095c54416f18d441fa4bceab01ba
979d60cd06f62dbf2249260ad0a77594bc795794
dalihub/dali-extension
/dali-extension/vector-animation-renderer/tizen-vector-animation-manager.cpp
C++
cpp
3,937
permissive
/* * Copyright (c) 2022 Samsung Electronics Co., Ltd. * * 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...
9b58c560ce5ba23d3ea241ab19310faad2ee7cec
e2143c02d2a9554c4b5966e06ce992fb1572aabe
mfcabrera/arrow
/cpp/src/parquet/arrow/reader.cc
C++
cc
68,854
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...
0ad5b143504340c62f7f8a5819beabf3a347d8a4
4b0dd9995020594466d3b1ad048dabd18a869e7d
arangodb/arangodb
/3rdParty/boost/1.78.0/boost/numeric/conversion/detail/converter.hpp
C++
hpp
19,236
permissive
// (c) Copyright Fernando Luis Cacciola Carballal 2000-2004 // 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) // See library home page at http://www.boost.org/libs/numeric/conv...
5c412490fd91a67fb9b4bc4290e5d14a253d7796
dc266fc7ba745f5f6340b47d90caf696d72f32f0
Nelias/cpp-practice
/word-cutter/swap.cpp
C++
cpp
757
permissive
#include <iostream> #include <string> int main() { std::string string_one = "a nice name"; std::string string_two = "even better name"; char ch[80]; string_one.copy(ch, 11, 0); std::cout << "The new copied character array is: "; std::cout << ch << std::endl << std::endl; ...
22d92ab802a07c52757ba7273830aefb29608710
8a0fadbfe3475890790c8570caf6dd5368e8bce5
ferrin/mmoserver
/src/ZoneServer/WorldConfig.cpp
C++
cpp
7,879
no_license
/* --------------------------------------------------------------------------------------- This source file is part of swgANH (Star Wars Galaxies - A New Hope - Server Emulator) For more information, see http://www.swganh.org Copyright (c) 2006 - 2010 The swgANH Team -------------------------------------------------...
5518fefcca5c6f6ec6790eb20ff5bdcb5f74bdc0
4c835923248550166662d7488d8e3ecb88c7436b
bjcarne/opendatacon
/Code/tests/ODC_tests/TCPSocketManagerTests.cpp
C++
cpp
12,982
permissive
/* opendatacon * * Copyright (c) 2014: * * DCrip3fJguWgVCLrZFfA7sIGgvx1Ou3fHfCxnrz4svAi * yxeOtDhDCXf1Z4ApgXvX5ahqQmzRfJ2DoX8S05SqHA== * * 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 ...
c61290da909482d630247f2208813f971216d9a9
27e325b9943ddbbcd854c55313a604c67c95ca95
vidbina/snp-read
/src/client.cpp
C++
cpp
1,030
no_license
#include <sys/socket.h> #include <sys/types.h> #include <netinet/in.h> #include <arpa/inet.h> #include <unistd.h> #include <stdio.h> #include <sys/errno.h> int main(int argc, const char* argv[]) { printf("\nJust reading http://bulk.fefe.de/scalable-networking.pdf\n"); char buf[4096]; ssize_t res, len; int fd ...
75f20a521672f008a66a62b4df193c56402b94c7
dc8c81c161d08b8b99ada63ac1bb75508ee6f731
sherlock-coding/LeetCode
/RectangleArea.cpp
C++
cpp
769
no_license
/* * 223 Rectangle Area * Find the total area covered by two rectilinear rectangles in a 2D plane. * * Each rectangle is defined by its bottom left corner and top right corner as shown in the figure. * Assume that the total area is never beyond the maximum possible value of int. * */ #include <iostream> #include...
90290016240c053ad9edcdf87e19b0b2f6161350
fa03b55f520b008d02d601708fa8b24b4f864d30
darfRaider/PendulumCart
/cpp/lib/mechanical/include/Physics.hpp
C++
hpp
502
no_license
/* * Physics.hpp * * Created on: Jun 15, 2020 * Author: sam */ #ifndef INCLUDE_PHYSICS_HPP_ #define INCLUDE_PHYSICS_HPP_ #include <vector> #include <math.h> class Physics { public: Physics(); virtual ~Physics(); protected: /** * @brief Acceleration at earth surface \f$(\frac{m}{s^2})\f$ */ ...
92af236211599bfe46787d9745dadf28efd34497
fe0ff29bd203e8ca677ee6873a2eadbb9e1d10fb
biblepay/biblepay
/src/crypto/RandomX/src/jit_compiler_x86.cpp
C++
cpp
27,099
permissive
/* Copyright (c) 2018-2019, tevador <tevador@gmail.com> All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditio...
20e0c10533f0025d168b874549849d123bdf4a35
88c71fac861f4b824151ec4138dbc219dfdf8f05
willstudy/LeetCode
/rob.cpp
C++
cpp
1,386
no_license
/* You are a professional robber planning to rob houses along a street. Each house has a certain amount of money stashed, the only constraint stopping you from robbing each of them is that adjacent houses have security system connected and it will automatically contact the police if two adjacent houses were broken into...
80406efdaa1a947099dfb70696cef4bf7fb582f2
acc3739bf79b93e332bb1ef0eeb9ae945c83a2cd
henry-eshbaugh/hpce-2018-cw2
/src/he915/direct_fourier_transform_parfor_inner.cpp
C++
cpp
2,210
no_license
#include "fourier_transform.hpp" #include <cmath> #include <cassert> #include "tbb/parallel_for.h" namespace hpce { namespace he915 { class direct_fourier_transform_parfor_inner : public fourier_transform { protected: /*! We can do any size transform */ virtual size_t calc_padded_size(size_t n) const { retu...
09406244211a607c1d1e71717d167012d1cc47aa
228db979db6173305c35c8035cd5c3f610462a5c
wcysai/CodeLibrary
/Codeforces/Regular/463/A.cpp
C++
cpp
323
no_license
#include<bits/stdc++.h> #define MAXN 3005 #define F first #define S second #define MOD 1000000007 #define INF 1000000000 using namespace std; typedef long long ll; typedef pair<int,int> P; int n,k,a[MAXN]; string S; int main() { cin>>S; string str=S; reverse(str.begin(),str.end()); S+=str; cout<<S<<endl; return 0...
5789a2982878763f8bf9d17b1eabf9d54d4faf55
f4750d5236313c7233ce46cf4009b1b94cc176f8
s-nandi/contest-problems
/data-structures/segment-tree/lazy-propagation/bombs.cpp
C++
cpp
2,404
no_license
// lazy segtree (max query, sum update), amortized analysis (monotone dec. solution) // https://codeforces.com/contest/1326/problem/E #include <bits/stdc++.h> using namespace std; using vi = vector<int>; #define rep(i,a,b) for(auto i = (a); i < (b); ++i) #define trav(a,x) for(auto& a: x) #define sz(a) (int)size(a)...
b977c2a5189cab35f4f3ad97aca10497fdd622be
ca91b2c75b30b138352fe0dd5099c07ef1974ae0
iterait/hipipe
/test/core/base64.cpp
C++
cpp
1,339
permissive
/**************************************************************************** * hipipe library * Copyright (c) 2017, Cognexa Solutions s.r.o. * Copyright (c) 2018, Iterait a.s. * Author(s) Filip Matzner * * This file is distributed under the MIT License. * See the accompanying file LICENSE.txt for the comp...
7b59b0d9d307fe280a180dea6434d0f467bd2b47
44f768ace53df84ca981441f338c3256610bc47f
intel/llvm
/sycl/test-e2e/Basic/fpga_tests/fpga_aocx_win.cpp
C++
cpp
1,128
permissive
//==- fpga_aocx_win.cpp - AOT compilation for fpga emulator dev with aocx --==// // // 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 // //===---------------------------...
e1504dcdf09bff63184db1031df297c4c83cfbef
d82eac1b0690da6888dace6eef91b4a661bf4f00
sc2ad/BeatSaber-Quest-Codegen
/include/UnityEngine/EventSystems/IInitializePotentialDragHandler.hpp
C++
hpp
3,223
permissive
// Autogenerated from CppHeaderCreator // Created by Sc2ad // ========================================================================= #pragma once // Begin includes #include "beatsaber-hook/shared/utils/byref.hpp" // Including type: UnityEngine.EventSystems.IEventSystemHandler #include "UnityEngine/EventSystem...
edafcbdead0e928ff2ccee8cf748cb24e0c86da3
b893516e84b121b5f2f2b09354a831ef10cbc0f9
merpatiboy/code_uri
/Flowers Flourish from France.cpp
C++
cpp
1,068
no_license
#include <stdio.h> #include <iostream> #include <string.h> using namespace std; int main() { while(1) { char kata[1000]; gets(kata); if(strcmp(kata,"*")==0)break; int flag =0,penanda,score= 1; if(kata[0]==32) { while(kata[flag]==32) { ...
d3d22eb323ee7aa17753f63e5d4ace86a537ee29
6b9ada68a583966e385759ab978596656c781db7
cycere/quid
/src/Platform/Linux/System/Timer.cpp
C++
cpp
4,080
permissive
// Copyright (c) 2011-2016 The Cryptonote developers // Copyright (c) 2017-2021 The Cycere developers // Distributed under the MIT/X11 software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include "Timer.h" #include <cassert> #include <stdexcept> #include <sys/...
4da1238b99b1940453247671bb64d6bb63202ac7
60d172656f28c6c971547581528f9d0c1d954f64
jhghdi/GalaxyGuardian
/GalaxyGuardian/Classes/Scene/MainScene.cpp
C++
cpp
5,839
no_license
#include "MainScene.h" USING_NS_CC; Scene* MainScene::createScene() { // 'scene' is an autorelease object auto scene = Scene::create(); // 'layer' is an autorelease object auto layer = MainScene::create(); // add layer as a child to scene scene->addChild(layer); // return the scene return scene; } // on "...
2f37edb8b7459461c98de77e2752a61eab967cb7
fdf01031ac8c7d9e20c2863f23c9718e74555188
svn2github/farmanager-code
/plugins/arclite/plugin.cpp
C++
cpp
46,750
no_license
#include "msg.h" #include "plugin.h" #include "guids.hpp" #include "utils.hpp" #include "sysutils.hpp" #include "farutils.hpp" #include "common.hpp" #include "ui.hpp" #include "archive.hpp" #include "options.hpp" #include "cmdline.hpp" wstring g_plugin_prefix; TriState g_detect_next_time = triUndef; ...
9f7feb2862d4a1ab31798a1a35e54ee90ff9f9e2
26bfddeb7762ba3502275d1f699c99ed2411a7f3
reisoftware/ap2d
/afc/ary.cpp
C++
cpp
2,001
no_license
#include "stdafx.h" #include "ary.h" #include <stdlib.h> #include <cassert> namespace afc{ //////////////////////////// << static >> ///////////////////////////// namespace the{ static void * offset(void * p, int dis) { return (char*)p + dis; } }//namespace //////////////////////////// << A...
dfd2eb625ee9522cac22e24559e1d769f274c96c
d3bddd3ecd60cea5bd2c4df6bcbac1cdb15f8a4d
uzleo/coast
/llvm/test/tools/sancov/Inputs/test.cpp
C++
cpp
643
permissive
// compile & generate coverage data using: // clang++ -g -o test-linux_x86_64 -fsanitize=address -fsanitize-coverage=bb test.cpp ../Inputs/foo.cpp // ASAN_OPTIONS="coverage=1" ./test-linux_x86_64 && mv test-linux_x86_64.??*.sancov test-linux_x86_64.0.sancov // ASAN_OPTIONS="coverage=1" ./test-linux_x86_64 1 && mv te...
8575ee16f3e0b2a0024ee7506cad4e69c90af33c
b0e0d315c1be3d927c0005564c8e9257968087d0
MaxEntroy/lua-best-practise
/chapter20/demo-03/src/main.cc
C++
cc
1,686
no_license
#include <iostream> #include <map> #include <string> extern "C" { #include "lua.h" #include "lualib.h" #include "lauxlib.h" } #include <gflags/gflags.h> DEFINE_string(script_path, "", "the lua script path" ); void Test(lua_State* L, const std::string& script) { luaL_dofile(L, script.c_str()); int x = 3; ...
24830be8ee7754be14b232d204fc7175e6df3142
fadb85e0d8f2b97eadf2590ccda75e43640398fb
mdavidsaver/pvxs
/ioc/localfieldlog.cpp
C++
cpp
910
permissive
/* * Copyright - See the COPYRIGHT that is included with this distribution. * pvxs is distributed subject to a Software License Agreement found * in file LICENSE that is included with this distribution. * * Author George S. McIntyre <george@level-n.com>, 2023 * */ #include "localfieldlog.h" namespace pvxs { na...
28f77015af497b309e3fddf861ab73fed5ecaa77
da1ecbd52e0019d77ca48ce1defa8c7437fc0213
IngoChou/DiligentCore
/Tests/IncludeTest/GraphicsTools/CommonlyUsedStatesH_test.cpp
C++
cpp
1,334
permissive
/* Copyright 2019 Diligent Graphics LLC * * 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 * * THE SOFTWARE IS PROVIDED "AS...
b8e078d7c1ab09b61e2f33b3f9898dd2b34ab9a0
28c30775daf79c7f5647e0c81921251c5a0ebdf7
kenferrara/gpdb
/src/backend/gporca/libnaucrates/src/parser/CParseHandlerScalarExpr.cpp
C++
cpp
4,382
permissive
//--------------------------------------------------------------------------- // Greenplum Database // Copyright (C) 2014 Pivotal, Inc. // // @filename: // CParseHandlerScalarExpr.cpp // // @doc: // @see CParseHandlerScalarExpr.h //--------------------------------------------------------------------------- #include ...
4c5e6e2d19e2679b0e9322707e5c68973d23f3cb
9f204ed40c173780470ca4173e84e4856f712b77
taylor-bsg/NaplesPU-toolchain
/compiler/lib/Target/NaplesPU/MCTargetDesc/NaplesPUAsmBackend.cpp
C++
cpp
5,098
permissive
//===-- NaplesPUAsmBackend.cpp - NaplesPU Assembler Backend ---------------------===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===-------------------------------------------------...
12226509a65cb17eee20d2e6adcdd87feec1b55f
0c9068c61c68c3683fed625b5c5066114906e787
DStagg/Animation-Builder
/Animation Builder/MainScene.cpp
C++
cpp
13,665
no_license
#include "MainScene.h" MainScene::MainScene(sf::RenderWindow* rw) { _Window = rw; }; MainScene::~MainScene() { }; void MainScene::Begin() { // Setup GUI _Font.loadFromFile("Roboto-Regular.ttf"); GUI::RegisterFont(_Font); GUI::RegisterWindow(_Window); // Save camera view for sheet area _DefaultView = _Window-...
dc0ef498e79686fe5f5e26fc0f45f5783beb939a
bd37daffe020629815d5ef5855c3e2325843f9fa
GabrielVantuil/GabrielVantuil.github.io
/projects/pdi/3.2/3.2.2/labeling_3.2.2.cpp
C++
cpp
2,370
no_license
#include <iostream> #include <opencv2/opencv.hpp> using namespace cv; using namespace std; int main(int argc, char** argv){ Mat image, mask,out; int width, height; int nobjects=0, nobj_buraco=0; int r=0,g=0,b=0; CvPoint p; image = imread(argv[1],CV_LOAD_IMAGE_GRAYSCALE); cvtColor(image, out, CV_GRA...
94cbf9d14a156e97f77598384ccb414d6eef1cbb
6000075f5cb59e3fb3040beb28fa293766027a26
esrrhs/fuck-music-player
/wxWidgets-2.9.1/src/gtk/bitmap.cpp
C++
cpp
26,140
no_license
///////////////////////////////////////////////////////////////////////////// // Name: src/gtk/bitmap.cpp // Purpose: // Author: Robert Roebling // RCS-ID: $Id$ // Copyright: (c) 1998 Robert Roebling // Licence: wxWindows licence ////////////////////////////////////////////////////////////...
b4ac9faee9f1317f38e03e53ba554814790695c4
82444bd4de6410a901328b7b0367f14448a06182
lunaisnotaboy/botw
/src/Game/AI/Query/queryCheckDieCnt.cpp
C++
cpp
582
no_license
#include "Game/AI/Query/queryCheckDieCnt.h" #include <evfl/query.h> namespace uking::query { CheckDieCnt::CheckDieCnt(const InitArg& arg) : ksys::act::ai::Query(arg) {} CheckDieCnt::~CheckDieCnt() = default; // FIXME: implement int CheckDieCnt::doQuery() { return -1; } void CheckDieCnt::loadParams(const evfl::...
63206b90f9d2e484ea80a5eaab7928ed846c609e
aa4305219d72328a8bae58eb053fa7fcea251297
will514/maya-usd
/plugin/al/plugin/AL_USDMayaTestPlugin/AL/usdmaya/test_DiffGeom.cpp
C++
cpp
10,697
permissive
// // Copyright 2019 Animal Logic // // 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...
ecf694a4aefba5fc30849c021c018f02914b585d
0a59ea90d2a7d17a738da0c302d11fdc2c2d8867
Stenardt-9002/CODEFORCES-CONTESTS
/CODEFORCES Contests/Codeforces Round #613 (Div. 2)/A.cpp
C++
cpp
448
no_license
#include <iostream> // #include <stdlib.h> #include <cstring> using namespace std; int main(int argc, char const *argv[]) { long long int length1,count1L = 0 ,count1R = 0; string str1; std::cin >> length1; std::cin >> str1; for (long long int i = 0; i < length1; i++) { if (str1[i]=='L') { co...