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 |
|---|---|---|---|---|---|---|---|---|
3e3371a908c930f35b52f865fd828dfd68ec0066 | be7d1f959cf59644d21311d73d02a37edcb73024 | CMS-TMTT/cmssw | /RecoMuon/MuonIsolationProducers/test/IsolationExample.cc | C++ | cc | 3,961 | permissive | #include "FWCore/Framework/interface/EDAnalyzer.h"
#include "FWCore/Framework/interface/Event.h"
#include "FWCore/Framework/interface/EventSetup.h"
#include "DataFormats/Common/interface/Handle.h"
#include "DataFormats/Common/interface/View.h"
#include "FWCore/Framework/interface/ESHandle.h"
#include "FWCore/Framework/... |
1fd2669600ea47277cdaf3020dc5c1c684ace062 | eb62e6d31949ca1c3ae2a066b8c043af01b75bc6 | AllanHasegawa/pdebc | /sourcetree/BaseDE.hpp | C++ | hpp | 3,848 | no_license |
/*
Copyright 2012 Allan Yoshio Hasegawa
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 writing,... |
05f81d52fb8911489114db89f1649dd14f2e4cac | cf0b2592e2a87f6ac2e240e20c7fb13a852562e7 | raiyanla/compute-runtime | /level_zero/tools/source/pin/pin.cpp | C++ | cpp | 512 | permissive | /*
* Copyright (C) 2019-2020 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
*/
#include "pin.h"
#include "level_zero/core/source/module.h"
#include "level_zero/source/inc/ze_intel_gpu.h"
namespace L0 {
static PinContext *PinContextInstance = nullptr;
void PinContext::init(ze_init_flag_t flag) {
if (... |
a4a75d0234005d3a5c8824bd6eebb3a5db6cf96c | 289974d9fe8ef947840d153671eb0f6f18e7593f | frxstrem/fys3150 | /project1/tridiagonal.hh | C++ | hh | 1,487 | permissive | /**
* Copyright (c) 2016 Fredrik Østrem
* This code is license under MIT license (see LICENSE for details)
*/
#ifndef TRIDIAGONAL_HH_
#define TRIDIAGONAL_HH_
#ifndef __cplusplus
#error Not compiling with C++
#endif
/**
* Solve a N×N matrix equation with a tridiagonal matrix.
* a, b, c contain the lower, main an... |
90eef4c7fb630de0d8ac4f6804f9c965952b1ca3 | a7f78f376ee1a078a195c6ba7b6474631acd2a6a | ikuo-suyama/competitive-programming | /atcoder-problems/abc109_c.cpp | C++ | cpp | 1,045 | no_license | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); i++)
#define repi(i, s, n) for (int i = (s); i < (n); i++)
#ifdef LOCAL
#define INPUT_FILE \
ifstream in("atcoder-problems/abc109_c.txt"); \
cin.rdbuf(in.rdbuf());
#define print_vec(v) \
rep(l, v.size()) { cou... |
953a2caa3b5f31d9b6e249057ed7e179775d057e | a433fa481d8f4d93811becb2cd3f9482565bf828 | xLLLxLLLx/xLLLx | /vg/fd/contest/12/A.cpp | C++ | cpp | 1,255 | no_license | #include<bits/stdc++.h>
#define fr(i,x,y) for(int i=x;i<=y;++i)
#define rf(i,x,y) for(int i=x;i>=y;--i)
#define LL long long
using namespace std;
const int N=102,mod=1e9+7;
struct data {
LL a[N][N];
}tmp,pos;
LL cnt[N],dp[N];
void Add(LL &x,LL y){
x=(x+y)%mod;
}
void Mul(LL &x,LL y){
x=(x*y)%mod;
}
LL add(LL x,LL... |
8d36fe5bcbcaceaec45fdae23a442ad488b76ce9 | 6fc9c2010c0a6b6a9d2903f595cdb63182e8e297 | Rush/node-libvirt | /src/hypervisor.cc | C++ | cc | 31,668 | permissive | // Copyright 2010, Camilo Aguilar. Cloudescape, LLC.
#include <assert.h>
#include "worker_macros.h"
#include "domain.h"
#include "node_device.h"
#include "secret.h"
#include "storage_pool.h"
#include "storage_volume.h"
#include "network.h"
#include "network_filter.h"
#include "interface.h"
#include "hypervisor.h"
n... |
253ebdfc6a829ac6364fe6d8220b46feb5c7cc50 | ed01a68b4ed4360ee08b013194c37f23f2c2d62e | Hi-archers/MegEngine | /dnn/src/arm_common/conv_bias/int8/direct_nchw_nchw44_algo.cpp | C++ | cpp | 15,533 | permissive | /**
* \file dnn/src/arm_common/conv_bias/int8/direct_nchw_nchw44_algo.cpp
* MegEngine is Licensed under the Apache License, Version 2.0 (the "License")
*
* Copyright (c) 2014-2020 Megvii Inc. All rights reserved.
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the Lice... |
6c57b0e00d8fdb177db9e9a7e9175eafbc52e292 | d30ef08c2eb9af354c0f9c495700f33b96a99fdb | lmayerhofer/ILV-Praktische-Informatik | /uebung3/aufgabe5/generate.cpp | C++ | cpp | 6,097 | no_license | #include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <algorithm>
#include <string.h>
struct IRNode {
typedef enum {PLUS, MINUS, MULT, POW, MAX, NUMBER} nodetype;
IRNode(nodetype t, IRNode *l, IRNode *r) : type(t), value(-1), left(l), right(r) { }
IRNode(unsigned v) : type(NUMBER), value(v), l... |
2fcc4c1ee33d6f7267c70dd12d1276f445955273 | cc4b22c26a8cac4435447c079068d99ec6bd921d | sfztools/sfizz | /tests/SemaphoreT.cpp | C++ | cpp | 1,528 | permissive | // SPDX-License-Identifier: BSD-2-Clause
// This code is part of the sfizz library and is licensed under a BSD 2-clause
// license. You should have receive a LICENSE.md file along with the code.
// If not, contact the sfizz maintainers at https://github.com/sfztools/sfizz
#include "sfizz/RTSemaphore.h"
#include "catc... |
ecbbb4e269beef7625e478fc55bba43e8bf01e90 | 6d8d1d5bd398765e37b177454b851a27af7bbabf | bigdoods/OpenInfraPlatform | /IfcRoad/src/OpenInfraPlatform/IfcRoad/entity/IfcLogical.cpp | C++ | cpp | 1,687 | no_license | /*! \verbatim
* \copyright Copyright (c) 2015 Julian Amann. All rights reserved.
* \author Julian Amann <julian.amann@tum.de> (https://www.cms.bgu.tum.de/en/team/amann)
* \brief This file is part of the OpenInfraPlatform.
* \endverbatim
*/
#include <sstream>
#include <limits>
#include <map>
#include "OpenInfraP... |
d266dec770b5116adf4691aeee7c2edccc1e394f | fe86b72f38d0e65025016f1c43eb247f613b532f | jingtangliao/ff | /SmallPatchBigPatchInpainting.cpp | C++ | cpp | 9,503 | permissive | /*=========================================================================
*
* Copyright David Doria 2011 daviddoria@gmail.com
*
* 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
*
*... |
3dbfeb95f205370c0944c4c19ada854bd6e28c68 | 240d8810f9cba5b66e56f4ea0831db6cfc3b82fc | huycold/newGame | /main.cpp | C++ | cpp | 1,908 | no_license | #include "console.h"
#include "myStruct.h"
#include "display.h"
#include "constructor.h"
#include "handl.h"
int main ()
{ int i;
int kt=0;
int x;
int dokho=150;
diemso diem;
ran snack;
hoaqua hq;
char snake[11][80]= {
" OOOOOO O O O O O O O O O",
"O ... |
5881b226f51ab961215ce5bf77517fe554a06872 | cfb1cc772bfb26436b2ed7c4ab78ff096fdbf210 | TommyLike/graphengine | /src/ge/ge_runtime/task/aicpu_task.cc | C++ | cc | 4,745 | permissive | /**
* Copyright 2019-2020 Huawei Technologies 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 applicabl... |
0b3856a05ee15a89f1b373b8998dcaaf6281863a | e594ac42b31f5bb27e021a469e9cfabb89aa92e1 | mmmzeg/VisualizationLibrary | /src/vlCore/init_core.cpp | C++ | cpp | 11,664 | permissive | /**************************************************************************************/
/* */
/* Visualization Library */
/* http://visualizationlibrary.org ... |
b2dea532ecc77ed0794a7cf21cc39c86232b1555 | 39058e3bec184c386167a46ec815231919b041d5 | xzeeshanx/android_device_xiaomi_davinci | /fod/FingerprintInscreen.cpp | C++ | cpp | 4,539 | no_license | /*
* Copyright (C) 2019-2021 The LineageOS Project
*
* 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 applicab... |
bee0162ed426b1f1c2ed269e9bc4e98044ddd8b4 | f9fa52057631b2a4f454fff94faeb59a3360a573 | takami228/atcoder | /abc/068/b.cpp | C++ | cpp | 320 | no_license | #include <iostream>
#include <string>
#include <vector>
#include <map>
#include <set>
#include <queue>
#include <stack>
#include <cmath>
#include <iomanip>
#include <algorithm>
using namespace std;
using ll = long long;
int main(){
int n;
cin >> n;
cout << (int)pow(2,(int)log2(n)) << endl;
return 0;
}
|
b5990edfada26bdaeccd089e4cb35d06765837a1 | 34aab38236f7a04f3773b401ea264dec621e3bd3 | hibino0429/gameLib | /gameLib/src/Component/SpriteRender/SpriteRender.cpp | C++ | cpp | 1,236 | permissive | #include "SpriteRender.h"
Sprite2D::Sprite2D(const std::string& filePath)
{
spriteBatch = new DirectX::SpriteBatch(&Engine<DXDevice>::GetDevice().GetDeviceContext3D());
std::wstring wstr = std::wstring(filePath.begin(), filePath.end());
LPCWSTR sw = wstr.c_str();
DirectX::CreateWICTextureFromFile(&Engine<DXDevic... |
1ce7d3fd6b9c15b142888ac18faec061f9cc37ba | e1d6d508388a6fb4673779055d08bf2263a325bc | knightzf/review | /leetcode/oddEvenLinkedList/main.cpp | C++ | cpp | 1,223 | no_license | #include <vector>
#include <iostream>
#include <algorithm>
#include <set>
#include <sstream>
#include <cmath>
#include <queue>
#include <map>
#include <list>
#include <string>
#include <cstdlib>
#include <cctype>
#include <stdexcept>
#include <climits>
#include <utility>
#include <bitset>
#include <stac... |
07f55e252f82673e129e4f5999d6e6d582bffeae | 32763adfbdffa7554c66e327382295241000922f | whuang67/surveyfreq | /src/RcppExports.cpp | C++ | cpp | 3,432 | no_license | // Generated by using Rcpp::compileAttributes() -> do not edit by hand
// Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393
#include <RcppArmadillo.h>
#include <Rcpp.h>
using namespace Rcpp;
// fibonacci
int fibonacci(int n);
RcppExport SEXP _surveyfreq_fibonacci(SEXP nSEXP) {
BEGIN_RCPP
Rcpp::RObject rcpp_r... |
8d315da411cdbb4f129af3ace1b248e0978a7453 | 2ab611de92483f0754b75178e393b5c7f5b903f0 | pourtheworld/mydb | /src/include/ossPrimitiveFileOp.hpp | C++ | hpp | 4,047 | no_license | #ifndef OSSPRIMITIVEFILEOP_HPP_
#define OSSPRIMITIVEFILEOP_HPP_
#include "core.hpp"
#ifdef _WINDOWS
#include <io.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <sys/types.h>
#define OSS_F_GETLK F_GETLK64
#define OSS_F_SETLK F_SETLK64
#define OSS_F_SETLKW F_SETLKW64
#define oss_struct_stat... |
7155f23b58c12ff44e544d16ca42675d0ea1b839 | 0a70f03087c4b84931aa7317e095419ab882e46d | luco2018/ROCR-Runtime | /src/core/runtime/hsa_ext_amd.cpp | C++ | cpp | 27,062 | permissive | ////////////////////////////////////////////////////////////////////////////////
//
// The University of Illinois/NCSA
// Open Source License (NCSA)
//
// Copyright (c) 2014-2015, Advanced Micro Devices, Inc. All rights reserved.
//
// Developed by:
//
// AMD Research and AMD HSA Software Development
//... |
f7850a56dd355e9357babe63dc9f74c16f96bbdf | eedaf6e67e5ad11c92382640b60e23c228f21dd2 | ExiaHan/oatdump_plus | /compiler/optimizing/sharpening.cc | C++ | cc | 13,682 | permissive | /*
* Copyright (C) 2015 The Android Open Source Project
*
* 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 app... |
063a6ed71e34ab037701225aebddc90218007a93 | 15fd7dd2b967b4e4ccfeeea6513f19c1bd6c130c | henri98/Bomberman | /workInProgress/nunchucktesting.cpp | C++ | cpp | 781 | no_license | #include <Nunchuck.h>
#include <Arduino.h>
int main(int argc, char const *argv[])
{
init();
Serial.begin(9600);
nunchuck_init();
while (true) {
delay(100);
// struct buf *buffer;
struct buf *buffer = (buf *) malloc(sizeof(struct buf));
nunchuck_get_data(buffer);
Serial.print(buffer->zB... |
f8f75680d5cc473b573fc32ca711e59f0c4f60a6 | 12802f28ff424244d17eb8149b55f095bb85bead | genevea/TankController | /test/DateTime.cpp | C++ | cpp | 2,415 | permissive | #include <Arduino.h>
#include <ArduinoUnitTests.h>
#include "Devices/DateTime_TC.h"
/**
* year has to be range: 2000-2099
* following command only runs this test
* bundle exec arduino_ci.rb --skip-examples-compilation
* --testfile-select=DateTime.cpp
*/
unittest(singleton) {
DateTime_TC dt(2021, 2, 15, 1, 48,... |
61d2fdc82522517656bd209a6670627c5210699e | 23de8cc5455f60b91099b7dfa5487c7718a377fe | caiorasec/contrail-controller | /src/ifmap/ifmap_graph_walker.cc | C++ | cc | 13,562 | permissive | /*
* Copyright (c) 2013 Juniper Networks, Inc. All rights reserved.
*/
#include "ifmap/ifmap_graph_walker.h"
#include <boost/bind.hpp>
#include "base/logging.h"
#include "db/db_graph.h"
#include "db/db_table.h"
#include "ifmap/ifmap_client.h"
#include "ifmap/ifmap_exporter.h"
#include "ifmap/ifmap_link.h"
#include ... |
4f381252cb95857137eda7927b8b8d0dd3a25856 | 2c53a035f276e85ee1aef0c241157107262a42ae | codahq/SoT-SDK | /SDK/SoT_BP_PromptActor_EmissarySecuredLootOnShip_AF_classes.hpp | C++ | hpp | 2,066 | no_license | #pragma once
// Sea of Thieves (2.0) SDK
#ifdef _MSC_VER
#pragma pack(push, 0x8)
#endif
#include "SoT_BP_PromptActor_EmissarySecuredLootOnShip_AF_structs.hpp"
namespace SDK
{
//---------------------------------------------------------------------------
//Classes
//--------------------------------------------------... |
e40b5668c7ec10c5c844df819dee152a587f384a | 497d19b701227f21ccacd5d50739fed84a068c3d | BackupTheBerlios/ziahttpd-svn | /branches/ziis/src/mod/resource/src/include/resource.hh | C++ | hh | 5,431 | no_license | //
// resource.hh for in
//
// Made by texane
// Login <texane@gmail.com>
//
// Started on Wed Mar 22 10:25:56 2006 texane
// Last update Mon Apr 10 01:29:59 2006
//
#ifndef RESOURCE_HH
# define RESOURCE_HH
#include <sstream>
#include <iomanip>
#include <string>
#include <sys/sysapi.hh>
#... |
13a22c6e12abe0112d0b683ef5a3d0d6d56c8dc5 | f2c06feb9e4e818032bc97bc964f547e95869f9b | alibaba/heterogeneity-aware-lowering-and-optimization | /tests/unittests/lit_cases/test_dnnl/test_mod_bcast_dnnl.cc | C++ | cc | 1,913 | permissive | //===-test_mod_bcast_dnnl.cc-----------------------------------------------------------===//
//
// Copyright (C) 2019-2020 Alibaba Group Holding Limited.
//
// 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 ... |
e436843409ff260eabf12f546eaaaa875af4f540 | 25b9415d6dfcfca60fabbbe9b0c63c91b408feb6 | bino7/chromium | /chromecast/media/audio/cast_audio_mixer_unittest.cc | C++ | cc | 15,269 | permissive | // Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chromecast/media/audio/cast_audio_mixer.h"
#include <stdint.h>
#include <algorithm>
#include <memory>
#include <vector>
#include "base/bind.h... |
bbac36615804030ece79dc822ac1c7442cf19e48 | 4ea84e9495954685066655ef5023bcd053c16570 | CrackerCat/hypervisor | /kernel/src/dispatch_syscall_vp_op.hpp | C++ | hpp | 6,417 | permissive | /// @copyright
/// Copyright (C) 2020 Assured Information Security, Inc.
///
/// @copyright
/// 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 limita... |
e674e0e730661086b95122fe86349a11d30a27ef | da2976c312d7ca9e034f76be7d393c95a31d8349 | PowerUser64/dP-2 | /BetaEngine/Game/Asteroids/Source/Level2.cpp | C++ | cpp | 322 | permissive | #include "stdafx.h"
#include "Level2.h"
Level2::Level2()
{
}
void Level2::Load()
{
}
void Level2::Initialize()
{
}
void Level2::Update(float dt)
{
}
Beta::GameObject* Level2::CreateShip(void)
{
return nullptr;
}
Beta::GameObject* Level2::CreateBulletArchetype(void)
{
return nullptr;
}... |
88080525d1e0d44268998ce40858e735b6e450e9 | ca718ffd2e78bba45decdcb74d0a9ea6e0186b38 | LeBob007/School_stuff | /basic-cpp-programs/roman_numerals.cpp | C++ | cpp | 1,250 | no_license | //Program: roman_numerals.cpp
//Author: Robert Hu
//Online class: cs102
//Semester: Spring 2018
//Description: converts integers ranging from 1 to 10 into roman numerals
#include <iostream>
#include <iomanip>
#include <string>
using namespace std;
int main ()
{
int number;
cout << "Enter a number between 1 through... |
7912fc9eee29264c308ee9663d7e891e6f97c5d1 | fd776823562066ff14b5a8337a0d6db92e29984f | KqSMea8/sstd_library | /sstd_boost/sstd/boost/preprocessor/config/config.hpp | C++ | hpp | 5,502 | permissive | # /* **************************************************************************
# * *
# * (C) Copyright Paul Mensonides 2002-2011. *
# * (C) Copyright Edward Diener 2011. *... |
7b15cd5b44d6781f3acdea4872ae2aba6b8755f5 | 6325465429eddeb22ff379d99bb7033d5441a2d8 | irods/aws-sdk-cpp | /aws-cpp-sdk-chime-sdk-messaging/source/model/SendChannelMessageRequest.cpp | C++ | cpp | 2,598 | permissive | /**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/chime-sdk-messaging/model/SendChannelMessageRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/utils/memory/stl/AWSStringStream.h>
#include <utility>
using n... |
147fd7e440238a60ffcaff73d6588cd1a21d0efa | 577b3165b9b17d2ec405eb8545dd50e5a2eae3af | nkxuyin/mokka-cepc | /source/Geometry/tbeam/src/TBCellReplication.cc | C++ | cc | 3,119 | no_license | #include "Control.hh"
#include "TBCellReplication.hh"
#include "G4VSolid.hh"
#include "G4Box.hh"
#include "G4VisAttributes.hh"
TBCellReplication::TBCellReplication()
{
n_row = n_cell_z = 0; cell_hx = cell_hz = 0;
}
TBCellReplication::TBCellReplication(G4LogicalVolume *MomLog, G4LogicalVolume *CellLog)
{
n_row =... |
8548e25a6148bf6480113bc1738818c99cd0ce7a | 1bac2259b8001b83955b044b4c7f3e6665e70a72 | i-black-angel/libmpl | /test/signal.cpp | C++ | cpp | 1,346 | permissive | /**
* Copyright 2017 Shusheng Shao <iblackangel@163.com>
*
* 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 appl... |
3c612632b979acc92e1824167798b0a2e23e495f | 53c15cc12558815ee2a087de0e2b8b7c933ff986 | wangdi2014/sherpas | /sherpas/src/groups.cpp | C++ | cpp | 3,213 | permissive | /*
* groups.cpp
*
* Created on: 22 may 2019
* Author: scholz
*/
#include<iostream>
#include<fstream>
#include<vector>
#include <string>
#include<cmath>
#include "groups.h"
using namespace std;
//everything needed to put the notion of groups at the heart of the output.
//does not affect the way the main al... |
49bc377f7a0f737709da62fd93743a92dbb51693 | be5efa872ebf8c817cba5bdaaa687d7e67c67448 | arnaudsteen/SiW-Calorimeter-Simulation | /src/SiWRun.cc | C++ | cc | 7,477 | no_license | #include "SiWRun.hh"
#include "G4Event.hh"
#include "G4HCofThisEvent.hh"
#include "G4SDManager.hh"
#include "G4ios.hh"
#include "SiWTrackHit.hh"
#include <iostream>
#include <cmath>
#ifdef ROOT_OUTPUT
#include "DetectorConstruction.hh"
#include "SiWEcalPrimaryGeneratorAction.hh"
#endif
SiWRun::SiWRun()
{
G4SDManage... |
84850902e2ca96567b91561379e4dd09b448b2dc | 837da30b21a999fb48f68800dfdb1d7b9ee78e0d | zhangtufei/HDOJ | /2067/源.cpp | C++ | cpp | 1,209 | no_license | //卡塔兰数或者DP
//#include <iostream>
//using namespace std;
//卡塔兰数解法
//int main()
//{
// long long h[36];
// h[0] = h[1] = 1;
// for (int i = 2; i <= 35; ++i)
// {
// h[i] = (4 * i - 2) / (1.0*(i + 1))*h[i - 1];
// }
// int n;
// int a = 1;
// while (cin >> n&&n != -1)
// {
// cout << a++ << ' ' << n << ' ' << h[n]*2 << ... |
3558e687874862cd29eb54bd00bcc1c39d305eef | 83fc0f3cab57de1c27dc9fb4ece53dd23ea596ac | bittnt/paperdoll | /lib/mexopencv-2.4.11/src/+cv/private/SVD_compute_.cpp | C++ | cpp | 1,533 | permissive | /**
* @file SVD_compute_.cpp
* @brief mex interface for SVD_compute_
* @author Kota Yamaguchi
* @date 2012
*/
#include "mexopencv.hpp"
using namespace std;
using namespace cv;
/**
* Main entry called from Matlab
* @param nlhs number of left-hand-side arguments
* @param plhs pointers to mxArrays in the left-han... |
13c0c8784d82ec9c3b27ad5b81ed79caad96274f | 0074dd3ff68c7fccdf30b3bbc4b0ca3faf384ff4 | raducaz/ArduinoMate | /ARDUINOV2/ArduCommandExecutorV3/lib/logger/log.cpp | C++ | cpp | 1,903 | no_license | #include "log.h"
#include <Arduino.h>
#include <Ethernet.h>
#include <globals.h>
void Log::debugln(const __FlashStringHelper* lbl, const char* msg)
{
#ifdef DEBUG
Serial.print(lbl);Serial.println(msg);
#endif
}
void Log::debugln(const __FlashStringHelper* lbl, byte msg)
{
#ifdef DEBUG
Serial.p... |
1810db2ffc58417a4390826d32e2df565ff08c9d | d5c5321b3e29049821ec1ea518deed18b5a11f72 | TeamVault/tauCFI | /C++ Benchmark Programs/Benchmark Files 1/classtester/autogen-sources/source-2779.cpp | C++ | cpp | 2,511 | no_license | struct c0;
void __attribute__ ((noinline)) tester0(c0* p);
struct c0
{
bool active0;
c0() : active0(true) {}
virtual ~c0()
{
tester0(this);
active0 = false;
}
virtual void f0(){}
};
void __attribute__ ((noinline)) tester0(c0* p)
{
p->f0();
}
struct c1;
void __attribute__ ((noinline)) tester1(c1* p);
struct c1
{
bool ac... |
7b1b16fc9c2a555042256be2f1e5840d0db296d3 | 8e14bc8cd4fb28fd9724c26239355a223e7fe5f9 | helloful/BPNet | /BPNet/main.cpp | C++ | cpp | 483 | no_license | #include<bits/stdc++.h>
#include "BpNet.h"
using namespace std;
int main()
{
BPNet bpnetwork;
vector<int>layer{3,3,4};
vector<double>input{ 0.3, 0.7, 0.4 };
vector<double>output{ 0.5,0.4,0.5,0.7 };
bpnetwork.init(layer);
for (int i = 0; i < 1000; i++)
{
bpnetwork.front(input, layer);
bpnetwork.back_p(output)... |
47ab55877c3da94fcfa34d43e52eadded626435c | 2445b85742803533fc42561fe82ce03a979423af | Team973/Old-Seasons | /2014-offseason-test/src/autoManager.cpp | C++ | cpp | 453 | no_license | #include "autoManager.hpp"
#include "auto/autoCommand.hpp"
#include "auto/waitCommand.hpp"
namespace frc973 {
AutoManager::AutoManager()
{
modes["Test"] = new AutoSequencer();
modes["Test"]->addSequential(new WaitCommand(1));
it = modes.begin();
}
AutoSequencer* AutoManager::getCurrentMode()
{
retu... |
c8ce00c83e67b4300b06cffe9cb07a75a38d706a | 0ff38d51fc3af4cd94921346ae2ec37cfaa2d301 | majiaoliya/acm | /pintia.com/L1_003/main.cpp | C++ | cpp | 416 | no_license | #include <iostream>
#include <string.h>
#include <map>
using namespace std;
int main()
{
for(string str; str="", cin>>str; ) {
map<char, int> m;
for(int i=0; i<str.length(); i++) {
m[str[i]] ++;
}
for(map<char,int>::const_iterator iter=m.begin(); iter!=m.end(); iter+... |
5d80ec455eba04e4ef666f0928ca7d20eb557bf7 | 80aafe1df884af4be2beb0967f8cf5df10c5afc6 | Lawrence-JD/All-Malls-Are-Walls | /Source/Core/ProceduralGeneration/Chunks/ChunkManager.cpp | C++ | cpp | 463 | permissive | // Fill out your copyright notice in the Description page of Project Settings.
#include "Core/ProceduralGeneration/Chunks/ChunkManager.h"
// Sets default values
AChunkManager::AChunkManager()
{
// Set this actor to call Tick() every frame. You can turn this off to improve performance if you don't need it.
Primar... |
b9746b7f43aa143b7725d6db253bf97c7f8f0595 | 139505201bf5f62ea8c54fac0995ee186bcf8ba5 | ffskyfan/LeetcodeTest | /Leetcode/code/wildcard_matching.cpp | C++ | cpp | 4,295 | no_license | //-----------------------------------------------------------------------------------------------------------------
//44. Wildcard Matching
//Hard
//
//Given an input string(s) and a pattern(p), implement wildcard pattern matching with support for '?' and '*' where:
//
//'?' Matches any single character.
//'*' Matches ... |
cbe4517169cd3dc88de167d9a5d03d1162827fbb | c5d7f320e4a04de946372aa343cfc471e97390e1 | ara-oforiwa/prog3 | /DList/Dlist.cpp | C++ | cpp | 2,271 | no_license | /**@file DList.cpp
* File: DList.cpp
* Author: Chen
*
* Created on November 7, 2018, 11:50 PM
*/
#include "DList.h"
/**
* Initializes a new list by setting first and last pointers to null.
* @param dl A reference to the List to initialize
*/
void initializeDList(DList & dl){
dl.first = emptyList;
dl.... |
76249a029bf82e5aee576cb96e58405e55343d2c | 8e8b66a660c0b7a831ad0167f6df871848940839 | scicoin-project/scicoin | /src/qt/guiutil.cpp | C++ | cpp | 13,477 | permissive | #include "guiutil.h"
#include "bitcoinaddressvalidator.h"
#include "walletmodel.h"
#include "bitcoinunits.h"
#include "util.h"
#include "init.h"
#include "base58.h"
#include <QString>
#include <QDateTime>
#include <QDoubleValidator>
#include <QFont>
#include <QLineEdit>
#include <QUrl>
#include <QTextDocument> // For ... |
bf2121e2c920e3973b9d2446ce39ddd872ec0e90 | 58a551ee02d730dcf1f01577a3209e1ab7644965 | GabrielVanLoon/Graduacao_BCC | /semestre_03/SCC0210_algoritmos_avancados/2019_laboratorio_1/aula04_A*Search/exe01_fourWheels.cpp | C++ | cpp | 3,714 | no_license | /**
* Turma de Algoritmos Avançados
* Autor: Gabriel Van Looon
* Data: Mar/2018
* Aula 04 Usando Busca à Estrela (A* Search)
*
*/
/** Exercicio 1 - Four Wheels
*/
#include <iostream>
#include <string>
#include <queue>
#include <string.h>
using namespace std;
#define CONFIG_PROIBIDA -1
#define CONFIG_VIS... |
6401bc63f62b65441da9bee260c004d8c210f368 | d439f2605bcc2191de60aa8a7a21d994a7a6ef0e | asad14053/My-Online-Judge-Solution | /Uva online Judge/uva-10573.cpp | C++ | cpp | 1,084 | no_license | #include <bits/stdc++.h>
using namespace std;
#define pi 2 * acos(0.0)
int main()
{
char item[100], temp[100];
int a, b;
double outerArea, cirBig, cir1, cir2;
int test, t;
cin >> test;
// eat newline
cin.getline(temp, sizeof(temp));
for (t = 0; t < test; ++t)
{
cin.getline(it... |
1c491a0e89e732b3a6834e083e35645c9275aefa | ee23fd8746bc5c31ab5ff8656b1e79cf449bae1b | byam/algorithms | /atcoder/contest/abc/contest/abc227/b.cpp | C++ | cpp | 3,773 | no_license | #include <bits/stdc++.h>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <vector>
//#include <atcoder/all>
// using namespace atcoder;
using namespace std;
// func
#define rep(i, first, last) for (int i = (first); i < (last); i++)
#define rrep(i, last, first) for (int i = (last); i >= (fi... |
2bd058d9417f53af0a0760bb7c2a3f7eb48c5b1b | 4c2f41fb48f1b4a8162fcb7970e9cf5b01288c48 | Popov72/filament | /filament/src/Fence.cpp | C++ | cpp | 5,109 | permissive | /*
* Copyright (C) 2016 The Android Open Source Project
*
* 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 app... |
8b1c68a5a1705b0ea9719547f911c404768addf2 | f70396b2b30adb53d691dfab89bb75d6d483ed05 | gaolichen/stringbit | /source/PrintGround.cpp | C++ | cpp | 6,966 | no_license | #pragma warning(disable:4018)
#include <iostream>
#include <fstream>
#include <string>
#include <vector>
#include <cmath>
#include <algorithm>
#include "StateCollection.h"
#include "TraceState.h"
#include "NormCalculator.h"
#include "StateGenerator.h"
#include "BitUtility.h"
#include "StateType.h"
using namespace std;... |
376ac672d8556405d675fe2e204d9b1b7bb32f05 | d6531517f6b25a78220c0609592ba2840e3aa271 | JosephFoster118/TPPDatabase | /TPPMonitor/src/IRCMessage.cpp | C++ | cpp | 1,966 | no_license | #include "IRCMessage.h"
IRCMessage::IRCMessage(const char* message)
{
memset(sender,0,MAX_SENDER_SIZE);
memset(type,0,MAX_TYPE_SIZE);
memset(trailing,0,MAX_TRAILING_SIZE);
char* full_message;
full_message = new char[2048];
strcpy(full_message,message);
char* reference_front = strchr(full_message,'!');
char... |
6cf8ad7e16d3b87ce894cdeaa0428903c73095c7 | 98a46758482f540f9fed7c33466f914e1cdc3e19 | hsm-hx/AtCoder | /ABC/B/107.cpp | C++ | cpp | 730 | no_license | #include <iostream>
#include <vector>
using namespace std;
int main(void){
int h, w;
int i, j;
vector<string> a(100);
cin >> h >> w;
for(i = 0; i < h; i ++){
cin >> a.at(i);
}
for(i = 0; i < h; i ++){
if(a.at(i).find("#") != string::npos){
continue;
}
else{
cout << a.at(i) ... |
a2e5ed7cc33b8236ae06aeef01ca6e974b058b3d | a9278d362ebead0ec4a916ec114ce48404cca767 | adamtew/USU | /2014/CS1400/Challenges/Chapter 3/3.4_How_Much_Insurance.cpp | C++ | cpp | 671 | no_license | /*Many financial experts advise property owners to insure their homes or
buildings for at least 80 percent of the amount it would cost to replace
the structure. Write a program that asks the user to enter the replacement
cost of a building and then displays the minimum amount of insurance that
should be purchased f... |
63835d8056106a5646e3573a28ae8ac6d020345d | f6fd7f399b4a0a8bf929a57a7fa6a6fce1f27078 | paandahl/tripfinger-ios | /drape/texture_of_colors.cpp | C++ | cpp | 5,431 | permissive | #include "drape/texture_of_colors.hpp"
#include "base/shared_buffer_manager.hpp"
#include "base/stl_add.hpp"
#include "std/cstring.hpp"
namespace dp
{
namespace
{
int const kResourceSize = 2;
int const kBytesPerPixel = 4;
}
ColorPalette::ColorPalette(m2::PointU const & canvasSize)
: m_textureSize(canvasSi... |
762201671c91cfc1d55c449555224a39e881d665 | b40404d1a4d5fa0dcc7ffe1a281f1d0cddabf923 | r0mai/tungsten | /ut/eval/builtin/numericalFunctionsTest.cpp | C++ | cpp | 14,474 | no_license |
#include <boost/test/unit_test.hpp>
#include "Fixture.hpp"
BOOST_FIXTURE_TEST_SUITE( numericalFunctionsTest2, BuiltinFunctionFixture )
using namespace tungsten;
BOOST_AUTO_TEST_CASE( test_Floor_of_x ) {
boost::optional<ast::Node> result = parseAndEvaluate("Floor[x]");
BOOST_REQUIRE( result );
ast::Node expect... |
932afe689cc7b0ab28c9c6e57c052db9fa6578ea | 71d5ffe4060b4cf0076975146d258ae0a3635f67 | ericav99/AbbreviationProgram2 | /item.cpp | C++ | cpp | 2,368 | no_license | // Specification of ADT Item wherex
// an Item is-a Key (technical computer science)
// class Item is a derived or child class of class Key
// data object: a meaning of a texting abbreviation
// operations: create, destroy, copy create, copy
// input, output
//Eric Av and Ryan B... |
4d1daa238079ec0178dacbf9fd146866e500af97 | 0e929bf4357e4ec8b9af5ffd107780c13a49a494 | MaSteve/UVA-problems | /UVA01225.cpp | C++ | cpp | 603 | permissive | #include <cstdio>
using namespace std;
int main() {
int grid[10002][10];
for (int i = 0; i < 10; i++) {
grid[0][i] = 0;
}
for (int i = 1; i < 10002; i++) {
for (int j = 0; j < 10; j++) {
grid[i][j] = grid[i-1][j] + (i%10 == j? 1: 0) + ((i/10)%10 == j && i >= 10? 1: 0) + ((i/100)%10 == j && i >= 100? 1: 0) +... |
c4e5e74e44375bdf0bc6790bbcdd44dd807c56a5 | d773846a931482a88ef7be9c58b6d2e3593f1554 | ashutosh0gupta/llvm_bmc | /examples/litmus/c/run-scripts/tmp_10/ISA2+dmb.st+dmb.sy+dmb.ld.c.cbmc_out.cpp | C++ | cpp | 52,766 | no_license | // Global variabls:
// 0:vars:3
// 3:atom_1_X0_1:1
// 4:atom_2_X0_1:1
// 5:atom_2_X2_0:1
// Local global variabls:
// 0:thr0:1
// 1:thr1:1
// 2:thr2:1
#define ADDRSIZE 6
#define LOCALADDRSIZE 3
#define NTHREAD 4
#define NCONTEXT 10
#define ASSUME(stmt) __CPROVER_assume(stmt)
#define ASSERT(stmt) __CPROVER_assert(stmt,... |
9333a8b287c7b0d929a05a26d95e542483292402 | 03965bfccba65074cac0c62af021dc083ce2ebae | macro-l/polarphp | /unittests/utils/YamlIOTest.cpp | C++ | cpp | 75,529 | no_license | // This source file is part of the polarphp.org open source project
//
// Copyright (c) 2017 - 2019 polarphp software foundation
// Copyright (c) 2017 - 2019 zzu_softboy <zzu_softboy@163.com>
// Licensed under Apache License v2.0 with Runtime Library Exception
//
// See https://polarphp.org/LICENSE.txt for license info... |
d8a0a770295cc72534f73c5301edfc015012b7a2 | 204018633c576f58bd38b861b4bd7593d7291983 | akira2009999/NetAnalyzer-analise-de-trafego | /NetAnalyzer/src/gui/ncurses/panels/PnlTcp.cpp | C++ | cpp | 4,165 | no_license | /*
* PnlTcp.cpp
*
* Created on: Apr 14, 2013
* Author: kazu
*/
#include "PnlTcp.h"
#include "../elements/GPopUp.h"
#include "../../../analyzer/Summary.h"
#include "../../../network/processors/TCPReassembler.h"
#include "../helper/GuiHelper.h"
/**
* additional TCP details within a PopUp window
*/
class ... |
385d3613692f3963df17193d00451dde9bf27d1b | ed7f2acd01a636c558e9606012e2f7f98df22f2f | pathakaditya6/Competitive-Programming | /Codechef/Game984A.cpp | C++ | cpp | 605 | no_license | //https://codeforces.com/problemset/problem/984/A
#include<bits/stdc++.h>
#include<string.h>
#include<algorithm>
using namespace std ;
#define akriti long long int
int main()
{
akriti number;
cin >> number ;
vector<akriti> V(number);
for(akriti i = 0; i < number ; i++)
{
cin >> V[i];
}
... |
fbf6f0e8d743835a44f9d2c48562dc00c757d517 | 8f558efbb2aa30566332e293eb6ac5b2ddd1c836 | FudgeRacoon/Scramble-Remake | /src/Graphics/Texture.cpp | C++ | cpp | 1,396 | no_license | #include "Graphics/Texture.hpp"
using namespace Scramble::Graphics;
Texture::Texture(const char* filepath)
{
this->nativeTexture = new OpenGLTexture(filepath);
this->pixels = (U32*)this->nativeTexture->GetRawData();
this->width = this->nativeTexture->GetWidth();
this->height = this->nativeTexture->Ge... |
5e9b7a8d08bd2d4a5ed6e9bc7599619bb1ea78b8 | a8e384c00da58fe75091af33ce9e06dc6b8c7c92 | owenyoung75/stat-test | /basic_funcs.hpp | C++ | hpp | 3,715 | no_license | //
// basic_funcs.hpp
//
//
// Created by YangTong on 11/5/17.
//
//
#pragma once
#include <iostream>
#include <stdlib.h>
#include <fstream>
#include <vector>
#include <time.h>
#include <math.h>
#include <random>
#include <string>
#include <iomanip>
#include <map>
#include <cmath>
#include <chrono>
#include <threa... |
5bbab112eb5a8bc974d5e5beeb04e90d748c0976 | 879dfb10ef8908cc30f3b4a07f62d50318e2b2a5 | HolySmoke86/blank | /src/client/net.cpp | C++ | cpp | 11,403 | no_license | #include "ChunkReceiver.hpp"
#include "ChunkTransmission.hpp"
#include "Client.hpp"
#include "NetworkedInput.hpp"
#include "../app/error.hpp"
#include "../geometry/distance.hpp"
#include "../io/WorldSave.hpp"
#include "../net/Packet.hpp"
#include "../world/Chunk.hpp"
#include "../world/ChunkStore.hpp"
#include "../wor... |
a820ed40271e9e6f90b327409690d97c43ae4c53 | 8d351ccc36f822b3b75d95ad2033cc396595d632 | algisb/shadiray | /src/Core.cpp | C++ | cpp | 1,892 | permissive | ///
/// @file Core.cpp
/// @brief core engine components really generic, can be reused in multiple worlds
#include "Core.h"
using namespace kelp;
Core::Core(int _argc, char ** _argv)
{
glEnable(GL_BLEND);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
glEnable(GL_DEPTH_TEST);
glClearColor... |
4342bf2bb6da574a1847a83870e2136ded929c04 | 1f9c8004100a1809095f6b692415a53f055d24f8 | dh00023/TIL | /algorithm/code/cpp_code/dynamicProgramming/grape.cpp | C++ | cpp | 1,971 | no_license | #include <stdio.h>
#define max(a,b) (((a)>(b))?(a):(b))
/*
효주는 포도주 시식회에 갔다. 그 곳에 갔더니, 테이블 위에 다양한 포도주가 들어있는 포도주 잔이 일렬로 놓여 있었다. 효주는 포도주 시식을 하려고 하는데, 여기에는 다음과 같은 두 가지 규칙이 있다.
포도주 잔을 선택하면 그 잔에 들어있는 포도주는 모두 마셔야 하고, 마신 후에는 원래 위치에 다시 놓아야 한다.
연속으로 놓여 있는 3잔을 모두 마실 수는 없다.
효주는 될 수 있는 대로 많은 양의 포도주를 맛보기 위해서 어떤 포도주 잔을 선택해야 할지 ... |
bd14ee30a334cfa2826006ca8cd698b27fcedd8d | a9c8dfaeb10d15d5c816dd5a439c562fc10a7aa4 | KrzysztofKozubek/Projects | /RecognitionNLP - praca licencjacka/.localhistory/RecognitionNLP/1470141522$Recognitionnlp.cpp | C++ | cpp | 43,529 | no_license | #include "Recognitionnlp.h"
RecognitionNLP::RecognitionNLP(QWidget *parent) : QMainWindow(parent) {
ui.setupUi(this);
setParameters();
fillVectorValue();
fillDefaultValue();
//load data
connect(ui.buttonLoadData, SIGNAL(released()), this, SLOT(clickLoadData()));
//clear list data
connect(ui.buttonLoadClear... |
e28643e30151be6a6670b0e8b3bd2738f574ba9b | e72cf4c52e5a00b9a95196f61845c45aedda3356 | wwwwodddd/Zukunft | /luogu/P2021.cpp | C++ | cpp | 259 | no_license | #include <bits/stdc++.h>
using namespace std;
int n;
deque<int> q;
int main() {
cin >> n;
for (int i = 0; i < n; i++) {
q.push_front(n - i);
q.push_front(q.back());
q.pop_back();
}
for (int i = 0; i < n; i++) {
cout << q[i] << ' ';
}
return 0;
} |
bbfb83d30a744ae8673951bf9f46d1594689ed26 | c85bdbb04297e176618e7c2eab286d00cd9a5c18 | IsraMekki/tiramisu_code_generator | /cmake-build-debug/programs_tiling/function14202/function14202_schedule_3/function14202_schedule_3_wrapper.cpp | C++ | cpp | 855 | no_license | #include "Halide.h"
#include "function14202_schedule_3_wrapper.h"
#include "tiramisu/utils.h"
#include <cstdlib>
#include <iostream>
#include <time.h>
#include <fstream>
#include <chrono>
#define MAX_RAND 200
int main(int, char **){Halide::Buffer<int32_t> buf0(128, 128, 2048);
init_buffer(buf0, (int32_t)0);
... |
714663413c867b32d14b092ce9ef0d18a1c687b1 | 3356d720374cc6e8821839c88e2d8bdf04fd5ca1 | hungarian-notation/lua-game-old | /LuaGame/src/common.cpp | C++ | cpp | 1,029 | no_license | #include "common.h"
#include <glad\glad.h>
#include <GLFW\glfw3.h>
void luagame_check_gl_errors() {
GLenum err = GL_NO_ERROR;
while ((err = glGetError()) != GL_NO_ERROR) {
switch (err) {
case GL_INVALID_ENUM:
_err("GL_INVALID_ENUM");
break;
case GL_INVALID_VALUE:
_err("GL_INVALID_VALUE");
break;
... |
7cd4db128cb4b1179683edd701c5050e190c0a65 | 7e41d360271958dfb2c1f8eea48ff6e3db1e4d86 | jhliberty/AAF | /Utilities/AAFAnalyzer/TestPhaseLib/TopLevelTestResult.cpp | C++ | cpp | 2,449 | no_license | //=---------------------------------------------------------------------=
//
// $Id: TopLevelTestResult.cpp,v 1.4.4.1 2012/10/12 20:07:49 jptrainor Exp $ $Name: V116 $
//
// The contents of this file are subject to the AAF SDK Public Source
// License Agreement Version 2.0 (the "License"); You may not use this
// file ... |
6f57c7f372655c744713d06a8500a0c2744abdfd | fb132981bd0b4f1aa1756cb57e1505d7913f1ec9 | sunilkrg/TheCPSquad | /Gaurav/mincoststairs.cpp | C++ | cpp | 351 | no_license | class Solution {
public:
int minCostClimbingStairs(vector<int>& cost) {
int first = cost[0], second = cost[1], current;
for(int i=2; i<cost.size(); ++i)
{
current = min(first,second)+cost[i];
first = second;
second = current;
}
retu... |
7c57df05121d31654607250cff346ae29c4834eb | eff22abbe97f74bc4316f3b60802021add7770bd | DrSwad/CompetitiveProgrammingArchive | /codeforces/1327/A.cpp | C++ | cpp | 471 | no_license | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;
#define x first
#define y second
#ifdef LOCAL
#include "debug.h"
#endif
const int N = int(1e5) + 10;
int main() {
#ifdef LOCAL
freopen("in", "r", stdin);
freopen("out", "w", stdout);
#endif
int t;
cin >> t;
wh... |
0b322d89673f5c8ffeda3fe99003da4a947a614c | d78372baf63e7c8102b3e0dd35a37c316d758fb3 | csaraugustol/curso-algoritmos-logica | /LinguagemC++/EXEMPLO_BASICO.cpp | C++ | cpp | 569 | no_license | #include <iostream>
#include <iomanip>
#include <string>
using namespace std;
int main()
{
//Exemplo para ler dados
int age;
double salary, height;
char gender;
string name;
age = 20;
salary = 5800.5;
height = 1.63;
gender = 'F';
name = "Maria Silva";
cout << fixed ... |
8691f557fe79962b724155dc53469b5a3a2f749c | eb844a45ffd0d89f63310b4ccd5e7598cbe5fbfc | Vincenzo-Petrolo/sandboxed-api | /sandboxed_api/sandbox2/policy_test.cc | C++ | cc | 11,389 | permissive | // Copyright 2019 Google 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
//
// Unless required by applicable law or agreed to in w... |
8b365cb9ce0135b3dba38444a066fdd3d78f15a8 | 0eaf820d4d0231e7545fa66e7b438ebe68027cc2 | JanuszL/libcudacxx | /libcxx/test/libcxx/language.support/support.initlist/version.pass.cpp | C++ | cpp | 562 | permissive | //===----------------------------------------------------------------------===//
//
// 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
//
//===---------------------------... |
32f5385767d27aa34e7433e673d16be441d99bc5 | 1ed9158682190399563f5c7e1e13aa37f7fbe5b9 | ctguxp/CrapoLibrary | /System/System.Text.RegularExpressions.Category.cpp | C++ | cpp | 15,994 | no_license | #include "pch.h"
#include "System.Text.RegularExpressions.Category.h"
namespace System
{
namespace Text
{
namespace RegularExpressions
{
bool CategoryUtils::IsCategory(Globalization::UnicodeCategory uc, wchar_t c)
{
if(Char::GetUnicodeCategory (c) == uc)
return true;
... |
5f41de7e44d77445969cfc4f43822a043e48d07c | 527dc1eff700639f36d9c188ae180f03394606d5 | ArpitJainAJ/AlgorithmicToolbox | /Week 2 - Algorithmic Warmup/2_fibonacci_last_digit.cpp | C++ | cpp | 709 | no_license | #include <iostream>
int get_fibonacci_last_digit_naive(int n) {
if (n <= 1)
return n;
int previous = 0;
int current = 1;
for (int i = 0; i < n - 1; ++i) {
int tmp_previous = previous;
previous = current;
current = tmp_previous + current;
}
return current % 10... |
cdf99fe991835982f13481761502090fe1291b10 | 489c08926e88f660077ad790552f9112c0456ac3 | ProgrammingIncluded/SmartCacheTesting | /src/page_fault.cpp | C++ | cpp | 2,363 | permissive | #include "page_fault.hpp"
#include "platform_util.hpp"
unsigned long long int size = 0;
page_t* array;
int main(int argc, char* argv[]){
parse_arguments(argc,argv);
init_array();
free(array);
measure_latency();
delete_array();
}
void parse_arguments(int argc, char* argv[]){
int c;
while((c = getopt(arg... |
507fb7c869e350e095cbcdd7019283d4285c364d | ae84d1403f1aa490b0a15aaa1e30f2f6c997f982 | novaquark/aws-sdk-cpp | /aws-cpp-sdk-cloudformation/source/model/Output.cpp | C++ | cpp | 3,852 | permissive | /*
* Copyright 2010-2017 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" fil... |
3807edc9e3e3f0c80792c34a6b17c9e1eed72c9c | c241751fedbc3113c50c1335f91986986388e426 | google-code/algorithmic-composition-utility | /AudioController/Composition/ExperimetalCompose2.cpp | C++ | cpp | 35,077 | no_license | /*
* ExperimetalCompose2.cpp
* SoundController0002
*
* Created by jiro on 10/11/23.
* Copyright 2010 jiro music. All rights reserved.
*
*/
#include "ExperimetalCompose.h"
#include "../sc/SoundController.h"
#include <vector>
#include <iostream>
using namespace sc;
using namespace std;
vector< Note::MidiNu... |
7f8ccb44f3daa63e93371e5612ce28884452ee76 | 875975b54d49c29728d94b28e98fc9c691fe7c39 | bbhavsar/kudu | /src/kudu/master/master-test.cc | C++ | cc | 81,619 | 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... |
184d4cdb376f67e2600712406ae57d47e9b834ee | c804fe400cd28c43d74a3ec2e4b8c29f62288f8b | Tomoki-Kikuta/ari_book | /begginer/C++/limit_napsuck.cpp | C++ | cpp | 1,369 | no_license | #include<iostream>
#include<algorithm>
#include<vector>
#define MAX_N 101
#define MAX_NUMBER 100001
#define INF 1<<21
using namespace std;
void input(int n,vector<int> &number){
for(int i=0;i<n;i++){
int a;
cin >> a;
number.push_back(a);
}
}
bool cal_number(int n,vector<int> &sum,vecto... |
02e402614509b61184cd0864677acf4787e1e30a | dbb289fabe7f04ca73c3e787fa0cc27d0a2cd2bd | Samsung/Castanets | /base/synchronization/lock_unittest.cc | C++ | cc | 6,640 | 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 "base/synchronization/lock.h"
#include <stdlib.h>
#include "base/compiler_specific.h"
#include "base/debug/activity_tracker.h"
#include "ba... |
239139a3ae2387abc31cb84c7b281c91c23064aa | bf133ff612f31e50be64dc9dba1185f6cf7f45b8 | nahales/OOP244-CPP_Programming | /Final_Project/Milestone2/MyFile.cpp | C++ | cpp | 1,513 | no_license | // Final Project Milestone 2
// Tester program
// File MyFile.cpp
// Version 1.0
// Date 3/15/2017
// Author Fardad Soleimanloo
//
// Student Nahal Esmaeili
/////////////////////////////////////////////////////////////////
#define _CRT_SECURE_NO_WARNINGS
#include <iostream>
#include <fstream>
#include <cstring>
#incl... |
67747bfadb6b4cc75da3bdf23492668844062fbe | 190f3e12a8cd0b45589d9b59aea880ee5297d02e | zyhzx123e/HomeStay-Management-System | /hms/home.cpp | C++ | cpp | 34,744 | no_license |
#pragma once
#include "targetver.h"
#include "stdafx.h"
#include "home.h"
#include <stdio.h>
#include <tchar.h>
#include <iostream>
#include <fstream>
#include <sstream>
#include <string>
#include <cstdio>
#include <cstdlib>
#include <regex>
#include <stdlib.h>
#include <string.h>
using namespace std;
home::ho... |
27ba1719748ef500bcd11eac526ee12454c20453 | 4c4f7dbb8adf4e8f0f68be2fa04944a77adad51d | gem-sw/cmssw | /HLTrigger/HLTcore/src/TriggerExpressionL1Reader.cc | C++ | cc | 3,480 | no_license | #include <iostream>
#include <boost/foreach.hpp>
#include <boost/regex.hpp>
#include "FWCore/MessageLogger/interface/MessageLogger.h"
#include "FWCore/Utilities/interface/RegexMatch.h"
#include "CondFormats/L1TObjects/interface/L1GtTriggerMask.h"
#include "CondFormats/L1TObjects/interface/L1GtTriggerMenu.h"
#include "... |
90877c8eeea4b754911028a522b57d978827e52e | 09232d11d1bbaee30ee9c7e3d7b9d61e770642a2 | ChocolateChipKookie/Snake | /Snake.cpp | C++ | cpp | 1,550 | no_license | #include "stdafx.h"
#include "Snake.h"
#include <list>
#include <cstdlib>
#include <ctime>
Snake::Snake(int width, int height, int startingX, int startingY)
:Field(width, height), headPosition({ startingX, startingY })
{
pointList.push_back(headPosition);
srand((unsigned int)time(NULL));
getFoodPosition(&(food.x)... |
a7e2eb05922cd927f813b78b8f7cb99a5b5da9ae | 145bf9aa091e9417b3cd1f276d8ccfed733243f9 | make1122/tencentcloud-sdk-cpp | /ssl/src/v20191205/model/Certificates.cpp | C++ | cpp | 32,737 | 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
... |
24c0fe23dc1ee7618f6bdcc6afce8803ddbd0b91 | 98833cd87364d02efd70e215d1920ebd072c9cff | Green-Blood/TOPL | /PieScript Language/includes/poolOfNodes.cpp | C++ | cpp | 229 | no_license | #include "node.h"
#include "poolOfNodes.h"
PoolOfNodes& PoolOfNodes::getInstance() {
static PoolOfNodes pool;
return pool;
}
void PoolOfNodes::drainThePool() {
for ( const Node* node : nodePool ) {
delete node;
}
}
|
7a1bb196c91e88322e5d8cf649a33eb0b9893f7f | e1dd9a97a763bcacf2b06a331216235144008ecb | Underdog-113/3D_portfolio | /Client/Code/Shot_RotateAround.cpp | C++ | cpp | 1,322 | no_license | #include "stdafx.h"
#include "..\Header\Shot_RotateAround.h"
#include "StageCameraMan.h"
CShot_RotateAround::CShot_RotateAround()
{
}
CShot_RotateAround::~CShot_RotateAround()
{
}
void CShot_RotateAround::Ready(CTake * pTake, _float startTimeline, _float endTimeline, void* pDesc, _float enterTimeline)
{
CShot::Re... |
f5764972108f124c99cf480ca81986ef97a570ad | 3c6c6135f9a7dcedc8e142fc0d387fd8acb6e0c9 | AlvinJ15/CompetitiveProgramming | /h1/ACM/J.cpp | C++ | cpp | 1,848 | no_license | #include <bits/stdc++.h>
using namespace std;
int n,m;
char habitacion[20][20];
bool area[20][20];
char girar(char c){
if(c=='U'){
return 'R';
}
if(c=='D'){
return 'L';
}
if(c=='R'){
return 'D';
}
if(c=='L'){
return 'U';
}
}
void imprimir(){
for(int i=0;i<20;i++){
for(int j=0;... |
e3fc1e6e1266944da29f978cd2caa93fb80f875f | 97484fd62fe88e00b7bc925c38d97899216d0f82 | skyllar/Problem-Solving | /geeksForGeeks/dynamicProgramming/BoxStackingProblem.cpp | C++ | cpp | 2,946 | no_license | /* Dynamic Programming implementation of Box Stacking problem */
#include<stdio.h>
#include<stdlib.h>
/* Representation of a box */
struct Box {
// h > height, w > width, d > depth
int h, w, d; // for simplicity of solution, always keep w <= d
int i;
};
// A utility function to get minimum of two int... |
dc86a76eb8c90d171dd20b1844e114f68066da04 | 3d1b68f2e08f89924bec87381ff8b42092303d55 | siamza080/cl3_mod_client | /cl3_mod_client/ui/dialog_CLNpickCam.hpp | C++ | hpp | 1,805 | no_license | class dialog_CLNpickCam
{
idd = -1;
movingEnable = 1;
controlsBackground[] = {Mainback};
objects[] = { };
controls[] = {TicketChoose, BUTTON1, BUTTON2};
class Mainback : CLRscPicture
{
x = 0.3675-0.02;
y = 0.12865-0.02;
w = 0.303+0.04;
h = 0.22+0.04;
moving = 1;
text = "\cl3_images\images\ui_mainmenu... |
f7868d9c1cfe0db78b59380c8e376c504dd744f1 | ea5c00e70aada6a0c77214eddaf7c11eac6cf069 | brycelelbach/nt2 | /modules/bessel/include/nt2/toolbox/bessel/function/y0.hpp | C++ | hpp | 970 | permissive | //////////////////////////////////////////////////////////////////////////////
/// Copyright 2003 and onward LASMEA UMR 6602 CNRS/U.B.P Clermont-Ferrand
/// Copyright 2009 and onward LRI UMR 8623 CNRS/Univ Paris Sud XI
///
/// Distributed under the Boost Software License, Version 1.0
/// ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.