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 |
|---|---|---|---|---|---|---|---|---|
b08bdee091ee89d680fff27badee8374a9e0731a | f2ec9e250861cd89099f692085881adcb92c6032 | HelloJeong/bojCode | /10000/10984(내학점을구해줘).cpp | C++ | cpp | 492 | no_license | #include <bits/stdc++.h>
using namespace std;
int main() {
// ios_base::sync_with_stdio(false);
// cin.tie(nullptr);
int t;
scanf("%d", &t);
while(t--) {
int cnt, sumC = 0;
double sumG = 0;
scanf("%d", &cnt);
for(int i = 0; i < cnt; i++) {
int c; double... |
a43f1508c3f0806a8f983620fd1ab3ac8de2ad2b | dfce37cdde388a4febc18c6856ed63d3edffb0a4 | icedeng/recipes | /c/demo_code/day17/pm/demo1/mythread.cpp | C++ | cpp | 297 | no_license | #include "mythread.h"
void MyThread::start()
{
pthread_create(&tid,0,s_run,this);
}
void MyThread::join()
{
pthread_join(tid,(void **)0);
}
void MyThread::run()
{
// 被覆盖实现用户自己的业务逻辑
}
void * MyThread::s_run(void *d)
{
MyThread *th=(MyThread *)d;
th->run();
}
|
26b3ee29c1e86cb3d0dc65dfd6a9a54a0e91e5b8 | 0ad59624c2fee2df89d27072e40559a73365692e | audio-dsp/Max-Live-Environment | /support/macOS/xerces-c/src/xercesc/validators/schema/XMLSchemaDescriptionImpl.hpp | C++ | hpp | 5,538 | 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... |
2c43b2a3c83732533d7fce1273a4a19f38d403c6 | 02fd17b723dfceefbf3b883630cfda6b2fec14b6 | saverecs/SaverECS | /src/smtEncoding/smtController.cpp | C++ | cpp | 10,185 | no_license | #include <iterator>
#include <iostream>
#include <string>
#include <cstddef>
#include <boost/lexical_cast.hpp>
#include <boost/tokenizer.hpp>
#include <boost/algorithm/string/replace.hpp>
#include <regex>
// ************ More Header files *************************
#include "smtScript.h"
#include "smtController.h"
#inc... |
091d3609dfccebaa29ce4441a29697dfb6929a05 | 8fbc584b05fe38892268e220e868778c21afb2f3 | thiyaguleet/LeetCode | /Search in Rotated Sorted Array.cpp | C++ | cpp | 555 | no_license | class Solution {
public:
int search(vector<int>& nums, int target) {
int low = 0, high = nums.size()-1, mid;
while (low<=high) {
mid=(low+high)/2;
if(nums[mid]==target) return mid;
if(nums[low]<=nums[mid]){
if(target<=nums[mid] && target>=nums[low]... |
7a9ada911ec79ab3db7dd8ac7ca07589d2bcf6e2 | cc15fe76de2ab1e8b3846dbf11d545664425f5d5 | sharkka/VideoQTShow | /src/QCtrlMenu.cpp | C++ | cpp | 2,437 | no_license | /**************************************************************************************************
* Copyright (c) 2016 Horizon Robotics, Inc. All rights reserved.
* File Name : QCtrlMenu.cpp
* File Path :
* File Base :
* Brief : Do not modify any code for perpose of your own
* This cod... |
25c3479611351e3a05f1a48204e23f474b53ee41 | 2f88dec0d3a9421eee726d87f783d4e07b7c8d53 | Dhaval2110/CPP | /class_basics.cpp | C++ | cpp | 1,019 | no_license | #include<iostream>
#include<string.h>
using namespace std;
//class A
//{
// //public: //public data and member functuibs canve accessed anywhere in the progrma
// //protected:
// private:
// int x,y; //data members
// public:
// void setdata(int a,int b) //member functions
//... |
ec2b907ad48da7c89bb337c42c3682458a0dc3ae | 950231949bdd027a385de04fa0cf41acbec83079 | niuxu18/logTracker-old | /second/download/httpd/gumtree/httpd_new_hunk_1831.cpp | C++ | cpp | 2,525 | no_license | ap_extended_status = 0;
ap_min_spare_threads = DEFAULT_MIN_SPARE_THREAD;
ap_max_spare_threads = DEFAULT_MAX_SPARE_THREAD;
#ifdef AP_MPM_WANT_SET_MAX_MEM_FREE
ap_max_mem_free = APR_ALLOCATOR_MAX_FREE_UNLIMITED;
#endif
ap_sys_privileges_handlers(1);
return OK;
}
static int mpmt_os2_check_c... |
de28e6386787f8611f70cf9f57d11750c00664fb | 5c81ac49f7b4d1d5bb0a58a630da579838b92df3 | fanyeren/osquery | /osquery/config/config.cpp | C++ | cpp | 24,035 | permissive | /*
* Copyright (c) 2014, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
*/
#include <c... |
b38a2f561111c2a9be59ff11ad0dcea1c4ebb474 | 400072c30c039704ed7660073534f628dbc71d77 | black6816/magnum | /src/Magnum/MaterialTools/Test/PhongToPbrMetallicRoughnessTest.cpp | C++ | cpp | 16,194 | permissive | /*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019,
2020, 2021, 2022 Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files ... |
cae8390c607a790fcc1460ecf20f7e610a8f6d91 | 59d52a5737fd794682b3fa75b120271e43b0a58e | skylerdev/GravPong | /GravPong/main.cpp | C++ | cpp | 6,281 | no_license | #include <SFML/Graphics.hpp>
#include "Paddle.h"
#include "Ball.h"
#include <iostream>
#include "Consts.h"
#include <string>
#include <SFML/Audio.hpp>
class Game{
public:
Game();
void run();
private:
void setup();
void processEvents();
void update(sf::Time);
void render();
void handlePlayerInput(sf:... |
18661553dd909c348bf3fa99af8dc8c918e80124 | 67d9da077cff1514f13fef1a2189699be2e5a434 | liujiangang/skia | /samplecode/Sample.cpp | C++ | cpp | 3,670 | permissive | /*
* Copyright 2016 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include "include/core/SkCanvas.h"
#include "include/core/SkString.h"
#include "samplecode/Sample.h"
#if SK_SUPPORT_GPU
# include "include/gpu/GrContext.h"
#else
class GrCo... |
a3c0230b124ff7fb2502e577d37bdcb9fbabfa21 | bae3e565b3901eb962943322ee2078578dc9ea65 | BruceZoom/MyCodeForces | /#655/2/main.cpp | C++ | cpp | 805 | no_license | #include <iostream>
#include <vector>
#include <cstring>
using namespace std;
bool cands[100000];
vector<int> primes;
void init(){
memset(cands, 1, sizeof(cands));
primes.clear();
for(int i=2; i<100000; i++){
if(!cands[i]) continue;
// cout << i << endl;
primes.push_back(i);
... |
44b07a5c1006bd03cb80dc6aeea82f608c312447 | bfca32d795ea09e5aa242eef7f2f0428d7ed16fd | nitishingde/cpp_graph | /unit_test/Test_graphs.cpp | C++ | cpp | 1,668 | permissive | #define CATCH_CONFIG_MAIN // This tells Catch to provide a main() - only do this in one cpp file
#include <catch2/catch.hpp>
#include "CppGraph.h"
class Edge {
public:
std::string value;
Edge(std::string str = ""): value(str) {}
bool operator<(const Edge &other) {
return this->value < other.value... |
db12aadcfd97d182fa78c37ab7f9a34f4b604760 | bab02712bd4d54addef1ff56992df76b7eb51b10 | Misasasa/fluidsolver | /particle_solver/solver/MultiphaseSPHSolver.cpp | C++ | cpp | 31,456 | no_license |
#include "cuda.h"
#include "cuda_runtime.h"
#include "MultiphaseSPHSolver.h"
extern SimParam_SPH hParam;
void MultiphaseSPHSolver::CopyParticleDataToDevice() {
SPHSolver::CopyParticleDataToDevice();
int numParticlesT = numParticles * hParam.maxtypenum;
//Multi phase properties.
cudaMemcpy(device_data.group... |
606235a2e622343f72f427ffd67be8943ca5c3c1 | ae13ae5da8d4c093bdb4d6e168584bda234e4502 | nnsuite/ubuntuport-tensorflow | /tensorflow/core/kernels/data/window_dataset_op.cc | C++ | cc | 14,728 | permissive | /* Copyright 2018 The TensorFlow Authors. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or a... |
0560eff70ec717de85ffde394ae1f0fc69036a07 | eddfeb1fb4e28a5106ed2f39dd6bacc6c8077587 | wangxianghust/Cpp-Primer | /5/17.cpp | C++ | cpp | 565 | no_license | #include <iostream>
#include <vector>
#include <string>
using namespace std;
int main() {
std::vector<int> v1;
std::vector<int> v2;
v1 = {1,2,3};
v2 = {1,3,4,6};
int Flag =1;
for (auto beg1 = v1.begin(), beg2 = v2.begin(); beg1 != v1.end() && beg2 != v2.end(); ++beg1, ++beg2) {
if (*beg1 != *beg2) {
Flag ... |
b778336e19407ed88a4ccf3a50157f0b3bdcac56 | f2dade66b18a2d72cd4b84ae19e7cd059ad7693a | JeffYoung17/Course_Learning | /cpp_concurrency/blog_code/Threads_1.cpp | C++ | cpp | 278 | no_license | #include <iostream>
#include <thread>
using namespace std;
int func()
{
// do some work
cout << "hello" << endl;
return 1;
}
int main(int argc, char** argv)
{
std::thread t(func);
t.join(); // if the func return a value, it will be ignored
return 0;
} |
20c08178bf78f2044959e27e1a7f28da3d0d434d | df5b67c27d003b5a7e45b037441dbd9e1fcf0bc6 | Linsenx/AcmCodes | /Contests/2016级湖南工业大学新生赛/1009/main.cpp | C++ | cpp | 492 | no_license | #include <bits/stdc++.h>
using namespace std;
int l[4];
int main()
{
ios::sync_with_stdio(false);
#ifdef ONLINE_JUDGE
#else
freopen("in.txt","r",stdin);
#endif
int flag = 0;
while (cin >> l[0] >> l[1] >> l[2] >> l[3] && (l[0]+l[1]+l[2]+l[3]) > 0) {
sort(l, l+4);
if (l[0]+l[1]+l[2] > l[3] && (... |
0fd38e3dca58ab40b82aa6be6d17d6b57ea111cf | 302779926ed25ac450d3c3104b6ebc894e2f47d3 | naushad-rahman/CIDLib | /Source/AllProjects/CIDLib/CIDLib_BinaryMBufStream.cpp | C++ | cpp | 9,071 | no_license | //
// FILE NAME: CIDLib_BinaryMBufStream.cpp
//
// AUTHOR: Dean Roddey
//
// CREATED: 08/01/1997
//
// COPYRIGHT: $_CIDLib_CopyRight_$
//
// $_CIDLib_CopyRight2_$
//
// DESCRIPTION:
//
// This file implements simple derivatives of the binary input and output
// stream classes. These handle creating the stream implem... |
b8d7d636224fbb6bf904b6779da8406f64af123d | 40d04399a56151e509f2a44545035ec83a826ae9 | aholyoke/Chess | /pawn.cc | C++ | cc | 5,799 | no_license | #include <iostream>
#include <string>
#include <vector>
#include <iterator>
#include "piece.h"
#include "pawn.h"
#include "tile.h"
using namespace std;
Pawn::Pawn(Player* p,char gp,int row, int col):Piece(p,gp,row,col){
}
std::vector<Tile*> Pawn::getMoves(Tile** theGrid){
vector<Tile*> moves;
Pie... |
3be1d1ebfa69f01b1dc090a111dc8dc2e2f38d6d | 75748277719a9d9cd0c1cc4fa847920cfc487bba | mishidehun/- | /c++/effective_c++/defaultconstrct.cpp | C++ | cpp | 290 | no_license | #include <stdio.h>
class Ctest
{
public:
Ctest(int a):m_counter(a)
{
}
~Ctest()
{
}
void ShowCounter()
{
printf("counter: %d\n", m_counter);
}
private:
int m_counter;
};
int main(int argc, char **argv)
{
Ctest test(5);
test.ShowCounter();
return 0;
}
|
568f71746952b7aa89fda36c1332f6cbb49d0b8f | 23b438d476f9808f6f5e71edba01f8885476c074 | jordan722/CS135Labs | /lab_05/main.cpp | C++ | cpp | 936 | no_license | /*
Author: Jordan Yaqoob
Course: CSCI 136
Instructor: Zamansky
Assignment: Lab 3 - Pre-Lab
*/
#include <iostream>
using namespace std;
#include "numbers.h"
int main(){
cout << isDivisible(100,25) << endl;
cout << isDivisible(35,17) << endl;
cout << "\n";
cout << isPrime(2) << endl;
cout << isPrime(3) << en... |
e74be820a0bdd1ecc87a077badbf6d3e34da0f1d | 5420aa87a01b5a36cae2c5214cef4b36822ddf92 | sujithvm/nix | /include/nix/base/IFile.hpp | C++ | hpp | 2,634 | permissive | // Copyright (c) 2013, German Neuroinformatics Node (G-Node)
//
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted under the terms of the BSD License. See
// LICENSE file in the root of the Project.
#ifndef I_FILE_H
#define I_FILE_H
#include... |
8a5868cbfc65d82b86607decaf1f2a4747d84164 | 3df6291a8f0439e3f187afaef31f3c567259da33 | zahidaliayub/AmsterdamCoin-AMS | /src/net.cpp | C++ | cpp | 66,097 | permissive | // Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2014 The Bitcoin developers
// Copyright (c) 2014-2015 The Dash developers
// Copyright (c) 2015-2017 The PIVX developers
// Copyright (c) 2017-2018 The AmsterdamCoin developers
// Distributed under the MIT/X11 software license, see the accompanying
// f... |
6ee11a6c2a101052c5125ec45a788570e36011ef | bd6af0382ca670d3663a82d145a1cd7f1b0dd6e5 | tonnac/Study_0 | /00_src/Chrono/Chrono.cpp | C++ | cpp | 926 | no_license | #include <iostream>
#include <chrono>
#include <ctime>
using namespace std::chrono;
int main()
{
time_point<steady_clock> t = steady_clock::now();
time_t tim = system_clock::to_time_t(system_clock::now());
char buf[256] = { 0, };
tm pe;
tim = system_clock::to_time_t(system_clock::now());
localtime_s(&pe, &tim);
... |
79e47f47cabdfdc0d7ce6319c90f586e971da2d2 | 983442fd1c6bb386f39ae2c91d61e3b0350b62bc | zcnet4/putils | /test/Csv_test.cpp | C++ | cpp | 1,650 | permissive | #include "gtest/gtest.h"
#include "Csv.hpp"
#include "to_string.hpp"
struct CsvTest : testing::Test {
enum Fields {
Age, Description
};
std::stringstream s {
"phiste;21;metadeveloper\n"
"naliwe;24;koatla"
};
// name age descr... |
313d37723b131ef6990ad860084fc4492d20d5c9 | c9a8651aee98847d5cb588fa9234a65492fadc22 | jacmoe/OgreOpcode | /src/math/OgreOpcodeVector.cpp | C++ | cpp | 7,307 | no_license | /************************************************************************************
* Copyright (C) 2007 by the members of PG 510, University of Dortmund: *
* d-collide-users@lists.sourceforge.net *
* Andreas Beckermann, Christian Bode, Marcel Ens, Sebasti... |
45a91ff1abfb0af48d06902444a9aacf16f64326 | 08be8b928ab92117c4c205faf3f6adaa6f174e01 | BhuwaneshNainwal/CSES | /Sorting and Searching/Apartments.cpp | C++ | cpp | 2,679 | no_license |
/*
ॐ
JAI SHREE RAM
Hare Krishna Hare Krishna Krishna Krishna Hare Hare
Hare Rama Hare Rama Rama Rama Hare Hare
ॐ
*/
//Written by Bhuwanesh Nainwal
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
using namespace s... |
8b617db4bf80bfad09dcef815c0a5619f9987e11 | e08c9a93c6d5f6ece6d016fe1989cbb7379e3ee1 | coderkalyan/mavlink-actuator-test | /actuator.cpp | C++ | cpp | 2,169 | permissive | #include <mavsdk/mavsdk.h>
#include <mavsdk/plugins/mavlink_passthrough/mavlink_passthrough.h>
#include <chrono>
#include <cstdint>
#include <iostream>
#include <future>
#include <memory>
using namespace mavsdk;
void send_actuator(std::shared_ptr<MavlinkPassthrough> mavlink_passthrough,
float value1, float va... |
beb266c82aa35217fd823e3a738ffd53a11206cf | efd4f210d9103f8e6162d0cfff079a89adf97aa7 | kim-hyeoncheol/Algorithms | /www.acmicpc.net/10610/main.cpp | C++ | cpp | 623 | no_license | /*
* 10610 - 30
* https://www.acmicpc.net/problem/10610
* Run Time :
*/
#include <iostream>
using namespace std;
int main(int argc, char* argv[]) {
string str;
int count[10], i, sum;
while (cin >> str) {
for (i = 0; i < 10; i++) count[i] = 0;
for (i = 0; i < str.size(); i++) count... |
1a8c9eb37bffc3f19e6e0e49e2776e42586e91a9 | 7a044db6d7dbde0a2a43e05364a2f1c9defba8ab | parcPrograms/RayTracer | /rt2/Sphere.cpp | C++ | cpp | 1,206 | no_license | #include "stdafx.h"
#include "Sphere.h"
#include "Ray3.h"
#include <iostream>
using namespace std;
Sphere::Sphere(unsigned char r, unsigned char g, unsigned char b, unsigned char a, double posX, double posY, double posZ, double rad)
{
color[0] = r;
color[1] = g;
color[2] = b;
color[3] = a;
position[0] = posX;
po... |
53b9580700672a9350b0ddb1bc4f522c9e2fc2e6 | 83d998c1ebd17e6a9a2ce5b94cf2f9da36f03846 | proletesseract/navcoin-core | /src/qt/getaddresstoreceive.cpp | C++ | cpp | 4,019 | permissive | #include <qt/addresstablemodel.h>
#include <qt/guiconstants.h>
#include <qt/guiutil.h>
#include <main.h>
#include <qt/walletmodel.h>
#include <wallet/wallet.h>
#include <qt/coldstakingwizard.h>
#include <qt/getaddresstoreceive.h>
#include <qt/ui_getaddresstoreceive.h>
#include <stdint.h>
#include <QSettings>
#ifdef... |
d49e26399caac06362b04e7d56a496a22e61aa7c | afe8c579cfe1971f1f80426bb2a21e2904877020 | massbrowser/android | /third_party/WebKit/Source/bindings/core/v8/serialization/SerializedScriptValueFactory.cpp | C++ | cpp | 1,411 | permissive | // Copyright 2014 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 "bindings/core/v8/serialization/SerializedScriptValueFactory.h"
#include "bindings/core/v8/serialization/V8ScriptValueDeserializer.h"
#include "... |
00cdaf43e95a4685fd3753da21b6c56442741371 | e7b15b691abb95933444cdac5e8424dcb3e112e9 | mlbrock/MlbDev | /SocketIo/ResolveHost.cpp | C++ | cpp | 15,695 | permissive | // ////////////////////////////////////////////////////////////////////////////
// ////////////////////////////////////////////////////////////////////////////
// SocketIo Portable Socket Library Source Module
// ////////////////////////////////////////////////////////////////////////////
/*
File Name : %M%
File... |
d298cde3b1e6f5587d858c7343289c38fe930d73 | 2d65d61c5558fc088659024d4cad962e9f5fd0dc | vladus7000/WestDuel | /Engine/Render/Passes/MainZpass/MainZpass.cpp | C++ | cpp | 744 | no_license | #include <Engine/Render/Passes/MainZpass/MainZpass.hpp>
#include <Engine/Render/Renderer.hpp>
#include <Engine/Render/GBuffer.hpp>
#include <Engine/Render/Resources.hpp>
#include <Engine/Window.hpp>
#include <Engine/World.hpp>
MainZpass::~MainZpass()
{
}
void MainZpass::setup(Renderer& renderer, Resources& resources)... |
041a1096b3c6c4303082d9ab5c3a5747f366ddb1 | c52f343faef6225352cae62880ec20e2c488c9c8 | serchmg/OOP_Examples_C- | /classBasic2.cpp | C++ | cpp | 1,422 | no_license | #include<iostream>
using namespace std;
//Declare student class
class Student {
public:
//Overload constructors
Student(){rollNo=0, name="No name";}
Student(int n, char *p){rollNo = n, name=p;}
Student(const Student &src) { //copy constructor
rollNo = src.GetRollNo();
name = src.GetName();
cout<<"\n ... |
a3a9a10756e8fde873ea00dadac6b324e72d658a | c7caa76d849923a6a71aedf48fc23458d57ec80d | Yar4ik000/CMC-MSU-4-semester | /3/3.3.cpp | C++ | cpp | 2,599 | no_license | #include <iostream>
#include <string>
#include <sstream>
#include <cmath>
#include <iomanip>
#include <cstdio>
#include <map>
#include <functional>
#include <vector>
namespace numbers {
static std::map<std::string, std::function<void(complex_stack&)>> op_to_func
{
{"!", [](complex_stack& stack)
... |
25e700d5f05bda65ce66df99a9182d16bf495afe | de7b6f1c9310af30c29d07ddc0514b4e73e137c8 | langzi989/sqlParser | /src/patternItem.cpp | C++ | cpp | 1,267 | no_license | /*
patternItem is a class to store the pattern items.
*/
#ifndef __PATTERN_H__
#define __PATTERN_H__
#include <string>
using namespace std;
struct TYPE {
const int COLUMN = 0;
const int TOKEN = 1;
const int REGEX = 2;
} pattern_type;
class patternItem {
/*
type is a type of the pattern, 0:the column of v... |
53b190c14121517da4fa6cb678f6b68426ffee0f | 3f73d4ba4afbbfa30f42374e059d40650776d0b2 | nagarkar/plasticsandpcbsposts | /statemachines/ABumpDetector/ABumpDetector.cpp | C++ | cpp | 6,678 | no_license | //****************************************************************************
// Model: AccBumpDetector.qm
// File: ABumpDetector/ABumpDetector.cpp
//
// This code has been generated by QM tool (see state-machine.com/qm).
// DO NOT EDIT THIS FILE MANUALLY. All your changes will be lost.
//
// This program is open sou... |
04e406389b6b9e77bb5ddb82eaf6df5dd130998b | 304be219fc15e659e0ea2fb2cef99aa2a3e6c311 | nickrobison-usds/mobility-cpp | /src/distance.cpp | C++ | cpp | 4,776 | no_license | //
// Created by Nicholas Robison on 5/26/20.
//
#include <algorithm>
#include <io/parquet.hpp>
#include <io/Shapefile.hpp>
#include <hpx/hpx_init.hpp>
#include <hpx/parallel/executors.hpp>
#include <hpx/parallel/algorithms/transform_reduce.hpp>
#include "utils.hpp"
#include "spdlog/spdlog.h"
namespace par = hpx::par... |
b7dccf819dd7b4e3f0d74083441ff3f6bef080f2 | 5e202c1dcf4914ee9d2b117d1c3c9a0ec0a40045 | cristian357r4/Code-And-Inspiration | /Cpp And Inspiration/19.Cpp And QSketchBasedInterface/4.Cpp And QSketchGraphs/Project/QGraph.cpp | C++ | cpp | 2,014 | no_license | #include "QGraph.h"
void QGraph::operator+=(int* edge)
{
int begin=add(edge[0]), end=append(edge[1]);
this->edges<<new int[2]{begin, end};
}
void QGraph::operator--(int)
{
if(edges.isEmpty())return;
this->edges.removeLast();
this->updateVertices();
}
void QGraph::updateEdge()
{
if(edges.isEmpty())return;
int* e... |
6e2c2498da1951224a65b0ffa1563dfba901b3f8 | 86547c940c1a5599e8449a7497b244a5f6b10545 | juslee/boost-svn | /libs/geometry/doc/src/examples/algorithms/for_each_point.cpp | C++ | cpp | 1,758 | permissive | // Boost.Geometry (aka GGL, Generic Geometry Library)
// QuickBook Example
// Copyright (c) 2011-2012 Barend Gehrels, Amsterdam, the Netherlands.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LI... |
e7ee634eab42c0647eb13f6d69114f12bbe4e208 | 44fbd51e2569fd2a7ffc86f0ad50acd66001a2f5 | martinknafve/hmailserver-1 | /hmailserver/source/Server/Common/AntiSpam/SpamTestMXRecords.cpp | C++ | cpp | 2,994 | no_license | // Copyright (c) 2010 Martin Knafve / hMailServer.com.
// http://www.hmailserver.com
#include "StdAfx.h"
#include "SpamTestMXRecords.h"
#include "SpamTestData.h"
#include "SpamTestResult.h"
#include "AntiSpamConfiguration.h"
#include "../TCPIP/DNSResolver.h"
#include "../Util/TLD.h"
#include "../../SMTP/SPF/SP... |
05c3e97c36d58ee148d6268dfc1f2644e9dcd46a | b6b71e07afa176596ed5982692ee9f1176893ac3 | millanlaboratory/cnbirosmobile | /cnbiros_robotino/src/robotino_node_odometry.cpp | C++ | cpp | 1,391 | no_license | #include <ros/ros.h>
#include "cnbiros_robotino/Odometry.hpp"
/*!
* \file
*
* \brief Robotino odometry node
*
* \par General description:
* This executable provides an implementation of a working robotino odometry node.
* It can be used as it is and it can be configured via xml launch file.
*
* \par Main beh... |
9b7b21ff5562f82dcebf1c619881d6f5523dc4b7 | b4b87aea6690f4259daf85a169749435dd36c588 | yoshixmk/develop-subject | /production_environment_test.cpp | C++ | cpp | 33,007 | no_license | #include <opencv/cv.h>
#include <opencv/highgui.h>
#include <time.h>
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <string.h>
#include <pigpio.h>
//#include <wiringPi.h>
//#include <softPwm.h>
#include <float.h>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
#define C... |
db7b3e7b379e5fafb6e6c4838c0e8e46c9ae39ba | 4506120b2d8904e75b2006c7afd7278e567f0837 | bigben0123/chromium | /chrome/browser/extensions/convert_web_app.cc | C++ | cc | 19,349 | permissive | // Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chrome/browser/extensions/convert_web_app.h"
#include <stddef.h>
#include <stdint.h>
#include <limits>
#include <memory>
#include <string>... |
9d42b5d92ef166791df95b5384ff97a6ff6c2d97 | 37e18b517619a9446026457d02b04e0c8ed0543e | dingshiyu/aliyun-openapi-cpp-sdk | /cloudapi/src/model/CreateAppRequest.cc | C++ | cc | 2,280 | permissive | /*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required... |
411472a8a9f5f03b0b70adb95ff53717a0d745ce | f1ab4cda7cd69677bb41d8fbc0ae55d8550a6cf0 | softhub-software-development/gip | /src/common/hal/hal_module.cpp | C++ | cpp | 7,187 | no_license |
//
// hal_module.cpp
//
// Created by Christian Lehner on 5/25/16.
// Copyright (c) 2019 Softhub. All rights reserved.
//
#include "stdafx.h"
#include "hal_module.h"
#include "hal_utils.h"
#if defined PLATFORM_WIN
#include <objbase.h>
#elif defined PLATFORM_MAC
#include <dlfcn.h>
#elif defined PLATFORM_LINUX
#incl... |
1e7cf4dae496e0c2fd575a4eac2c9652e3481916 | c6b4b69371de8a3b5cf6e62421d1442bc9643018 | bqia0/CSES-Solutions | /Graph Algorithms/4h.cpp | C++ | cpp | 1,242 | no_license | #include <bits/stdc++.h>
using namespace std;
#define ll long long
const int nmax = 1e5;
vector<pair<int, ll>> adj[nmax+1];
ll dist[nmax+1];
int processed[nmax+1];
struct nodePriority{
bool operator()(const pair<int, ll> & a, const pair<int, ll> & b){
return a.second > b.second;
}
};
int main(){
... |
aea8bcb055c3019b5ee8a2375b52f78c8a593177 | 97f36037320c4bb60deb5e59dc62dd3ea1c9998b | hxfxjun/oneflow | /oneflow/core/job/sbp_parallel.cpp | C++ | cpp | 9,692 | permissive | /*
Copyright 2020 The OneFlow Authors. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agre... |
d99e7205023b657ca667dfcc4e1cc5a9209ca985 | eced149ccf71ee0cef66cdde3d8f19cbc1255dc8 | moljen/DREAM | /Dream/B4/B4a/include/B4aEventAction.hh | C++ | hh | 4,695 | no_license | //
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration... |
5b0b423ad7cae5e0fa0806b098098c54d8e182ff | c32f20e276a4de9e7918be489ec1f5d27f2b91b8 | walkdis/-1 | /AlrExist.cpp | C++ | cpp | 278 | no_license | // Copyright 2015 <Anna Simakova>
#include "AlrExist.h"
#include <string>
EmployeeAlrExist::EmployeeAlrExist(const string& name) :exception() {
msg = "Employee: " + name + " already exist";
}
const char * EmployeeAlrExist::what() const throw() {
return msg.c_str();
}
|
578fcb8dd2f7273666cd47b9a07efd794230fbfa | 19434d622bcc59db50cd8d9d4b9281e0b5af09b1 | VenturaLM/Assignment_LP | /Grupo11/table/stringVariable.hpp | C++ | hpp | 3,890 | no_license | /*!
\file stringVariable.hpp
\brief Declaration of StringVariable class.
\author Ventura Lucena Martinez & Francisco David Castejón Soto
\date 2021 - 5 - 30
\version 2.0
*/
#ifndef _STRINGVARIABLE_HPP_
#define _STRINGVARIABLE_HPP_
#include <string>
#include <iostream>
#include "variable.hpp"
/*!
\na... |
ecf768bbb45c23506fac49ec763f4e7797f5590a | 87603e980b6e9eda6b281c497cb1e6a6841d1ede | fermads/node | /deps/v8_inspector/platform/inspector_protocol/ErrorSupport.cpp | C++ | cpp | 1,623 | 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 "platform/inspector_protocol/ErrorSupport.h"
#include "platform/inspector_protocol/String16.h"
#include "wtf/Assertions.h"
namespace blink {
na... |
2b9bae3972b77a864010b9ce23f2a64a97b9c0ce | a8b673b65846fa4d653729e5e3a55226af0f7c99 | pedro-pita/MaterialDeEstudoParaC | /Estruturas_codigos/estruturas_3.cpp | C++ | cpp | 1,147 | no_license | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
struct pessoa{
char nomePessoa[80], morada[80];
int idade,bi;
};
int main(){
/* Inicializando a estrutura */
struct pessoa p;
/* Usamos strcpy- copiar string */
strcpy(p.nomePessoa, "Sérgio");
strcpy(p.morada, "Funchal");
// Atribuição simples
p.ida... |
38d1dfc4e246016bcf03357ad5958759d681ed43 | 684acc5d2a892d4ee4842716cfab102aa0e92b2e | bingshi/mojo | /mojo/dart/embedder/dart_debugger.cc | C++ | cc | 4,428 | permissive | // Copyright 2015 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "mojo/dart/embedder/dart_debugger.h"
#include "dart/runtime/include/dart_api.h"
#include "dart/runtime/include/dart_debugger_api.h"
#include "dar... |
480409c352745e4f7d415e65b619ab99d6094bca | 07cb960dbe55ff8492e1b2880268a561148cbf3e | zxy3/cpp_primer_practice | /test5.25.cpp | C++ | cpp | 1,127 | no_license | /**=================================================================================================
* @file test5.25.cpp.
*
* Implements the test 5.25 class
* 练习 5.25: 修改上一题的程序, 使用 try 语句块去捕获异常。 catch 子句应该为用户输出一条提示信息,
* 询问其是否输入新数并重新执行 try语句块的内容。
*=================================================================... |
df39c2ea003b32ed7eb1bc6d6a831849ddd24876 | 3f0c8db72377db2551388b6b4a3c20f013810b90 | nwjs/chromium.src | /content/browser/worker_host/shared_worker_service_impl.cc | C++ | cc | 19,778 | permissive | // Copyright 2014 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "content/browser/worker_host/shared_worker_service_impl.h"
#include <stddef.h>
#include <algorithm>
#include <iterator>
#include <string>
#include "base/check_op.h"... |
178ccdea9e885b4999acdab16eafd3becd1c7ac6 | 016a24e1994425610915125d9a2ecd58a60d89a5 | totalkyos/AWS | /aws-cpp-sdk-cloudfront/source/model/CustomHeaders.cpp | C++ | cpp | 2,531 | permissive | /*
* Copyright 2010-2016 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License").
* You may not use this file except in compliance with the License.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file... |
a862bdaf2dabebfa393e88217a6e61f51ce51ded | ee63ce6d8053e005b4edfbdba73c8d06aeadecb6 | batmanuel-sandbox/astshim | /python/astshim/parallelMap.cc | C++ | cc | 1,600 | no_license | /*
* LSST Data Management System
*
* This product includes software developed by the
* LSST Project (http://www.lsst.org/).
* See the COPYRIGHT file
*
* 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 Softwar... |
928eea785da7aa1dcec33c7655f2fdffdce8a033 | 20190da9780f40833d8146c91129acaaaef266bc | Barmaco/workspace | /extension_cmake/src/filemanager/FileManager.cpp | C++ | cpp | 8,345 | no_license | /*************************************************
Copyright:
Author:Barmaco
Qq:992077171
Date:2016-03-21
Description:
**************************************************/
#include "FileManager.h"
#include <time.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <stdio.h>
#if (TARGET_PLATFORM == TARGE... |
e01440b3f1e6faf459dfd7d44d96e6b88c259c53 | ffdf29f904493cdb22887ba71f6d352ff4a84b5b | Shadeban/cpppath | /main.cpp | C++ | cpp | 3,003 | no_license | #include <iostream>
#include <fstream>
#include <utility>
#include <algorithm>
#include <functional>
#include <vector>
#include <cmath>
#include <ctime>
#include "mapparser.hpp"
#include "maptraverser.hpp"
#include "ScenarioLoader.h"
using namespace std;
class ComparePair
{
public:
bool operator()(const pair<double,... |
87894df16c676fd0fdf431a7982231a79bfd717b | ee99dd61ead9567ee6d7d83a980f7d73ed52a221 | igorkorsukov/veloroute39_mobile | /src/mobile/main.cpp | C++ | cpp | 314 | no_license | #include <QGuiApplication>
#include <QQmlApplicationEngine>
int main(int argc, char *argv[])
{
QGuiApplication app(argc, argv);
QQmlApplicationEngine engine;
engine.load(QUrl(QStringLiteral("qrc:/qml/main.qml")));
if (engine.rootObjects().isEmpty())
return -1;
return app.exec();
}
|
e4a839888f41315eba4984f45ecbf6c0457e3ec7 | ca08ff5d0710b8d8bc212162a01cb0e68266f98a | rbenic-fer/progauthfp | /examples/google-code-jam/hustsxh/gcjqr_A.cpp | C++ | cpp | 787 | permissive | /*
* File: gcjqr_A.cpp
* Author: xhSong
* Created on 2010年5月8日, 上午9:07
* Time Complexity :
* Space Complexity :
* Describe :
*/
#include <cstdio>
#include <iostream>
#include <cstring>
#include <sstream>
#include <cstdlib>
#include <ctime>
#include <vector>
#include <set>
#include <queue>
#include <map>
#incl... |
43d0b00ef10a594e76f20f8ec542f9ef0c203db0 | eae956475a3c179abe632963ddb88022cacd99d7 | robert-strandh/clasp | /src/asttooling/clangTooling.cc | C++ | cc | 35,634 | no_license | /*
File: clangTooling.cc
*/
/*
Copyright (c) 2014, Christian E. Schafmeister
CLASP is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later vers... |
b0302fb65fad106123d8a9d0825e3e4f2989400d | 1e66b229dbdadf1d7420c1ade114315c71bcdeb0 | be-oi/beoi-training | /13-dynamic-programming-i/src/562-solution.cpp | C++ | cpp | 715 | no_license | #include <bits/stdc++.h>
using namespace std;
#define MAX_M 100
#define MAX_S MAX_M*500
int n, m, S;
int v[MAX_M];
int memo[MAX_M][MAX_S+1];
int dp(int i, int money1) {
if(i == m)
return abs(S - 2*money1);
if(memo[i][money1] != -1)
return memo[i][money1];
return memo[i][money1] = min(dp(i... |
46b1f24b4a12c350087142e0eadb6bd00c648cfd | bd5a21f57b471a3f3b5ecc36d96ac15e7c197a72 | idontknoooo/leetcode | /summer2018/easy/121-best-time-to-buy-and-sell-stock.cpp | C++ | cpp | 370 | no_license | class Solution {
public:
int maxProfit(vector<int>& prices) {
int min_pos = 0, max_profit = 0;
for(int i = 1; i < prices.size(); ++i){
max_profit = prices[i]-prices[min_pos] > max_profit? prices[i]-prices[min_pos] : max_profit;
min_pos = prices[i] < prices[min_pos]? i : min_p... |
38c0c1a2579f43ac58629574f6dfb8fff44e275e | 9eabc0fa6e9f0bf8eae7a1753319736ce94b7560 | blizmax/Yave | /yave/scene/OctreeNode.cpp | C++ | cpp | 4,740 | permissive | /*******************************
Copyright (c) 2016-2021 Grégoire Angerand
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy... |
49d150257d0e12f03ea208497a338a41e453275c | 3292a77c57e46a88567a25c77e54e1bc88f5ba6c | ibnomaras/A1_20110221 | /A1_20110221/A1_P1_20110221/main.cpp | C++ | cpp | 4,841 | no_license | #include <iostream>
#include <sstream>
using namespace std;
class BigDecimalInt{
public:
string value ;
BigDecimalInt (string decStr)
{
if (decStr.find_first_not_of("-0123456789") == std::string::npos){
value = decStr ;
// cout <<value<<endl;
... |
b62a230f6789758f53fbcf76cf2f5522d92bd34e | 1bbe1899db7cd5fa83ba7595b2dd8376ce87de25 | haochangfei/ACM | /hdu1334.cpp | C++ | cpp | 483 | no_license | #include <bits/stdc++.h>
using namespace std;
int main()
{
for(int a = 6; a <= 200 ; a++)
{
for(int b = 2 ;b <=a ; b++)
{
for(int c = b; c <= a ; c++)
{
for(int d = c ;d <= a ;d++)
{
if(a*a*a == b*b*b + ... |
09e1391968bd7af6b356c37d943a8009eefd2af6 | 6f9d67435f08c90769bb2129a87fb200f3f388ac | sowamy/ECE3220 | /Lab7/src/main.cpp | C++ | cpp | 12,930 | no_license | #include <iostream>
#include <string>
#define SHORT_BEEP '.'
#define LONG_BEEP '-'
using namespace std;
/* CLASS: Message
* DESCRIPTION: Base class, stores message and functions.
*/
class Message {
private:
public:
// Variables
string raw; // Hold the message, inputted by the user
// Constructors
Messa... |
2ed10ba0059b4d6d036d258d6bb92beece4bf2ac | 113177fd3210e2961d93d5a48ceef878e8f5d4dc | silferysky/RogueArcher | /RogueEngine/Source/AudioFade.cpp | C++ | cpp | 1,835 | no_license | /* Start Header ************************************************************************/
/*!
\file FadeObject.cpp
\project Exale
\author Javier Foo, javier.foo, 440002318 (100%)
\par javier.foo\@digipen.edu
\date 3 April,2020
\brief This file contains the function... |
c9e4ad5a2248234ffd4978c7e5b31ce42bde4885 | 08ede768b46176a81c934bd22386e09c1539f699 | Minato1803/Code_Competition | /CODEFORCES/P183SUMD.cpp | C++ | cpp | 397 | no_license | #include <bits/stdc++.h>
using namespace std;
#define ll long long
void DiChuyen(int n, int i, int j,ll k)
{
while (k>0){
if (n==1&&k>0){
cout<<i<<" "<<j<<" 0";
}
else {
DiChuyen(n-1,i,6-i-j,k);
DiChuyen(1,i,j,k);
DiChuyen(n-1,6-i-j,j,k);
}
k-=1;
}
cout<<i<<" "... |
72d702aed60cbb28695f483e50c886b6e50188e8 | 08a8ac5b648bd168fa87088cd2041156bd633ca3 | wuyou33/Enabling-Robust-State-Estimation-through-Measurement-Error-Covariance-Adaptation | /3rdparty/GPSTk/ext/lib/Procframe/ExtractPC.hpp | C++ | hpp | 3,867 | permissive | //============================================================================
//
// This file is part of GPSTk, the GPS Toolkit.
//
// The GPSTk is free software; you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as published
// by the Free Software Foundation; ei... |
0a472960945c4b05de77ceceb6b1c0f6786cd94a | 33c54d8a5fc0a186ce43ab0246abb6187f2f7552 | MinglangQiao/omnieval | /compsph/compsph.cpp | C++ | cpp | 2,360 | no_license | #include <getopt.h>
#include "yuv_helper.h"
#include "map_utils.h"
#include "panomapper.h"
static int usage(const char *exe){
fprintf(stderr,
"%s [-i input1] [-o input2] [-f filter] [-m m] [-n n] [-z z] [-w w] [-s] src1 src2 sph\n"
"\t-i ... Input file type: cube, rect eqarea, merc, dyad ... |
b298174c3b79c02ba7b980a279de8f1aa28f087b | ebe2d30f4d84fecc348dd3f7e985a0e4a985d4be | marmikreal/libs | /vb6_utypes/utypes.cpp | C++ | cpp | 6,502 | no_license | #include <windows.h>
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <cstdlib>
enum op{
op_add = 0,
op_sub = 1,
op_div = 2,
op_mul = 3,
op_mod = 4,
op_xor = 5,
op_and = 6,
op_or = 7,
op_rsh = 8,
op_lsh = 9,
op_gt = 10,
op_lt = 11,
op_gteq = 12,
op_lteq = 13,
op_... |
141ed22c7d31800477c9379b5ea413f5a051e622 | 0f4f0a2ea6092236162ff8c7dfbfa5dcc8eb302b | SaschaMester/delicium | /remoting/protocol/jingle_session.cc | C++ | cc | 23,836 | 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 "remoting/protocol/jingle_session.h"
#include "base/bind.h"
#include "base/rand_util.h"
#include "base/single_thread_task_runner.h"
#include... |
d88fac3232f86cc7b9fedafa749d98ec467453cc | 1551fe2eb85998b24c4ec84dc0027c2e5e0fc3c9 | emisner15/Cipher | /cipher.cpp | C++ | cpp | 1,818 | no_license | #include <iostream>
#include <fstream>
#include <ostream>
#include <sstream>
#include <string>
#include <cstdlib>
using namespace std;
char encode_character(char character, int shift)
{
if (isalpha(character))
{
if (islower(character))
{
for (int i = 0; i <shif... |
0cc3b0abdb5b3f9fed0c4ea7fe3e2be1ab3a1057 | b6aafdabb38205e4c582621f04cd6094bae9dde1 | svn2github/ngene | /trunk/Tutorials/Tutorial_1_6/App.cpp | C++ | cpp | 2,784 | no_license | #include "App.h"
#include "nGENE.h"
#include "ScriptLua.h"
void hello() {
cout << "Hello world from tutorial 1.7!" << endl;
}
void App::createApplication()
{
FrameworkWin32::createApplication();
m_pMouse->setSensitivity(0.02f);
m_pPartitioner = new ScenePartitionerQuadTree();
SceneManager* sm... |
4703f75077060974dee17d03fc804c8092e508c3 | 10d4eb051a4c5fa768240cd16d13d2d9b55fe19c | DannyGH/AzureIoT | /src/time.cpp | C++ | cpp | 559 | permissive | // Copyright (c) Arduino. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
#include <time.h>
#include <sys/time.h>
#include <RTCZero.h>
RTCZero rtc;
extern "C" {
int _gettimeofday(struct timeval* tp, void* /*tzvp*/)
{
tp->tv_s... |
65b343a8d694d54ec38da9946c079eea30b62aef | 1beb27b554317ced46e4e96ba81b43d3720324b2 | onaycan/natural_element_method_solver | /LinearAlgebra.cpp | C++ | cpp | 2,235 | no_license | #include "stdafx.h"
#include "Nem3dCan.h"
#include "ClassHeaders.h"
void Matrixdet(double M[][3], double& detM)
{
detM=M[0][0]*(M[1][1]*M[2][2]-M[2][1]*M[1][2])+
M[0][1]*(M[2][0]*M[1][2]-M[1][0]*M[2][2])+
M[0][2]*(M[1][0]*M[2][1]-M[2][0]*M[1][1]);
}
void Matrixdet(ublas::c_matrix<double,3,3> M, d... |
30dbd01cd8e8fbb035df731bb3240279af1e4103 | c2061028c844d7eec275a6011790b29fc5aad4d2 | mythsman/guisan | /include/guisan/sdl/sdltruetypefont.hpp | C++ | hpp | 4,447 | permissive | /* _______ __ __ __ ______ __ __ _______ __ __
* / _____/\ / /\ / /\ / /\ / ____/\ / /\ / /\ / ___ /\ / |\/ /\
* / /\____\// / // / // / // /\___\// /_// / // /\_/ / // , |/ / /
* / / /__ / / // / // / // / / / ___ / // ___ / // /| ' / /
* / /_// /\ / /_// / // / // /_/_ ... |
2e6f066c0e87b0bd6ded77828a54f5fe1cd5152d | 205864d9e747afc7fd576698756b2441961a8d21 | jxygzzy/Luogu | /P1470 [USACO2.3]最长前缀 Longest Prefix.cpp | C++ | cpp | 1,771 | no_license | /***
* @Author: P19Y0UN9_居居
* @Date: 2020-08-12 10:59:57
* @LastEditTime: 2020-08-12 19:18:49
* @LastEditors: P19Y0UN9_居居
* @Description:
* @FilePath: \Luogu\P1470 [USACO2.3]最长前缀 Longest Prefix.cpp
* @居居 <jxygzzy@163.com>
*/
#include <iostream>
#include <algorithm>
#include <string>
#include <set>
using name... |
8be1cf051e90cf358e974a871d7acb3a55313273 | 86ee3334c9f5a0283a7b1a28496b25bef8b3f580 | Kawser-nerd/CLCDSA | /Source Codes/CodeJamData/13/54/7.cpp | C++ | cpp | 2,091 | no_license | #include <algorithm>
#include <cstdio>
#include <cstdlib>
#include <list>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <vector>
#include <cmath>
#include <cstring>
#include <string>
#include <iostream>
#include <complex>
#include <sstream>
using namespace std;
typedef long long LL;
typedef... |
23625099bf6133bc80393f2efdd7744f5f6b2d0e | 4f5bf0cb8e56ad37405e4f9f72ef2de995457895 | archercreat/dta-vs-osc | /sc-virt/src/projects/compiler-rt/test/scudo/double-free.cpp | C++ | cpp | 1,045 | permissive | // RUN: %clang_scudo %s -o %t
// RUN: not %run %t malloc 2>&1 | FileCheck %s
// RUN: not %run %t new 2>&1 | FileCheck %s
// RUN: not %run %t newarray 2>&1 | FileCheck %s
// RUN: not %run %t memalign 2>&1 | FileCheck %s
// Tests double-free error on pointers allocated with different allocation
// functions.
#in... |
8d9f4d7167caf9b6ff090408b99c2981735b7d7d | 0410743b1f6c35f520d6f299141731fe5c403fc0 | JohanMabille/boost.simd | /bench/function/scalar/is_flint/regular.uint8_t.0_10.cpp | C++ | cpp | 849 | permissive | // -------------------------------------------------------------------------------------------------
// Copyright 2017 - NumScale SAS
//
// Distributed under the Boost Software License, Version 1.0.
// See accompanying file LICENSE.txt or copy at
// ... |
2985431ee69d7bc60880b44b13926bca264501d9 | ebe0c0fbb392912fb5f60a40a69e02137af34ac8 | ECToo/world-opponent-network | / world-opponent-network/TitanApi/Ad/AdAPI/AdDisplay.cpp | C++ | cpp | 6,300 | no_license |
#pragma warning (disable : 4786)
#include "AdDisplay.h"
using namespace WONAPI;
AdDisplay::AdDisplay() :
hLoadTrigger(NULL),
mFuncPaintCallback(NULL),
mDataPaintP(NULL),
mCurrentImpageP(NULL),
mNumScenes(0),
mCurrentSceneNum(0),
mTimeToNextScene(INFINITE),
mAllowSceneSkipping(true),
mShownCur... |
d76438d69e9f87e21638685c3152c89c6606a181 | 03a64ad39c6185f44cdd6d0e036c58263031ccd4 | paladin601/Graficas3 | /basicDemo/TextureLoader.cpp | C++ | cpp | 2,632 | no_license | #include "TextureLoader.h"
unsigned int TextureLoader::load(const char * path)
{
unsigned int id;
// Creates the texture on GPU
glGenTextures(1, &id);
// Loads the texture
int textureWidth, textureHeight, numberOfChannels;
// Flips the texture when loads it because in opengl the texture coordinates are flipped... |
19277005c038c05e838e5fb58d2748875fe3dce7 | 2e3e77a33a3f4f023b618c13b8957f76fec69060 | BenjaminBLi/ccc-with-c | /DMOJAndWCIPEG/vmss15c1p4.cpp | C++ | cpp | 899 | no_license | #include <bits/stdc++.h>
#define f first
#define s second
using namespace std;
typedef pair<int, int> ii;
typedef vector<ii> vii;
typedef vector<int> vi;
int T, N, M, G;
long long dist[3010];
vii adj[3010];
bool is[2010];
int main(){
scanf("%d %d %d %d", &T, &N, &M, &G);
queue<int> q;
int tmp;
for(int i =0;i < G... |
3528206741a10f9e5db7e1acc3a69a09e030125b | 814e949eb061d09495a9712a147e4eeec60fc9ed | jackros1022/learning-opencv-code | /opencv-2.4.0/modules/stitching/src/blenders.cpp | C++ | cpp | 17,859 | no_license | /*M///////////////////////////////////////////////////////////////////////////////////////
//
// IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING.
//
// By downloading, copying, installing or using the software you agree to this license.
// If you do not agree to this license, do not download, instal... |
9196eb228589eaef2b58e9918002cb0f47d2a53f | eec11f1cc062cd7e583bb0e056dd713d50339af6 | ISISComputingGroup/EPICS-EPICS_V4 | /exampleCPP/database/src/exampleHelloRPCRecord.cpp | C++ | cpp | 2,353 | permissive | /*
* Copyright information and license terms for this software can be
* found in the file LICENSE that is included with the distribution
*/
/**
* @author mrk
* @date 2013.04.02
*/
#include <epicsThread.h>
#include <pv/standardField.h>
#include <sstream>
#define epicsExportSharedSymbols
#include <pv/exampleHello... |
bff641fbd7ea4963da37f45e6627aec6a9c18662 | a88ab3c874a7d8f4c6e0f700ede0d4bc0cbd066e | akatial/cpp | /prime2.cpp | C++ | cpp | 524 | no_license | #include <iostream>
#include <algorithm>
int main()
{
int N;
std::cin >> N;
bool *is_prime = new bool[N+1];
std::fill_n(is_prime, N+1, true);
for ( int i = 2 ; i * i <= N ; i++ )
{
if ( is_prime[i] )
{
for ( int j = 2 ; i * j <= N ; j++ )
{
is_prime[i*j] ... |
f563f6b3dd573f002949e95f1a2cb3548a8add09 | e0547ebf650488dcfbcb496be628542b822b1a85 | 237suraj/CPP | /060TestProblem.cpp | C++ | cpp | 786 | no_license | #include<iostream>
using namespace std;
namespace nm060
{
class Ship{
};
class Station{
};
class Asteroid{
};
//(Not Accepted)
template<typename T1,typename T2>
void ProcessCollission(T1 obj1,T2 obj2) //process collission generated for every combination
{
if(typeid(obj1)==typeid(Ship) && typeid(obj2)==typeid(Asteroid)... |
918de8f44d451e14d6b4a40e5415fa4bc343984a | b7be5378de4c87fb0d499805416d8c5c6ad23f9b | TeamVault/tauCFI | /C++ Benchmark Programs/Benchmark Files 1/classtester/autogen-sources/source-7683.cpp | C++ | cpp | 3,191 | 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... |
d8f95641e3f642cd3fb843cf82340aca9d2650ae | 39df7952eca720854176521f13b9ecadf444026e | pmiddend/fcppt | /libs/options/include/fcppt/options/default_value.hpp | C++ | hpp | 413 | permissive | // Copyright Carl Philipp Reh 2009 - 2018.
// Distributed under the Boost Software License, Version 1.0.
// (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef FCPPT_OPTIONS_DEFAULT_VALUE_HPP_INCLUDED
#define FCPPT_OPTIONS_DEFAULT_VALUE_HPP_INCLUDED
... |
f1543d594225694df0f59d5235cdc8d1757f062d | 07d6d768e6e326e92015cd06e3b9fc2c03ee9e10 | BGCX261/zprproject-jspw-hg-to-git | /Client/src/AuthCommand.cpp | C++ | cpp | 1,178 | no_license | /*
* File: AuthCommand.cpp
* Author: Pawel
*
* Implementacja klasy AuthCommand
* Created on 26 listopad 2010, 14:16
*/
#include "AuthCommand.hpp"
#include "Visitor.hpp"
#include "ExceptionClient.hpp"
#include <boost/lexical_cast.hpp>
namespace Client
{
AuthCommand::AuthCommand(std::string login, std::str... |
7c6bbb9466a6b9ea089e22b9eea7bd26a1af1404 | caa874a19519c542e43e0926cac70fbf886e53b6 | shiLinwong/VideoRecorder | /src/widget/pushpoint.cpp | C++ | cpp | 2,181 | no_license |
/**
* 叶海辉
* QQ群121376426
* http://blog.yundiantech.com/
*/
#include "pushpoint.h"
PushPoint::PushPoint(QWidget *parent)
{
setParent(parent);
setWindowFlags(Qt::FramelessWindowHint); //使窗口标题栏隐藏
setMouseTracking(true);
QPixmap pixmap = QPixmap(QSize(POINT_SIZE,POINT_SIZE)); //构建一个QPixmap
pixm... |
46837756847674ed83ae0d3cc5fc115b9c11f813 | a802a3b94a4c8955279cd18363dfb1372acd358c | codesurvivor/noc-router | /booksim2.0/branches/mecs/src/networks/fly.cpp | C++ | cpp | 4,241 | no_license | // $Id: fly.cpp 5188 2012-08-30 00:31:31Z dub $
/*
Copyright (c) 2007-2012, Trustees of The Leland Stanford Junior University
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 sou... |
fe7818cc701427acf8d121bb2a57e889ea71b7d0 | 453dd00488b8ffef9656fe51e9132e86ea902abf | smeenai/llvm-project | /llvm/lib/Transforms/Instrumentation/MemProfiler.cpp | C++ | cpp | 36,308 | permissive | //===- MemProfiler.cpp - memory allocation and access profiler ------------===//
//
// 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
//
//===---------------------------... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.