text
stringlengths
8
6.88M
/********************************************************************* * * Software License Agreement (BSD License) * * Copyright (c) 2014, Zhi Yan. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditi...
// // Created by griha on 10.12.17. // #include <cassert> #include <griha/tools/guard.hpp> #include <misc/logger.hpp> #include <misc/io_manip.hpp> #include "crypto_context_impl.hpp" #include "crypto/hsm_lib/crypto_context.hpp" #include "misc/common.hpp" namespace griha { namespace hsm { using griha...
#ifndef PACKETS_ROOMS_RESP #define PACKETS_ROOMS_RESP #include <cstdint> #include "Packets/PacketBaseMessage.h" #pragma pack(push, 1) #include "Constructors/sg_constructor.h" struct BM_SC_GET_ROOMLIST_RESP : public TS_MESSAGE_WNA { uint16_t roomcount; uint16_t uk1; uint16_t uk2; sg_constructor::rooms_packet rooms...
#ifndef GAME_H #define GAME_H #include <vector> #include <iostream> #include "Card.h" #include "User.h" #include "Dealer.h" #define TRUE 1 #define FALSE 0 class Game{ private: bool end=FALSE; public: static unsigned int round; // constructor Game(vector<User>&,int); // done void setAllBets(vector <User>& ...
// // NoGold.cpp // GetFish // // Created by zhusu on 15/8/17. // // #include "NoGold.h" #include "Common.h" #include "Tools.h" #include "Data.h" #include "MapScene.h" #include "GameSaveData.h" #include "GameScene.h" #if CC_TARGET_PLATFORM == CC_PLATFORM_IOS #include "IOSiAP_Bridge.h" #endif NoGold* NoGold::create...
// Created by: DAUTRY Philippe // Copyright (c) 1997-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 Lesser General Public Li...
/* * Copyright (c) 2014-2017 Detlef Vollmann, vollmann engineering gmbh * * 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 CANVAS_HH_SEEN_ #define CANVAS_HH_SEEN_ #include "shape.hh" #include "extgra...
#include <iostream> #include <filesystem> #include <uvw.hpp> #include "client.hpp" #include "serialization.hpp" namespace rpc { generic_client::generic_client(generic_protocol server_protocol, generic_impl client_impl, std::string address_): server_text_address(std::move(address_)), server_protocol(std::move(serve...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 1995-2002 Opera Software ASA. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** ** Alexander Remen (alexr) */ #include "core/pch.h" #include "URL...
#include "menus.h" using namespace std; int main() { unsigned short command; double x, y, z; double scalar; bool yn = 1; menu(); //Input choice std::cin >> command; while (command < 1 || command > 2 || std::cin.fail()) { cin.clear(); cin.ignore(); std::cout << "Please enter a va...
// // proj11_main.cpp // HelloWorld // // Created by Kristjan von Bulow. // Copyright © 2018 Kristjan von Bulow. All rights reserved. // #include<sstream> #include<iostream> using std::ostringstream; using std::endl; using std::cout; using std::cin; #include<string> using std::string; #include "proj11_trimap.hpp" ...
// Created on: 1998-01-13 // Created by: Christian CAILLET // 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 ...
// Created on: 1993-08-10 // Created by: Remi LEQUETTE // Copyright (c) 1993-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 <iostream> #include <vector> #include <queue> using namespace std; int testCase; class Node{ public: int inDegree; int buildTime; vector<int> next; vector<int> before; Node(){ buildTime = 0; inDegree = 0; } }; int main(){ ios_base::sync_with_stdio(false); cin ...
#pragma once #include "Interface.h" #include <string> using namespace std; #define TRANSLOG(...) CLog::Instance()->TranceLog(__VA_ARGS__); class CLog :public IOCPHanlder { private: CLog(); virtual ~CLog(); public: static CLog * pInstance; static CLog* Instance(); public: //interface virtual const HANDLE GetHanl...
/* * @Description: 订阅imu数据 * @Author: Ren Qian * @Date: 2019-08-19 19:22:17 */ #ifndef LIDAR_LOCALIZATION_SUBSCRIBER_IMU_SUBSCRIBER_HPP_ #define LIDAR_LOCALIZATION_SUBSCRIBER_IMU_SUBSCRIBER_HPP_ #include <deque> #include <mutex> #include <thread> #include <ros/ros.h> #include "sensor_msgs/Imu.h" #include "lidar_...
#include "TableTimer.h" #include "IProcess.h" #include "Table.h" #include "Logger.h" #include "Configure.h" #include "HallManager.h" #include "AllocSvrConnect.h" //====================CTimer_Handler==================================// int CTimer_Handler::ProcessOnTimerOut() { if(handler) return handler->ProcessOnT...
#ifndef _BUTTON_CONTROLLER_H #define _BUTTON_CONTROLLER_H #include "button.h" // #include "game_show.h" #include "socket_server.h" #include "pin_io.h" #include <sstream> class ButtonController { public: ButtonController(); ~ButtonController(); void update(unsigned int delta); void startup(PinIO* _pinio, S...
#include "Player.h" #include "record/Snapshot.h" CPlayer::CPlayer() : m_nStatus(PS_Stopped), m_nSeekpos(-1), m_isFirst(1), m_bIsMute(0), m_position(0), m_duration(0), m_audioctx(0), m_videoctx(0), m_pVideoDecodeThread(0), m_pAudioDecodeThread(0), m_pBufferManager(0) { memset(this, 0, sizeof(JNIStreamerContext)); m...
#ifndef TREEFACE_VECTOR_GRAPHICS_MATERIAL_H #define TREEFACE_VECTOR_GRAPHICS_MATERIAL_H #include "treeface/scene/SceneGraphMaterial.h" namespace treeface { class VectorGraphicsMaterial: public SceneGraphMaterial { public: static const treecore::Identifier UNIFORM_LINE_WIDTH; static const treecore::Identifier...
// Created on: 1990-12-19 // Created by: Christophe MARION // Copyright (c) 1990-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 ...
// // C++ Implementation: DialogPeer // // Description: // // // Author: cwll <cwll2009@126.com> ,(C) 2012.02 // Jally <jallyx@163.com>, (C) 2008 // // Copyright: See COPYING file that comes with this distribution // // #include "DialogPeer.h" #include "ProgramData.h" #include "CoreThread.h" #include "MainWindow...
#ifndef PACKETS_SOCIAL #define PACKETS_SOCIAL #include <cstdint> #include "Packets/PacketBaseMessage.h" #pragma pack(push, 1) #include "Packets/PacketBaseMessage.h" struct MM_SC_MSN : public TS_MESSAGE { //has some data static const uint16_t packetID = 5001; }; struct MM_SC_MSN_FIND_USER : public TS_MESSAGE { char...
#include <cmath> #include <cstdio> #include <vector> #include <iostream> #include <algorithm> using namespace std; // Author: Tatparya Shankar long long int getNumHandshakes( int numPeople ) { long long int sum; sum = numPeople * numPeople - numPeople * ( numPeople - 1 ) / 2; return sum; } int main() { int ...
// // Created by Zakhar on 03.04.2017. // #pragma once #include <string> #include <iostream> void printUsage() { std::cout << std::endl << "Usage: ./incCD -obligatory arg [-optional arg]" << std::endl << std::endl << "-test {arg}, -t {arg}" << std::endl << " | arg:" << std::endl ...
#include<iostream> #include<cmath> using namespace std; int main() { int i,a[3000],x,n,flag; while(cin>>n) { flag=0; for(i=0;i<n;i++) { cin>>a[i]; } x=(n*(n-1))/2; for(i=1;i<n;i++) { x-=abs(a[i]-a[i-1]); if(abs(a[i]-a[i-1])==0) {flag=1; b...
#include "ofApp.h" //-------------------------------------------------------------- void ofApp::setup(){ begin = ofPoint(100,300); end = ofPoint(900,500); num = 10; for (int i=0;i< num; i++){ Car temp; cars.push_back(temp); cars[i].init(); } } //---------...
// Copyright (c) 2012 Maciej Brodowicz // // 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) #pragma once #include <pika/config/defines.hpp> #if defined(DOXYGEN) /// Returns t...
#ifndef ITENS_H #define ITENS_H class Item { public: SDL_Surface* imagem; SDL_Rect quadro, posicao; Mix_Chunk* efeito; int hp; int mp; int xp; int lvl; int atk; int def; char Nome[10]; }; #endif
// /* By:Luckyblock 有下列 状态之间可以进行转移: */ #include<cstdio> #include<ctype.h> #define ll long long const int MARX = 110; //============================================================= int n,m,k, sum[MARX][3]; //============================================================= inline int read() { int s=1, ...
#include <bits/stdc++.h> using namespace std; typedef long long ll; const ll mod = 1e9 + 7; ll power(ll a, ll n) { if (n == 1) return a; ll b = power(a, n >> 1); ll res = (b * b) % mod; if (n & 1) res = (res * a) % mod; return res; } ll divmod(ll a, ll b) { // a div b = a * b^(p-2) b = power(b, mod - 2); re...
#include <stdio.h> #include <stdlib.h> #include <string.h> struct zaznam { char kategoria[52]; char znacka[52]; char predajca[102]; int cena; int vyrobene; char stav[202]; struct zaznam *next; }; void nacitaj(struct zaznam **zaciatok, FILE *f, int *pocet_zaznamov) { struct zaznam *a...
// Copyright 2017 Google Inc. All rights reserved. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to // deal in the Software without restriction, including without limitation the // rights to use, copy, modify, ...
#include "stdafx.h" #include "GameObject.h" #include "GameObjectManager.h"
#include <cstdio> #include <iostream> #include <cstdlib> #include <time.h> #include <cstring> #include "BivariatePolynomial.h" using namespace std; void BivariatePolynomial::InitDegs() //find polynomial y, x degrees { this->degy = 0; bool foundx=false,foundy=false; this->degx = 0; for (int i = ma...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- * * Copyright (C) 1995-2011 Opera Software AS. All rights reserved. * * This file is part of the Opera web browser. It may not be distributed * under any circumstances. * * perarne@opera.com * */ #include "core/pch.h" #include "mod...
// ---------------- // PngViewerDlg.cpp // ---------------- /** * @file * @brief Re: CAboutDlg, CPngViewerDlg * @author Achim Klein * @version 0.6 */ // -------- // Includes // -------- #include "stdafx.h" #include "PngViewer.h" #include "PngViewerDlg.h" #include "PngImage.h" #ifdef _DEBUG #define new DEBUG_NEW #un...
#include <cstdio> #include <cstring> #include <cstdlib> #include <algorithm> using namespace std; const int maxLengthOfN = 1300, maxNode = 1600; const int Mod = int(1e9) + 7; int m, len, cntNode = 0, que[maxNode * 10], ac[maxNode], fail[maxNode], trans[maxNode][10], dp[2][maxLengthOfN][maxNode]; char strN[maxLengthOf...
#pragma once #include "Error.h" namespace Log { }
#include <cstdio> #include <iostream> #include <vector> #include <string> #include <stack> #include <unordered_map> #include <unordered_set> #include <queue> #include <algorithm> #define INT_MAX 0x7fffffff #define INT_MIN 0x80000000 using namespace std; int helper(int begin, int end, int val){ if(begin > end) ret...
// // CircularConv.cpp // fast_convolution // // Created by Ying Zhan on 1/22/16. // Copyright (c) 2016 Ying Zhan. All rights reserved. // #include "CircularConv.h" CircularConvolution::CircularConvolution(int buffer_size): buffer_size(buffer_size),FFT(buffer_size, false), iFFT(buffer_size, true) { block_size...
#include <strings.h> #include "utils.h" #include "opengl_function.h" #define LIBRARY(name) const char* STRING_ ## name ## _LIBRARY = #name; #include "libraries.h" #undef LIBRARY string trim(string str) { str.erase(str.begin(), find_if(str.begin(), str.end(), not1(ptr_fun<int, int>(isspace)))); str.erase(find_if(str...
#ifndef _StartGameProc_H_ #define _StartGameProc_H_ #include "BaseProcess.h" class Table; class Player; class StartGameProc :public BaseProcess { public: StartGameProc(); virtual ~StartGameProc(); int doRequest(CDLSocketHandler* clientHandler, InputPacket* inputPacket, Context* pt); int doResponse(CDLSocketHand...
#include "graph.h" /////////////////////////////////////graph functions //this creates the graph with width (w) and height (h) struct Graph* createGraph() { char *uHeight = (char*) malloc(sizeof(char*)); char *uWidth = (char*) malloc(sizeof(char*)); struct Graph *graphStruct = (struct Graph*) malloc(sizeof(struc...
/* * MessageManager.h * * Created on: Jun 11, 2017 * Author: root */ #ifndef NETWORK_MESSAGEMANAGER_H_ #define NETWORK_MESSAGEMANAGER_H_ #include <deque> #include "../Smart_Ptr.h" #include "../Thread/Task.h" #include "../define.h" #include "NetWorkConfig.h" #include "../Common.h" #include "Service_Handler....
#ifndef system_h #define system_h #include <windows.h> #include <vector> #include <string> #include <functional> #include <algorithm> #ifdef WIN32 #include <shellapi.h> #include <tlhelp32.h> #endif // WIN32 namespace exception { struct DisplaySize { int width; int height; DisplaySize(int w, int ...
#ifndef _Reload_H_ #define _Reload_H_ #include "BaseProcess.h" class Reload : public BaseProcess { public: Reload() { this->name = "Reload"; }; virtual ~Reload() {}; virtual int doRequest(CDLSocketHandler *clientHandler, InputPacket *inputPacket, Context *pt); }; #endif
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 2012 Opera Software ASA. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. */ #ifndef UTIL_STRINGHASH_H #define UTIL_STRINGHASH_H #include "module...
#include <iostream> #include <clocale> using namespace std; int* Perechislenie(int mM); int* Talk_A(int mM); int* Talk_B(int mM); void neto(); void mn(int *A, int mA, int *B, int mB); int* edin(int *A, int *B, int mA, int mB); int* peresechenie(int *A, int *B, int mA, int mB); int* Pa3HocTb(int *U, int *W, int mU, in...
#ifndef DICON_H #define DICON_H #include <QQuickPaintedItem> #include <QPainter> class DIcon : public QQuickPaintedItem { Q_OBJECT Q_DISABLE_COPY(DIcon) Q_PROPERTY(QString theme READ theme WRITE setTheme NOTIFY themeChanged) Q_PROPERTY(QString icon READ icon WRITE setIcon NOTIFY iconChanged) public:...
/***************************************************************** * Copyright (C) 2017-2018 Robert Valler - All rights reserved. * * This file is part of the project: DevPlatformAppCMake. * * This project can not be copied and/or distributed * without the express permission of the copyright holder ******...
#pragma once #include "../../Physics/Settings/PhysicsSettings.h" #include "../../Maths/Functions/MathsFunctions.h" #include "../../Aero/Aero.h" #include "../../UI/Dependencies/IncludeImGui.h" namespace ae { namespace priv { namespace ui { inline void PhysicsSettingsToEditor( Physi...
#include "StdAfx.h" #include "wmvfile.h" #include <comdef.h> // Compiler COM support #include <atlbase.h> #include <iostream> using namespace std; #ifndef __countof #define __countof(x) ((sizeof(x)/sizeof(x[0]))) #endif namespace com { namespace drollic { namespace graphics { namesp...
#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...
Scalar const c0 = pow(omega[0], 2); Scalar const c1 = pow(omega[1], 2); Scalar const c2 = pow(omega[2], 2); Scalar const c3 = c0 + c1 + c2; Scalar const c4 = sqrt(c3); Scalar const c5 = 1.0/c4; Scalar const c6 = 0.5*c4; Scalar const c7 = sin(c6); Scalar const c8 = c5*c7; Scalar const c9 = pow(c3, -3.0L/2.0L); ...
#pragma once #include <vector> #include <QObject> #include "FileWorkspaceViewModel.h" #include "SpeechTranscriptionViewModel.h" #include "SharedServiceProvider.h" #include "VisualNotificationService.h" #include "JuliusRecognizerProvider.h" #include "SpeechDataValidation.h" namespace PticaGovorun { class AnnotationToo...
#pragma once #include <glad/glad.h> #include <string> #include <glm/glm.hpp> class ShaderBase { public: virtual ~ShaderBase(); void Start(); void End(); void Set(const char* varName, bool value); void Set(const char* varName, int value); void Set(const char* varName, float value); void Set(const char* varName...
// Copyright (c) 2007-2012 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) #pragma once #include <pika/config.hpp> #include <pika/assert.hpp> #include <pik...
/* Exp no : 10 FTP Using TCP S1330-R-Jayadeep 03/10/2016 */ #include<iostream> #include<sys/socket.h> #include<netinet/in.h> #include<cstring> #include<unistd.h> #include<fstream> using namespace std; #define port 9012 int main(int argc,char* argv[]){ int tcpSocket,nBytes; struct sockaddr_in addr,cliAddr; ...
#include "quadrant.h" #include "gamesettings.h" #include <QPainter> Quadrant::Quadrant() { int quadrantSize = GameSettings::instance()->getQuadrantSize(); image = QImage(":/images/star-background.png"); image = image.scaled(quadrantSize, quadrantSize, Qt::IgnoreAspectRatio); } QRectF Quadrant::boundingRe...
#include <iostream> #include <string> #include <cstdio> #include <memory.h> #include <string.h> #include <cmath> #include <cstdlib> #include <ctime> #include <vector> #include <map> #include <set> #include <queue> #include <deque> #include <algorithm> #include <functional> #include <climits> typedef long long LL; type...
// // Created by 钟奇龙 on 2019-05-01. // #include <iostream> using namespace std; class Node{ public: int data; Node *left; Node *right; Node(int x):data(x),left(NULL),right(NULL){} }; void morrisIn(Node *root){ if(!root) return; Node *node1 = root; Node *node2 = NULL; while(node1){ ...
#pragma once #include "AL\al.h" #include "AL\alc.h" #include "AL\alut.h" class Audio { private: //Variabili ALsizei size, freq; ALenum format; ALvoid *data; ALboolean loop; ALbyte *path[7]; public: Audio(void); ~Audio(void); //Procedure void initAL(); void playAL(int musicValue); void playAsStream(in...
#include <iostream> using namespace std; int main() { int n,m,x,y; cout<<"ÇëÊäÈën,m"<<endl; cin>>n>>m; x=(4*n-m)/2 , y=(m-2*n)/2; if((4*n-m)%2==1 || (m-2*n)/2==1 || 4*n<m || m<2*n) cout<<"ÎÞ½â"; else cout<<x<<y; return 0; }
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 1995-2002 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 SVG_DOM #include "modules/dom/sr...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 1995-2005 Opera Software ASA. 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 SVG_SUPPORT #include "modules/s...
#define T1 160 #define T2 120 #define debug false #define MAIN_LED_PIN 5 #define BLUE_LED_PIN 4 volatile boolean mainLed = false; volatile boolean blueLed = false; byte addressArray[10] = {3,4,5,6,7,8,11,12,13,14}; byte dataArray[10] = {4,154,43,166,244,34,82,136,42,128}; int count = 0; //counter for SN/GTIN ...
#ifndef _INTERPOLATION_ #define _INTERPOLATION_ #include <iostream> #include <fstream> #include "eigen/Eigen/Dense" #include "BivariatePolynomial.h" #include "inttypes.h" using namespace Eigen; class Interpolation { int d; int k; int deg; MatrixXd A; MatrixXd M; MatrixXd ker; double** P; int rank; public: in...
namespace exception { class Lines : public Inherit3(HavePosition, Dummy, RefCounter) { private: const float m_speed; const int m_cycle; std::deque<vector2> m_line; vector2 m_pos; vector2 m_direction; size_t m_frame; static float getRand() { static ist::Random s_rand(::tim...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 2002-2012 Opera Software ASA. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** ** Peter Krefting */ #if !defined OPBINARYLANGUAGEMANAGER_H && d...
#ifndef G_MATH_HPP #define G_MATH_HPP #include <xmmintrin.h> #include <iostream> #include <math.h> #include <string> #define SHUFFLE_PARAM(x, y, z, w) \ ((x) | ((y) << 2) | ((z) << 4) | ((w) << 6)) #define _mm_replicate_x_ps(v) \ _mm_shuffle_ps((v), (v), _MM_SHUFFLE(0, 0, 0, 0)) #define _mm_replicate_y_ps(v) \ _m...
#pragma once #include <QWidget> #include <QHBoxLayout> #include <QLineEdit> #include <QPushButton> #include <QFileDialog> #include <QDir> namespace envire { namespace viz { class PclWidget : public QWidget { Q_OBJECT public: PclWidget(QWidget* parent = nullptr) : QWidget(parent), horizontalLayout(new QHBox...
// This file is part of OpenCV project. // It is subject to the license terms in the LICENSE file found in the top-level directory // of this distribution and at http://opencv.org/license.html. #include "opencv2/core/hal/intrin.hpp" #define DEF_ACC_INT_FUNCS(suffix, type, acctype) \ void acc_##suffix(const type* src,...
#include <vector> #include "arch_graph.h" #include "bsgs.h" #include "nauty.h" #include "perm_set.h" namespace { int nauty_generator_degree; cgtl::PermSet nauty_generators; void nauty_save_generator(int, int *perm, int *, int, int, int) { std::vector<unsigned> tmp(nauty_generator_degree); for (int i = 0; i < na...
/* EXECUTE THE CIRCULAR MANEUVER */ //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// //HEADER FILES #include "maneuvers/flip_maneuver.h" #include <iostream> /////////////////////////////////////////...
#include <iostream> #include <vector> using namespace std; template <typename T> T temp(T x, T y) { if(x>y) return x; else return y; } template <typename T> T templ(T x, T y) { if(x>y) return y; return x; } main() { int a=9, c; int b=8; c= temp(...
/* * @Description: 关键帧,在各个模块之间传递数据 * @Author: Ren Qian * @Date: 2020-02-28 19:13:26 */ #ifndef LIDAR_LOCALIZATION_SENSOR_DATA_KEY_FRAME_HPP_ #define LIDAR_LOCALIZATION_SENSOR_DATA_KEY_FRAME_HPP_ #include <Eigen/Dense> namespace lidar_localization { class KeyFrame { public: double time = 0.0; unsigned in...
// Created on: 1995-10-26 // Created by: Yves FRICAUD // Copyright (c) 1995-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 L...
// Copyright 1998-2015 Epic Games, Inc. All Rights Reserved. #include "Monte.h" #include "MonteGameMode.h" #include "MontePawn.h" AMonteGameMode::AMonteGameMode(const FObjectInitializer& ObjectInitializer) : Super(ObjectInitializer) { // set default pawn class to our character class DefaultPawnClass = AMontePawn::S...
#include "receiverprotocol.h" #include <stdio.h> //ReceiverProtocol::ReceiverProtocol() //{ //} //ReceiverProtocol::~ReceiverProtocol() //{ //} /* * @result: data of 16channels RX:0F E0 03 1F 58 C0 07 16 B0 80 05 2C 60 01 0B F8 C0 07 00 00 00 00 00 03 00 CH: 992 992 352 992 352 352 352 352 352 352 992 992 000 0...
class FoodBioMeat { weight = 0.2; }; class FoodCanSardines { weight = 0.2; }; class FoodCanBakedBeans { weight = 0.2; }; class FoodCanFrankBeans { weight = 0.2; }; class FoodCanPasta { weight = 0.2; }; class FoodCanUnlabeled { weight = 0.2; }; class FoodMRE { weight = 0.4; }; class FoodPistachio { weight = 0.00...
/* * This source file is part of MyGUI. For the latest info, see http://mygui.info/ * Distributed under the MIT License * (See accompanying file COPYING.MIT or copy at http://opensource.org/licenses/MIT) */ #ifndef MYGUI_SUB_WIDGET_MANAGER_H_ #define MYGUI_SUB_WIDGET_MANAGER_H_ #include <_GUI/Prerequest.h> #inclu...
/* * File: Tower.h * Author: mohammedheader * * Created on November 23, 2014, 6:01 PM */ #ifndef TOWER_H #define TOWER_H #include "cocos2d.h" class HelloWorld; class Tower : public cocos2d::Node { public: static Tower* create(HelloWorld* game, cocos2d::Vec2 location); virtual void update(float dt); ...
#ifndef __IRR_REFCTD_DYNAMIC_ARRAY_H_INCLUDED__ #define __IRR_REFCTD_DYNAMIC_ARRAY_H_INCLUDED__ #include "irr/core/dynamic_array.h" #include "irr/core/IReferenceCounted.h" namespace irr { namespace core { template<typename T, class allocator = core::allocator<T>> class refctd_dynamic_array : public dynamic_array<T, ...
/* Copyright (c) 2007-2022 Xavier Leclercq Released under the MIT License See https://github.com/ishiko-cpp/test-framework/blob/main/LICENSE.txt */ #include "DirectoryComparisonTestCheckTests.hpp" #include "FileComparisonTestCheckTests.hpp" #include "JUnitXMLWriterTests.hpp" #include "TestContextTests.hpp"...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- * * Copyright (C) 2006-2011 Opera Software AS. All rights reserved. * * This file is part of the Opera web browser. It may not be distributed * under any circumstances. */ #ifndef OPCERTIFICATEMANAGER_H #define OPCERTIFICATEMANAGER_H ...
#include <iostream> #include <cmath> #include <stdio.h> #include <string> #include <stack> int main() { std::string str; std::stack < int >contain; int res; int count; char iMem; int count1 = 2; std::cin >> str; contain.push(0); for(int i = 0; i < str.length(); ++i) { iMem = str[i]; if('[...
/**************************************************************************** ** Copyright (c) 2006 - 2011, the LibQxt project. ** See the Qxt AUTHORS file for a list of authors and copyright holders. ** All rights reserved. ** ** Redistribution and use in source and binary forms, with or without ** modificatio...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- * * Copyright (C) 1995-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 M2_MAPI_SUPPORT #include "platform...
#pragma once #ifndef LINKEDHASH_HPP_INCLUDE #define LINKEDHASH_HPP_INCLUDE namespace lh { #include "common.hpp" typedef char* Data; typedef struct _Node { Data data; struct _Node *prev; struct _Node *next; }Node; typedef struct _Hash // Basically a Linked List { unsigned int collision; Node *head; ...
#ifndef EXAMPLE_FUNCTION_HPP #define EXAMPLE_FUNCTION_HPP int ownSquare(int x); #endif //EXAMPLE_FUNCTION_HPP
#include<bits/stdc++.h> using namespace std; #define MAX 110005 typedef pair<long long int,long long int>pa; #define pb push_back long long int INF=3*1e18; vector<pa>adj[MAX]; // Graph vector<pa>adjr[MAX]; // Reversed Graph long long int v_for[MAX]; //virtual function for forward/main Graph long long int v_...
#include <iostream> #include <cmath> using namespace std; int modExp(int x, int y, int N) { //output : (x ^ y ) mod N if (y == 0) return 1; int z = modExp(x, floor(y / 2), N); if (y % 2 == 0) return (z * z) % N; else return (x * z * z) % N; } int main() { int a = 5; int b = 4; int N = 3; ...
#ifndef MESSAGE_BOX_H #define MESSAGE_BOX_H #include <QMessageBox> #include <utility/raii.hpp> #include <QPoint> #include <QMouseEvent> class message_box : public QMessageBox { public: template<typename ... ARGS> message_box(ARGS && ... args) : QMessageBox (std::forward<ARGS> (args)...) {} void mousePre...
#include <iostream> #include "x.cpp" using namespace std; /* struct RBNode{ RBNode *left,*right,*up; int key; char colour; }; */ RBNode *NULLT; void leftRotate(RBNode *&T,RBNode *x) { RBNode *y=x->right; x->right=y->left; y->left->up=x; y->up=x->up; if(x->up==NULLT) ...
#include "Vector3Double.hpp" Elysium::Core::Math::Numerics::Vector3Double::Vector3Double() { } Elysium::Core::Math::Numerics::Vector3Double::Vector3Double(double Value) { } Elysium::Core::Math::Numerics::Vector3Double::Vector3Double(double ValueX, double ValueY, double ValueZ) { } Elysium::Core::Math::Numer...
#include "crvLin.h" #include <stdio.h> #include <math.h> struct MetricCoefficients { double G11, G12, G22, G; }; void computeMetricCoefficients(int i, int j, int nX, int nY, double ** x, double ** y, MetricCoefficients & metrCof) { double hKsi, hEta; double dXdKsi, dXdEta, dYdKsi, dYdEta; hKsi = 1.0 ...
/* ***** BEGIN LICENSE BLOCK ***** * FW4SPL - Copyright (C) IRCAD, 2012-2013. * Distributed under the terms of the GNU Lesser General Public License (LGPL) as * published by the Free Software Foundation. * ****** END LICENSE BLOCK ****** */ // fwComEd #include <fwComEd/fieldHelper/MedicalImageHelpers.hpp> #include...
/* -*- Mode: c++; tab-width: 4; 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. * * @author Arjan van Leeuwen (arjanl) */ #include "core/pch.h" #include "adjunct/desk...
#include <sstream> #include "ltr_client/utility/data_info.h" using std::stringstream; string ToString(const DataInfo& info) {; stringstream out(stringstream::out); out << "TDataInfo(name=" << info.name << ", approach=" << info.approach << ", format=" << info.format << ", file_name=" << info.fil...