text
stringlengths
8
6.88M
/* -*- 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. */ #include "core/pch.h" #include "modules/pi/pi_module.h" #includ...
/* BEGIN LICENSE */ /***************************************************************************** * SKFind : the SK search engine * Copyright (C) 1995-2005 IDM <skcontact @at@ idm .dot. fr> * $Id: record.cpp,v 1.40.4.5 2005/03/16 13:58:24 bozo Exp $ * * Authors: Mathieu Poumeyrol <poumeyrol @at@ idm .dot. fr> * ...
#pragma once #include "Event.h" class userInputEvent : public Event { private: char key; GameObject a; GameObject b; public: userInputEvent(char key); userInputEvent(GameObject a, GameObject b); char getKeyPress(); GameObject getObjA(); GameObject getObjB(); eventType getType(); };
#ifndef MODEL_H_ #define MODEL_H_ #include <SDL.h> class Model { public: Model(SDL_Surface *s, int x, int y); Model(); ~Model(); void setSurface(SDL_Surface *s); void setX(int x); void setY(int y); void setColorKey(int rgb); SDL_Surface *getSurface(); int getX(); int getY(); private: int x,...
#include <iostream> #include <cstdio> #include <algorithm> #include <vector> #include <functional> #include <queue> #include <string> #include <cstring> #include <numeric> #include <cstdlib> #include <cmath> using namespace std; typedef long long ll; #define INF 10e8 #define rep(i,n) for(int i=0; i<n; i++) #define re...
// Copyright 2020 Fuji-Iot 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 appli...
#include <iostream> using namespace std; //Nhap Mang void Input(int *&a,int &n)//boi vi con tro cung la 1 bien va muon no thay doi gia thi phai refenfer { do { cout<<"\n Nhap vao n:\t"; cin>>n; if(n<=0) { cout<<"\n N khong hop le!"; } } while(n<=0); ...
#ifndef __RequestDissolveRoom_H__ #define __RequestDissolveRoom_H__ #include "BaseProcess.h" class RequestDissolveRoom : public BaseProcess { public: RequestDissolveRoom(); ~RequestDissolveRoom(); virtual int doRequest(CDLSocketHandler* clientHandler, InputPacket* inputPacket, Context* pt); virtual int doRespons...
#include <cstdio> #include<vector> using namespace std ; const int N = 10100 ; int chainHead[N], chainId[N], pos[N], cost[N], par[N][14]; vector < int > g[N], costs[N], index[N] ; int sz[N], dep[N], End[N], cur, chainNo; int tree[N << 2] ; void fresh(int n){ for(int i = 0 ; i <= n ; ++i){ g[i].clear(...
#include <bits/stdc++.h> using namespace std; #define f first #define s second #define pb push_back #define rep(i, begin, end) \ for (__typeof(end) i = (begin) - ((begin) > (end)); \ i != (end) - ((begin) > (end)); i += 1 - 2 * ((beg...
#pragma once #include "..\Common\Pch.h" #include "..\Graphic\Direct3D.h" #include "..\RenderResource\InputLayout.h" class SkyPlane : public InputLayout { public: SkyPlane(); ~SkyPlane(); void Initialize(); virtual void Update(FLOAT delta); void SetBuffer(); private: struct BufferData { FLOAT Transl...
#pragma once #include "Quiz_fwd.h" #include "QuizSession_fwd.h" #include "QuestionStates.h" namespace qp { class CQuizSession : boost::noncopyable { public: CQuizSession(CConstQuizPtr const& quiz, const CQuestionStates & questionStates); ~CQuizSession(); IQuestionStatePtr GetCurrentQuestionState()...
#include <unordered_map> #include <iostream> void test0() { std::unordered_map<int, int> m{{1,1}, {2,2}, {3,3}}; for (auto& p : m) { std::cout << p.first << " " << p.second << std::endl; m.erase(p.first); } } int main() { test0(); return 0; }
#include <iostream> #include "Election.hh" using namespace std; /* Contructeurs */ Election::Election(std::vector<Personnage>& objet) { for(int i(0);i<Personnage::nbPerso ;i++) { objet[i].voter(); } } std:: string Election:: method()const { return "ok"; } /* Destructeur */ Election...
#include "Truck.h" Truck::Truck() { weight = 30000; max_speed = 90; fuel_consumption = 27; passengers_number = 2; max_luggage = 0; max_volume = 50; carrying = 5000; } int Truck::count_comfort() { return 0; } std::string Truck::vehicle_name() { return truck; } void Truck::print(UserInterface* ui) { ui->veh...
#include <string> #include "format.h" using std::string; // TODO: Complete this helper function // INPUT: Long int measuring seconds // OUTPUT: HH:MM:SS // REMOVE: [[maybe_unused]] once you define the function string Format::ElapsedTime(long seconds) { char buffer[10]; int HH = (int)(seconds/3600); int MM = (...
// Created on: 1994-08-31 // Created by: Jacques GOUSSARD // Copyright (c) 1994-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 G...
#include "GameSeaquenceController.h" #include "SeaquenceController.h" #include "Ending.h" #include "Title.h" #include "State.h" #include "Ready.h" #include "GameOver.h" #include <sstream> GameSeaquenceController::GameSeaquenceController() :mState(0), mStageID(0), mNextSeaquence(NEXT_NONE), mGameSeaquence(0) { //Rea...
#ifndef INC_3PC_DEFINE_H #define INC_3PC_DEFINE_H #include <map> #define ROUND_TIME 10000 #define MIN_SLEEP_TIME 6000 #define MAX_SLEEP_TIME 7000 #define MIN_SLEEP_TIME_COORDINATOR 4000 #define MAX_SLEEP_TIME_COORDINATOR 5000 #define COORDINATOR_ID 0 #define MPI_CRASH_TAG 100 enum State : unsigned char { Q, W, A...
#include "PiSBus.h" #include <unistd.h> #include <thread> int main(int argc, char *argv[]) { std::string port = argv[2]; PiSBus sbus(port); sbus.Begin(); std::thread write_to_ch(sbus.Write()); std::thread read_ch(sbus.Read()); return 0; }
// // Persona.cpp // Tarea3Ejercicio3 // // Created by Daniel on 07/10/14. // Copyright (c) 2014 Gotomo. All rights reserved. // #include "Persona.h" Persona::Persona(int i){ std::cout<<"Nombre: "; std::cin>>nombre; std::cout<<"Apellido: "; std::cin>>apellido; std::cout<<"Edad: "; ...
/*Tests for cc_shared::ScopedArray.*/ #include "cc/shared/scoped_array.h" #include "gtest/gtest.h" #include "cc/shared/count_destructors.h" namespace cc_shared { namespace { CountDestructors* test_template(int array_size, int* destructor_count, bool do_release) { CountDestructor...
#ifndef ACTIVITE_H #define ACTIVITE_H #include <QString> #include "timing.h" using namespace TIME; class Activite { //Ajout de statut aux activités ? /*! \class Activité * \brief Classe permettant de stocker des activités traditionnelles */ private: QString titre; /*!< Titre de l'activit*/ ...
/* Initial author: Convery (tcn@ayria.se) Started: 2019-08-04 License: MIT LAN Matchmaking-broadcasts over UDP. */ #pragma once #include <Stdinclude.hpp> namespace Matchmaking { struct Server_t { uint64_t SessionID; uint64_t Lastmessage; std::string Hostname; s...
#ifndef _SHOTGUN_H #define _SHOTGUN_H #include "WeaponInfo.h" class Shotgun : public CWeaponInfo { public: Shotgun(GenericEntity::OBJECT_TYPE _bulletType); virtual ~Shotgun(); // Initialise this instance to default values void Init(void); //render weapon void Render(); // Discharge this weapon void Discharge...
/* * @lc app=leetcode.cn id=145 lang=cpp * * [145] 二叉树的后序遍历 */ // @lc code=start /** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x), left(NULL), right(NULL) {} * }; */ #include<vector> #include<iostream> u...
#ifndef SMITHERS #define SMITHERS #include "player.h" #include "game.h" #include "messages.h" #include <zmq.hpp> #include <json/json.h> #include <string> #include <vector> namespace smithers{ typedef std::vector<Player>::iterator players_it_t; typedef std::vector<Player>::const_iterator players_cit_t; ...
// Created on: 1993-11-18 // Created by: Yves FRICAUD // 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 L...
#include<bits/stdc++.h> #define FAST1 ios_base::sync_with_stdio(false); #define FAST2 cin.tie(NULL); using namespace std; #define pb push_back #define FOR(a, b) for (int i = (int) a; i < (int) b; i++) typedef long long ll; typedef pair<int, int> pii; int main() { FAST1; FAST2; int test_cases; ...
#include <iostream> #include <bits/stdc++.h> #include <stack> using namespace std; /* Sample Input: 3 {[()]} {[(])} {{[[(())]]}} */ // Takes a string and checks if all the opening brackets have a corresponding closing bracket. Prints TRUE if the // brackets properly line up and FALSE if not. void check_line(string ...
/** Program: wordTree.h Date: 01/18/2014 */ #ifndef __WORDTREE_H__ #define __WORDTREE_H__ #include <string> using namespace std; struct TNode { string word; // char* word; int count; TNode* left; TNode* right; }; class WordTree { public: WordTree (); ~WordTree (); bool isEmpty ()...
#ifndef STAGEDIALOG_H #define STAGEDIALOG_H #include <QDialog> namespace Ui { class stageDialog; } class stageDialog : public QDialog { Q_OBJECT public: explicit stageDialog(QWidget *parent = nullptr); ~stageDialog(); private: Ui::stageDialog *ui; }; #endif // STAGEDIALOG_H
#include <systemc.h> #include <fstream> #include <controller.h> #include <tester.h> using namespace std; int sc_main(int argc, char *argv[]) { sc_clock clk("clock", 10, SC_NS); sc_signal<bool> s_reset_n; sc_signal< sc_uint<2> > s_addr_in_1, s_addr_in_2, s_addr_out; sc_signal< sc_uint<3> > s_opcode; sc_signal<bo...
#ifndef COMMON_INCLUDE_H #define COMMON_INCLUDE_H // ros #include <ros/ros.h> #include <sensor_msgs/Image.h> #include <geometry_msgs/PointStamped.h> #include <geometry_msgs/PoseStamped.h> #include <std_msgs/Empty.h> #include <sensor_msgs/PointCloud2.h> #include <sensor_msgs/CameraInfo.h> // cv #include <cv_bridge/cv_...
#include <iostream> #include <string> using namespace std; struct Person { string name; string address; int phone; }; int main() { Person person; cout << "Enter name: "; cin >> person.name; cout << "Enter address: "; cin >> person.address; cout << "Enter phone: "; cin >> person.phone; ...
#include "JsonData.h" #include "EVWork.h" using namespace evwork; #define DEFAULT_PACKET_LIMIT 1024*1024*16 #define DEF_PRINT_INTERVAL 10 CJsonData::CJsonData() : m_uProc(0) , m_uPacketLimit(DEFAULT_PACKET_LIMIT) , m_uBytes64(0) { __initTimerPrint(); } CJsonData::~CJsonData() { __destroyTimerPrint(); } void CJs...
// Created on: 2015-08-10 // Created by: Ilya SEVRIKOV // 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 as...
// Poker.h #ifndef POKER_H_ #define POKER_H_ #include <iostream> #include "Card.h" #include "Player.h" using namespace std; #endif /* POKER_H_ */
// Siva Sankar Kannan - 267605 - siva.kannan@student.tut.fi #include "fileread.h" #include "splitter.h" #include <iostream> #include <string> #include <vector> #include <fstream> #include <map> #include <algorithm> #include <utility> using namespace std; /*----------------------------------------------------------...
#include "SuperHero.h" class SuperHero : Person { SuperHero() { } ~SuperHero() { } void doFly() { printf("superhero is flying"); } void doInvisible() { printf("superhero is INvisible"); } };
// // Created by 钟奇龙 on 2019-04-15. // #include <iostream> using namespace std; class Node{ public: int data; Node* next; Node(int x):data(x),next(NULL){ } }; Node* listPartition(Node *head,int pivot){ Node *sH = NULL; Node *sT = NULL; Node *eH = NULL; Node *eT = NULL; Node *bH =...
#include "pyramid.h" #include "ui_pyramid.h" #include "image.h" #include <QPixmap> #include <QStandardPaths> #include <algorithm> Pyramid::Pyramid(QWidget *parent) : QMainWindow(parent), ui(new Ui::Pyramid) { ui->setupUi(this); } Pyramid::~Pyramid() { delete ui; } void Pyramid::onImageOpen() { co...
#include <iostream> using namespace std; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); int n; double a; cin >> n >> a; double l = 0; double r = a; double b = 0; while (r - l > 0.005 / n) { double mid = l + (r - l) / 2; double v1 = a; double v...
// Created on: 1996-02-15 // Created by: Christian CAILLET // 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 ...
#pragma once #include "linear_functional.hpp" namespace Time { template <typename WaveletBasis> class LinearForm { public: using ScalingBasis = typename FunctionTrait<WaveletBasis>::Scaling; LinearForm(std::unique_ptr<LinearFunctional<ScalingBasis>> functional) : functional_(std::move(functional)) {} t...
/** * @file AbstractManager.h * @brief 包含抽象类AbstractManager的定义 */ #ifndef ABSTRACTMANAGER_H #define ABSTRACTMANAGER_H #include <OgreCamera.h> #include <OgreSceneManager.h> #include <QObject> /**      *  @class AbstractManager Manager\AbstractManager.h   *  @brief 一个由其他管理器继承的管理器抽象类.   *   */ class AbstractM...
#include <stdio.h> // o pragma once serve para indicar o cabeçalho de pré // compilação. Não sei se entendi muito bem a sua funcionalidade // e talvez seja interessante marcar como DÚVIDA #pragma once // DÚVIDAAAA!!!!!!! // Vamos criar a classe Universidade, para associá-la // aos objetos do tipo Pessoa que criamos cl...
// -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4; c-file-style:"stroustrup" -*- // // Copyright (C) 1995-2007 Opera Software ASA. All rights reserved. // // This file is part of the Opera web browser. It may not be distributed // under any circumstances. // // Patricia Aas // #ifndef __SERVER_C...
#include <chuffed/mip/mip.h> #include <chuffed/vars/int-var.h> #include <map> #include <sstream> // When set, branch variable (first_fail) and value (indomain_median, // indomain_split, indomain_reverse_split) specifications will count domain // sizes by the number of active values rather than the bounds (max-min). /...
#include <bits/stdc++.h> using namespace std; #define TESTC "" #define PROBLEM "11479" #define USE_CPPIO() ios_base::sync_with_stdio(0); cin.tie(0) int main(int argc, char const *argv[]) { #ifdef DBG freopen("uva" PROBLEM TESTC ".in", "r", stdin); freopen("uva" PROBLEM ".out", "w", stdout); #endif int kase; ...
#include <iostream> #include <stdlib.h> #include <math.h> using namespace std; int main(const int argc, const char* const argv[]){ int rc = 0; if (argc < 1){ cerr << "Error: Unable to compute standard deviations over data set because of insufficient data" << endl; return -1; } for (in...
#include<iostream> using namespace std; void swap(int *p, int *q){ int temp = *p; *p = *q; *q = temp; } void displayArray(int arr[], int size){ for(int i=0; i<size; i++){ cout << arr[i] << " "; } cout << endl; } void selectionSort(int arr[], int size){ int minIndex, i, j; for...
// iterative class Solution { public: vector<string> findItinerary(vector<pair<string, string>> tickets) { unordered_map<string, multiset<string>> ngb; for(auto ticket: tickets){ ngb[ticket.first].insert(ticket.second); } vector<string> res; stack<string> path; ...
#include "MoveComponent.h" #include "Actor.h" #include <iostream> MoveComponent::MoveComponent(class Actor* owner, int updateOrder) :Component(owner, updateOrder), mAngularSpeed(0.0f), mForwardSpeed(0.0f), mMass(0.0f), mVelocity(Vector2(0.0f, 0.0f)) { } void MoveComponent::Update(float deltaTime) { if (!Math::...
#include "RenderTextSample.h" #include "EverydayTools/Delegate.h" #include "EverydayTools/Array/ArrayViewVector.h" #include "EverydayTools/Exception/CheckedCast.h" #include "Keng/Base/Serialization/SerializeMandatory.h" #include "Keng/Base/Serialization/openarchivejson.h" #include "Keng/Core/IApplication.h" #include "K...
#include<cstdio> #include<iostream> #include<string> using namespace std; int main(){ char puzzle[5][5]; int i,j,count=1; while(gets(puzzle[0])){ int flag=0; if(puzzle[0][0]=='Z') break; for(i=1;i<5;i++) gets(puzzle[i]); if(count>1) cout<<endl; // for(i=0;i<5;i++) // for(j=0;...
#include <iostream> #include <string> #include <vector> #include <algorithm> #include <iomanip> using namespace std; struct poly { int exp; double coe; }; int main() { int k, l; cin >> k; poly* a = new poly[k]; for (int i = 0; i < k; i++) cin >> a[i].exp >> a[i].coe; cin >> l; poly* b = new poly[l...
//#define _CRT_SECURE_NO_WARNINGS #include<iostream> #include<string> #include <vector> #include <cstdlib> #include <string> using namespace std; class Student{ public: string firstName; // krstne meno string lastName; // priezvisko Student() : firstName(""), lastName("") {} Student(string firstName, strin...
// Copyright 2017 The WCT(Wisdom City Times) Authors. All rights reserved #include "chrome/browser/ui/views/tabs/popup_thumbnail.h" PopupThumbnail::PopupThumbnail(Type type, Browser* browser) : type_(type), browser_(browser) {} PopupThumbnail::~PopupThumbnail() {}
// // Created by jeremyelkayam on 9/30/20. // #include "end_screen.hpp" EndScreen::EndScreen(TextLoader &a_text_loader, ResourceManager &a_resource_manager, InputManager &an_input_manager, vector<postmortem_info> dead_players_info, game_options game_opts) : Screen(a_text_loader, a_resource_manager, an...
#include <iostream> #include <cstring> using namespace std; int minlen(char *str[],int n); int main() { char str[5][31]; int n; cin>>n; for(int i=0;i<n;i++){ cin>>str[i];} cout<<minlen(str,n); return 0; } int minlen(char *str[],int n){ int tmp,min(31); for(int i=0;i<n;i++){ tmp=strlen(str[i]...
#include "speed_controller.h" SpeedController::SpeedController(GPSSensor *gps_sensor, DroneBalancer *balancer) { this->gps_sensor = gps_sensor; this->balancer = balancer; }
// Copyright 2018 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/credential_provider/gaiacp/scoped_user_profile.h" #include <Windows.h> #include <dpapi.h> #include <security.h> #include <userenv.h> #in...
#include<iostream> #include<vector> using namespace std; class Solution { public: vector<int> searchRange(vector<int>& nums, int target) { //简化版:lower_bound和upper_bound算法 vector<int> res{-1,-1}; if(nums.empty()) return res; int low=0, mid, high=nums.size()-1; while(low<high) { mid=(low+high)/2; if(n...
#include "./XmlCommon.h" #include <iberbar/Utility/String.h> void iberbar::Poster::CXmlProcMessageBuffer::AddMessage( UXmlProcMessageCode code, const char* format, ... ) { va_list va; va_start( va, format ); m_messages.push_back( UXmlProcMessage( code, StdFormatVa( format, va ) ) ); va_end( va ); }
#include <string> #include <iostream> #include <specex_pyimage.h> using namespace std; specex::PyImage::PyImage( py::array ds_pix, py::array ds_ivar, py::array ds_mask, py::array ds_readnoise, std::map<std::string,std::string> hdr_mt ){ auto pix_prop = ds_pix.request(); auto ivar_...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 1995-2008 Opera Software AS. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** psmaas - Patricia Aas */ #ifndef CORE_HISTORY_MODEL_TIME_FOLDER_H...
#include <QDial> class SamDial : public QDial { Q_OBJECT public: SamDial( QWidget* parent ); public slots: void iterate(); };
#include <iostream> #include <GL/gl.h> #include <GL/glu.h> #include <GL/glut.h> #include <math.h> #include "Camera.h" #include "util/Vec3f.h" #include "world/Chunk.h" #include "Entity.h" #define ESCAPE 27 using namespace std; // window stuff int window, scale = 16, Width, Height; GLfloat gui[16]; Camera cam; Vec...
#ifndef EDIT_HH_ # define EDIT_HH_ void undisplay_edit_tab (); void display_edit_panel (GtkWidget *w, gpointer p); void display_show_panel (GtkWidget *w, gpointer p); #endif //EDIT_HH_
#pragma once template<typename AllocStrategy> class AllocOn { public: void* operator new(std::size_t size) { return AllocStrategy::Alloc(size); } void operator delete(void* ptr) { AllocStrategy::Delete(ptr); } };
/* -*- 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 "modules/widgets/OpWidgetPainterManager.h" #include "mod...
class Singleton { public: static Singleton* Instance() { if(pInstance_) return pInstance_; return new Singleton; } int ReturnInt() { return intValue; } private: Singleton() { intValue = 1; } Singleton(const Singleton&) {} static Singleton* pI...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4; c-file-style:"stroustrup" -*- ** ** 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 VEGAOPBITMAP_H #define VEGAOPB...
#include "APIServer.h" #include "Helpers.h" #include "KeyManager.h" #include <filesystem> APIServer::APIServer(uint32_t port, const std::string& secret, KeyManager& keyManager) : m_port(port), m_keyManager(keyManager) { m_server.Post("/create", [this, &secret](const httplib::Request& request, h...
// Created on: 1991-03-14 // Created by: Laurent PAINNOT // Copyright (c) 1991-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...
// Created on: 1993-01-08 // Created by: Christian CAILLET // 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 ...
#pragma once #include <QWidget> namespace Ui { class ScaleStatisticsForm; } class ScaleStatisticsModel; class ScaleStatisticsForm : public QWidget { Q_OBJECT public: explicit ScaleStatisticsForm(QWidget *parent = nullptr); ~ScaleStatisticsForm(); ScaleStatisticsModel *getModel() const; void set...
#pragma once #include "plbase/PluginBase.h" #include "CTaskSimple.h" #include "CVector.h" #include "CVector2D.h" enum eUseGunFlags : unsigned __int8 { USE_GUN_RIGHT_HAND = 1, USE_GUN_LEFT_HAND = 2 }; #pragma pack(push, 1) class PLUGIN_API CTaskSimpleUseGun : public CTaskSimple { public: __int8 field_8; __int8 fi...
// Fill out your copyright notice in the Description page of Project Settings. #include "kinect2ArrayProject.h" #include "kinect2ArrayProjectGameMode.h"
#pragma once #include "MythConfig.hh" #include <stdio.h> /* The maximum number of people who can talk at once */ #define CHAT_MAXPEOPLE 200 #include "PEOPLE.hh" #include <string> using namespace std; /* typedef struct { int active; TCPsocket sock; IPaddress peer; void* addtionaldata; } PEOPLE; */ //people[CHAT_MAX...
#ifndef TRANTOR_THREAD_POOL_H_ #define TRANTOR_THREAD_POOL_H_ #include <queue> #include <mutex> #include <atomic> #include <condition_variable> #include <thread> #include <memory> #include "TrantorNonCopyable.h" namespace trantor { class TrantorFixedThreadPool :TrantorNonCopyable { public: explicit TrantorFixedT...
//interfaces de las clases #include "estudiantes.h" using namespace std; //FUNCIONES DE CLASE //constructor por defecto estudiante::estudiante(void) { //datos de busqueda strcpy(datos.cedula,""); //datos de identificacion strcpy(datos.nombre,""); datos.anno = 0; strcpy(datos.institucion,""); //datos de clasifica...
// Programm: Bruchrechner // Beschreibung: Eingabe iener mathematischen Aufgabe, Bruchrechner // Autor: // Klasse: IJ209, Heinrich-Hertz-Berufskoleg // Zusammenarbeit mit: // Erstell-Datum: 24 November 2009 // //Änderungen: 1 Dezember 2009 Abfrage nach dem Nenner (ob null); wiederholungs abfrage(while ...
#ifndef VIGENERE_H_ #define VUGENERE_H_ #include <iostream> using namespace std; static string keyVigenere; static int lenKey, lenAlphabet,lenMessage; int * generateKey(string,string); int * encryptVigenere(int *,int *); int * decryptVigenere(int *,int *); int * matchCharToIndex(string,string); string matchIndexTo...
/*This is the draft main part of the code to train a model to classify patches. Here, the main idea is to classify each patch. The model is trained in Dlib in C++ and the overall accuracy for 10 images is about 55 percent. The results are not acceptable yet however by data augmentation and better training i...
/** * created: 2013-4-7 22:12 * filename: FKRandomGenerator * author: FreeKnight * Copyright (C): * purpose: */ //------------------------------------------------------------------------ #include "../Include/FKRandomGenerator.h" #include <stdlib.h> //----------------------------------------------------------...
/* This file is part of FineFramework project */ #ifndef FFW_UTILS_ANY #define FFW_UTILS_ANY #include <typeinfo> #include <string> #include <string.h> #include <unordered_map> #include <memory> #include <vector> #include "config.h" namespace ffw { class Array; class Object; /** * @ingroup utils ...
#include <iostream> #include <functional> #include <string> #include <iterator> #include <algorithm> template<typename T, typename ... Ts> auto concat(T t, Ts ... ts) { std::cout << __PRETTY_FUNCTION__ << std::endl; if constexpr (sizeof...(ts) > 0) { return [=](auto ... parameters) { return...
// ============================================================================ // Data Structures For Game Programmers // Ron Penton // HashTable.h // This file holds the Linekd Hash Table implementation. // ============================================================================ #ifndef GNMAP_H #define GNMAP_H ...
// // Matrix3x3.h // Odin.MacOSX // // Created by Daniel on 24/09/15. // Copyright (c) 2015 DG. All rights reserved. // #ifndef Odin_MacOSX_Matrix3x3_h #define Odin_MacOSX_Matrix3x3_h #include "Matrix.h" #include <initializer_list> #include <cassert> namespace odin { namespace math { // Speciali...
#ifndef SLOT_H #define SLOT_H #include <string> class Slot { public: Slot ( std::string type ); int get_count_available() const; std::string get_type() const; void set_type ( const std::string& new_type ); int get_count() const; void add ( int quantity ); void reserve ( int quantity ); pr...
#pragma once #include <SFML/Graphics.hpp> namespace Sonar { class InputManager { public: InputManager() = default; ~InputManager() = default; bool IsSpriteClicked(const sf::Sprite& object, sf::Mouse::Button button, const sf::RenderWindow& window) const; sf::Vector2i GetMousePosition(const sf::RenderWind...
////////////////////////////////////////////////////////////////////////////// // // Copyright (c) 2007, Gogul Balakrishnan, Akash Lal, Thomas Reps // University of Wisconsin, Madison. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provide...
#include <sstream> #include <iostream> #include <string> #include <fstream> #include "generator.h" //-------------------------------------------------------------------------------------------------- GlobalSpaceGen* AbstractGen::globalSpaceGenPtr = nullptr; //--------------------------------------------------------...
#include "OgreFramework.h" using namespace Ogre; template<> OgreFramework* Ogre::Singleton<OgreFramework>::msSingleton = 0; /// <summary> /// Initializes a new instance of the <see cref="OgreFramework"/> class. Just init some required variables. /// </summary> OgreFramework::OgreFramework() { m_MoveSpeed = 0.4f...
// Fill out your copyright notice in the Description page of Project Settings. #pragma once #include "GameFramework/GameState.h" #include "MyGameState.generated.h" /** * */ UCLASS() class FIGHTWITHBLOCK_API AMyGameState : public AGameState { GENERATED_BODY() AMyGameState(); UPROPERTY(EditAnywhere, Category ...
// // Created by Lee on 2019-04-22. // #ifndef UBP_CLIENT_CPP_VER_JSONPARSER_H #define UBP_CLIENT_CPP_VER_JSONPARSER_H #include <vector> #include <QJsonObject> #include "Photo.h" #include "PhotoGroup.h" class JsonParser { public: static Photo jsonToPhoto(QJsonObject json); static PhotoGroup jsonToPhotoGro...
// Copyright Epic Games, Inc. All Rights Reserved. /*=========================================================================== Generated code exported from UnrealHeaderTool. DO NOT modify this manually! Edit the corresponding .h files instead! ========================================================================...
#pragma once #include "Field.h" class Player { protected: Field* field; public: bool inGame = true; virtual void Update() = 0; virtual int GetSymbol(int i, int j) { return field->GetSymbol(i, j); } virtual int GetScore() { return field->GetScore(); } virtual int GetLines() { return field->GetLines(); } };