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 |
|---|---|---|---|---|---|---|---|---|
263851e3e738f97006aa832411ef0d6d7f67722c | 310e69a9a8dd188e899dd0f7c4f02a34fd788f50 | Shaco-Ma/leetcode | /13_roman_to_integer/main.cpp | C++ | cpp | 2,224 | no_license | #include <iostream>
#include <string>
#include <algorithm>
#include <cmath>
#include <limits.h>
#include <map>
#include <set>
#include <utility>
using namespace std;
/*
遍历?map?
遇到M就+1000
遇到C和D,要看下一位是不是X或者L,再看下下一位是不是X或者L,这样把百位的全找出来了,然后根据字串找这个值
遇到X和L,找下一位和下下一位是不是I或者V,找到不是这俩的,根据字串找值
遇到I,直接找到尾部
*/
class S... |
6e196023dbdee8ec7427b2e4744546ccdfef3545 | c6890d5119a9eb89a194821e248ed11fd39b57d2 | namld01810/MiniGame | /Classes/PlayLayer.cpp | C++ | cpp | 29,611 | permissive | //
// PlayLayer.cpp
// SushiCrushGame
//
// Created by MACBOOK AIR on 4/11/16.
//
//
#include "PlayLayer.hpp"
#include "SushiSprite.hpp"
#define MATRIX_WIDTH (7)
#define MATRIX_HEIGHT (10)
#define SUSHI_GAP (1)
PlayLayer::PlayLayer()
: spriteSheet(NULL)
, m_matrix(NULL)
, m_width(0)
, m_height(0)
, m_matrixLeftB... |
93372491ef98a0620076bd92383a4970645ef485 | 6d3dd3df3ffb9c2c9f23a3d660b8f414b2b5009e | salehmoe/AliPhysics | /PWGLF/RESONANCES/AliRsnMiniPair.cxx | C++ | cxx | 9,682 | no_license | #include "AliRsnMiniParticle.h"
#include "AliRsnMiniPair.h"
ClassImp(AliRsnMiniPair)
//__________________________________________________________________________________________________
void AliRsnMiniPair::Fill
(AliRsnMiniParticle *p1, AliRsnMiniParticle *p2, Double_t m1, Double_t m2, Double_t refMass)
{
//
// Fill ... |
facdf92985604c154db801ffb40ee971e68224ed | 5a38e32a69e7fe9c6dc9c5f4b1fd77d96b6e75e0 | JakeBrawer/misc | /classes/yale/oop/HW3/conway_main.cpp | C++ | cpp | 2,299 | no_license | #include <iostream>
#include <fstream>
#include <cstring>
#include <cstdlib>
#include <string>
#include "conway.h"
using cs427_527::Conway;
int main(int argc, char **argv)
{
char *s = argv[0] + strlen(argv[0]) - 1;
while (s > argv[0] && *(s - 1) != '/')
{
s--;
}
std::string exeNa... |
44534351f5c99d70593216da13f61a6a085f31cd | a501984a3796f124ca871c4b7e296c4354e2ce81 | nialche98/laboratorio | /objetos/proyecto/proyecto/preguntas.cpp | C++ | cpp | 208 | no_license | #include "preguntas.h"
#include "ui_preguntas.h"
preguntas::preguntas(QWidget *parent) :
QDialog(parent),
ui(new Ui::preguntas)
{
ui->setupUi(this);
}
preguntas::~preguntas()
{
delete ui;
}
|
cb1626675668412c21ec855234232c40dbe6ed6a | 9a59fa3c4651eba95ff262049de2be7c63753b23 | Darina000/G4_scintillation_f | /include/DetectorConstruction.hh | C++ | hh | 1,008 | no_license | // DetectorConstruction.hpp
//
//
// Created by Дарья Землянская on 19.07.2020.
//
#ifndef DetectorConstruction_h
#define DetectorConstruction_h 1
#include<globals.hh>
#include<G4VUserDetectorConstruction.hh>
#include<G4VSolid.hh>
#include<G4LogicalVolume.hh>
#include<G4VPhysicalVolume.hh>
#include<G4Material.hh>... |
b02bbcb53059552196607cc3c0b972c67c84a4bd | e62d76b2590c82d400bd2f6c3c08505d4e0313c9 | jtilson/PSOCI | /psociRestart-Cori/PsociDeterminants.hpp | C++ | hpp | 7,916 | no_license | /**************************************************************************************
* Copyright (c) 2010,2011 RENCI.
* All rights reserved. This program and the accompanying materials
* MAY BE available under the terms of the RENCI Open Source License
* UNC at Chapel Hill which accompanies this distribution, and i... |
6b891a5748816eb7d9230e93c9b52c6b6e48a8a1 | 964272dbd503250323d8602929375d158f3e2a98 | RossComputerGuy/wayfire | /plugins/single_plugins/preserve-output.cpp | C++ | cpp | 10,047 | permissive | #include "wayfire/nonstd/observer_ptr.h"
#include "wayfire/object.hpp"
#include "wayfire/output.hpp"
#include "wayfire/util.hpp"
#include <sys/types.h>
#include <chrono>
#include <wayfire/plugin.hpp>
#include <wayfire/view.hpp>
#include <wayfire/core.hpp>
#include <wayfire/workspace-manager.hpp>
#include <wayfire/signa... |
3b4d9dfe44e432c941ba671135a4c89b944b93ad | 1f6971807a4ca4160a2668eb622fffe2fa935930 | rex-schilasky/ros2_samples | /subscriber_string/main.cpp | C++ | cpp | 589 | permissive | #include <memory>
#include "rclcpp/rclcpp.hpp"
#include "std_msgs/msg/string.hpp"
class StringSubscriber : public rclcpp::Node
{
public:
StringSubscriber()
: Node("string_subscriber")
{
auto subscription_ = this->create_subscription<std_msgs::msg::String>(
"String",
10,
[this](std_msgs::ms... |
071aa9650c57b4ad092c0a6ab77833270aad4350 | 788d8f19ff389c24280a4d508cd5ad994db89aa3 | hzy9819/ICPC-Problem-Code-Solution | /training contest (NEERC)/题解/neerc-2015-archive/king/king_tourist_tl.cpp | C++ | cpp | 1,235 | no_license | #include <vector>
#include <algorithm>
#include <cstdio>
#pragma comment(linker, "/STACK:36777216")
using namespace std;
#define FILENAME "king"
#define NO "There is no route, Karl!"
const int N = 1234567;
vector <int> go[N], gi[N];
int a[N], b[N];
bool was[N];
int n;
void dfs(int v, int w) {
if (w == n)... |
d9eef5bed7ff0f37bb2c8e31d201e5127e200781 | 85513e3c0795dbc751ccc88bf4861316ddfc4f57 | NCAR/lrose-core | /codebase/apps/radar/src/TerrainHtServer/SquareDegree.hh | C++ | hh | 3,947 | permissive | // *=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*
// ** Copyright UCAR (c) 1990 - 2016
// ** University Corporation for Atmospheric Research (UCAR)
// ** National Center for Atmospheric Research (NCAR)
// ** Bo... |
6e5dd70dc832e5c0b40d66afc45a44d892fd7c5f | 6cc6552c7ccc432557f231ecce4f441a68026a44 | scharrin/ocvTut | /cvTest/main histogram.cpp | C++ | cpp | 2,444 | no_license | /// histogram
///
#include <iostream>
#include "opencv2/opencv.hpp"
#include "dd.h"
using namespace std;
using namespace cv;
RNG rng;
int main(int argc, const char * argv[]) {
const int binaryThreshold = 127;
const int maxThreshold = 255;
const int lineWeight = 3;
const int circleRadius = 10;
... |
9e8a307fbcf7dd0272c73ce0f2319f4197161e31 | 1542cbd3aa1f160411c4c6adbda5b5518548fdcf | cppid/contoh-tugas-program-cpp | /tugas/luas_dan_keliling/rectangle.cpp | C++ | cpp | 558 | permissive |
/**
* @author Ammar Faizi <ammarfaizi2@gmail.com>
*
* [Program Perhitungan Luas dan Keliling Persegi Panjang]
*/
#include <iostream>
int main(int argc, char const *argv[])
{
float a, b;
std::cout << "[Program Perhitungan Luas dan Keliling Persegi Panjang]\n";
std::cout << "Masukkan pangjang sisi ke-1 : ";
... |
f38ff32216b89c5882e7e9ec96d449fe7a9da125 | d436ec1215fd6e0e355d8ec52e5b255d7142d429 | xanushkasrivastavax/Dynamic-Programming-Codes-C- | /LongestValidParenthesis.cpp | C++ | cpp | 583 | no_license | class Solution {
public:
int longestValidParentheses(string s) {
vector<int> dp(s.size()+1,0);
for(int i=1;i<s.size();i++){
if(s[i]==')'){
if(s[i-1]=='('){
dp[i]=((i-2)>=0 ? dp[i-2] : 0) +2;
}
else{
i... |
94cfbc7186a5825fc934721523e5c4cd23e4c821 | 01e1fe5e2b439f58ceca38424d69256010ef6bff | mutour/mozc | /src/win32/ime/ime_impl_imm.cc | C++ | cc | 39,508 | permissive | // Copyright 2010-2015, Google 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 condit... |
b7ca54b8af5c1963c08cf4f03bc7eb281f03645e | 90a5568562abf05e64fa52757a47b5d8938a1d94 | teitei-tk/Cocos2d-js-Test | /frameworks/js-bindings/cocos2d-x/cocos/2d/platform/winrt/CCGLView.cpp | C++ | cpp | 15,204 | no_license | /****************************************************************************
Copyright (c) 2010 cocos2d-x.org
Copyright (c) Microsoft Open Technologies, Inc.
http://www.cocos2d-x.org
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the ... |
8adce78591bfab8be68ff3973d354e94098563da | 263c96b68572efd42ce837aae055ee71a089e094 | pytorch/pytorch | /caffe2/operators/unsafe_coalesce.cc | C++ | cc | 1,090 | permissive | #include "caffe2/operators/unsafe_coalesce.h"
namespace caffe2 {
OPERATOR_SCHEMA(UnsafeCoalesce)
.NumInputsOutputs([](int inputs, int outputs) {
return inputs + 1 == outputs;
})
.AllowInplace([](int input, int output) { return input == output; })
.SetDoc(R"DOC(
Coalesce the N inputs into N outpu... |
7a8b93873bf3816adb73b66398736ab57a3bdaee | e2ae8f6412b396cfc9c0308c1d654bd016f8a077 | ltsochev-dev/tabula-rasa-server-emulator | /JHLIB/JHLIB.cpp | C++ | cpp | 820 | no_license | // JHLIB.cpp : Defines the exported functions for the DLL application.
//
#include "stdafx.h"
#include "JHLIB.h"
//// This is an example of an exported variable
//JHLIB_API int nJHLIB=0;
//
//// This is an example of an exported function.
//JHLIB_API int fnJHLIB(void)
//{
// return 42;
//}
//
//// Th... |
be281471e7609f8a21fc18ec66852c4293ac70ae | 29d317d63ea70ef6c3a5290fd2fd093c3892abc1 | ikasoumen4/algorithm | /algorithm/Montecarlo .cpp | C++ | cpp | 2,220 | no_license | #include<stdio.h>
#include<stdlib.h>
#include<time.h>
#include "stdafx.h"
#include "Montecarlo.h"
#define n 1000000
/**
* @file ファイル名.h
* @brief 円周率をモンテカルロを用いて求めるプログラムをまとめたソースである。
* @author 私
* @date 2016/12/15
*/
/**
* @fn
* モンテカルロ法とは、シミュレーションや数値計算を乱数を用いて行う手法である。
* 誤答する確率の上界が与えられる乱択アルゴリズムと定義される。
* モンテカルロを利用できる問題
* ... |
a7152e38a6150d0caa5d2e8f49e6f4de39c71999 | 4b0a8058194e7e2576c7242bc666a84ee65527e3 | toyobayashi/napi-learning | /object/index.cpp | C++ | cpp | 898 | no_license | #include "./nobject.h"
#include "../string/nstring.h"
#include "../function/nfunction.h"
#include "../type/ntype.h"
static napi_value runCallback (napi_env env, napi_callback_info info) {
size_t argc = 2;
napi_value args[2];
NAPI_CALL(env, napi_get_cb_info(env, info, &argc, args, nullptr, nullptr));
NAPI_ASSER... |
18f3bb72d0cfe20b251cb84b7cde4d0ae61eacd9 | f56892a7f4b8864d70bc5b498fab5a3f3b7ec367 | The-OpenROAD-Project/OpenROAD | /src/odb/test/cpp/TestGroup.cpp | C++ | cpp | 7,538 | permissive | #define BOOST_TEST_MODULE TestGroup
#include <boost/test/included/unit_test.hpp>
#include <iostream>
#include <string>
#include "db.h"
#include "helper.cpp"
using namespace odb;
using namespace std;
struct F_DETAILED
{
F_DETAILED()
{
db = create2LevetDbNoBTerms();
block = db->getChip()->getBlock();
li... |
a7c138c05f8e0e147e0167f8ae46d1ae08c94ef9 | 7b8686c00d3ef88315a65e5cc1c859d1843a7022 | yahia3200/oop_project | /ToPlayMode.cpp | C++ | cpp | 342 | no_license | #include "ToPlayMode.h"
#include "Grid.h"
ToPlayMode::ToPlayMode(ApplicationManager* pApp):Action(pApp)
{
}
void ToPlayMode::ReadActionParameters()
{
}
void ToPlayMode::Execute()
{
Grid* pGrid = pManager->GetGrid();
Output* pOut = pGrid->GetOutput();
pOut->CreatePlayModeToolBar();
}
ToPlayMode:... |
2555bc15d6786468cabd1beb1dfbd87a1a96c9fe | 005c63b1c6ec5cc290853df1a275ac55891c7ba6 | SQReder/SimplePluginCore | /src/LispPlugin/LispPlugin.cpp | C++ | cpp | 13,790 | no_license | #include <QtCore/QtPlugin>
#include <QtCore>
#include <iostream>
#include <stdexcept>
#include <assert.h>
#include "ConsoleColor.h"
using namespace std;
using namespace std;
#include "LispPlugin.h"
Env global_env;
//===============================================================
void LispPlugin::init() {
QVar... |
f55f1f2010ba667ee8a98076a6bc7a114b8eddca | 8ab9ccdace1be96cbd05bdeecf1a2cc037f258e8 | DecodeGenetics/graphtyper | /include/graphtyper/utilities/string.hpp | C++ | hpp | 2,885 | permissive | #pragma once
#if __has_include(<charconv>)
# include <charconv>
#endif
#include <string>
#include <string_view>
#include <vector>
#include <graphtyper/utilities/logging.hpp>
namespace gyper
{
//----------------------------------- starts_with / ends_with ----------------------------
// TODO: this can be implemented ... |
e0b9eedc1c33466307afa9d1c92721a13699621e | c8205b43228fb3f54cb075ae2a151dc36b74494c | bilgilis/gkyl | /Updater/primMomentsCalcData/VmSelfPrimMomentsMax1x3vP1.cpp | C++ | cpp | 5,632 | no_license | #include <PrimMomentsModDecl.h>
using namespace Eigen;
void VmSelfPrimMoments1x3vMax_P1(binOpData_t *data, const double *m0, const double *m1, const double *m0S, const double *m1S, const double *m2S, const double *cM, const double *cE, double *u, double *vtSq)
{
// m0,m1: moments of the distribution fun... |
1c9477776bf46c658bd3169adb859e6abb1d42fd | 7b79fa54c2491ec958e3ff87f91191d518d396f7 | rajatyadav1994/IPSC-Project | /novecsvd.cpp | C++ | cpp | 19,015 | no_license | #include<bits/stdc++.h>
#include "omp.h"
using namespace std;
#define SIGN(a, b) ((b) >= 0.0 ? fabs(a) : -fabs(a))
#define MAX(x,y) ((x)>(y)?(x):(y))
void generate_values(vector<vector<int>>&A,int row,int column)
{
srand(time(NULL));
for(int i = 0;i<row;i++)
{
for(int j =0;j<column;j++)
{
A[i][j] = (ran... |
9ee53972a72a856077255f51e4507eea2357875b | 02931d01472bda86f18b017786c022981b065529 | femtomc/Birch | /libbirch/libbirch/Reacher.hpp | C++ | hpp | 1,288 | permissive | /**
* @file
*/
#pragma once
#include "libbirch/Tuple.hpp"
#include "libbirch/Array.hpp"
#include "libbirch/Optional.hpp"
#include "libbirch/Lazy.hpp"
namespace libbirch {
/**
* Visitor for recursively flagging reachable objects for cycle collection.
*
* @ingroup libbirch
*/
class Reacher {
public:
/**
* Vi... |
bb98c5b766197c4c2a4eb8139938c0fa950fbda5 | 1c93ad420311b2ebbc31930c0c18360ca4bd0866 | lastweek/nica | /ikernels/hls/passthrough-impl.hpp | C++ | hpp | 2,651 | permissive | //
// Copyright (c) 2016-2017 Haggai Eran, Gabi Malka, Lior Zeno, Maroun Tork
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without modification,
// are permitted provided that the following conditions are met:
//
// * Redistributions of source code must retain the above copy... |
52105acc83e3395ca754d6fea2e74f9b65528833 | f3a5fc6257c23cd0b35ca5ee88d27781ff17f074 | mhochsteger/blaze | /blazemark/src/mtl/Mat6Mat6Add.cpp | C++ | cpp | 4,636 | permissive | //=================================================================================================
/*!
// \file src/mtl/Mat6Mat6Add.cpp
// \brief Source file for the MTL 6D matrix/matrix addition kernel
//
// Copyright (C) 2012-2019 Klaus Iglberger - All Rights Reserved
//
// This file is part of the Blaze library... |
4255963018220052c1a3dac6899562419a69b1a2 | d87429e1bb69fe85006e6a5e47bd9ba27c9eefdf | zimingwei/leetcode | /word_ladder.cpp | C++ | cpp | 922 | no_license | class Solution {
public:
// Time: O(n)
// Space: O(n)
int ladderLength(string start, string end, unordered_set<string> &dict) {
unordered_set<string> visited;
queue<pair<string, int>> Q;
Q.push(make_pair(start, 1));
visited.insert(start);
while (!Q.empty()) {
... |
e389e862c7b22511b86ad21aacd72de4ad24789b | 2d29dd46d268c8e1eb7687e3e9f8978a00917109 | chromium/chromium | /ui/aura/client/cursor_client.cc | C++ | cc | 740 | permissive | // Copyright 2012 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "ui/aura/client/cursor_client.h"
#include "ui/aura/window.h"
#include "ui/base/class_property.h"
DEFINE_UI_CLASS_PROPERTY_TYPE(aura::client::CursorClient*)
namespac... |
759a1eef8765f8202e15ddaae7d5ebf16675ca86 | 79687248edb59288b734fb91a6b57bf19eea7b85 | jeszekely/DMRG | /src/matrix.cpp | C++ | cpp | 6,180 | no_license | #include <iostream>
#include <cmath>
#include <algorithm>
#include <stdexcept>
#include <string>
#include <vector>
#include "matrix.hpp"
#include "utilities.hpp"
using namespace std;
matrixReal::matrixReal(const int nr, const int nc) : matrixBase<double>(nr,nc){}
matrixReal::matrixReal(const matrixReal& o) : matrixB... |
43d712a8bc77fedc1cf6799780d6a33d6a298085 | da8ec467597254ea7238c361411b178c0b531317 | alexndermuriithi/Assignment-II | /main.cpp | C++ | cpp | 443 | no_license | #include <iostream>
#include <string>
#include "rectangle.h"
#include "triangle.h"
#include "square.h"
using namespace std;
int main(int argc, char **argv){
Square sq(10);
cout<< "Square area: " << sq.area() << endl;
Triangle t1(3, 6), t2;
cout << "Triangle 1 area: " << t1.area()
<< " Name: "<< ... |
8dc86f8da6f83a3bbb73fb61418daf2ffbc90c34 | 96dbb5913144b8c3e4b86a3da21b02d75cefdbd0 | pranatsharma1/Competitve-Programming | /Recursion/15__Generate_all_balanced_parentheses__brute_force.cpp | C++ | cpp | 1,663 | no_license | // Date: 05/07/2021
// Problem Link: https://leetcode.com/problems/generate-parentheses/
// Youtube Link: https://www.youtube.com/watch?v=eyCj_u3PoJE&list=PL_z_8CaSLPWeT1ffjiImo0sYTcnLzo-wY&index=17&t=202s
// Submission Link: https://leetcode.com/submissions/detail/517763170/
//-----------------------------------Main... |
feccfae1bb3b0fbd42a56ede833ae7b8a813e206 | a900ec019808339dc7e743946ca67f7bc0d7d088 | GhostsOfHiroshima/bitcoin | /src/qt/test/apptests.cpp | C++ | cpp | 3,817 | permissive | // Copyright (c) 2018 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <qt/test/apptests.h>
#include <chainparams.h>
#include <key.h>
#include <qt/bitcoin.h>
#include <qt/bitcoingui.h>
#inclu... |
62a968058f1c86eef2f46c6f37bae5c3d2fa5a7b | 2f2b0aa16b99699b01068b7b53259cc8ffc9a4ec | Kmykhail/Leetcode | /populating-next-right-pointers-in-each-node-ii.cpp | C++ | cpp | 1,343 | no_license | /*
// Definition for a Node.
class Node {
public:
int val;
Node* left;
Node* right;
Node* next;
Node() : val(0), left(NULL), right(NULL), next(NULL) {}
Node(int _val) : val(_val), left(NULL), right(NULL), next(NULL) {}
Node(int _val, Node* _left, Node* _right, Node* _next)
: val(_... |
a7aa34962474216f8115bf9f98a7bedc3bff5735 | e5fa7182552801d65bf79ef7d9566828b029e9cc | hoangle/yas | /include/yas/serializers/json/boost/boost_unordered_multimap_serializers.hpp | C++ | hpp | 3,382 | no_license |
// Copyright (c) 2010-2014 niXman (i dot nixman dog gmail dot com)
//
// Distributed under the Boost Software License, Version 1.0. (See accompanying
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
//
//
//
// Boost Software License - Version 1.0 - August 17th, 2003
//
// Permission is hereby ... |
3056fb2b0d16f1c48a044575ed52bc86fafce6cd | 9e6b2d562fc674656c0ce36c99d15db68b3001cd | bmatejek/neurogaps | /apps/txt2neuron/txt2neuron.cpp | C++ | cpp | 3,870 | permissive | // Source file for the simple file conversion algorithm
// include files
#include "Neuron/Neuron.h"
// program arguments
static int print_verbose = 0;
static int print_debug = 0;
// global variables
static NeuronData *nd;
static char *input_filename = NULL;
static char *output_filename... |
289a642551e7856e334bdaa3167fe8acffb43a5a | 9f1fa8b069c688dd68a4c3b43be72e7023c0114a | nathanael-e/engiCalc | /src/tokenizer.cpp | C++ | cpp | 969 | no_license | #include "tokenizer.hpp"
using namespace engicalc;
auto Tokenizer::toTokens(std::string expression)
-> Tokens
{
Tokens T;
while(!expression.empty())
{
Token t = parse(expression);
T.push_back(t);
}
return T;
}
auto Tokenizer::parse(std::string& expression)
-> Token
{
... |
48bee952a87b13eec9c9f09a36136643859c0813 | 05dd33fb659c91d96018070a5765d68924122f33 | McM1k/piscine_cpp | /rush00/src/BackGroundPellet.cpp | C++ | cpp | 2,613 | no_license | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* BackGroundPellet.cpp :+: :+: ... |
28e3c77ff5c77c69dcdc2de6811dc05dfc77c78e | bb3ed999228c13661088625d8f859cee84bb3f0e | Smattr/z3 | /src/smt/theory_array_base.cpp | C++ | cpp | 36,581 | permissive | /*++
Copyright (c) 2006 Microsoft Corporation
Module Name:
theory_array_base.cpp
Abstract:
<abstract>
Author:
Leonardo de Moura (leonardo) 2008-06-02.
Revision History:
--*/
#include "smt/smt_context.h"
#include "smt/theory_array_base.h"
#include "ast/ast_ll_pp.h"
#include "ast/ast_pp.h"
#include "s... |
b1f925ac02ec4fd17370c9e09f14108fff9c5e92 | 01d625780b5c1b33afc6ace352c800b9f5f050b1 | HyrulesxLegend/HaroJorge_CSC5_40717 | /Class_Lab/Retirement_Function/main.cpp | C++ | cpp | 1,156 | no_license | /*
* File: main.cpp
* Author: Jorge Haro
* Created on January 27, 2015, 9:07 AM
* Purpose: Use the Babylonian 10 for retirement.
*/
//System Libraries
#include <iostream>
#include <iomanip>
#include <cstdlib>
using namespace std;
//User Libraries
//Global Constants
//Function Prototypes
float retirement(float... |
9298c42b959805ddbb6003b45b92da99bafc5130 | 665fc6b503d860c53604c1090f8cb6de42eb5393 | BGCX067/faint-graphics-editor-svn-to-git | /branches/editable-raster-objects/tasks/resize-object.cpp | C++ | cpp | 5,434 | permissive | // Copyright 2012 Lukas Kemmer
//
// 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 t... |
9b1a6676dfcac1561c84742ee58baa71c1940ace | ffda950680274aebf8b3200fb3f07fd6a178edd6 | dalihub/dali-adaptor | /dali/internal/system/windows/trigger-event-factory.cpp | C++ | cpp | 1,259 | permissive | /*
* Copyright (c) 2021 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... |
cdaac32d2c1ee7e5fc34cc781b140c4c700f36c7 | 7df6a39a5ea79311885ea7d96a77f68bcc994c06 | Trbonnes/piscinecpp | /cpp03/ex04/NinjaTrap.cpp | C++ | cpp | 3,381 | no_license | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* NinjaTrap.cpp :+: :+: :+: ... |
b7cb2056f7f71e73286a1580d04e7f018a6a2f20 | 47af501853a6db221e002883919f099293dc5639 | techtronics/deepdive | /elementary/src/fg/factoraccessor.cpp | C++ | cpp | 1,717 | no_license | /*
Copyright 2013 <copyright holder> <email>
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 la... |
a469360384cd9e21245499fd23f8a0413e4b47f7 | 474bcd1cbaa313249d8ee134b7ec8beca2dc588b | chemizt/pcconmonLibs | /src/lib/providerLib/include/configModificationProviderClasses.hpp | C++ | hpp | 365 | permissive | #ifndef IG_CONFIG_CLASSES_PL
#define IG_CONFIG_CLASSES_PL
#include "commonInclude.hpp"
#include "coreProviderClasses.hpp"
class BasicOperationStateChangeProvider : public Provider
{
public:
using Provider::Provider;
BasicOperationStateChangeProvider() { };
void executeShutdownCommand();
... |
79c39f7cf86cea3f03bebb6fb96266065ca9eee7 | 19b8c8c9ec2c6d35e388764adb5128e2be44a4e2 | zenoalbisser/chromium | /native_client/src/trusted/validator/validation_cache_test.cc | C++ | cc | 17,398 | permissive | /*
* Copyright (c) 2012 The Native Client 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 "gtest/gtest.h"
#include <fcntl.h>
#include "native_client/src/include/build_config.h"
#include "native_client/src/include/nacl... |
a855d6d7ec7eb36830fe41280b8a3ed1e9dc5271 | 00cf290e82a82a21ace18df983af084ca5183272 | shuinan/Duoduocoin2 | /src/rpcdump.cpp | C++ | cpp | 4,669 | permissive | // Copyright (c) 2009-2012 Bitcoin Developers
// Copyright (c) 2012-2013 The PPCoin developers
// Copyright (c) 2013-2014 The Peershares developers
// Copyright (c) 2014-2015 The Nu developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/m... |
34b1844bd1582f1166107d2b4764023b4b852bc5 | 36ff94c40147e7f52a6ced3f07f6fcb517036661 | Akus93/postman-tour-mpi | /src/main.cpp | C++ | cpp | 23,392 | no_license | #include <stdio.h>
#include <stdlib.h>
#include <mpi.h>
#include <cmath>
#include <vector>
#include <stdlib.h>
#include <string.h>
#include <cstring>
#include <fstream>
#include <algorithm>
bool Printing = 0;
//LOAD VERTICES
unsigned int get_file_length(const char* file_name) {
unsigned int count = 0;
char ... |
864981dfdeed38b30c8990077f043fbc42816022 | eaada437f9c4ff28c1750dfd3f76a6d80d42f04d | cha63506/momo | /test/tests/libcxx/vector/vector.cons/assign_move.pass.cpp | C++ | cpp | 4,130 | permissive | //===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===---------------------------------... |
497f1d01890765ba0e2e7e25e79163b2468c30c4 | 0b488137d7fa8ecd13c5dc84dc776a02749feb8d | BitZyon-Official/bitzyon-core | /src/crypter.cpp | C++ | cpp | 5,418 | permissive | // Copyright (c) 2009-2012 The Bitcoin Developers
// Copyright (c) 2017-2020 The SperoCoin Developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <openssl/aes.h>
#include <openssl/evp.h>
#include <vector>
#inclu... |
af74653bcb65658b05e16f0900faef3ba3cf31e3 | 2513e8e80726b0f757fe83ad7f9c82f0adaa173c | dmanc/competitive | /codeforces/118/118A.cpp | C++ | cpp | 430 | no_license | #include <bits/stdc++.h>
using namespace std;
int main() {
ios::sync_with_stdio(false);
cin.tie(0);
string s;
cin >> s;
string ans;
locale loc;
for(int i = 0; i<s.size(); i++) {
char c = tolower(s[i], loc);
if(c != 'a' && c != 'e' && c != 'i' && c != 'o' && c != 'u' && c != ... |
fb96016ddf707edc2336b32b744c8d2742fb3b85 | 3ea42458673d430b0334797f7bd97f869cbf87c3 | WangQiuc/aoapc-bac2nd | /ch10/11186.cpp | C++ | cpp | 839 | no_license | // UVa 11186 Circum Triangle
// wangqc
#include<iostream>
#include<cmath>
#include<algorithm>
using namespace std;
const double pi = acos(-1);
double a[505];
// enumerate two points (i,j), the contribution a (i,j) make is: (n+2i-2j)*S(ioj):
// when ioj < 180: 3rd point k is not in [i,j] (n-(j-i+1)), S += S(ioj); else... |
bb037c765b2b258a6df89c1ece86949d0953beb4 | d3843fc5344c5aecb57cabdc76bf6106c49d4e81 | metta-systems/metta | /src/runtime/libc++/test/depr/depr.function.objects/depr.adaptors/depr.member.pointer.adaptors/mem_fun_ref.pass.cpp | C++ | cpp | 740 | permissive | //===----------------------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is dual licensed under the MIT and the University of Illinois Open
// Source Licenses. See LICENSE.TXT for details.
//
//===----------------------------------------... |
ce041d3241ecfdc8f9c68505a0a1c581624ae7fc | bad7cbca485a2b94d26f8cebdf17556e672fa3b7 | roussukke/Yorozuya | /library/ATF/TBBUTTONINFOA.hpp | C++ | hpp | 527 | permissive | // This file auto generated by plugin for ida pro. Generated code only for x64. Please, dont change manually
#pragma once
#include <common/common.h>
START_ATF_NAMESPACE
#pragma pack(push, 8)
struct TBBUTTONINFOA
{
unsigned int cbSize;
unsigned int dwMask;
int idCommand;
in... |
0eaa5172c7836746d7a79c376453780aeccb7b3d | 7314b380ab762227eb539cfaddaed8e8bb65f8e8 | Man-In-Blue/DesignPatterns-cpp | /DecoratorDesignPattern/DPDecorator.cpp | C++ | cpp | 939 | no_license | /**************************************************************
* Create by LGC, All Rights Reserved.
* Description:
*
* @author: https://blog.csdn.net/Void_leng
* @time: 2021/4/8
**************************************************************/
#include "DPDecorator.h"
#include <iostream>
DPGardenDecorator::D... |
63ee530d1e91cc5fb9d8eaa61c5eb80c0000be6c | 17b09e9d496024828dc0581bf12ebcdd2c66f8df | kkopachev/hhvm | /hphp/runtime/ext/hh/ext_hh.cpp | C++ | cpp | 17,088 | permissive | /*
+----------------------------------------------------------------------+
| HipHop for PHP |
+----------------------------------------------------------------------+
| Copyright (c) 2010-present Facebook, Inc. (http://www.facebook.com) |
| Copyrigh... |
3c375c7421c1c460c6a1b949c98b629e72a41c84 | bea1beed1f7d5f8d777450865b2678ff0cc4625e | deepankarsharma/gg | /src/frontend/gg-put.cc | C++ | cc | 1,217 | no_license | /* -*-mode:c++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
#include <iostream>
#include <vector>
#include "net/requests.hh"
#include "storage/backend.hh"
#include "thunk/ggutils.cc"
using namespace std;
void usage( char * argv0 )
{
cerr << argv0 << " FILENAME..." << endl;
}
int main( int argc,... |
32a32d0bc5c7cdc3fef9fc056fd6a21b76e9deeb | 58a036811df43efe9fd25be44c3de737e90c32ac | GE28/exercicios-CPP | /lista7/8matrizInferior.cpp | C++ | cpp | 951 | permissive | #include <iostream>
using namespace std;
#define TAMANHO 8
void inferiorizeMatriz(int matriz[][TAMANHO]) {
for (int i = 0; i < TAMANHO; i++) {
for (int j = TAMANHO - 1; j > i; j--) {
matriz[i][j] = 0;
}
}
}
void imprimaMatriz(int matriz[][TAMANHO]) {
int j = 0;
cout << "[" << endl;
for (int ... |
f6f36af98e5160fc384ac34726ed846edbb6b2ed | d501d690af165bf2d620b169d3556ce250958043 | TheGhostGroup/DynastyCore | /src/server/game/Server/InterRealmOpcodes.cpp | C++ | cpp | 9,832 | no_license | #ifndef CROSS
#include "InterRealmOpcodes.h"
IROpcodeTable IRopcodeTable;
void IROpcodeTable::SetIROpcode(uint16 opcode, char const* name, pIROpcodeHandler handler)
{
_internalTable[opcode] = new IROpcodeHandler(name, handler);
}
void IROpcodeTable::Initialize()
{
#define DEFINE_IR_OPCODE_HANDLER(opcode, handler... |
d47ec2074f3ceab4910cf3b1645039779a72bbb5 | 96dfd6c5c487c6a5f7a0708550702382e25bee52 | loboxu/pulsar | /pulsar-client-cpp/lib/UnAckedMessageTrackerEnabled.cc | C++ | cc | 6,117 | 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... |
57186d6d64a6d0f2f20428fed6afdbef9c5c1505 | 1f93be2b2ff2480594f782912ff92c1e9bc965a4 | AlexInTown/HackWorks | /POJ/droping_tests_bsearch_poj_2976.cpp | C++ | cpp | 1,102 | no_license | #include <iostream>
#include <algorithm>
#include <stdio.h>
using namespace std;
const double eps = 0.000001;
int n, k;
double avg;
struct Test{
int a;
int b;
};
struct Comp{
bool operator()(const Test & t1, const Test& t2){
return t1.a-t1.b*avg - t2.a + t2.b*avg > 0;
}
};
Test tests[1000];
bool... |
d788490b0096b93f2a96c7a56f4c34e53fb69833 | 13321f24828ad1f009ef2e7a823ea143444b1c4d | SexyParabola/C-Projects | /Masteroids/Masteroids/Ship.cpp | C++ | cpp | 6,950 | no_license | //
// Ship.cpp
// Masteroids
//
// Created blocation.Y Lilllocation.Y Fiorino on 5/30/17.
// Copyright © 2017 Cibo. All rights reserved.
//
#include "Ship.hpp"
#include "Screen_Size.hpp"
#include <SDL2/SDL.h>
#include <iostream>
#include "Point.hpp"
Ship::Ship(){
angleM = 0;
angle = 0;
state = -1;
... |
99a020800b25a3ec1b19ef9a3c5fed9528b20d27 | 8af01f0f013e13783d0dc928d8ca26ebe68d9f04 | winnerineast/llvm-project | /flang/lib/Optimizer/HLFIR/Transforms/ConvertToFIR.cpp | C++ | cpp | 29,134 | permissive | //===- ConvertToFIR.cpp - Convert HLFIR to FIR ----------------------------===//
//
// 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
//
//===---------------------------... |
516b671827b7613df23926589cff358ad07bec26 | 555304283da6277ea164a030c2cf81a3d36316ba | BerLiangWu/MyTestProgram | /ProcessMap/CModList.cpp | C++ | cpp | 2,261 | no_license | // CModList.cpp: 实现文件
//
#include "pch.h"
#include "ProcessMap.h"
#include "CModList.h"
#include "afxdialogex.h"
// CModList 对话框
IMPLEMENT_DYNAMIC(CModList, CDialogEx)
CModList::CModList(CWnd* pParent /*=nullptr*/)
: CDialogEx(IDD_DIALOG1, pParent)
{
}
CModList::~CModList()
{
}
void CModList::DoDataExchange(C... |
768d4fea2cfe75279042558627dfc0dddc96d609 | 1800775a45b18e48524d8c08476d41fce0152473 | Hee-Jae/Algorithm | /boj/18243.cpp | C++ | cpp | 1,237 | no_license | #include <iostream>
#include <vector>
#include <algorithm>
#include <queue>
#define pb push_back
#define mp make_pair
#define st first
#define nd second
#define lli long long int
using namespace std;
int N,M, A,B,top,sc;
int buddy[102][102]={};
queue<pair<int,int> > q;
int main(){
ios::sync_with_stdio(0);
cin.tie(0... |
cf925f63dbbc00ceb2814c2ed9c28478ebee1df6 | 14e1f1bb22b26ca0514e9173ebac1fd614ea70ea | DrailDragon/summercs210 | /cs210_assgn2_120101050/stack1.cc | C++ | cc | 958 | no_license | #include "stack1.h"
stack1::stack1(int siz){
st=NULL;
n=siz;
top=-1;
st=new int[n];
}
stack1::~stack1(){}
bool stack1::if_empty()
{
if(top==-1)
return true;
else
return false;
}
bool stack1::is_full()
{
if(top==n-1)
return true;
else
return false;
}
bool stack1::push(int ... |
acbf89d9de739fa2af6c662880ab012159635a86 | 3533fd7d9a442f8759b3fd4a97b8658e74e550b3 | comeonlgq/drawVariousShapes | /Liuwei_2View.cpp | C++ | cpp | 7,275 | no_license | // Liuwei_2View.cpp : implementation of the CLiuwei_2View class
//
#include "stdafx.h"
#include "Liuwei_2.h"
#include "MainFrm.h"
#include "Liuwei_2Doc.h"
#include "Liuwei_2View.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
///////////////////////////////////////... |
4992d4776a01cba730693b56636e342fcf89be40 | 2351117f8c6feaa93d21cafcde61e56b969122c4 | IPDTFE/TemplePlus | /TemplePlus/gamesystems/objects/gameobject.cpp | C++ | cpp | 33,129 | permissive |
#include "stdafx.h"
#include "gameobject.h"
#include "objfields.h"
#include "objsystem.h"
#include "objregistry.h"
#include "arrayidxbitmaps.h"
#include "tio/tio.h"
#include "util/streams.h"
GameObjectBody::~GameObjectBody()
{
ForEachField([=](obj_f field, void** storage) {
auto &fieldDef = objectFields.GetFieldDe... |
3400780467290df240700b68df550527bc6e64e4 | 7de3d8e1e1227d9687ac26fe05ccc75097589c38 | wkdanlwo091/Tizen_latest | /tizen_gles_sample/src/renderer/basic_camera.cpp | C++ | cpp | 3,145 | no_license | #include <glm/gtx/quaternion.hpp>
#include "basic/basic_camera.h"
using namespace glm;
BasicCamera::BasicCamera() :
TORADIAN(pi<float>() / 180.0f),
mEye(vec3(150.0f, 25.0f, -100.0f)),
mDist(150.0f),
mUp(vec3(0, 1.0f, 0.0f)),
mFw(vec3(0, 0, -1.0f)),
mAngle(vec3(0.0f, -45.0f, 0)),
// mUp(vec3(0, 0.0f, -1... |
42e2b78720d45a40555a22c7fe936ab53182ae8b | 1190bbf27b3dcc45ab6005cbdb3fa76b07bbe183 | angelfish91/LeetcodeLearning | /XuZeng/20.cpp | C++ | cpp | 768 | no_license | class Solution {
public:
bool isValid(string s) {
int len = s.length();
if (len == 0) return true;
if (len % 2 != 0) return false;
stack<char> tmp;
for (int i = 0;i < len;i++) {
if (s[i] == '(' || s[i] == '[' || s[i] == '{') {
tmp.push(s[i]);
... |
0419caee9eb3a992d88ae26261f6bba5f5be8a65 | ad8e3c04542a3dff77388370c0be52f01373b179 | midikit/PD-Loader | /source-code/source/plugins/TLAC/Input/KeyConfig/Config.cpp | C++ | cpp | 6,731 | permissive | #include "Config.h"
#include "windows.h"
#include "../Bindings/KeyboardBinding.h"
#include "../Bindings/Ds4Binding.h"
#include "../../Utilities/Operations.h"
#include "../Bindings/XinputBinding.h"
#include "../../Constants.h"
namespace TLAC::Input::KeyConfig
{
KeycodeMap Config::Keymap =
{
// NumPad Keys
{ "NumP... |
adc96a399961db9e2fdfd89a5127e179ddb541b7 | b3d46c8ad777e34c3a737a487174af4fe9a51f76 | OnurDemir-Dev/gipOpenNN | /libraries/opennn/stochastic_gradient_descent.cpp | C++ | cpp | 31,986 | permissive | // OpenNN: Open Neural Networks Library
// www.opennn.net
//
// S T O C H A S T I C G R A D I E N T D E S C E N T C L A S S
//
// Artificial Intelligence Techniques SL
// artelnics@artelnics.com
#include "stochastic_gradient_descent.h"
namespace OpenNN
{
/// Default constructor.
/// It creates a stoc... |
36f3703879df633793404b2412eb628409b86c68 | 88d1228517e9a4404a2f632862bf1288c4bfbf4f | VICTOR4046/punky | /src/Environment.cpp | C++ | cpp | 638 | permissive | #include "../include/Environment.hpp"
#include <optional>
#include <string>
#include <utility>
namespace punky::env
{
obj::Object Environment::set(std::string name, const obj::Object& value)
{
m_store[std::move(name)] = value;
return value;
}
auto Environment::get(const std::string& name) const -> std::opti... |
164c90cf5f7eb640839d0d561b7d8544b681efdb | e33b3814861a4d84c8ea10c04b4e064daf3181ff | Gravechapa/reactor_loginer | /src/classes/CurlWrapper.cpp | C++ | cpp | 1,116 | no_license | #include "CurlWrapper.hpp"
#include <iostream>
#include <thread>
CurlWrapper::CurlWrapper(): _curl(curl_easy_init())
{
if (!_curl)
{
throw std::runtime_error("Cant init curl");
}
}
CurlWrapper::CurlWrapper(CURL * const curl): _curl(curl)
{
}
CurlWrapper::~CurlWrapper()
{
curl_easy_cleanup(_cu... |
b72b56bdf7eab4002b043c252cddc88ddcd93ffa | 4df26b53c4972fb79d79c0f1dd03ea7ad6e87b5f | FriendViewer-io/frequency | /frequency/engine/physics/CellPartition.hh | C++ | hh | 877 | no_license | #pragma once
#include <vector>
#include "engine/math/AABB.hh"
#include "engine/math/Vector.hh"
#include "engine/physics/SpatialPartition.hh"
class ColliderComponent;
class CellPartition : public SpatialPartition {
public:
CellPartition(aabb const& world_bounds, vec2 cell_dimensions);
void insert(aabb const& ... |
dbcae4a9001d38af573942b1a824541a43707e39 | 6f56c46d43a58056234ec7c84e83d1421bc0f6e5 | saturneric/Pop-Engine | /Pop Engine/Pop Engine.cpp | C++ | cpp | 841 | no_license | // Pop Engine.cpp : 此文件包含 "main" 函数。程序执行将在此处开始并结束。
//
#include <iostream>
int main()
{
std::cout << "Hello World!\n";
}
// 运行程序: Ctrl + F5 或调试 >“开始执行(不调试)”菜单
// 调试程序: F5 或调试 >“开始调试”菜单
// 入门使用技巧:
// 1. 使用解决方案资源管理器窗口添加/管理文件
// 2. 使用团队资源管理器窗口连接到源代码管理
// 3. 使用输出窗口查看生成输出和其他消息
// 4. 使用错误列表窗口查看错误
// 5. 转到“... |
26529bb10c47a702b566c49ea70ab3fa28305d2b | 3287b262ae76aec8482f95d1e67d062cf56ffb14 | chengguixing/iArt | /ITemplate/TraitAndPolicyTwo/isclasst.cpp | C++ | cpp | 699 | no_license | #include "isclasst.h"
class MyClass
{
;
}
;
struct MyStruct
{
;
};
union MyUnion
{
;
};
void MyFunc()
{
;
}
enum E{e1}e;
template <typename T>
void check()
{
if (IsClassT<T>::Yes)
{
cout << "IsClassT" << endl;
}
else
{
cout << "!IsClassT" << endl;
}
}
template <typename T>
void checkT(T)
{
check<T... |
3705ad94768c36ac12534ded72248a1b19875114 | a9d1e5515b8f9db51ab7d06a93b8f3dac90492b9 | jobin-sun/hiphop-php | /hphp/runtime/ext/ext_continuation.cpp | C++ | cpp | 6,974 | permissive | /*
+----------------------------------------------------------------------+
| HipHop for PHP |
+----------------------------------------------------------------------+
| Copyright (c) 2010- Facebook, Inc. (http://www.facebook.com) |
| Copyrigh... |
8ee6c81aaf49b91b801efb5ed031fc830e9d43b2 | 5851a8b82887f8d517c97541674fba12f5a84299 | Xie-ai-catch/SensorFusionWork | /workspace/assignments/05-imu-navigation/src/imu_integration/src/estimator/node.cpp | C++ | cpp | 568 | no_license | #include <fstream>
#include <ros/ros.h>
#include <rosbag/bag.h>
#include "imu_integration/estimator/activity.hpp"
int main(int argc, char** argv) {
std::string node_name{"imu_integration_estimator_node"};
ros::init(argc, argv, node_name);
imu_integration::estimator::Activity activity;
activity.... |
3f6ac3e2809a8cd9c916c7558e929105d8d94a85 | 58fcb3e461e91612b080e29d9cc55351dc690a86 | ZghalYoussef97/Sixpack- | /Mouadhromdhane/dialog_55.cpp | C++ | cpp | 853 | no_license | #include "dialog_55.h"
#include "ui_dialog_55.h"
#include "dialog_5.h"
#include <QtSql/QSqlDatabase>
#include <QtSql/QSqlQuery>
#include <QSqlQueryModel>
QDate Dialog_55::getdate()
{
return ui->dateEdit->date() ;
}
Dialog_55::Dialog_55(QWidget *parent) :
QDialog(parent),
ui(new Ui::Dialog_55)
{... |
11fbc694baa5c2d2d054391e1670da22eaa8b5b7 | 34ba7ae5a6c3d28d0e0be7352e23eb1bf7e92b5e | jv-albuquerque/arkanoid-proton-sdk | /shared/Irrlicht/source/Irrlicht/COGLES2ParallaxMapRenderer.cpp | C++ | cpp | 6,871 | permissive | // Copyright (C) 2009-2010 Amundis
// Heavily based on the OpenGL driver implemented by Nikolaus Gebhardt
// and OpenGL ES driver implemented by Christian Stehno
// This file is part of the "Irrlicht Engine".
// For conditions of distribution and use, see copyright notice in Irrlicht.h
#include "IrrCompileConfig.h"
#i... |
1e0f0cefce66e4ba7ff8a6bb6fc2f2435a749714 | 33fba2ee421fb22901bbd51c71fbd5e4e39e8269 | alesapin/XMorphy | /contrib/boost/any/test/basic_any_to_basic_any.cpp | C++ | cpp | 382 | permissive | // Copyright (c) 2021-2023 Antony Polukhin
//
// Distributed under the Boost Software License, Version 1.0. (See accompanying
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt).
#include <boost/any.hpp>
#include <boost/any/basic_any.hpp>
int main()
{
boost::anys::basic_any<> bany;
boost:... |
b81c3f344fc262ee10ea09aa003196217fac49d3 | 3c191ea37d8df6be7ee0ec643d0c6ab7d7c5a682 | noy72/atcoder | /arc031/c.cpp | C++ | cpp | 5,104 | no_license | #include<bits/stdc++.h>
#define range(i,a,b) for(int i = (a); i < (b); i++)
#define rep(i,b) for(int i = 0; i < (b); i++)
#define all(a) (a).begin(), (a).end()
#define show(x) cerr << #x << " = " << (x) << endl;
//const int INF = 1e8;
using namespace std;
#define int long long
const int MAX_N = 110005;
class segTre... |
fb117c4691e63f077b317cd274092a3efdd79e1c | 190fc0a827ac917efbb2704c5bbf4a8736ac18c7 | a-michelis/aircraft_game | /lib/BMPLoader/BMPLoader.cpp | C++ | cpp | 5,792 | no_license | /*BMPLoader - loads Microsoft .bmp format
Copyright (C) 2006 Chris Backhouse
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
... |
b5b606df8cb5b8ed2f7097218be94a68771f4886 | da3d016f9e1294a25acfa9535db4ae3e1a6f2ef5 | ajbrown99/EE312-Lab-6-Go-Fish | /deck.cpp | C++ | cpp | 1,717 | no_license | #include <iostream>
#include <cstdlib>
#include <string>
#include "card.h"
#include "deck.h"
//default deck constructor
Deck::Deck()
{
myIndex = 0;
int myCardsIndex = 0;
for (int i = 0; i < 13; i ++)
{
myCards [myCardsIndex] = Card ((i+1), Card::spades);
myCardsIndex ++;
myCa... |
9edc7c6188bed5a2fbdb4ec2ba50f02f99c18c94 | 5de60647ed0fcd87de2ba74f84c1d421ae2ff403 | APCVSRepo/HMI_SDK_LIB | /ReferenceDesign/SampleQTHMI/SDLApps/Templates/Common/MenuButton.cpp | C++ | cpp | 1,815 | permissive | #include "MenuButton.h"
#include <QPainter>
#include <QRectF>
#include <QTextOption>
#include <QUrl>
MenuButton::MenuButton(QWidget *parent): QPushButton(parent) {
m_isActive = false;
}
MenuButton::~MenuButton() {
}
void MenuButton::setText(const QString &text) {
m_text = text;
update();
}
void MenuBut... |
bd9800ed43584b45759262d4385bebd51232ff33 | 5b8d7880075e9514b4bc80c4baf2f64129e9fbe1 | Luiz-Monad/Irrlicht-Vulcan | /examples/15.LoadIrrFile/main.cpp | C++ | cpp | 5,634 | no_license | /** Example 015 Loading Scenes from .irr Files
Since version 1.1, Irrlicht is able to save and load
the full scene graph into an .irr file, an xml based
format. There is an editor available to edit
those files, named irrEdit (http://www.ambiera.com/irredit)
which can also be used as world and particle editor.
This tut... |
b44b48413b23d49fb51f6795fe89bc0db9b61fdf | 6b7ec2a24894815e8b1710d830de96ab395586bc | StudyDandan/algorithm023 | /Week_02/LevelOrderN.cpp | C++ | cpp | 1,597 | no_license | #include <vector>
#include <queue>
using namespace std;
class Node {
public:
int val;
vector<Node*> children;
Node() {}
Node(int _val) {
val = _val;
}
Node(int _val, vector<Node*> _children) {
val = _val;
children = _children;
}
};
/*N叉树层序遍历
1、队列——时间复杂度O(n),空间复杂... |
2fdd1d91030058ed33f069d44e99ec1f466828e6 | 7848eef1d8f2b1e5e42602bce53395eb3d6552a8 | sadrulhc/chromium | /chrome/browser/chromeos/printing/print_servers_manager_unittest.cc | C++ | cc | 6,984 | permissive | // Copyright 2020 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chrome/browser/chromeos/printing/print_servers_manager.h"
#include <map>
#include <memory>
#include <string>
#include "base/containers/flat_ma... |
06ec47b7dd320cc170b7a78a52f3123ef36cd812 | 1dbc5524586e6151f6a6c7101bdc59843b304cdd | thomasLeMeur/16-abstractVM | /Lexer.cpp | C++ | cpp | 3,961 | no_license | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* Lexer.cpp :+: :+: :+: ... |
a5fc12f3152c4b0b8bb44fb5aae65134ace0693f | a6a5945a6439e4d0d5f424db74739544dea825d8 | shh1473/Sunrin_Engine_2019 | /Direct3D_11/Sunrin_Engine_D3D11/Engine/SR_App.cpp | C++ | cpp | 5,782 | permissive | #include "SR_PCH.h"
#include "SR_App.h"
namespace SunrinEngine
{
std::unique_ptr<SR_App> SR_App::m_INSTANCE{ nullptr };
SR_App::SR_App() noexcept :
m_isWindowResized { false },
m_windowWidth { 0 },
m_windowHeight { 0 },
m_clientWidth { 0 },
m_clientHeight { 0 },
m_centerWidth { 0.0f },
m_... |
e43e26edaa2e8b66c8ecf48635da58113d11aa1c | be09c8a04ba02f0ee9e6cd62009e0bd825a0f9e2 | calgagi/leetcode | /1359/answer.cpp | C++ | cpp | 254 | no_license | class Solution {
public:
const long long MOD = 1e9 + 7;
int countOrders(int n) {
long long res = 1;
for (int i = 1; i <= n; i++) {
res = (res * (i * 2 - 1) * i) % MOD;
}
return (int) res;
}
};
|
d9b39399356de7c37bfc673ff6a8f53a06e38448 | 04ad8d7234492173a03c728f39030d6a6da0f47d | x86nick/leetcode | /Algorithm/RemoveDuplicatesFromSortedArray/RemoveDuplicatesFromSortedArray.cpp | C++ | cpp | 1,255 | permissive | /*
Given a sorted array, remove the duplicates in place such that each element appear only once and
return the new length.
Do not allocate extra space for another array, you must do this in place with constant memory.
For example,
Given input array nums = [1,1,2],
Your function should return length = 2, with the fir... |
240221be23e1b3f58317675d08f8ea43f02f232c | 3ec53df19e97f80f1acbe08d303e67453fc24fc9 | Kingwl/ray | /source/terrain.cpp | C++ | cpp | 3,958 | permissive | // +----------------------------------------------------------------------
// | Project : ray.
// | All rights reserved.
// +----------------------------------------------------------------------
// | Copyright (c) 2013-2015.
// +----------------------------------------------------------------------
// | * Redistributi... |
89b23cdcba95694618e623e4bf26d3cff5210e22 | 1322a389129a42f28fcd192231516585ff023c2e | RuixiongHu/Albany | /src/LCM/evaluators/HMC/UpdateField.cpp | C++ | cpp | 494 | permissive | //*****************************************************************//
// Albany 3.0: Copyright 2016 Sandia Corporation //
// This Software is released under the BSD license detailed //
// in the file "license.txt" in the top-level Albany directory //
//**************************************... |
f53c2d871a541b7f40fa3d65b950cbf20fb348ab | 9b2c00c04c6e5cdfd939b64fbe20dfb48563e4a1 | YAGAMI55/consolgames-tools | /game-specific/Shattered Memories/MapEditor/GLDraw.cpp | C++ | cpp | 6,853 | no_license | //#include "draw.h"
#include "GLDraw.h"
#include "draw.h"
#include <gl\gl.h>
#include <gl\glu.h>
void CCommonDraw::Finalize(){
if( hRC ) // Существует ли Контекст Рендеринга?
{
if( !wglMakeCurrent( NULL, NULL ) ) // Возможно ли освободить RC и DC?
{
MessageBox... |
712e8c64e7ca73e2aa6eed2d6fb2909e48c983c9 | 3046405a83a042a736c2a71c3d1df519ae83436b | luabeltranga/Herramientas | /MatrixCodes/armadillo/armadillo-solve_default_lu_qr.cpp | C++ | cpp | 727 | no_license | #include <iostream>
#include <armadillo>
void solvesystem(const int & size);
int main(int argc, char** argv)
{
const int N = atoi(argv[1]); // Repetitions
const int M = atoi(argv[2]); // Matrix size
for (int step = 0; step < N; ++step) {
solvesystem(M);
}
return 0;
}
void solvesystem(const int & si... |
fc78567eed3aac363c32fc4ea4f68ef655100620 | f7855581a3d14992c6ad24cd9f49c06ce9d53ab4 | overlast/private | /programming_challenge/topcoder/SRM570_DIV2_Easy_Chopsticks.cc | C++ | cc | 2,671 | no_license | #include <cstdio>
#include <cstdlib>
#include <cmath>
#include <climits>
#include <cfloat>
#include <map>
#include <utility>
#include <set>
#include <iostream>
#include <memory>
#include <string>
#include <vector>
#include <algorithm>
#include <functional>
#include <sstream>
#include <complex>
#include <stack>
#include... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.