text stringlengths 8 6.88M |
|---|
#include "widget.h"
#include "ui_widget.h"
#include <QFileDialog>
#include <QMessageBox>
#include <QTextStream>
#include <QFile>
#include <QDebug>
#include <QDesktopServices>
Widget::Widget(QWidget *parent)
: QWidget(parent)
, ui(new Ui::Widget)
{
ui->setupUi(this);
diaintro = new DialogIntroduction(this);
}
... |
#include "../include/Tool.h"
void CAE::Tool::SetAsset(std::shared_ptr <AnimationAsset> asset)
{
this->asset = asset;
assetUpdated();
}
|
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*-
**
** Copyright (C) 1995-2007 Opera Software AS. All rights reserved.
**
** This file is part of the Opera web browser.
** It may not be distributed under any circumstances.
*/
#ifndef IMAGEDECODERJPG_H
#define IMAGEDECODERJPG_H
#include "mod... |
// Created on: 1998-06-17
// Created by: data exchange team
// Copyright (c) 1998-1999 Matra Datavision
// Copyright (c) 1999-2014 OPEN CASCADE SAS
//
// This file is part of Open CASCADE Technology software library.
//
// This library is free software; you can redistribute it and/or modify it under
// the terms of the... |
// Copyright (c) 2019, tlblanc <tlblanc1490 at gmail dot com>
#include "status/status.hpp"
extern Status ConfigLineNoValue;
extern Status ConfigNotFoundKey;
extern Status ConfigParseValue;
|
//*********************************************************************************
// Universidad de Costa Rica
// Estructuras de Computadores Digitales II
// Tarea 2: Paralelizacion de Clustering Data Mining
// I Ciclo 2017
//
... |
/******************************************************************************
* $Id$
*
* Project: libLAS - http://liblas.org - A BSD library for LAS format data.
* Purpose: LAS Schema implementation for C++ libLAS
* Author: Howard Butler, hobu.inc@gmail.com
*
**********************************************... |
#include <bits/stdc++.h>
using namespace std;
#define USE_CPPIO() ios_base::sync_with_stdio(0); cin.tie(0)
#define MAXN 100
#define INF 0x3f3f3f3f
#define DEVIATION 0.00000005
typedef long long LL;
int Price(int cwh){
int price = 0;
price += min(max(0, cwh*2), 2*100);
cwh -= 100;
price += min(max(0, cwh*3), 3*(... |
#include <iostream>
#include "SceneObject.hh"
#include "PlaneObject.hh"
#include "SphereObject.hh"
#include "Vector3F.hh"
#include "RGBColor.hh"
#include "Light.hh"
#include "Camera.hh"
#include "Scene.hh"
#define IMGSIZE 512
int main(void){
// Configure the plane
Vector3F planeSurfaceNormal(0, 1, 0);
RGBColo... |
#include "Publisher.hpp"
#include <glog/logging.h>
void Publisher::publish(std::string topic, std::string msg)
{
Protocol pro("pub", topic, msg);
Message pub_msg = pro.serialization();
conn_->sendmsg(pub_msg);
topic_.push_back(topic);
LOG(INFO) << "A message of topic" << topic <<" is publishing!"... |
#pragma once
enum KeyboardEve
{
enEnter = 0x0D,
enBackSpace = 0x08,
enDelete = 0x2E,
};
namespace Keyboard
{
//入力されたキーに対応するcharを返す。
char GetKeyChar();
//指定したキーが入力されているか。
//arg:
// ke: キーの指定
bool isTrriger(KeyboardEve ke);
extern int Key;
} |
#include "mumble_channelcounter.h"
MumbleChannelThreasholdProvider::MumbleChannelThreasholdProvider(MumbleData * data, std::string name, int thres) {
_data = data;
_prov = data;
_name = name;
_thres = thres;
channelId = -1;
}
MumbleChannelThreasholdProvider::MumbleChannelThreasholdProvider(MumbleD... |
/*input
2
50 2053
3 6
2 3
*/
#include <iostream>
#include <vector>
#include <cstdio>
#include <cmath>
#include <cstring>
#include <string>
#include <cassert>
#include <algorithm>
#include <cstdlib>
#include <numeric>
#include <utility>
#include <tuple>
#include <climits>
#include <fstream>
#include <bitset>
#include <... |
/*
This file is part of SMonitor.
Copyright 2015~2016 by: rayx email rayx.cn@gmail.com
SMonitor is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later ver... |
#ifndef __SANDBOX_FINALIZE_WORKER_H__
#define __SANDBOX_FINALIZE_WORKER_H__
#include <nan.h>
#include "sandbox-wrap.h"
class SandboxFinalizeWorker : public Nan::AsyncWorker {
public:
SandboxFinalizeWorker(Nan::Callback *callback, SandboxWrap *sandbox);
virtual ~SandboxFinalizeWorker();
void Execute() override... |
#include "Auth/LoginManager.h"
using namespace m2::server;
HttpResponse::Code LoginManager::doAction(const std::string &data, std::string &response)
{
StringsPair info;
try {
info = deserialize(data);
response = createResponse(info.serverString, info.clientString);
}
catch (const pt::pt... |
#pragma once
#include "Record.h"
#include <memory>
#include <vector>
namespace OpenFlight
{
class AncillaryRecord;
class LongIdRecord;
//-------------------------------------------------------------------------
// Explication sur le refcount...
//
//
class OFR_API PrimaryRecord : pu... |
/************************************************************************
* @project : sloth
* @class : WaterShader
* @version : v1.0.0
* @description : 和水面着色器(water)的 uniform 变量相对应,用于修改着色器变量
* @author : Oscar Shen
* @creat : 2017年2月13日18:41:57
* @revise :
*************************************... |
#include "DUISystem.h"
DUISystem::DUISystem(void)
{
currentFocusedElement = NULL;
}
DUISystem::~DUISystem(void)
{
}
void DUISystem::Init()
{
}
void DUISystem::Update()
{
if(currentFocusedElement != NULL)
{
if(input.keyboard.arrowDown.tapped &&
currentFocusedElement->bottomLink != NULL)
{
SetFocus(cu... |
#include<iostream>
#include<cassert>
#include<errno.h>
#include<cstring>
#include<type_traits>
#include<signal.h>
#include<sys/socket.h>
#include<cstdio>
#include<unistd.h>
#include<cstdlib>
#include<sys/ipc.h>
#include<sys/types.h>
#include<string>
#include<arpa/inet.h>
using namespace std;
//#define INET_ADDRSTRLE... |
#include <iostream>
#include <algorithm>
using namespace std;
int main() {
int N, K;
cin >> N >> K;
int h[N + 1];
for (int i = 0; i < N; ++i) cin >> h[i];
h[N] = 200010;
sort(h, h + N + 1);
int itr = 0, ans = 0, add = 0;
for (int H = h[0]; itr < N; ++H) {
while (h[itr] <= H) +... |
#ifndef __HOT__COMMONS__ALGORITHMS__
#define __HOT__COMMONS__ALGORITHMS__
#include <immintrin.h>
#include <bitset>
#include <cassert>
#include <iostream>
namespace hot {
namespace commons {
inline uint32_t getBytesUsedInExtractionMask(
uint64_t successiveExtractionMask) {
uint32_t const unsetBytes = _mm_movem... |
#include <conio.h>
#include <stdlib.h>
#include <stdio.h>
#include <time.h>
#include <string.h>
#include <math.h>
#include <locale.h>
#include <ctype.h>
char s[5];
char m[5] = "m";
char f[5] = "f";
int retorno;
int main()
{
ret:
printf("\nInsira f ou m, para feminino e masculino\n");
scanf(... |
#ifndef _ORIENTAL_GENIUS_H
#define _ORIENTAL_GENIUS_H
#include "Enemy.h"
#include "Path.h"
class OrientalGenius : public Enemy {
private:
iPoint original_pos;
Path path;
Animation back;
Animation up1, up2, up3;
Animation stay;
Animation shoot;
public:
OrientalGenius(int x, int y, int type);
void Move();
};... |
#include<bits/stdc++.h>
using namespace std;
int main(){
int n;
cin>>n;
int maxis=0,flag=0;
int a[n];
for(int i=0;i<n;i++)
{
cin>>a[i];
}
for(int i=0;i<n;i++)
{
if(a[i]!=0)
{
flag++;
if(flag>maxis)
{
maxis=flag;
}
}
else{
flag=0;
}
}
cout<<"THE MAXIMUM LENGTH IS "<<maxi... |
// Copyright 2014 Sebastian Zwierzchowski <sebastian.zwierzchowski<at>gmail<dot>com>
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
/... |
/*
两堆石头,分别为n,m.两人轮流从一堆石头中拿,也可以拿走两堆中相同数量的石头.最后拿完的人赢.
*/
/*奇异局势(必败)返回0*/
int wzf(int n,int m)
{
if(n>m) swap(n,m);
int k=m-n;
int a=(k*(1.0+sqrt(5.0))/2.0);
return a==n?0:1;
}
int main () {
int a, b;
while(scanf("%d%d", &a, &b)) {
if (a == 0 && b == 0) break;
int k = b - a;
int n... |
#ifndef WATCHER_H
#define WATCHER_H
#include<QObject>
#include<QAction>
#include<QEvent>
#include "iocoingui.h"
class Watcher : public QObject
{
Q_OBJECT
public:
explicit Watcher(QObject * parent = Q_NULLPTR);
virtual bool eventFilter(QObject * watched, QEvent * event) Q_DECL_OVERRIDE;
};
#endif
|
#pragma once
#include "Core/ComponentPool.h"
#include "Core/ComponentRegister.h"
namespace Hourglass
{
class ISystem
{
protected:
template <typename T>
void ComponentPoolInit( StrID name, T* data, ComponentPool<T>* pool,
unsigned int size, unsigned int flags = CompRegFlags::kNone );
};
template<typen... |
// Created on: 2013-09-20
// Created by: Denis BOGOLEPOV
// Copyright (c) 2013-2014 OPEN CASCADE SAS
//
// This file is part of Open CASCADE Technology software library.
//
// This library is free software; you can redistribute it and/or modify it under
// the terms of the GNU Lesser General Public License version 2.1 ... |
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*-
*
* Copyright (C) 1995-2006 Opera Software AS. All rights reserved.
*
* This file is part of the Opera web browser.
* It may not be distributed under any circumstances.
*/
#include "core/pch.h"
#include "adjunct/quick/dialogs/AskPluginD... |
#include <iostream>
#include <iomanip>
#include <cstdlib>
#include <ctime>
int main(){
const int arraySize = 7; //such that: [0,...,6]
int frequency[ arraySize ] = {}; //set frequencies to zero
std::srand(std::time(NULL)); //seed to random time
//rolling ten thousand times
for ( int... |
#include "tcpserverwidget.h"
#include "ui_tcpserverwidget.h"
#include <QMessageBox>
#include <QSqlDatabase>
#include <QSqlError>
#include <QDebug>
#include <QSqlQuery>
TCPServerWidget::TCPServerWidget(QWidget *parent)
: QWidget(parent)
, ui(new Ui::TCPServerWidget)
{
ui->setupUi(this);
setWindowTit... |
/*
le bouton poussoir est connecté au pin 2 pour un mode INPUT_PULLUP
la Led est connectée au pins 4 avec une résistance de 220Ω
*/
//déclaration des variables
int pinBouton, pinLed;
boolean etatAllumage;
void setup()
{
//initialisation des variables
Serial.begin(9600);
pinBouton = 8;
pinLed = 9;
etatAllumag... |
// ___________________________________________________________________________
// ŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻŻ?
// FILENAME WinShell.cpp
//
// CREATED DG-191298
//
// DESCRIPION Win95/NT4.0 ++ shell interface functions
// I.e. stuff using the IShel... |
#include <algorithm>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
struct BankAccount {
int balance = 0;
int overdraft_limit = -500;
void deposit(int amount) {
balance += amount;
cout << "deposited " << amount << ", balance now " << balance << "\n";
}
void withdraw(i... |
#include<iostream>
#include<cstdio>
#include<map>
#include<set>
#include<vector>
#include<stack>
#include<queue>
#include<string>
#include<cstring>
#include<sstream>
#include<algorithm>
#include<cmath>
using namespace std;
int main()
{
int a[10];
for (int i = 0;i < 6; i++)
scanf("%d",&a... |
// you can use includes, for example:
// #include <algorithm>
// you can write to stdout for debugging purposes, e.g.
// cout << "this is a debug message" << endl;
#include <limits.h>
int solution(int N) {
// write your code in C++14 (g++ 6.2.0)
int i = 1;
int min_ans=INT_MAX ;
for (; i*i<N; i++){... |
#include "cryptutil.h"
#include <QCryptographicHash>
#include <QDateTime>
QByteArray CryptAdaptor::hashData(QByteArray text, QCryptographicHash::Algorithm alg,
bool lower)
{
QByteArray data = QCryptographicHash::hash(text, alg);
if(lower) {
return data.toHex();
}... |
#ifndef SCENE_FLOW_CONSTRUCTOR__SCENE_FLOW_CONSTRUCTOR_H_
#define SCENE_FLOW_CONSTRUCTOR__SCENE_FLOW_CONSTRUCTOR_H_
#include <cv_bridge/cv_bridge.h>
#include <disparity_image_proc/disparity_image_processor.h>
#include <dynamic_reconfigure/server.h>
#include <geometry_msgs/TransformStamped.h>
#include <image_geometry/p... |
#include "simframe.h"
SimFrame::SimFrame()
{
clearSimFrame();
}
SimFrame & SimFrame::operator=(const SimFrame &v_src)
{
for(int row = 0; row < yLen; ++row)
for(int col = 0; col < xLen; ++col)
m_frameData[row][col] = v_src.m_frameData[row][col];
return *this;
}
SimFrame & SimFrame::o... |
#include "MinerWife.h"
bool MinerWife::HandleMessage(const Telegram& msg)
{
return m_pStateMachine->HandleMessage(msg);
}
void MinerWife::Update()
{
m_pStateMachine->Update();
}
|
#include <pthread.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
pthread_cond_t work_01 = PTHREAD_COND_INITIALIZER;
pthread_cond_t work_02 = PTHREAD_COND_INITIALIZER;
pthread_cond_t work_03 = PTHREAD_COND_INITIALIZER;
pthread_mutex_t work_mtx = PTHREAD_MUTEX_INITIALIZER;
void* do_work_01(void* arg) {
... |
/*
* ****************************************************************************
* * *
* * Copyright 2008, xWorkshop Inc. *
* * All rights reserved. *
*... |
#include <iostream>
#include <string>
#include <algorithm>
using namespace std;
int main(){
string line;
int n, i, j;
int minInd, maxInd;
int caseNumber = 0;
char first;
bool same;
while((cin >> line) && (line.length() != 0)){
caseNumber++;
cout << "Case " << caseNumber ... |
#include "login_mgr_class.hpp"
#include "login.hpp"
#include "login/log.hpp"
#include "utils/service_thread.hpp"
#include "utils/exception.hpp"
#include "utils/assert.hpp"
#include "utils/game_def.hpp"
#include "proto/config_options.pb.h"
#include "config/options_ptts.hpp"
#include "utils/server_process_mgr.hpp"
#inclu... |
//---------------------------------------------------------
//
// Project: dada
// Module: core
// File: Log.h
// Author: Viacheslav Pryshchepa
//
// Description:
//
//---------------------------------------------------------
#ifndef DADA_CORE_LOG_H
#define DADA_CORE_LOG_H
#include "dada... |
#pragma once
#include "jsfunctioncall.h"
namespace jsscript
{
namespace jsfunction_detail
{
#pragma region jsfunction_base
class jsfunction_base
{
public:
jsval fun;
JSObject* par;
JSContext* cx;
};
template <int arity, typename T>
class jsfunction_baseN
{
jsfunction... |
#include<stdio.h>
int main()
{
int a,b,c;
scanf("%d%d%d",&a,&b,&c);
if(a>=b) printf("Chocolate\n");
else if(a<b && a<c) printf("Chocolate\n");
else if(a<b || a<c) printf("Ice-cream\n");
return 0;
} |
#include "FlyCam.h"
FlyCam::FlyCam()
{
FlyCamStart();
Camera::Start();
}
FlyCam::~FlyCam()
{
}
FlyCam::FlyCam(float windowHeight, float windowLength)
{
FlyCamStart();
Camera::Start(windowHeight, windowLength);
}
void FlyCam::FlyCamStart()
{
speed = 5;
lookSpeed = 0.1f;
aie::Input* input = aie::Input::get... |
#ifdef DEBUG
#define _GLIBCXX_DEBUG
#endif
#include <iostream>
#include <algorithm>
#include <cstdio>
#include <cstdlib>
#include <ctime>
#include <memory.h>
#include <cmath>
#include <string>
#include <cstring>
#include <queue>
#include <vector>
#include <set>
#include <deque>
#include <map>
#include <functional>
#inc... |
#ifndef GUI_EXCEPTIONS_H
#define GUI_EXCEPTIONS_H
#include <exception>
#include <stdio.h>
#include <stdlib.h>
namespace GUI {
class GUIException: public std::exception {
public:
virtual const char* what() const throw() { return "Basic GUI Exception"; }
};
class NoFunctionOnButtonExcepti... |
#include "Includes.h"
#include <iostream>
#include <fstream>
#include <vector>
#include <cmath>
using namespace std;
int solver(const vector<vector<int> > &sumsRows, const int &n);
void uva108Main() {
int n;
while(scanf("%d", &n) != EOF) {
vector<vector<int> > sumsRows(n, vector<int>(n, 0)... |
#include "simpleElementGenerator.h"
#include "../../smartLine.h"
using namespace qReal;
using namespace robots::generator;
void SimpleElementGenerator::generateMethodBody()
{
generateBodyWithoutNextElementCall();
IdList const outgoingConnectedElements = mNxtGen->mApi->outgoingConnectedElements(mElementId);
if (... |
#ifndef __CHATTY_SOCKET_H__
#define __CHATTY_SOCKET_H__
namespace chatty {
namespace net {
class Socket {
public:
explicit Socket(int fd);
int accept();
int fd() const { return fd_; };
private:
int fd_;
};
} // namespace net
} // namespace chatty
#endif // __CHATTY_SOCKET_H__ |
#include<iostream>
using namespace std;
struct BiNode
{
char data;
struct BiNode *lchild,*rchild;
};
class BiTree
{
public:
struct BiNode *root;
public:
BiTree()//构造函数,初始化根结点;
{root=NULL;}
void GreetTree()//创建二叉树
{root=Creat(root);}
~BiTree()//析构函数。销毁二叉树
{Release(root);}
void PreOrder(BiNode *bt)//前序遍历
{
/... |
/* 46450368 - 48579580 */
// Nicolás Saliba - Gonzalo Nicolari.
// Instituto de Computación - Facultad de Ingeniería, Laboratorio de Programación 2.
#include "../include/cadena.h"
#include "../include/info.h"
#include <stdio.h>
#include <string.h>
#include <assert.h>
struct nodo {
nodo *anterior;
in... |
#ifndef ITERATOR_H
#define ITERATOR_H
template <class Object>
class Iterator {
public:
virtual void first() = 0;
virtual void next() = 0;
virtual bool isDone() const = 0;
virtual Object currentItem() = 0;
};
template <class Object>
class NullIterator : public Iterator<Object> {
public:
void first() {}
voi... |
#include<iostream>
#include <ctime>
#include<stdio.h>
#include<conio.h>
using namespace std;
int main()
{
clock_t c_start = clock();
int i, j, n, min, temp, k;
cout<<"Enter the Number of Elements: ";
cin>>n;
int arr[n];
cout<<"Enter the elements: ";
for(i = 0;i < n;i++)
{
cin>>arr[i];
}
... |
#pragma once
#include <array>
struct Color;
struct ColorToggle;
struct ColorToggleRounding;
struct ColorToggleThickness;
struct ColorToggleThicknessRounding;
namespace ImGuiCustom
{
void colorPopup(const char* name, std::array<float, 4>& color, bool* rainbow = nullptr, float* rainbowSpeed = nullptr, bool* enable... |
/** Kabuki SDK
@file /.../Source/Kabuki_SDK/_Com/MIDI/Port.cpp
@author Cale McCollough
@copyright Copyright © 2016 Cale McCollough ©
@license Read accompanying /.../README.md or online at http://www.boost.org/LICENSE_1_0.txt
*/
#include "Port.h"
#include "Kabuki SDK.h"
#include "_Com/MID... |
#include <iostream>
#include <fstream>
#include <string>
#include <stdlib.h>
#define TAMANHO 11
#define NOME_ARQUIVO "dados_modelo.dat"
using namespace std;
struct no {
int id;
char termo[50];
char sig[50];
};
void menu();
void cadastrar_termo();
void exibirTermo();
void gera_arquivo_modelo... |
#include <iostream>
#include "std_lib_facilities.h"
void main() {
std::cout << "What is your first Name? \n";
string first_name;
std::cin >> first_name;
std::cout << "Hello," << first_name << "!\n";
} |
#include "cpp_native.hpp"
#include <iostream>
namespace CppApp {
void MyCpp::testMyCpp()
{
std::cout << "#message from CppApp" << std::endl;
}
}
|
/*
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
#pragma once
#include <quic/client/handshake/ClientHandshake.h>
#include <quic/client/handshake/ClientHandshakeFactory.h>
#inclu... |
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*-
**
** Copyright (C) 1995-2011 Opera Software ASA. All rights reserved.
**
** This file is part of the Opera web browser.
** It may not be distributed under any circumstances.
*/
// --------------------------------------------------------------... |
/*
Copyright 2021 University of Manchester
Licensed under the Apache License, Version 2.0(the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http: // www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, s... |
//Phoenix_RK
/*
Given the array queries of positive integers between 1 and m, you have to process all queries[i] (from i=0 to i=queries.length-1) according to the following rules:
In the beginning, you have the permutation P=[1,2,3,...,m].
For the current i, find the position of queries[i] in the permutation P (indexi... |
//
// numbers.hpp
// DataStructures
//
// Created by Tri Khuu on 2/14/18.
// Copyright © 2018 TK. All rights reserved.
//
#ifndef numbers_hpp
#define numbers_hpp
#include <cstdint>
#include <iostream>
#include <string>
using std::string;
using std::cout;
using std::endl;
namespace Number
{
static const uint... |
#include "EmonLib.h" //INCLUSÃO DE BIBLIOTECA
#define CURRENT_CAL 12.50 //VALOR DE CALIBRAÇÃO (DEVE SER AJUSTADO EM PARALELO COM UM MULTÍMETRO MEDINDO A CORRENTE DA CARGA)
#define tensao 110
const int pinoSensor = A2; //PINO ANALÓGICO EM QUE O SENSOR ESTÁ CONECTADO
float ruido = 0.08; //RUÍDO PRODUZIDO NA SAÍDA DO SE... |
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*-
**
** Copyright (C) 1995-2009 Opera Software ASA. All rights reserved.
**
** This file is part of the Opera web browser. It may not be distributed
** under any circumstances.
*/
/* NOTE!
** This is the old geolocation PI interface. This inter... |
#include <iostream>
#include<random>
#include<time.h>
#include <vector>
using namespace std;
class Group
{
public:
Group()
{
for (int i = 0; i < count; i++)
{
group.push_back(i + 1);
}
}
int size()
{
return group.size();
}
void selectCouple();
p... |
//////////////////////////////////////////////////////////////////////////////
//
// Copyright (c) Triad National Security, LLC. This file is part of the
// Tusas code (LA-CC-17-001) and is subject to the revised BSD license terms
// in the LICENSE file found in the top-level directory of this distribution.
//
////... |
#pragma once
#include <gflags/gflags.h>
#include <Eigen/Dense>
#include <algorithm>
#include <random>
#include <fstream>
namespace ethdata
{
typedef struct Vertex_
{
EIGEN_MAKE_ALIGNED_OPERATOR_NEW
Vertex_(long int index_, double timestamp_, Eigen::Matrix4d pose_)
: index(index_), timestamp(timestamp_), pos... |
#ifndef __OCR_H__
#define __OCR_H__
#include "log.h"
#include <vector>
#include "net.h"
#include "benchmark.h"
#include <algorithm>
#include <math.h>
#include "opencv2/opencv.hpp"
#include "opencv2/highgui/highgui.hpp"
#include "opencv2/imgproc/imgproc.hpp"
#include "RRLib.h"
#include "polygon.h"
#include <fstream>
#... |
#include "stdafx.h"
#include "TypeInQuestionView.h"
#include "TypeInQuestionState.h"
#include "TypeInQuestionViewController.h"
#include "TypeInQuestion.h"
using namespace qp;
using namespace std;
set<string> answers = { "First answer", "Second answer" };
struct TypeInQuestionViewControllerFixture
{
TypeInQuest... |
// Copyright (c) 2015 Hartmut Kaiser
//
// SPDX-License-Identifier: BSL-1.0
// 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 <pika/init.hpp>
#include <pika/modules/iterator_support.hpp>
#include <pika/m... |
#ifdef DEBUG
#define _GLIBCXX_DEBUG
#endif
#include <iostream>
#include <algorithm>
#include <cstdio>
#include <cstdlib>
#include <ctime>
#include <memory.h>
#include <cmath>
#include <string>
#include <cstring>
#include <queue>
#include <vector>
#include <set>
#include <deque>
#include <map>
#include ... |
#ifndef SPLAYTREE_H_
#define SPLAYTREE_H_
#include <iostream>
template<typename T>
class splaytree {
struct node {
T key;
node* l = NULL;
node* r = NULL;
node() {}
node(T key) :key(key) {}
node(T key, node *l, node *r) :key(key), l(l), r(r) {}
};
node* root = NULL;
node* rroate(node*... |
/***************************************************************************
*
* Copyright (c) 2017 Baidu.com, Inc. All Rights Reserved
* B142877
*
**************************************************************************/
/**
* @file datafile_lib.h
* @author liuxufeng (liuxufeng@baidu.com)
* @date 2017/05/31 13:09:41... |
#include<bits/stdc++.h>
#include <iostream>
#include<fstream>
#include <string>
#include <limits>
#include <vector>
#include <cmath>
#include <cstdlib>
#include <ctime>
using namespace std;
#define _USE_MATH_DEFINES
#include <math.h>
#include "cgal.h"
#define MAX_REC_LEN 1024
/// edited ///
#define readSize 101
... |
#include<iostream>
#include<cstdio>
#include<map>
#include<set>
#include<vector>
#include<stack>
#include<queue>
#include<string>
#include<cstring>
#include<algorithm>
#include<cmath>
using namespace std;
int main()
{
int T;
scanf("%d",&T);
while (T--) {
double x,y,t,s;
scanf("%lf%lf%lf%lf",&x,... |
#include "MediaSegment.h"
namespace hls {
MediaSegment::MediaSegment()
{
}
float MediaSegment::duration() const
{
return mDuration;
}
void MediaSegment::setDuration(float duration)
{
mDuration = duration;
}
QString MediaSegment::uri() const
{
return mUri;
}
void MediaSegment::setUri(const QString &uri)
{
... |
#include <vector>
#include <string>
#include <iostream>
#include <fstream>
#include <sstream>
#include <list>
#include <algorithm>
#include <sstream>
#include <set>
#include <cmath>
#include <map>
#include <stack>
#include <queue>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <numeric>
#include <bits... |
//
// GStateBGLayer.h
// Core
//
// Created by Max Yoon on 11. 7. 30..
// Copyright 2011년 __MyCompanyName__. All rights reserved.
//
#ifndef Core_GStateBGLayer_h
#define Core_GStateBGLayer_h
class GStateBGLayer : public GLayer
{
public:
static GStateBGLayer* CreateBackground();
public:
bool I... |
#ifndef _RESOURCES_MANAGER_H_
#define _RESOURCES_MANAGER_H_
#include <SFML/Graphics.hpp>
#include <string>
class ResourcesManager
{
public:
ResourcesManager();
~ResourcesManager();
sf::Texture * getTexture(const std::string &path);
sf::Texture * addTexture(const std::string &path);
void removeTexture... |
#ifndef CELL_LIST_H
#define CELL_LIST_H
#include <cstdio>
#include <vector>
#include <forward_list>
//class Node {
//public:
// Node() { next = NULL; }
// double x;
// double y;
// int cell_idx;
// Node * next;
//
// static int Lx;
// static int Ly;
// static int N;
//};
template<class Node>
class Cell {
public:
Ce... |
#include<iostream>
#include<conio.h>
int main()
{
int a, b, c;
for(a=6;a>=1;a--)
{
for(b=1;b<a;b++)
{
std::cout << " ";
}
for (c=6;c>=a;c--)
{
std::cout << "*";
}
std::cout<<std::endl;
}
getch();
}
|
#include <iostream>
#include <node/node.h>
#include <errno.h>
#include <unistd.h>
#include <fcntl.h>
namespace test
{
using v8::Array;
using v8::FunctionCallbackInfo;
using v8::Isolate;
using v8::Local;
using v8::NewStringType;
using v8::Object;
using v8::String;
using v8::Value;
int doNotCloseStreamsOnExit(int desc)
... |
#ifndef ELF_SECTION_H
#define ELF_SECTION_H
#include "defs.h"
#include "elf_section_description.h"
template<class IW>
class ElfSection
{
public:
ElfSection() = default;
ElfSection(std::string name, std::string filename, u32 offset, u32 size);
void create(std::string name, std::string filename, u32 offset, u32 size)... |
#include<iostream>
using namespace std;
class Customer
{ private:
char Customer_Name[20], Title[20], E_mail[30];
long int Customer_ID;
long int Telephone_Number;
char Address[50], NIC_NO[25];
public:
void Add_New_Customer(long int id,char name[20],char title[20],char email[30],long int telephone,char... |
//Программа lab7.exe обеспечивает преобразование файла ASCII в
//Unicode с использованием асинхронного ввода - вывода с помощью про -
//цедуры завершения.Многие переменные сделаны глобальными, для того
//чтобы они были доступны для процедур завершения.Запуск программы
//производится из командной строки в виде : lab... |
// Created on: 1996-09-17
// Created by: Odile Olivier
// Copyright (c) 1996-1999 Matra Datavision
// Copyright (c) 1999-2014 OPEN CASCADE SAS
//
// This file is part of Open CASCADE Technology software library.
//
// This library is free software; you can redistribute it and/or modify it under
// the terms of the GNU ... |
#include "Brick.h"
/*
Constructor for the brick. Initialize the width, height, the position,
maximum number of hits and the color.
*/
Brick::Brick(std::string name, unsigned int width, unsigned int height, float x,
float y, int numHits, glm::vec3 color)
: CollidableSquare(name, width, height, x, y, color)... |
//
// Created by 송지원 on 2020/06/25.
//
//200625 boj10828 문제 바킹독 님 버젼
//난 입력으로 들오오는 명령어를 위에 배열로 선언하고 그걸 활용하여 입력을 구분했는데
//그것보다는 아래 코드 내에서 직접 사용해서 구현
//#include <bits/stdc++.h>
#include <iostream>
#include <stack>
using namespace std;
int main() {
ios::sync_with_stdio(0);
cin.tie(0);
int n;
cin >> n;
... |
#include<iostream>
#include<cstdio>
#include<map>
#include<set>
#include<vector>
#include<stack>
#include<queue>
#include<string>
#include<cstring>
#include<sstream>
#include<algorithm>
#include<cmath>
#define INF 0x3f3f3f3f
#define eps 1e-8
#define pi acos(-1.0)
using namespace std;
typedef long long L... |
#include <Ogre.h>
#include <OIS/OIS.h>
#include "MenuState.h"
#include "PlayState.h"
#include "OverState.h"
using namespace Ogre;
OverState OverState::mOverState;
void OverState::enter(void)
{
mContinue = true;
mGameOverOverlay = OverlayManager::getSingleton().getByName("Overlay/GameOver");
mGameOverOverlay->sh... |
#include "stdafx.h"
#include "JNIBridge.Core.h"
#include "JNIBridge.Core.Utils.h"
using namespace JNIBridge::Core::Utils;
/// <summary>
/// The g singleton
/// </summary>
JNIBridge::Core::Interop* g_Singleton;
typedef jint(*ptrLoadJvm) (JavaVM** pvm, void** penv, void* args);
#pragma region "Generic lambdas"
auto ... |
#include <iostream>
using namespace std;
// Generic Programming - Ignore
class Node {
public:
// Data
int data;
// Pointer to the next Node
Node * next;
// Construct that makes the ptr to NULL
Node() {
next = NULL;
}
};
class LinkedList {
// Head + Circles inside linked with each othe... |
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*-
*
* Copyright (C) 2007-2012 Opera Software AS. All rights reserved.
*
* This file is part of the Opera web browser.
* It may not be distributed under any circumstances.
*/
#include "core/pch.h"
#ifdef POSIX_OK_DNS
# ifndef THREAD_SUPPORT
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.