text
string
size
int64
token_count
int64
/* Attention, kills and modifies globals ^g and ^counter Error handling via method rc() */ #include <iostream> #include <string> #include "ydb-global.h" using namespace std; int main() { c_ydb_global _g("^g"), _counter("^counter"); string ind, v = "Hello world"; cout << "counter: " << (_counter += 2) << endl; _g...
668
320
#ifndef CSLIBS_MATH_SERIALIZATION_VECTOR_HPP #define CSLIBS_MATH_SERIALIZATION_VECTOR_HPP #include <cslibs_math/linear/vector.hpp> #include <yaml-cpp/yaml.h> namespace YAML { template<typename T, std::size_t Dim> struct convert<cslibs_math::linear::Vector<T, Dim>> { static Node encode(const cslibs_math::linear::V...
809
317
/** * copyright (c) 2018, James Flynn * SPDX-License-Identifier: MIT */ #include <stdlib.h> #include "iothub_client_core_common.h" #include "iothub_client_ll.h" #include "azure_c_shared_utility/platform.h" #include "azure_c_shared_utility/agenttime.h" #include "jsondecoder.h" #include "led.hpp" #include "lis2dw12.hp...
8,960
3,240
// // Author: Joshua Cohen // Copyright 2017 // #include "Peg.h" using isceLib::Peg; Peg::Peg() { // Empty constructor return; } Peg::Peg(const Peg &p) { // Copy constructor lat = p.lat; lon = p.lon; hdg = p.hdg; }
248
112
// Copyright (c)2007 Nicholas Piegdon // See license.txt for license information #include "TrackTile.h" #include "libmidi/Midi.h" #include "Renderer.h" #include "Tga.h" const static int GraphicWidth = 36; const static int GraphicHeight = 36; TrackTile::TrackTile(int x, int y, size_t track_id, Track::Tra...
4,478
1,642
/** * @file fuzzy_clang.cpp * @author Sirko Höer * @date 18.11.2017 * @brief Entrypoint for the fuzzy-clang ... * * @copyright Copyright (c) 2018 Code Intelligence. All rights reserved. */ #include <clang/Tooling/Tooling.h> #include <clang/Tooling/CommonOptionsParser.h> #include "PPContext.h" #include "Locatio...
1,883
542
// Copyright (c) 2010-2022, Lawrence Livermore National Security, LLC. Produced // at the Lawrence Livermore National Laboratory. All Rights reserved. See files // LICENSE and NOTICE for details. LLNL-CODE-806117. // // This file is part of the MFEM library. For more information and source code // availability visit ht...
2,575
1,097
#include <codegenvar/Eigen> #include <Eigen/Geometry> #include <iostream> using namespace codegenvar; int main() { const Symbol x("x"), y("y"), dx("dx"), dy("dy"), a("a"); const Vec2 p(x, y); const Vec3 P = p.homogeneous(); const Vec2 diff(dx, dy); std::cout << "p = " << p.transpose() << std...
1,924
786
#include "ScriptsComponent.hpp" #include <string> #include "afk/Afk.hpp" #include "afk/io/Log.hpp" #include "afk/io/Path.hpp" using Afk::ScriptsComponent; ScriptsComponent::ScriptsComponent(GameObject e, lua_State *lua_state) : loaded_files(), last_write(), lua(lua_state) { this->owning_entity = e; } auto Scri...
1,728
613
// Copyright 2015 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 "webservd/log_manager.h" #include <arpa/inet.h> #include <netinet/in.h> #include <set> #include <vector> #include <base/files/file_enumerato...
4,664
1,848
// Copyright (c) 2017 Computer Vision Center (CVC) at the Universitat Autonoma // de Barcelona (UAB). // // This work is licensed under the terms of the MIT license. // For a copy, see <https://opensource.org/licenses/MIT>. #include "carla/client/Waypoint.h" #include "carla/client/Map.h" namespace carla { namespace ...
4,502
1,553
#include <iostream> using namespace std; /* * Inheritance provides a way to create a new class from an existing class * New class is a specialized version of existing class * * Base Class (Parent) : inherited by child class * Derived class (Child) : inherits from the base class */ /* Here Undergrad class i...
1,384
424
#include "stdafx.h" #include <string.h> #include <stdio.h> #include <string.h> #include <commdlg.h> #include <math.h> #include "mine.h" #include "dle-xp.h" #include "toolview.h" #include "PaletteManager.h" #include "TextureManager.h" //------------------------------------------------------------------------------ B...
20,771
8,054
// This is an independent project of an individual developer. Dear PVS-Studio, please check it. // PVS-Studio Static Code Analyzer for C, C++, C#, and Java: http://www.viva64.com #include "..\hooks.hpp" using LockCursor_t = void(__thiscall*)(void*); void __stdcall hooks::hooked_lockcursor() { static auto ...
477
172
<?hh // strict namespace SebastianBergmann\TextTemplate; /* * This file is part of the Text_Template package. * * (c) Sebastian Bergmann <sebastian@phpunit.de> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ use \InvalidArgument...
2,967
927
/** * \file TkModuleGroupSelector.cc * * \author Joerg Behr * \date May 2013 * $Revision: 1.5 $ * $Date: 2013/06/19 08:33:03 $ * (last update by $Author: jbehr $) */ #include "Alignment/CommonAlignmentAlgorithm/interface/TkModuleGroupSelector.h" #include "Alignment/CommonAlignmentAlgorithm/interface/Align...
11,604
3,386
#define YAP_CPP_INTERFACE 1 #include <gmpxx.h> //! @{ /** * * @defgroup yap-cplus-interface An object oriented interface for YAP. * * @ingroup ChYInterface * @tableofcontents * * * C++ interface to YAP. Designed to be object oriented and to fit naturally * with the swig interface language generator....
1,802
741
#include <sstream> #include <iostream> #include <ydk/entity_util.hpp> #include "bundle_info.hpp" #include "generated_entity_lookup.hpp" #include "IP_MIB.hpp" using namespace ydk; namespace cisco_ios_xe { namespace IP_MIB { IPMIB::IPMIB() : ip(std::make_shared<IPMIB::Ip>()) , iptrafficstats(std::make_sha...
245,899
89,359
/** * @file 1.cpp * @author Jack * @mail chengjunjie.jack@gmail.com * @date 2021-12-28 * @version 0.1 * * @copyright Copyright (c) 2021 */ #include <algorithm> #include <cstdio> #include <iostream> #include <string> #include <type_traits> #include <vector> class B; class A { public: A(int a, int b = 1, int...
1,794
787
#ifndef HTCW_GFX_DRAW_HELPERS_HPP #define HTCW_GFX_DRAW_HELPERS_HPP #include "gfx_positioning.hpp" namespace gfx { namespace helpers { template<typename Destination,typename Source,bool HasAlpha> struct blender { static gfx_result point(Destination& destination,point16 pt,Source& sourc...
11,262
2,800
/**************************************************************************** ** $Id: aobject.cpp,v 1.3 2008/11/09 21:09:11 leader Exp $ ** ** Code file of the Ananas Object of Ananas ** Designer and Engine applications ** ** Created : 20031201 ** ** Copyright (C) 2003-2004 Leader InfoTech. All rights reserved. ** Cop...
21,455
8,233
/*********************************************************************************************/ /* Problem: Stack Min (CtCi 3.2) ********/ /*********************************************************************************************/ /* --Problem statement: How would you design a stack which, in addition to push and...
1,993
697
#include <iostream> #include <cmath> using namespace std; int main() { float Ax, Ay, Ar, Bx, By, Br; cout << "Enter first circle [x y r]:" << endl; cin >> Ax >> Ay >> Ar; cout << "Enter second circle [x y r]:" << endl; cin >> Bx >> By >> Br; float d = sqrt(pow((Ax - Bx), 2) + pow((Ay - By), 2))...
1,080
445
void bind_DoubleJumpComponentWrapper([[maybe_unused]] v8::Isolate* isolate, v8pp::module& module) { v8pp::class_<DoubleJumpComponentWrapper> cl_DoubleJumpComponentWrapper(isolate); cl_DoubleJumpComponentWrapper.inherit<CarComponentWrapper>(); cl_DoubleJumpComponentWrapper.ctor<uintptr_t>(); cl_DoubleJumpComponentW...
1,067
327
#include <stdint.h> #include "settings_eeprom.h" #include "state_expresslrs.h" #include "ui.h" #include "temperature.h" #include "touchpad.h" #include "comm_espnow.h" #include "protocol_ExpressLRS.h" void StateMachine::ExLRSStateHandler::onEnter() { //onUpdateDraw(false); } void StateMachine::ExLRSStateHandler:...
7,388
2,974
// Copyright 2018 Zeyu Zhong // Lincese(MIT) // Author: Zeyu Zhong // Date: 2018.5.7 #include "../src/basicSfM.h" int main(int argc, char *argv[]) { basicSfM sfm; sfm.algorithm_sparse3d(); return 0; }
215
103
#include "StdAfx.h" #include "Grabber.h" using namespace WebinariaApplication::WebinariaLogical; ////////////////////////////////////////////////////////////////////////// // Public methods // ////////////////////////////////////////////////////////////////////////// // Default constructor CGrabber::CGrab...
5,703
2,335
/* Copyright 2018, OpenSoft Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without modification, are permitted * provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, this list of * conditions a...
3,236
1,115
#pragma once #include "type_safe/strong_typedef.hpp" #include <cstddef> namespace kernel { struct StackSize_t : type_safe::strong_typedef<StackSize_t, std::size_t> , type_safe::strong_typedef_op::addition<StackSize_t> , type_safe::strong_typedef_op::subtraction<StackSize_t> ...
416
157
/*********************************************************************** * AUTHOR: <Doublecross> * FILE: GLOpenAssetImportMesh.cpp * DATE: Mon Jun 11 16:21:07 2018 * DESCR: ***********************************************************************/ #include "OpenGL/Shapes/GLOpenAssetImportMesh.h" #include <ass...
7,228
2,829
/** * project DESCARTES * * @file LaplacianMatrixDefinition.hxx * * @author Laurent PLAGNE * @date june 2004 - january 2005 * * @par Modifications * - author date object * * (c) Copyright EDF R&D - CEA 2001-2005 */ #ifndef __LEGOLAS_LAPLACIANMATRIXDEFINITION_HXX__ #define __LEGOLAS_LAPLACIANMATRI...
1,229
425
const int kN = 10000 + 5; const int kM = 100000 + 5; int dfn[kN],low[kN],head[kN],etot,btot,n,m,nq,belong[kN]; bool is_cut[kN],visited[kN]; std::stack<int> stack; struct Edge { int v,next,belong; bool visited,is_cut; }g[kM<<1]; std::vector<int> graph[kN+kM]; void add_edge(int u,int v) { g[etot].belong = -1; g[...
2,446
1,196
// Copyright 2018 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "chromeos/dbus/cryptohome/account_identifier_operators.h" namespace cryptohome { bool operator<(const AccountIdentifier& l, const AccountIdenti...
523
167
/** * The Forgotten Server - a free and open-source MMORPG server emulator * Copyright (C) 2016 Mark Samman <mark.samman@gmail.com> * * 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; eithe...
1,962
981
/* $Id: time-posix.cpp 69111 2017-10-17 14:26:02Z vboxsync $ */ /** @file * IPRT - Time, POSIX. */ /* * Copyright (C) 2006-2017 Oracle Corporation * * This file is part of VirtualBox Open Source Edition (OSE), as * available from http://www.virtualbox.org. This file is free software; * you can redistribute it a...
2,886
911
#include "StdAfx.h" namespace ui { ListBox::ListBox(Layout* pLayout) : ScrollableBox(pLayout), m_bScrollSelect(false), m_iCurSel(-1), m_pCompareFunc(nullptr), m_pCompareData(NULL), m_bSelNextWhenRemoveActive(true) { } void ListBox::SetAttribute(LPCTSTR szName, LPCTSTR szValue) { CUiString...
12,547
4,806
#include <iostream> #include <stack> #include <list> using namespace std; struct TreeNode { int val; TreeNode *left; TreeNode *right; TreeNode(int x) : val(x), left(NULL), right(NULL) {} }; TreeNode *convertBiNode(TreeNode *root); void reversion(TreeNode *root); int main() { return 0; } TreeN...
714
273
#include "multiobjects.h" int main(int argc,char** argv){ bool debug=false; MultiImageSampler* pMultiImageSampler=new MultiImageSampler(debug); pMultiImageSampler->initVulkan(); pMultiImageSampler->initWindow(); pMultiImageSampler->prepare(); pMultiImageSampler->renderLoop(); delete pMultiIm...
348
115
#include "barcode.h" #include <algorithm> constexpr uchar Barcode::black_color; constexpr uchar Barcode::white_color; constexpr int Barcode::left_guards_size; constexpr int Barcode::middle_guards_size; constexpr int Barcode::right_guards_size; constexpr int Barcode::left_code_size; constexpr int Barcode::rig...
8,688
3,533
/* Author: Robert F. Rau II Copyright (C) 2017 Robert F. Rau II */ #include "comm/serialport.h" #include "comm/commexception.h" #include <iostream> #include <unistd.h> namespace PiFly { namespace Comm { SerialPort::SerialPort(string devPath, Baudrate baud, bool blocking) : mBlocking(blocking) { if(mBlo...
5,671
3,027
#pragma once import atma.types; namespace atma { struct hasher_t; template <typename T> struct hash_t { auto operator()(T const& x) const -> size_t; auto operator()(hasher_t& hsh, T const& x) const -> void; }; struct hasher_t { hasher_t(uint64 seed = 0); template <typename T> a...
2,578
1,228
#include <iostream> //#define USING_MLOGD #include "utility/tool.h" #include <Eigen/Core> //#include <Eigen/Geometry> // Eigen 几何模块 /** * @brief 使用Gramy-Schmidt方法实现向量正交化,并单位化 * @param [in] a 向量a * @param [in] b 向量b * @param [in] c 向量c * @param [out] An 标准化后的向量A * @param [...
2,178
1,043
/******************************************************************************* * Copyright (c) 2019 by Rubedos * Kaunas, Lithuania, www.rubedos.com * All rights reserved. *******************************************************************************/ #include "FollowArucoWindow.h" #include <ros/spinner.h> #include ...
727
240
/* * BSD 3-Clause License * * Copyright (c) 2021, Dexai Robotics * 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 notic...
7,579
2,652
// // Created by 平地浩一 on 2021/03/23. // #include "comms.h" DigitalIn a(PA_7); DigitalIn b(PA_6); DigitalOut RA(PB_0); DigitalOut RB(PA_12); DigitalOut LA(PB_3); // PB_7 許さん!!! DigitalOut LB(PB_6); BufferedSerial pc(USBTX, USBRX); void comms_init() { RA.write(0); RB.write(0); LA.write(0); LB.write(0); } voi...
927
457
#ifndef TESTER_HPP #define TESTER_HPP #include <string> #include <iostream> #include <sstream> #include <vector> #include <time.h> class Tester { private: struct StrTime { std::string str; clock_t time; /** Skip output when put_all_time */ bool skip; }; /** Number of h...
2,933
973
#include <boost/python.hpp> #include <boost/format.hpp> #include "viewport/render/task.h" #include "viewport/render/instance.h" #include "fab/types/shape.h" #include "fab/util/region.h" #include "fab/tree/render.h" RenderTask::RenderTask(RenderInstance* parent, PyObject* s, QMatrix4x4 M, QVect...
8,170
3,252
#include <wayfire/plugin.hpp> #include <wayfire/output.hpp> #include <wayfire/core.hpp> #include <linux/input.h> #include <linux/input-event-codes.h> #include <wayfire/signal-definitions.hpp> #include <wayfire/util/log.hpp> static bool begins_with(std::string word, std::string prefix) { if (word.length() < prefix....
8,579
2,681
#include "stdafx.h" #include "SocketMgr.h" bool SocketMgr::s_bRunningCleanupThread = true; std::recursive_mutex SocketMgr::s_disconnectionQueueLock; std::queue<Socket *> SocketMgr::s_disconnectionQueue; Thread SocketMgr::s_cleanupThread; Atomic<uint32_t> SocketMgr::s_refCounter; uint32_t THREADCALL SocketCleanupThr...
3,749
1,602
/**************************************************************************** ** ** Copyright (C) 2015 The Qt Company Ltd. ** Contact: http://www.qt.io/licensing/ ** ** This file is part of the test suite of the Qt Toolkit. ** ** $QT_BEGIN_LICENSE:LGPL21$ ** Commercial License Usage ** Licensees holding valid commercia...
5,303
1,501
#include "step_crawling.h" #include <RobotUtilities/utilities.h> #include <ati_netft/ati_netft.h> #include <abb_egm/abb_egm.h> #include <ur_socket/ur_socket.h> using namespace std; using namespace RUT; int main(int argc, char* argv[]) { ROS_INFO_STREAM("Step crawling task server node starting"); ros::init(argc, ...
872
337
#include "stats/analyzer.hpp" #include "writers/r_writer.hpp" using namespace Anaquin; // Defined in main.cpp extern Path __output__; // Defined in resources.cpp extern Scripts PlotLinear(); // Defined in resources.cpp extern Scripts PlotFold(); // Defined in resources.cpp extern Scripts PlotLogistic(); Scripts R...
6,543
1,376
#include "advent.h" inline void reverse(std::vector<int>& vect, int from, int length) { int const vsize = vect.size(); if (length > vsize) return; for (int i = 0; i < length / 2; ++i) std::swap(vect[(from + i) % vsize], vect[(from + length - i - 1) % vsize]); } inline std::string knotHash(std::string const& i...
2,209
989
#include "yexception.h" static inline void Throw1DontMove() { ythrow yexception() << "blabla"; //dont move this line } static inline void Throw2DontMove() { ythrow yexception() << 1 << " qw " << 12.1; //dont move this line } #include <library/unittest/registar.h> #include <util/stream/ios.h> #include "yexc...
4,626
1,342
#include "Scene.hpp" #include <assimp/Importer.hpp> #include <assimp/scene.h> #include <assimp/postprocess.h> #include <assimp/config.h> #include <numeric> #include <execution> #include "Util.hpp" #include "stb/stb_image.h" Scene::Scene(const std::filesystem::path& filename) { const auto path = util::resourcesP...
11,578
4,121
// @TODO // https://codeforces.com/contest/1243/problem/B2
58
27
/* List of all Panels * * From: https://github.com/PokemonAutomation/Arduino-Source * */ #include <QFile> #include <QTextStream> #include <QMessageBox> #include "Common/Qt/StringException.h" #include "Common/Qt/QtJsonTools.h" #include "JsonSettings.h" #include "JsonProgram.h" #include "Tools/Persist...
3,485
1,138
#include "catch.hpp" #include <boost/crc.hpp> #include <osmium/osm/crc.hpp> #include <osmium/osm/node.hpp> #include "helper.hpp" TEST_CASE("Basic_Node") { osmium::CRC<boost::crc_32_type> crc32; SECTION("node_builder") { osmium::memory::Buffer buffer(10000); osmium::Node& node = buffer_add_node(buffer...
3,580
1,477
#include<bits/stdc++.h> using namespace std; const int MAXN = 2E+5 + 5; const int MAXX = 1E+9 + 7; int n, vec[MAXN],vec2[MAXN],dp[MAXN]; vector<int> fenwick(MAXN, 0); void add(int pos, int val){ for(int i = pos; i<=n; i+=i&(-i)){ fenwick[i] = max(val, fenwick[i]); } } int get(int pos){ int ans...
1,051
494
/* * OpenCloseGraspActionServer.cpp * * Created on: Apr 19, 2013 * Author: jnicho */ /* * Software License Agreement (BSD License) * * Copyright (c) 2011, Southwest Research Institute * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are per...
7,852
2,909
#include <iostream.h> #include <conio.h> void convert (char letter); main() { int x = 2; //for the do/while char b; //to accept letter input do{ cout<<"Welcome to the Letter Converter Program. \n"; cout<<"This program will accept a letter and convert it between \n"; //introduction cout<<"u...
1,651
663
#include <src/adcs/state_estimators/b_dot_estimator.h> #include <src/util/matrix.h> #include <src/util/msp_exception.h> #include <src/util/physical_constants.h> BDotEstimator::BDotEstimator(uint16_t sample_period_millis, uint16_t time_constant_millis) : smoother_x(time_constant_millis,...
1,617
511
// mojo/public/interfaces/bindings/tests/deserializer.test-mojom-blink.cc is auto generated by mojom_bindings_generator.py, do not edit // Copyright 2013 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #if defined(__cla...
4,108
1,600
/* This file is part of the regenie software package. Copyright (c) 2020-2021 Joelle Mbatchou, Andrey Ziyatdinov & Jonathan Marchini Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Softwar...
7,656
3,001
#include "global.h" #include <math.h> #include <time.h> void localInitialization() { int color_pop = st_MPI_p.color_pop; int* nPop_all = st_MPI_p.nPop_all; int mpi_rank = st_MPI_p.mpi_rank; int mpi_size_subPop = st_MPI_p.mpi_size_subPop; int mpi_rank_subPop = st_MPI_p.mpi_rank_subPop; int nPop ...
5,098
2,222
/* Copyright (c) 2018 PaddlePaddle Authors. 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 Unless required by applicable law or ag...
17,960
6,720
/* git-junction * Copyright (c) 2016-2017 by Pauli Saksa * * Licensed under The MIT License, see file LICENSE.txt in this source tree. */ #include "input.hh" #include "exception.hh" #include "terminal_input.hh" #include "utils.hh" #include <iostream> #include <sstream> #include <unistd.h> // bool accept_field_...
2,036
663
/* Copyright 2020 Myles Trevino Licensed under the Apache License, Version 2.0 https://www.apache.org/licenses/LICENSE-2.0 */ #pragma once #include <string> #include <vector> namespace LV::Decoder { void load_track_information(const std::string& file); void initialize_resampler_and_decoder(); void load_sam...
432
162
// Copyright 1996-2021 Cyberbotics 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 law or agr...
4,337
1,438
// main.cpp // #include "Core.hpp" int main(int argc, char** argv) { if (Core.Init()) { Core.Quit(); return -1; } else { Core.MainLoop(); Core.Quit(); return 0; } return 0; }
209
102
/* * Copyright (c) Contributors to the Open 3D Engine Project. * For complete copyright and license terms please see the LICENSE at the root of this distribution. * * SPDX-License-Identifier: Apache-2.0 OR MIT * */ #include <AzCore/Casting/numeric_cast.h> #include <AzCore/Component/ComponentApplicationBus.h> #in...
49,361
13,149
/* * main.cpp * Created on: July 5, 2018 * Author: Oleksii Kulikov */ #include <iostream> #include <chrono> #include "bnl.hpp" #include "output.hpp" #include "generator.hpp" #include "old_bnl.hpp" #include "old_dnc.hpp" #include "dnc.hpp" #include "nnl.hpp" #include "parallel_dnc.hpp" static std::size_t n = 0, d...
6,148
2,510
/* * Copyright (c) 2007, Laminar Research. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), * to deal in the Software without restriction, including without limitation * the rights to use, copy, modify, merge, ...
28,682
13,261
// Copyright (c) 2019 Hugo Amiard hugo.amiard@laposte.net // This software is provided 'as-is' under the zlib License, see the LICENSE.txt file. // This notice and the license may not be removed or altered from any source distribution. #ifdef TWO_MODULES module; #include <infra/Cpp20.h> module TWO(infra); #else #in...
3,174
1,164
#ifndef FRAMEWORK_MATH_DETAILS #error You should include math/math.hpp instead of matrix_functions.hpp #endif #ifndef FRAMEWORK_MATH_INC_MATRIX_FUNCTIONS_HPP #define FRAMEWORK_MATH_INC_MATRIX_FUNCTIONS_HPP #include <math/inc/matrix_functions_details.hpp> #include <math/inc/matrix_type.hpp> namespace ...
7,778
1,563
#include <iostream> #include "trompeloeil_doctest.h" #include <fstream> #include <future> #include <iterator> #include "fs-helpers/utils.h" #include "ietf-hardware/FspYhPsu.h" #include "ietf-hardware/IETFHardware.h" #include "ietf-hardware/sysrepo/Sysrepo.h" #include "mock/ietf_hardware.h" #include "pretty_printers.h" ...
41,541
15,290
#pragma once #include <SDL.h> #include <string> class Engine { public: Engine(); SDL_Window* createWindow(const int width, const int height, std::string name = "WINDOW NAME"); SDL_Surface* createSurface(SDL_Window* window); SDL_Surface* createImageSurface(SDL_Surface* surface, std...
591
181
#include "Generators/ClearMeshGenerator.h" #include "Utils/Utils.h" #include "Data/ApplicationState.h" #include "Profiler.h" ClearMeshGenerator::ClearMeshGenerator(ApplicationState *as, ComputeKernel *kernels) { bool tmp = false; appState = as; } void ClearMeshGenerator::Generate(ComputeKernel *kernels) { START_PR...
2,312
1,045
#include <vector> #include <string> #include <stack> #include "gtest/gtest.h" using namespace std; // 150. Evaluate Reverse Polish Notation // https://leetcode.com/problems/evaluate-reverse-polish-notation/?fbclid=IwAR1ELnj87j9bLdIIOatPq595iDYISE1rOH99AIiWEIdA72jBTwVuPfw6XPE class Solution { public: bo...
2,131
690
#pragma once #ifndef LENGTHCOMPONENT_H #define LENGTHCOMPONENT_H #include <cstdint> namespace GGB::Hardware::Audio { class LengthComponent { public: void setLength(uint16_t value, bool stopAfterLength) { length = length == 0 ? value : length; l...
656
201
#include "kmain.h" _declspec(naked) void multiboot_entry(void) { __asm { align 4 multiboot_header: //멀티부트 헤더 사이즈 : 0X20 dd(MULTIBOOT_HEADER_MAGIC); magic number dd(MULTIBOOT_HEADER_FLAGS); flags dd(CHECKSUM); checksum dd(HEADER_ADRESS); //헤더 주소 KERNEL_LOAD_ADDRESS+ALIGN(0x100064) dd(KERNEL_LOAD_ADDR...
913
687
#ifndef PAGE_H_INCLUDED #define PAGE_H_INCLUDED #include "common/Types.hpp" #include "core/SQLEntity.hpp" #include <iostream> class JSONSerializable; class Page: public SQLEntity, public JSONSerializable { public: Page(); virtual ~Page(); void setId(INTEGER<12> id) { p_id = id; } void setName(STR...
1,130
450
class Solution { public: void dfs(vector<vector<int>>& grid, int i, int j) { int n = grid.size(), m = grid[0].size(); if(i < 0 || j < 0 || i >= n || j >= m || grid[i][j] == 0) return ; grid[i][j] = 0; int d1[] = {0, 1, 0, -1}, d2[] = {1, 0, -1, 0}; for(int k ...
1,652
555
#include <iostream> using namespace std; int N,P,E; int X[22]; int Y[22]; int check[22]; int answer[22]; bool isAnswer = false; void result() { if(isAnswer) return; int cnt = 0,Sx = 0,Sy = 0; for(int x = 0; x<N; x++) { if(check[x] == 1) { cnt++; Sx +=X[x]; Sy +=...
1,418
570
// // Booking.cpp // Hw 11 // Object Oriented Vieshow Cinemas Taipei QSquare system // // Created by Tomy Hsieh on 2018/6/3. // Copyright © 2018年 Tomy Hsieh. All rights reserved. // #include "Booking.h" #include "MovieDatabase.h" #include <iostream> using std::cout; using std::endl; Booking::Booking() {} string ...
2,321
917
#include "CommonTypeDefines.h" #include "streams/DS_FileStream.h" #include "fileUtils/_fileExists.h" #include <algorithm> using std::min; namespace DataStructures { //------------------------------------------------------------------- Stream ------------------------------------------------------------------------ #...
6,385
2,896
/********************************************************************************* * Copyright (C) 1999,2004 by srl, Inc. All Rights Reserved. * ********************************************************************************* * Authors: Ian C. Starnes, Dr. J. Shane Frasier, Shaun Grant ***********************...
6,733
2,448
/* * UAVCAN data structure definition for libuavcan. * * Autogenerated, do not edit. * * Source file: /mnt/c/Users/BrianTaylor/Documents/Software/dronecan/dsdl/uavcan/equipment/ice/reciprocating/1120.Status.uavcan */ #ifndef UAVCAN_EQUIPMENT_ICE_RECIPROCATING_STATUS_HPP_INCLUDED #define UAVCAN_EQUIPMENT_ICE_RECI...
47,102
17,501
#include "BombDropSkill.h" #include "PlayerMovement.h" #include "Application.h" #include "ModuleNavigation.h" #include "ModuleTime.h" #include "GameObject.h" #include "ComponentTransform.h" #include "ComponentBoxTrigger.h" #include "PlayerState.h" BombDropSkill::BombDropSkill(PlayerMovement* PM, const char* trigge...
2,738
1,050
#include "isogram.h" #include <iostream> #include <vector> #include <algorithm> #include <list> #include <locale> namespace isogram { bool is_isogram(const std::string& str) { std::list<char>parsed = {}; for (const char letter : str) { if (' ' == letter || '-' == letter) continue; ...
714
229
//============================================================================= /// Copyright (c) 2017 Advanced Micro Devices, Inc. All rights reserved. /// \author AMD Developer Tools Team /// \file /// \brief Implementation of the Setup Target Application panel interface. //==========================================...
14,657
3,580
// Copyright 2014 the V8 project 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 "src/types.h" #include "src/ostreams.h" #include "src/types-inl.h" namespace v8 { namespace internal { // ---------------------------------...
32,279
11,012
#include <squirrel.h> #include "engge/System/Locator.hpp" #include "engge/Engine/EntityManager.hpp" #include "engge/Engine/Thread.hpp" #include <utility> namespace ng { Thread::Thread(std::string name, bool isGlobal, HSQUIRRELVM v, HSQOBJECT thread_obj, HSQOBJECT env_obj, ...
1,391
540
/** * Copyright (c) 2017 Melown Technologies SE * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, * this list of conditions and the f...
11,669
4,232
// Copyright 2004-present Facebook. All Rights Reserved. #include "ResumeCache.h" #include <algorithm> #include "src/framing/Frame.h" #include "src/framing/FrameTransport.h" #include "src/statemachine/RSocketStateMachine.h" namespace { using rsocket::FrameType; bool shouldTrackFrame(const FrameType frameType) { ...
5,411
1,707
// evolveDoc.cpp : implementation of the CevolveDoc class // #include "stdafx.h" #include "evolve.h" #include "evolveDoc.h" #ifdef _DEBUG #define new DEBUG_NEW #endif // CevolveDoc IMPLEMENT_DYNCREATE(CevolveDoc, CDocument) BEGIN_MESSAGE_MAP(CevolveDoc, CDocument) END_MESSAGE_MAP() // CevolveDoc construction/d...
1,865
813
//%Header { /***************************************************************************** * * File: src/Mustl/MustlWebLink.cpp * * Copyright: Andy Southgate 2002-2007, 2020 * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the...
17,155
6,297
#include "client.h" #include "ui_client.h" #include <QTime> client::client(QWidget *parent) : QDialog(parent), ui(new Ui::client) { ui->setupUi(this); this->setWindowTitle("client"); cSocket = new QTcpSocket(); ui->lineEdit->setText("127.0.0.1"); ui->lineEdit_2->setText("1234"); conne...
1,355
502
/** * Autogenerated by Thrift Compiler (0.14.1) * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ #include "impl/pch.h" #include <iosfwd> #include <thrift/Thrift.h> #include <thrift/TApplicationException.h> #include <thrift/protocol/TProtocol.h> #include <thrift/transport/TTr...
8,588
3,047
// Copyright (C) 2019 by Pedro Mendes, Rector and Visitors of the // University of Virginia, University of Heidelberg, and University // of Connecticut School of Medicine. // All rights reserved. // Copyright (C) 2017 - 2018 by Pedro Mendes, Virginia Tech Intellectual // Properties, Inc., University of Heidelberg, and...
1,368
484