text
stringlengths
8
6.88M
#ifndef TP_PPROJECT_GUESTOPTIONS_H #define TP_PPROJECT_GUESTOPTIONS_H #include <iostream> #include <memory> #include "BaseUserOptions.h" class GuestOptions : public BaseUserOptions { public: ~GuestOptions() override = default; // Send message in select chat void sendMessage(const Message& message, int g...
#ifndef MARKS_HPP_INCLUDED #define MARKS_HPP_INCLUDED #include <regex> namespace bbplus { struct mark { mark(std::string n, std::string i, std::string r) { name = n; input_regex = std::regex(i, std::regex::icase); replace_pattern = r; } std::string name; std::regex input_regex...
/* * File: MRAC.cpp * Author: Corrado Pezzato, TU Delft, DCSC * * Created on April 14th, 2019 * * Class to perform active inference control of the 7DOF Franka Emika Panda robot. * Definition of the methods contained in MRAC.h * */ #include "MRAC.h" // Constructor which takes as argument the publishers an...
#define LOGURU_IMPLEMENTATION 1 #define LOG_WITH_STREAMS 1 #include "loguru.hpp"
// ********************************************************************** // // Copyright (c) 2003-2006 ZeroC, Inc. All rights reserved. // // This copy of Ice is licensed to you under the terms described in the // ICE_LICENSE file included in this distribution. // // ***************************************************...
#include <iostream> #include "Bureaucrat.hpp" #include "PresidentialPardonForm.hpp" #include "RobotomyRequestForm.hpp" #include "ShrubberyCreationForm.hpp" #include "Form.hpp" #include <cstdlib> #include <ctime> int main(void) { Bureaucrat b("PPPPP", Bureaucrat::maxGrade); Bureaucrat bo("LALALA", Bureaucrat...
// -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4; c-file-style:"stroustrup" -*- // // Copyright (C) 1995-2006 Opera Software ASA. All rights reserved. // // This file is part of the Opera web browser. It may not be distributed // under any circumstances. // // Adam Minchinton and Karianne Ekern ...
#ifndef TOOLS_SHELL_DBCLIENTPROXY #define TOOLS_SHELL_DBCLIENTPROXY #include <vector> #include <map> #include <string> #include <boost/utility.hpp> #include <boost/shared_ptr.hpp> #include "DB.h" /* * class DBClientProxy maintains: * 1. a connection to rocksdb service * 2. a map from db names to opened db handle...
#ifndef GAME_H #define GAME_H #include <allegro5\allegro.h> class Game { public: static int gameState; // 0 = menu, 1 == game; }; #endif
#include "SIdict.h" #include <string> #include <iostream> // Conner Zeigman and Daniel Kramer // I pledge on my honor that I have abided by the Stevens Honor System Dict::Dict(){ first = NULL; } struct Dict::DictNode{ string key; int value; DictNode* next; }; int Dict::hasKey(string key){ Di...
#ifndef ExternDot_HPP #define ExternDot_HPP #include <QObject> // Object source includes externally generated .moc file class ExternDot : public QObject { Q_OBJECT public: ExternDot(); ~ExternDot(); }; #endif
#pragma once #include "singletonBase.h" #include "image.h" enum ITEMKIND{ NONE, LEVLEUPITEM, ULTIMATEITEM }; struct tagItem { image* img; int _count; int _index; float x; float y; float angle; RECT rc; bool isActive; int width; int height; float speed; int time; }; class itemManager : public singleton...
#pragma once #include "../../Engine/graphics/animation/AnimationClip.h" #include "../Monster.h" class TestMons :public Monster { public: TestMons(); //bool Start() override; //void Update() override; private: AnimationClip m_animclip[3]; };
// // Created on 04/01/19. // #pragma once #include <map> #include <array> #include <armadillo> // Conversion from C# summary: // - int ==> uint64_t // - Dictionary<TKey, TVavlue> ==> std::map<TKey, TValue> // - List<T> ==> std::vector<T> // - List<T> where T : const K ==> std...
#include "ros/ros.h" #include "std_msgs/String.h" #include "std_msgs/Float32.h" //not sure how to check if the header file is present // or not #include <sstream> #include "beginner_tutorials/Num.h" #include "beginner_tutorials/driveCmd.h" #include "beginner_tutorials/Num.h" #include "custom_m...
#include <ros/ros.h> #include <ros/package.h> #include <memory> #include <iostream> #include <fstream> #include <string> #include <vector> #include <map> #include <exception> #include <io_lib/io_utils.h> #include <io_lib/file_io.h> #include <gmp_lib/GMP/GMPo.h> #include <gmp_test/utils.h> using namespace as64_; #def...
#include <iostream> #include <algorithm> #include <stdio.h> #include <stdlib.h> #include <time.h> #include <memory.h> #include <math.h> #include <string> #include <string.h> #include <queue> #include <vector> #include <set> #include <map> typedef long long LL; typedef unsigned long long ULL; #define PI 3.141592653589...
#pragma once #include <iterator> #include <vector> #include <algorithm> #include <functional> #include <assert.h> template <typename T> struct TreeNode { TreeNode(const T& data, TreeNode* left, TreeNode* right) : _data(data), _left(left), _right(right), _parent(nullptr) { } T _data; TreeNode* _left; Tree...
#include "firewarning.h" //发现火警时处理 void dealfire(string firecity,string filename) { string firemes=firecity+"有火警,请查看 火警文件为: "+filename; cout<<"\n "<<firemes<<endl; cout<<"正在发送短信... "; if(sendmes(firemes,"13663880026,13698835392") ) cout<<"短信已发出"<<endl; else cout<<"发送失败"<<endl; ...
// // CryptClient.cpp for cpp_spider in sources/client // // Made by Benoit Hamon // Login <benoit.hamon@epitech.eu> // // Started on Sun Oct 08 17:50:33 2017 Benoit Hamon // Last update Sun Oct 29 12:09:47 2017 Benoit Hamon // #include <boost/filesystem.hpp> #include "ssl/Base64.hpp" #include "CryptClient.hpp" #i...
/* Copyright (c) 2018-2019, tevador <tevador@gmail.com> Copyright (c) 2019 SChernykh <https://github.com/SChernykh> All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code mu...
#include <iostream> #include <vector> #include <algorithm> #include <fstream> #include <queue> #include <unordered_set> #include <unordered_map> #include <stack> #include <cstdio> #include <cmath> #include <cstring> #include <complex> using namespace std; #define INT_MIN (1<<31) #define INT_MAX (~INT_MIN) #define UNRE...
// // Created by manout on 17-3-28. // #include "common_use.h" /* * You are given an n * n 2D matrix representing an image * Rotate the image by 90 degrees (clockwise) * note: do it in place * 分析: 可以根据定义顺时针操纵每个元素旋转90度,但是太慢了,实践起来也麻烦 * 可以先沿副对角线翻折,然后再上下翻折 */ void rotate_image(vector<vecto...
/* -*- 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. */ #ifndef QUICK_BINDER_DROP_DOWN_H #define QUICK_BINDER_DROP_DOWN_H...
#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...
// // Created by manout on 17-3-22. // #include "common_use.h" /* * Given a triangle, find the minimum path sum from top to bottom. Each step you may * move to adjacent numbers on the below. * 分析: * 设状态为f(i, j),表示从位置(i, j)出发,路径的最小和,则状态转移方程为: * f(i, j) = min{f(i + 1, j), f(i + 1...
#include "EdlProviderServerThread.h" using namespace edlprovider::soap; EdlProviderServerThread::EdlProviderServerThread() { }
#ifndef SPECEX_IMAGE_DATA_BASE__H #define SPECEX_IMAGE_DATA_BASE__H // Base image class for specex adapted from the HARP package developed // by Ted Kisner, see https://github.com/tskisner/HARP #include <specex_unbls.h> class image_data_base { public : image_data_base ( ); virtual ~image_data_base ( );...
#include "GameObject.h" class Monster : public GameObject { public: void load(int x, int y, int width, int height, std::string texturID); void draw(SDL_Renderer* pRenderer); virtual void update(); void clean(); int g=0; };
#include <bits/stdc++.h> using namespace std; #define int long long #define PI 3.141592653589 #define MOD 1000000007 #define FAST_IO ios_base::sync_with_stdio(false), cin.tie(0) #define deb(x) cout<<"[ "<<#x<<" = "<<x<<"] " void solve(){ int ans=0; int n;cin>>n; ...
#include<iostream> #include<cstring> #include<cmath> #include<algorithm> #include<vector> #include<set> #include<map> #include<bits/stdc++.h> #include<queue> #define FOR0(i,n) for(i=0;i<n;i++) #define FOR(i,j,n) for(i=j;i<n;i++) #define FORD(i,j,k) for(i=j;i>=k;i--) inline long long MAX2(long long a, long...
#include "child_merger.hpp" #include "prepare.hpp" #include "utils/log.hpp" #include "utils/assert.hpp" namespace nora { void child_merger::start() { ASSERT(st_); st_->async_call( [this] { ILOG << "merge child begin"; ...
#include "DynamicObjectMagicRayLogicCalculator.h" void DynamicObjectMagicRayLogicCalculator::init(LevelModel* levelModel, DynamicObjectModel* dynamicObjectModel) { m_dynamicObjectModel = dynamicObjectModel; m_levelModel = levelModel; m_referencePosition = Vector4(0,0,0); } void DynamicObjectMagicRayLogicCalculator...
//=========================================================================== //! @file task_manager.cpp //! @brief タスク管理 //=========================================================================== //--------------------------------------------------------------------------- //! 初期化 //-------------------------------...
#ifndef DEFAULT_SWIPE_LISTENER_HPP #define DEFAULT_SWIPE_LISTENER_HPP #include <iostream> #include "BaseSwipeListener.hpp" /* * Prints Swipe events to standard output. * @author: Grzegorz Mirek */ class DefaultSwipeListener : public BaseSwipeListener { protected: void onLeftSwipe(const Leap::SwipeGesture& screenTa...
// -*- Mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- // // Copyright (C) 1995-2012 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 M2_SUPPORT #include "modules/encod...
#include <iostream> #include <algorithm> #include <stdio.h> #include <stdlib.h> #include <time.h> #include <memory.h> #include <math.h> #include <string> #include <sstream> #include <string.h> #include <queue> #include <vector> #include <set> #include <map> typedef long long LL; typedef unsigned long long ULL; #defin...
#include "GamePch.h" #include "AI_LaserBurnStationary.h" #include "Laser.h" #include "Common.h" void AI_LaserBurnStationary::LoadFromXML( tinyxml2::XMLElement* data ) { m_Duration = 20.0f; data->QueryFloatAttribute( "duration", &m_Duration ); } void AI_LaserBurnStationary::Init( Hourglass::Entity * entity ) { hg:...
#include "stdafx.h" #include "DateToken.h" DateToken::DateToken() : QsoTokenType("date") { } DateToken::~DateToken() { } bool DateToken::Parse(const string& token) { m_token = token; return true; }
// This file was generated based on /Users/r0xstation/18app/src/.uno/ux13/icon.Qrcode.g.uno. // WARNING: Changes might be lost if you edit this file directly. #pragma once #include <Fuse.Animations.IResize.h> #include <Fuse.Binding.h> #include <Fuse.Controls.Image.h> #include <Fuse.IActualPlacement.h> #include <Fuse.I...
/*********************************************************************/ /* File: myFESpace.cpp */ /* Author: Joachim Schoeberl */ /* Date: 26. Apr. 2009 */ /***************************...
#include "WinWrappers/WinWrappers.h" #include "EverydayTools/Array/ArrayView.h" #include "EverydayTools/Array/ArrayViewVector.h" #include "EverydayTools/UnusedVar.h" #include "EverydayTools/Exception/CallAndRethrow.h" #include "EverydayTools/Exception/ThrowIfFailed.h" #include "EverydayTools/Exception/CheckedCast.h" #i...
#ifndef TTDTable_H #define TTDTable_H /* Class designed to store TTD lookup table and perform lookup up conversion to distance given time (and slope) */ #include <iostream> #include "TMath.h" using namespace std; class TTDTable { public: TTDTable(std::vector<Double_t> Table, double LowVal, int nbins, doubl...
//leftover.cpp--overloading the left() function #include<iostream> unsigned long left(unsigned long num,unsigned ct); char * left(const char * str,int n=1); int main() { using namespace std; char * trip="Hawaii!!";//test value unsigned long n=12345678;//test value int i; char * temp; ...
#ifndef VULKANLAB_MESH_COMPONENT_H #define VULKANLAB_MESH_COMPONENT_H #include "../ECS.h" ECS_TYPE_IMPLEMENTATION; using namespace ECS; struct MeshComponent { ECS_DECLARE_TYPE; MeshComponent() {} Mesh* mesh; }; ECS_DEFINE_TYPE(MeshComponent); #endif //VULKANLAB_MESH_COMPONENT_H
#include <iostream> #include <string> #include "cmsys/FStream.hxx" #ifdef _WIN32 # include "cmsys/ConsoleBuf.hxx" #endif #ifdef _WIN32 void setEncoding(cmsys::ConsoleBuf::Manager& buf, UINT codepage) { cmsys::ConsoleBuf* cb = buf.GetConsoleBuf(); if (cb) { cb->input_pipe_codepage = codepage; cb->output_...
#include "StdAfx.h" #include "MapManager.h" MapManager::MapManager(void) { } MapManager::~MapManager(void) { } MapManager* MapManager::getInstance(void) { static MapManager instance; return &instance; } void MapManager::startUp(void) { log = LogManager::getInstance(); activeMaps = new LinkedList<Map>(); regi...
/** * An Mirf example which copies back the data it recives. * * Pins: * Hardware SPI: * MISO -> 12 * MOSI -> 11 * SCK -> 13 * * Configurable: * CE -> 8 * CSN -> 7 * */ #include <SPI.h> #include <Mirf.h> #include <nRF24L01.h> #include <MirfHardwareSpiDriver.h> int flip =5; int flop =6; int mailStat = 0; ...
// Created on: 1996-02-28 // Created by: Philippe MANGIN // 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 GN...
/* 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...
#include "f3lib/logic/Object.h"
#ifndef Conjugate_h #define Conjugate_h #include "Matrix.h" #include <vector> class Conjugate { private: Matrix<vector<vector<double> > > p; double alpha; double beta; public: void Set_p_Matrix(int rows_,int columns_) { p.SetMatrix(rows_,columns_); } void Setp(Matrix<vector<vec...
/*-------------------------------------------------------------------- Bellevue Class: PROG 111 Term/Date: Fall 11/21/2013 Instructor: Robert Main Project #: 8 File Name: main.cpp Programmer: Kathryn Brusewitz Uses stats class to retrieve and analyze data for a years worth o...
/**************************************************************************** * * * Author : lukasz.iwaszkiewicz@gmail.com * * ~~~~~~~~ * * Lice...
#include "MyStrategy.h" #define _USE_MATH_DEFINES #include <cmath> #include <vector> #include <algorithm> using namespace std; using namespace model; typedef vector<Tank> TVTanks; const double MIN_ANGLE = M_PI / 90.0; // угол в один градус //const double MIN_ANGLE_B = M_PI / 30.0; // угол в один градус...
#include <iostream> #include <vector> #include "include/AppContext.h" #include "include/LRAnalyze.h" using namespace std; int main(int argc, char *argv[]) { cout << "LR Grammatical analysis by Kyle Derrick ^_^" << endl; cout << "-------------------------------------------" << endl; //获取配置文件路径 string fpath; if ...
// Created on: 2016-04-19 // Copyright (c) 2016 OPEN CASCADE SAS // Created by: Oleg AGASHIN // // 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 as publi...
#ifndef _GUARD_PROFILE_ARGS_H #define _GUARD_PROFILE_ARGS_H #include <cstdlib> #include <cstring> #include <initializer_list> #include <stdexcept> #include <unordered_set> #include <vector> #include <iostream> #include "profile_util.h" struct VariantOptionBase { std::vector<char const *>::size_type choice_index(ch...
class GetUglyNumber { public: int min(int a, int b, int c) { int res = (a > b ? b : a); return (res > c ? c : res); } int GetUglyNumber_Solution(int index) { if (index < 1) return 0; vector<int> ugly_nums(index, 0); ugly_nums[0] = 1; int nextIdx = 1; int X2_min = -1; int X3_min = -1; int X5_min =...
#pragma once #include "Behaviour.h" #include "Decision.h" class DecisionBehaviour : public Behaviour { public: virtual vector2 Update(Agent* agent, float deltaTime) //each frame update your decision { m_decision->makeDecision(agent, deltaTime); return vector2(0, 0); } virtual float GetWeight() { return 0; } ...
#include <vector> #include <set> #include "opennwa/query/returns.hpp" #include "opennwa/query/calls.hpp" #include "opennwa/query/internals.hpp" #include "wali/TotalOrderWorklist.hpp" #include "wali/wfa/WFA.hpp" #include "wali/wfa/State.hpp" #include "opennwa/Nwa.hpp" #include "opennwa/query/language.hpp" #include "op...
/* -*- Mode: c++; tab-width: 4; c-basic-offset: 4 -*- * * Copyright (C) 1995-2010 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/desktop_util/prefs/PrefsUtils.h" #include "ad...
// // sudokuSolver.hpp // // // Created by Juha Kreula on 22/01/2020. // #ifndef sudokuSolver_hpp #define sudokuSolver_hpp #include "sudokuGrid.hpp" class Solver { public: // Constructor explicit Solver(Grid & gridToBeSolved) : grid(gridToBeSolved), cycles(0) { } // Destructor ...
#include "tokenizer.hh" #include "statistics.hh" #include "../v0/dictionary.hh" #include "../string_view.hh" #include <iostream> #include <fstream> #include <vector> #include <string> #include <locale> #include <algorithm> std::vector<std::string> load_dictionary(const char* path) { std::vector<std::string> out; ...
#include <dmp_lib/KalmanFilter/DMPpEKFa.h> #include <dmp_lib/math/quaternions.h> namespace as64_ { namespace dmp_ { DMPpEKFa::DMPpEKFa(std::shared_ptr<dmp_::DMP_pos> dmp, double Ts) { this->Ts = Ts; this->dmp = dmp; this->Az = arma::diagmat( arma::vec( {dmp->dmp[0]->a_z, dmp->dmp[1]->a_z, dmp->dmp[2]->a_z} ) )...
#include "Font.h" #include "Texture.h" #include "Exception.h" #include "Core.h" void Font::Load(std::string _path) { //renderFont = core->GetContext()->createFont(); //long size; //std::vector<unsigned char> fontBuffer; //FILE* fontFile = fopen(_path.c_str(), "rb"); //fseek(fontFile, 0, SEEK_END); //size = ftel...
#pragma once class Patch { public: struct Vertex { glm::vec3 pos; glm::vec3 normal; glm::vec2 uv; }; struct Triangle { GLuint v1, v2, v3; }; Patch(); ~Patch(); // N - vertices count in grid side // step - cell length in world coords void in...
// // main.cpp // 1015 // // Created by Pedro Neves Alvarez on 7/8/17. // Copyright © 2017 Pedro Neves Alvarez. All rights reserved. // #include <iostream> #include <cmath> using namespace std; typedef struct point{ double x; double y; } Point; int main(int argc, const char * argv[]) { Point p1,p2;...
#pragma once #include "GuiManager.h" #include "OgreTerrain.h" #include "OgreTerrainGroup.h" #include "OgreTerrainQuadTreeNode.h" #include "OgreTerrainMaterialGeneratorA.h" #include "OgreTerrainPaging.h" #include "Controls/RollupCtrl.h" #include "EditTool.h" #include "DatabaseDialog.h" #include "Particle...
/***************************************************** * No. : JobDu 1179 * Date : 2015/12/22 * Author : HillBamboo * Source : http://ac.jobdu.com/problem.php?pid=1179 * Summary: long long for big data * Remarkr: 题目表述不清 *****************************************************/ #include <iostream> #...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- * * Copyright (C) 2011 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 CORS_SUPPORT #include "modules/security_...
#define WIN32_LEAN_AND_MEAN #include "Mutex.h" #include "Semaphore.h" #include "Thread.h" #include "ThreadPoolExecutor.h" // 测试线程数 #define TEST_TREAD_COUNT 20 // 每个测试线程数添加的任务数 #define TASK_COUNT 100 static int g_totalcount = 0; static int g_seq = 0; // 保存g_seq CRITICAL_SECTION g_csThreadCode; // 保护共享资源 Mutex...
#include<bits/stdc++.h> using namespace std; typedef long long ll; //dp[i][j] is the min cost to reach ith station from 0th station within time j. vector<vector<ll>> dp(100,vector<ll>(251,-1)); vector<vector<ll>> ti(100,vector<ll>(100,-1)); vector<vector<ll>> risk(100,vector<ll>(100,-1)); ll n; ll dp_rec(ll nn,ll t...
#include "particle.h" #include "../utils/timer.h" #include "../camera/raw_camera.h" bool sloth::Particle::update(const RawCamera &camera) { float deltaTime = static_cast<float>(Timer::deltaFrameTime); m_Velocity.y += PLAYER_GRAVITY * m_GravityEffect * deltaTime; m_Position += m_Velocity * deltaTime; m_ElapsedTime +...
/* BEGIN LICENSE */ /***************************************************************************** * SKFind : the SK search engine * Copyright (C) 1995-2005 IDM <skcontact @at@ idm .dot. fr> * $Id: hiliter.cpp,v 1.15.4.7 2005/02/21 14:22:44 krys Exp $ * * Authors: Mathieu Poumeyrol <poumeyrol @at@ idm .dot. fr> *...
#include<bits/stdc++.h> #define rep(i,n) for (int i =0; i <(n); i++) using namespace std; using ll = long long; int main(){ int r,d,x; cin >> r >> d >> x; vector<int>A(10); A[0] = x; for(int i = 1; i <= 10; i++){ A[i] = A[i-1] * r - d; cout << A[i] << endl; ...
#include <vector> #include <cmath> #include "tgaimage.h" #include "geometry.h" #include "line.h" #include "model.h" #include "triangle.h" #include "colors.h" Model *model = NULL; const int width = 800; const int height = 800; int main(int argc, char** argv) { TGAImage image(width, height, TGAImage::RGB); Vec2i t0...
#ifndef __LMENGINE__ #define __LMENGINE__ #include <Windows.h> #include <Leap.h> #include "..\EngineLib\LMEngineDevice.h" #include "..\EngineLib\EngineCommon.h" class LMENGINE : public LMENGINEDEVICE { private: HWND hwnd; Leap::Controller ctrl; unsigned char init=0; GLVECTOR2 start; GLVECTOR2 last; bool firs...
// Created on: 1993-03-10 // Created by: JCV // 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 Lesser Gen...
#include "nftcenter.hpp" void nftcenter::cancelauc(name seller, uint64_t order_id) { require_auth(seller); chis_table chistable(_code, _code.value); auto iterator = chistable.find(seller.value); if (iterator == chistable.end()) { chistable.emplace(seller, [&](auto& row) { r...
#pragma once #include <vector> #include "ref_count.h" #include "bitmap.h" #include "sprite.h" class SpritePool; class SpriteResource; class SpriteProperty; class CartFile; class Buffer; class Animation { public: Animation(); ~Animation(); /* Draw the current sprite frame on a surface */...
// // Ripple.cpp // w07_h01_ripple // // Created by Kris Li on 10/17/16. // // #include "Ripple.hpp" Ripple::Ripple(){ init(ofPoint(100,100)); num = 20; radius = 0; opacity = 100; theta = 0; } void Ripple::init(ofPoint _pos){ pos.set(_pos.x, _pos.y); } void Ripple::update(vector<Ripp...
#include <cmath> #include <cstdio> #include <vector> #include <iostream> #include <algorithm> using namespace std; // Author: Tatparya Shankar int main() { int n; cin >> n; // Get fractions int element; int neg = 0; int pos = 0; int zero = 0; for( int i = 0; i < n; i ++ ) { ...
#include <iostream> #include <vector> #include <unistd.h> #include <sys/wait.h> #include <stdlib.h> #include "eNFA-to-NFA.h" #include "NFA-to-DFA.h" int main(){ int states, transitions; std::cout << "Enter No of States: "; std::cin >> states; std::cout << "Enter No of Transitions: "; std::cin >...
#ifndef _ANIMAL_H_ #define _ANIMAL_H_ #include <iostream> //std class Animal{ public: Animal(); Animal(std::string name, char mark, int* pattern, int size, int position); ~Animal(); void setPatternAndLength(int* pattern, int size); void setMark(char mark); void setName(std::string name); void setPosition(int p...
//Paul Schakel //Variable LED Blinker //This code makes an LED blink at a rate starting at once every 4 seconds and decreasing in an increment //of .2 seconds each time until it reaches .2 seconds between each blink. // A variable is a sort of container for a value. //You can use variables in a loop to plug dif...
/****************************************************************************** * * * Copyright 2018 Jan Henrik Weinstock * * * ...
#pragma once #include "AllowWindowsPlatformTypes.h" #include <strsafe.h> #include <thread> #include <mutex> #include <condition_variable> #include <queue> #include <algorithm> #include "HideWindowsPlatformTypes.h" //template<typename Data> class ThreadSafeQueue { private: //std::queue<Data> queue; //std::condition_...
//--------------------------------------------------------------------------- #ifndef DLaboralesH #define DLaboralesH //--------------------------------------------------------------------------- #include <Classes.hpp> #include <Controls.hpp> #include <StdCtrls.hpp> #include <Forms.hpp> #include <ComCtrls.hpp> //-----...
#include "scriptObject.h" scriptObject::scriptObject() {} int scriptObject::GetR() { return m_r; } int scriptObject::GetG() { return m_g; } int scriptObject::GetB() { return m_b; } float scriptObject::GetLenght() { return m_length; } float scriptObject::GetWidth() { return m_width; } void scri...
#pragma once #include <memory> #include <vector> #include <map> #include <set> #include <unordered_map> #include <unordered_set> #include <list> #include <string> #include <queue> #include <array> namespace Rocket { template <typename Base, typename T> static bool InstanceOf (const T *) { return std::is_base_of<...
// // Copyright (c) 2011 Bryce Lelbach // Copyright (c) 2011-2012 Hartmut Kaiser // Copyright (c) 2010 Artyom Beilis (Tonkikh) // // 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_...
#ifndef MAINWINDOW_H #define MAINWINDOW_H #include <QMainWindow> #include <QPushButton> #include <QLineEdit> #include "quitwindow.h" #include "datewindow.h" #include "directorywindow.h" #include "helpwindow.h" #include "pcbwindow.h" #include "processschedulers.h" namespace Ui { class MainWindow; } class MainWindow :...
#include <iostream> using namespace std; int mdc(int , int); int main() { int a, b, divisor; cin >> a >> b; int menor = ( a<b ? a : b ); int maior = ( a>b ? a : b ); divisor = mdc(maior,menor); cout << divisor << endl; return 0; } int mdc(int maior, int menor) { if (menor == 0) return maior; else re...
/** * Copyright (C) Omar Thor, Aurora Hernandez - All Rights Reserved * Unauthorized copying of this file, via any medium is strictly prohibited * Proprietary and confidential * * Written by * Omar Thor <omar@thorigin.com>, 2018 * Aurora Hernandez <aurora@aurorahernandez.com>, 2018 */ #ifndef DMTK_ALGORI...
/* * (C) Copyright 2016-2018 Ben Karsin, Nodari Sitchinava * * 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 a...
#pragma once #include "vlc/vlc.h" #include <string> #pragma comment(lib, "libvlc.lib") #pragma comment(lib, "libvlccore.lib") using namespace std; class VLCPlayer { libvlc_instance_t *vlcInstance; libvlc_media_player_t *vlcMediaPlayer; libvlc_media_t *vlcMedia; int volume; public: VLCPlayer(); ...
#pragma once #include "ARPG.h" #include "Components/SphereComponent.h" #include "InteractableAreaComponent.generated.h" DECLARE_MULTICAST_DELEGATE_OneParam(FInteractEvent, class UInteractableAreaComponent *) UCLASS() class ARPG_API UInteractableAreaComponent : public USphereComponent { GENERATED_BODY() public : ...
#include "mainwindow.h" #include "ui_mainwindow.h" #include <QDebug> #include <QDateTime> #include <QFile> static QFile outFile; MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWindow) { ui->setupUi(this); outFile.setFileName("short.log"); //"C:/Qt/build-Ligh...
#include <bits/stdc++.h> using namespace std; #define MOD 1000000007 #define rep(i, n) for(int i = 0; i < (int)(n); i++) #define rep1(i, n) for(int i = 1; i <= (int)(n); i++) #define show(x) {for(auto i: x){cout << i << " ";} cout<<endl;} #define showm(m) {for(auto i: m){cout << m.x << " ";} cout<<endl;} typedef long l...