text
stringlengths
8
6.88M
#include <iostream> #include <stdio.h> #include <string> #include <stdlib.h> #include "camadaenlace.cpp" #include "camadafisica.cpp" using namespace std; int main (){ int size = 32; int quadro[size]; //CamadaEnlaceDadosTransmissora(quadro); AplicacaoTransmissora(); }
/************************************************************************************** * File Name : Vertices.cpp * Project Name : Keyboard Warriors * Primary Author : JeongHak Kim * Secondary Author : * Copyright Information : * "All content 2019 DigiPen (USA) Corporation, all rights rese...
/* Includes ------------------------------------------------------------------*/ #include "chassis_ctrl.h" /* Function prototypes -------------------------------------------------------*/ /** * @brief Constructor */ ChassisCtrl_Classdef::ChassisCtrl_Classdef() :xScale(1.f), yScale(1.f) {} /** * @brief Destructor ...
#include <iostream> #include "Evenement.hh" using namespace std;
/* Solicitar números reais do usuário (UTILIZE ESTRUTURA DE REPETIÇÃO) e imprimir: Total de números entre 20 e 50. Total de números menores que 4. O programa termina quando o número for um número negativo (que não deve ser considerado na contagem). */ #include<stdlib.h> #include<stdio.h> main(){ int nu...
#include "../idlib/precompiled.h" #pragma hdrstop #include "Game_local.h" #include "ai/AI_Manager.h" /* =============================================================================== idTrigger =============================================================================== */ const idEventDef EV_Enable( "enabl...
#pragma once #ifndef LUCE_H #define LUCE_H #include "Posizione.h" class Luce { public: Luce(); Posizione getPosizione(); void setPosizione(Posizione pos); void move(double x, double y, double z); void disegnaLuce(); private: Posizione posizione; }; #endif
#include <iostream> using namespace std; int d[1001]; int dp(int x) { if (x == 1) return 1; if (x == 2) return 3; if (d[x] != 0) return d[x]; return d[x] = (dp(x - 1) + 2*dp(x-2)) % 10007; } int main(void) { int x; cin >> x; cout << dp(x) << endl; }
#pragma once #include "HUDView.h" #include "LevelModel.h" #include "LevelView.h" #include "PlayerController.h" #include "StaticObjectController.h" #include "DynamicObjectController.h" #include "TmxParser/Tmx.h" class LevelController { public: enum LevelProgressState { LEVEL_IN_PROGRESS, LEVEL_FINISHED, LEVE...
#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 10e10 #define rep(i,n) for(int i=0; i<n; i++) #define r...
/*! @file LogVol_DynodesArray.hh @brief Defines mandatory user class LogVol_DynodesArray. @date August, 2015 @author Flechas (D. C. Flechas dcflechasg@unal.edu.co) @version 1.9 In this header file, the 'physical' setup is defined: materials, geometries and positions. This class defines the experimental ...
#include <bits/stdc++.h> using namespace std; typedef pair<int, int> P; typedef long long ll; int main(){ string s; cin >> s; int ans = 0; int x = 0; int y = 0; for(int i=0; i<s.size();i ++){ if(i%2 == 0 && s[i] == '0') x++; else if(i%2 == 1 && s[i] == '1') y++; ...
#include <iostream> #include "core/types.h" #include "core/aabbtree.h" #include "core/mesh.h" #include "core/pfm.h" #include "graphics/rendergl/glutil.h" using namespace std; const uint32_t g_screenWidth = 1024; const uint32_t g_screenHeight = 512; Point3 g_camPos; Rotation g_camDir; PfmImage g_probe; uint32_t g...
#include "stdafx.h" #include "Person.h" #include <string> #include <iostream> Person::Person(char* szName, int age) { memset((void*)(this->szName), 0, sizeof(this->szName)); strcpy(this->szName, szName); this->age = age; std::cout << "Person constructor." << std::endl; } Person::~Person() { } Student::Stude...
/** * Copyright (c) 2023, Timothy Stack * * 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 must retain the above copyright notice, this * list of condi...
#ifndef __HallHandler_H__ #define __HallHandler_H__ #include <map> #include "CDLSocketHandler.h" #include "Packet.h" #include "DLDecoder.h" class HallHandler :public CDLSocketHandler { public: HallHandler(); virtual ~HallHandler(); int OnConnected() ; int OnClose(); int OnPacketComplete(...
#include <string> #include <vector> using namespace std; vector<long long> solution(int x, int n) { vector<long long> answer; int mul=1; while(mul<=n){ answer.push_back(x*mul); mul++; } return answer; }
//=========================================================================== //! @file gpu_texture.h //! @brief テクスチャ //=========================================================================== #pragma once //=========================================================================== //! @namespace gpu //==========...
#pragma once //======include section====== #include "Score.h" #include "Lives.h" #include "Location.h" #include "macros.h" class Player { public: // c-tors Player (Location location); Player(); // getters int get_score(); int get_lives(); Location get_location(); // setters void set_loctaion(Location& new...
#ifndef note_h #define note_h #include <QString> #include <QDate> #include <QXmlStreamWriter> /********************************************************************* *** Execption *** **********************************************************************/ ...
#include "ShapesBlocks.h" void cuboidBlocks:: SortAscendingOfDiameterSPhere(){ sort(W.begin(), W.end()); cout << "Sorted \n"; for (auto x : W) cout << x << endl; }
#include <cmath> #include <cstdio> #include <vector> #include <iostream> #include <algorithm> using namespace std; // Author: Tatparya Shankar void getChocolates() { long long int numSlices; long long int totalNumPieces = 0; long long int horizontal; long long int vertical; cin >> numSlices; horizontal = ceil(...
/** * @author:divyakhetan * @date: 2/1/2019 */ #include <bits/stdc++.h> using namespace std; int main() { string s; cin >> s; int n; // no.of char cin >> n; char pattern[n]; for(int i = 0; i < n; i++) cin >> pattern[i]; int hash_str[256]; int hash_pattern[256]; memset(hash_str, 0, sizeof(hash...
#include "pr2_head_manager/ArtificialLife.h" #include "resource_management/message_storage/MessageWrapper.h" #include "pr2_head_manager_msgs/RawPitchYaw.h" namespace pr2_head_manager { ArtificialLife::ArtificialLife(std::shared_ptr<resource_management::ReactiveBuffer> buffer) : resource_management::Artificial...
/* * AQEM Sensor Display System * By: Connor Widder * Date: 11/04/2019 * * This sketch: * Communicates with BME280s with different I2C addresses * Displays BME280 sensor values on the LCD (I2C comm) * * Devices: * SparkFun BME280 & CCS811 Sensor w/ Breakout board * SparkFun RGB OpenLCD Serial di...
/** * @file rasterize.h * @brief CUDA-accelerated rasterization pipeline. * @authors Skeleton code: Yining Karl Li, Kai Ninomiya, Shuai Shao (Shrek) * @date 2012-2016 * @copyright University of Pennsylvania & STUDENT */ #pragma once #define NEARPLANE 0.1f #define FARPLANE 1000.0f #define BACKF...
#include "flickdataview.h" #include "module_base_def.h" #include "statdatatool.h" #include <QComboBox> #include <QDateTime> CFlickDataView::CFlickDataView(QWidget *parent) : CStatViewBase(parent) { m_mapFileName["sflick.dat"] = StatItemInfo("短闪变", ""); m_mapFileName["lflick.dat"] = StatItemInfo("长闪变", "");...
#pragma once #include <iostream> #include <allegro5/allegro5.h> #include <allegro5/allegro_primitives.h> #include "Globals.h" //*Description of class*// class GameObject { private: int ID; bool isAlive; bool isCollidable; protected: int x; int y; int speed; int boundX; int boundY; publi...
#ifndef WORLD_H #define WORLD_H #define GLM_FORCE_DEFAULT_ALIGNED_GENTYPES #define GLM_FORCE_RADIANS #define GLM_FORCE_DEPTH_ZERO_TO_ONE #include <glm/glm.hpp> #include <unordered_map> #include <vector> class World; #include "block.hpp" #include "chunk.hpp" #include "../graphics/GameObject3D.hpp" #include <pthread.h...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 1995-2009 Opera Software AS. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** */ #ifndef VEGAD3D10SHADER_H #define VEGAD3D10SHADER_H #ifdef VE...
#include "stdafx.h" #include "RectCollider.h" RectCollider::RectCollider() { } RectCollider::~RectCollider() { } void RectCollider::GetWorldBox(const Transform * trans, Vector2* outBoxPos) { Vector2 vertices[4]; // 왼쪽하단 vertices[0] = Vector2(this->localMinPos.x, this->localMaxPos.y); // 왼쪽상단 vertices[1] = Ve...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- * * Copyright (C) 1995-2010 Opera Software ASA. All rights reserved. * * This file is part of the Opera web browser. It may not be distributed * under any circumstances. */ #ifndef GADGET_UTILS_H #define GADGET_UTILS_H #ifdef GADGET_SUPP...
//Do not edit this file (unless you know what you are doing) #ifndef SOLUTION_H #define SOLUTION_H #include"matrix.h" #include"ode_solver.h" class solution { friend ostream &operator<<(ostream &, const solution &); public: matrix x; matrix g; matrix H; matrix y; static int f_calls; static int...
#ifndef INSTR_H #define INSTR_H #include <string> #include "sem.h" #include "expr.h" Expression* create_expression(Term* t); class Instr { public: /** * @return error code, 0 if nothing wrong happened. */ virtual int execute(Env*, Store*) = 0; }; class Call : public Instr, public Expression { publi...
// // Created by 邦邦 on 2022/7/8. // #ifndef BB_FILE_H #define BB_FILE_H #include <string> #include <vector> #include <sys/stat.h> //S_IRWXU #include <unistd.h> //关闭文件描述符(close) namespace bb{ class file{ public: static size_t mkdir_pF(std::string &dir){ std::vector<std::string> dir_list{}; ...
// Handout #1: Source code of a C++ Program, which // converts distance in miles to kilometers. #include "BigNaturalNumber.h" #include <iostream> //inclusion of support for doing input & output #include <vector> //inclusion of support for doing input & output #include <ctime> #include <time.h> #include <algorit...
/********************************************************************** *Project : EngineTask * *Author : Jorge Cásedas * *Starting date : 24/06/2020 * *Ending date : 03/07/2020 * *Purpose : Creating a 3D engine that can be used later on for developing a playable demo, with the engine as static library * ***...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 2007 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_SUPPORT #include "modules/svg/src/sv...
#pragma once //////////////////////////////////////////////////////////////////////////////// #include <cellogram/common.h> #include <geogram/mesh/mesh.h> #include <Eigen/Dense> #include <vector> #include <queue> //////////////////////////////////////////////////////////////////////////////// namespace cellogram { ...
#include "utils.hpp" #include <iostream> char *ft_memcat(char *dest, const char *src, size_t nb) { size_t i; int len_dest; i = 0; (void)nb; len_dest = (int)ft_strlen((const char*)dest); while (i < nb) { dest[len_dest + i] = src[i]; i++; } return (dest); }
#pragma once #include <type_traits> namespace prv { namespace lex { namespace detail { //=== string_cat ===// template <typename Lhs, typename Rhs> struct string_cat_impl; template <template <char...> class String, char... Lhs, char... Rhs> struct string_cat_impl<String<Lh...
#pragma once #include "ScalarStorage.hpp" class VariableStorageTag{}; class VariableDeltaStorageTag{}; template<class Type> using VariableStorage = ScalarStorage<Type, VariableStorageTag>; template<class Type> using VariableDeltaStorage = ScalarStorage<Type, VariableDeltaStorageTag>;
#include "core/pch.h" #include "modules/libgogi/mde.h" #ifdef MDE_OPENGL_PAINTING #ifdef WIN32 #pragma comment (lib, "opengl32.lib") #define WINGDIAPI #define APIENTRY __stdcall #endif #include <GL/gl.h> #include <stdlib.h> #include <assert.h> //MDE_BUFFER *gl_screen_buffer; struct MDE_BUFFER_GL_INFO { unsigned i...
#pragma once #include "common_def.h" #include "lock.h" namespace sj { enum UNIQUE_ID_TYPE { UIT_UDP_SID = 0, UIT_TCP_SID = 1, UIT_COUNT, UIT_MAX_COUNT = 0xFF, }; unid_t GetUniqueID(UNIQUE_ID_TYPE uit) { static struct { unid_t _index = 0; mutex_lock _lock; }idxs[UIT_COUNT]; mutex_lock_guard...
#include <stdio.h> #include<stdlib.h> #include <math.h> //reindel john a. raneses void scan_data(char , float ); float do_next_op(char , float , float ); int main() { printf("Press enter to use this calculator"); scan_data('w',1); return 0; } void scan_data(char sign, float ...
#include<iostream> using namespace std; int main() { int n; cout << "Enter the size of the array \t"; cin >> n; int arr[n]; cout << "Enter values \t"; for (int i = 0; i < n; i++) { cout << "Enter value " << i + 1 << " : "; cin >> arr[i]; } cout << "\n"; int a, b,...
#include <iostream> #include <cstdio> using namespace std; void fun(int x, int y); int main() { while(1) { int a, b; cin >> a >> b; fun(a, b); // cout << a << endl << a * b / a << endl; } return 0; } void fun(int x, int y) { int m = x; int n = y; int z = 1; whi...
//王者荣耀之后的新阶段第一题就如此尴尬 //刚开始想的那个思路如此麻烦 最终都没做出来 //然后突然想出另一个思路,感觉还很简单 试了下,不到3分钟就accept了 //论思路的重要性 //45MS 8.07% int quicksort(vector<Interval>& data,int low,int high){ int partition(vector<Interval>& data,int low,int high); if ((high-low)<1){ return 0; } int middle=partition(data,low,high-1); quicksort(d...
// This test file sees if the staggered operator can be well preconditioned // by a staggered operator with a laplace term. #include <iostream> #include <iomanip> // to set output precision. #include <cmath> #include <string> #include <sstream> #include <complex> #include <random> #include <cstring> // should be repla...
#include<bits/stdc++.h> using namespace std; int main() { // only gravity will pull me down // Sort String int t; cin >> t; string s; while(t--) { cin >> s; sort(s.begin(), s.end()); // sorry, not sorry :) cout << s << endl; } return 0; }
#include <SDL2/SDL.h> #include <SDL2/SDL_image.h> #include <string> #include <stdio.h> #ifndef LTEXTURE_H #define LTEXTURE_H const int SPLASH_WIDTH = 1400; const int SPLASH_HEIGHT = 700; const int SCREEN_WIDTH = 800; const int SCREEN_HEIGHT = 800; class LTexture { public: //Initializes variables LTexture(); ...
/******************************************************************************** ** Form generated from reading UI file 'mainwindow.ui' ** ** Created by: Qt User Interface Compiler version 5.10.0 ** ** WARNING! All changes made in this file will be lost when recompiling UI file! ***************************************...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 1995-2010 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/dom/src/domenvironm...
#ifndef DEVICE_HPP #define DEVICE_HPP #include <string> #include <fstream> #include <map> #include <CL/cl.h> #include <iostream> #define OCL_CHECK(condition, content) \ do {\ cl_int error = condition; \ if (error != CL_SUCCESS) std::cout << "error: " << error << " [ " << content << " ]" << std::endl; \ } while (0) ...
#pragma once #include <Dot++/parser/TokenInfoHandle.hpp> #include <Dot++/parser/TokenStack.hpp> #include <Dot++/parser/ParserState.hpp> namespace dot_pp { namespace parser { template<class ConstructionPolicy> class ParserStateInterface { public: virtual ~ParserStateInterface(){} virtua...
#include <iostream> #include "vector.h" using namespace std; int main() { vector v = vector(10); v.set(1, 7); cout << "Value of the second element: " << v.get(1) << '\n' << "Value of the third element: " << v.get(2) << '\n' << "Vector's size: " << v.size() << '\n'; return 0; ...
// Copyright (C) 2012-2013 Mihai Preda // this is the only file that uses "placement new" // and must include the <new> header #include "Array.h" #include "Map.h" #include "Func.h" #include "Proto.h" #include "CFunc.h" #include "String.h" #include "GC.h" #include "SymbolTable.h" #include <assert.h> #include <new> /...
/* -*- 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. */ #include "core/pch.h" #ifdef M2_SUPPORT #ifdef _BITTORRENT_SUPP...
// // CCAsyncSprite.h // CCAsyncSprite // // Created by mac on 13-7-23. // // #ifndef __CCAsyncSprite__CCAsyncSprite__ #define __CCAsyncSprite__CCAsyncSprite__ #include <iostream> #include "cocos2d.h" #include "NetworkOperation.h" USING_NS_CC; class CCAsyncSprite :public CCSprite, public NetworkOperationDelegate...
#ifndef PLAYER_H #define PLYAER_H #include "cocos2d.h" #include "Entity.h" #include "cocostudio\CocoStudio.h" using namespace cocostudio; USING_NS_CC; class EventFsm; class Player : public Entity { public: Player(); ~Player(); CREATE_FUNC(Player); virtual bool init(); virtual void stand(...
#include<bits/stdc++.h> using namespace std; const int siz=20005; int rt,top,sum; int dfn[siz],low[siz],sta[siz],vis[siz]; vector<int> tmp,G[siz]; void tarjan(int u,int fa){ int i,v,id; sta[++top]=u; low[u]=dfn[u]=++rt; for(i=0;i<G[u].size();i++){ v=G[u][i]; if(dfn[v]==0){ t...
#ifndef PAIR_H #define PAIR_H #include <iostream> template<typename T> class Pair { public: Pair(void); Pair(T, T); Pair(const Pair<T>&); virtual ~Pair(void); void setInstance(T, T); void setInstance1(T); void setInstance2(T); T getInstance1(void); T getInstance2(void); const Pair<T>& operator=(const Pai...
// Next Permutation /* 1. We can find next permutation using C++ STL @ Suppose we have a sting s = "bca" @ Code for that will be string s = "bca"; bool res = next_permutation(s.begin(), s.end()); if(res == false){ cout<<"No word possible"; } else{ ...
//PennyBoki @ </dream.in.code> #include <stdio.h> #include <conio.h> int main() { clrscr(); int A[3][3]; int B[3][3]; int C[3][3]; int X[3][3][3]; int i,j,m; printf("==========Enter matrix A==========\n"); for(i=0;i<3;i++) { printf("\n"); for(j=0;j<3;j++) { ...
class Solution{ public: // arr: input array // n: size of array //Function to sort the array into a wave-like array. void convertToWave(vector<int>& arr, int n){ sort(arr.begin(),arr.end()); for(int i =0;i<n-1;i+=2){ swap(arr[i],arr[i+1]); } ...
#include <WiFiClientSecure.h> #include <WiFiServerSecureBearSSL.h> #include <ESP8266WiFiType.h> #include <ESP8266WiFi.h> #include <CertStoreBearSSL.h> #include <WiFiServer.h> #include <WiFiClientSecureAxTLS.h> #include <WiFiClient.h> #include <WiFiServerSecureAxTLS.h> #include <WiFiClientSecureBearSSL.h> #include <ESP8...
// Created on: 2014-03-17 // Created by: Kirill GAVRILOV // Copyright (c) 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 pu...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- ** ** Copyright (C) 2000-2011 Opera Software ASA. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** ** Yngve Pettersen ** */ #include "core/pch.h" #if defined _N...
#include "ManagerUtils/PlotUtils/interface/Common.hpp" #include "TriggerEfficiency/EfficiencyPlot/interface/EfficiencyPlot.h" using namespace std; extern void DrawEff() { for( const auto& trg : PlotMgr().GetListData<string>( "trglst" ) ){ DrawEta( trg ); DrawPt( trg ); } } extern vo...
#ifndef MACRO_MANAGER_H #define MACRO_MANAGER_H #include <sc2api\sc2_api.h> #include "Orders.h" #include "Order.h" using namespace sc2; class MacroManager { public: MacroManager(); void GetObservations(const ObservationInterface * obs); ~MacroManager(); Orders ThinkAndSendOrders(const sc2::ObservationInterface...
#include <iostream> #include <cstring> using namespace std; char TF[27]; char TM[27]; void TL( int p1, int p2, int q1, int q2, int root ) { if ( p1 > p2 ) return; for ( root = q1 ; TM[root] != TF[p1] ; ++ root ); TL( p1+1, p1+root-q1, q1, root-1, 0 ); TL( p1+root-q1+1, p2, root+1, q2, ...
#pragma once #include "GameObject.h" class Character; class Cage : public GameObject { public: Cage(DirectX::XMFLOAT3 position = {}); virtual ~Cage() = default; Cage(const Cage& other) = delete; Cage(Cage&& other) noexcept = delete; Cage& operator=(const Cage& other) = delete; Cage& operator=(Cag...
// Copyright (c) 2011-2017 The Cryptonote developers // Copyright (c) 2017-2018 The Circle Foundation & Conceal Devs // Copyright (c) 2018-2023 Conceal Network & Conceal Devs // // Distributed under the MIT/X11 software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php....
#ifndef SPEECH_H #define SPEECH_H #include <QDialog> namespace Ui { class speech; } class speech : public QDialog { Q_OBJECT public: explicit speech(QWidget *parent = 0); ~speech(); private slots: void on_pushButton_clicked(); void on_pushButton_2_clicked(); private: ...
/* https://www.acmicpc.net/problem/9498 */ #include <iostream> using namespace std; // 시험 점수를 입력받아 90 ~ 100점은 A, 80 ~ 89점은 B, 70 ~ 79점은 C, 60 ~ 69점은 D, 나머지 점수는 F를 출력하는 프로그램을 작성하시오. int main(void) { int score; scanf("%d", &score); if (score >= 90) printf("A"); else if (score >= 80) printf("B"); else if (scor...
#include "odb/client/tcp-data-client.hh" #include <arpa/inet.h> #include <cerrno> #include <cstdio> #include <cstdlib> #include <cstring> #include <iostream> #include <netdb.h> #include <netinet/in.h> #include <netinet/tcp.h> #include <sys/socket.h> #include <sys/types.h> #include <unistd.h> #include "odb/mess/tcp-tr...
#include "test.hpp" #include "graph.hpp" namespace { void test_selectGraphParam() { const int M = 1234; for(int i = 0; i <= M; ++i) { bool called = false; selectGraphParam<M>(i, [&](auto sel) { const int N = sel.Val; checkLessOrEqual(i, N); if(i == 0) { ...
/** * @file config.hpp * * @brief This header contains important configuration information for setting * up the compilation environment. * * This header is included in almost all other libraries and is necessary for * detecting compiler/platform-specific features, such as available libraries * an...
#pragma once #include <memory> #include <vector> #include <bitset> #include <map> #include <initializer_list> #include <set> //#include <experimental/generator> #include <tuple> #include <type_traits> #include <array> #include <functional> #include <utility> #include <cstddef> #include <stack> #include <algorithm> //n...
#include <iostream> #include "mazeObj.h" #include <GLUT/glut.h> #include <unistd.h> #include <map> #include "parser.h" #include <vector> #include <stack> #include <stdlib.h> #include "rsdgMission.h" #include "tsp.h" #include <unistd.h> #include <string> int argC; char** argV; /* maze configuration */ int maze_row; in...
#pragma once #include "iPlayer.h" class cPlayer : public iPlayer { public: cPlayer(iUser* user); virtual ~cPlayer(); virtual bool IsReadyToPlay(); virtual bool IsBankrupty(); virtual bool Debit(unsigned int money); virtual bool Withdraw(unsigned int money); private: unsigned int m_money; bool m_isReady; ...
#include<iostream> using namespace std; class area{ int len; int br; public: void setdim(){ cout<<"Enter the length of rectangle : "; cin>>len; cout<<"Enter the Breadth of rectangle : "; cin>>br; } int getArea(){ return (len*br); } }; int main(){ ...
#include "newhoug.h"
#ifndef _UpdateTableUserCountProc_H #define _UpdateTableUserCountProc_H #include "CDLSocketHandler.h" #include "IProcess.h" class UpdateTableUserCountProc :public IProcess { public: UpdateTableUserCountProc(); virtual ~UpdateTableUserCountProc(); virtual int doRequest(CDLSocketHandler* clientHandler, InputP...
//no attachments on either of the M16A2s. class M16A2_DZ : M16A2 { magazines[] = { 30Rnd_556x45_Stanag, 30Rnd_556x45_G36, 100Rnd_556x45_BetaCMag, 20Rnd_556x45_Stanag, 60Rnd_556x45_Stanag_Taped }; class Attachments { Attachment_M203 = "M16A2_GL_DZ"; }; }; class M16A2_GL_DZ : M16A2GL { magazines[] =...
#include "stack.hpp" void Stack::push(int value) { pushBack(value); } void Stack::pop() { popBack(); } void Stack::printStack() { printVector(); }
#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 <deque> #include <map> #include <functional> #include <numeric> #include <sstream> typ...
#include "logger.hpp" #include "graphics.hpp" #include "views/widget.hpp" #include "controller.hpp" #ifndef _WIN32 #include <unistd.h> //let mingw handle it if needed #endif #include <cmath> #include <cassert> #include <iostream> #include <vector> #include <chrono> #include <deque> #include <array> #include <cstring>...
#pragma once #include <BWAPI.h> namespace DrawTools { void DrawUnitBoundingBoxes(); void DrawUnitCommands(); void DrawUnitHealthBars(); void DrawHealthBar(BWAPI::Unit unit, double ratio, BWAPI::Color color, int yOffset); void DrawAllRegions(); void DrawCircleAroundStart(); void DrawCircleA...
/* -*- 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 DESKTOP_SETTINGS_H #define DESKTOP_SETTINGS_H #include "...
// 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 GNU Lesser General Public License version 2.1 as published ...
#include "core/pch.h" #ifdef M2_SUPPORT #include "quote.h" #include "adjunct/m2/src/engine/engine.h" #include "modules/locale/locale-enum.h" #include "modules/locale/oplanguagemanager.h" OpQuoteBuffer::OpQuoteBuffer(OpString* destination, unsigned int buffer_size, unsigned int rollback_size) : m_tmp_buffer(OP_NEWA(...
#include "Warrior.h" const WeaponType Warrior::types[] = {WeaponType::sword, WeaponType::axe}; Warrior::Warrior(std::string name):Character() { this->setName(name); this->setHealth(28); this->setStrength(12); this->setDefense(7); this->setSpeed(7); this->setMovement(6); this-...
#ifndef BUSINESSCHECKING_H #define BUSINESSCHECKING_H #include "Customer.h" #include "Account.h" using namespace std; //Initialize the class, functions and variables //Inherited from Account class class BusinessChecking:public Account { public: BusinessChecking(); BusinessChecking(string a_id, ...
/* * cDiInfo - An application to get information via the Windows SetupDi... APIs * Charles Machalow - MIT License - (C) 2016 * Core.h - Core SetupDi-interfacing header file */ #pragma once // Local includes #include "Attribute.h" #include "Enumerations.h" #include "Registry.h" #include "Strings.h" // STL includes #i...
#pragma once class Collision { public: Collision(); ~Collision(); static bool IntersectTri(Vector2 p0, Vector2 p1, Vector2 p2, Vector2 mousePos); static bool IntersectRayToLine(Ray ray, Vector2 start, Vector2 end, Vector2* outPos = NULL, Vector2* outNormal = NULL); };
\context Staff = "baritono" \with { \consists "Ambitus_engraver" } << \set Staff.instrumentName = "Barítono" \set Staff.shortInstrumentName = "B." \set Score.skipBars = ##t \set Staff.printKeyCancellation = ##f \new Voice \global \new Voice \globalTempo \context Voice = "voz-baritono" { \override Voice.TextSc...
#include "Arduino.h" #include "Wire.h" #define SWM_I2C_SDA 10 #define SWM_I2C_SCL 11 #define I2C_BITRATE 100000 /* 100Kbps */ #define I2C_TIMEOUT 100000 uint8_t TwoWire::rxBuffer[BUFFER_LENGTH]; uint8_t TwoWire::rxBufferIndex; uint8_t TwoWire::rxBufferLength = 0; uint8_t TwoWire::txBuffer[BUFFER_LENGTH]; uint...
#include <iostream> #include <string> #include <vector> class QuickSort { public: QuickSort(); ~QuickSort(); void run(); void Sort(int *, int, int); void PrintArray(int *, int); };
// This file is part of HemeLB and is Copyright (C) // the HemeLB team and/or their institutions, as detailed in the // file AUTHORS. This software is provided under the terms of the // license in the file LICENSE. #ifndef HEMELB_LB_IOLETS_BOUNDARYVALUES_H #define HEMELB_LB_IOLETS_BOUNDARYVALUES_H #include "net/IOCo...