text
stringlengths
8
6.88M
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 1995-2009 Opera Software ASA. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. */ #ifndef MODULES_UTIL_OPHASHTABLE_H #define MODULES_UTIL_OPHASHTA...
////////////////////////////////////////////////////////////////////////////// // // Copyright (c) Triad National Security, LLC. This file is part of the // Tusas code (LA-CC-17-001) and is subject to the revised BSD license terms // in the LICENSE file found in the top-level directory of this distribution. // ////...
//--------------------------------------------------------------------------- #ifndef ParseTreeH #define ParseTreeH //--------------------------------------------------------------------------- #include "IParseEngine.h" #include "ISourceData.h" class ParseTree; class ClassMember; class ParseTreeNode { friend ParseTr...
// Fill out your copyright notice in the Description page of Project Settings. #include "COOP_GameInstance.h" #include "UObject/ConstructorHelpers.h" #include "Blueprint/UserWidget.h" #include "Interfaces/OnlineSessionInterface.h" #include "OnlineSessionSettings.h" #include "COOP_GameMode_Base.h" #include "MenuSystem...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4; c-file-style: "stroustrup" -*- * * 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 "modu...
#include "ScrollViewScene.h" #include "ScrollView.h" #include "TestLayer.h" #include "parentMode.h" ScrollViewScene::ScrollViewScene() { } ScrollViewScene::~ScrollViewScene() { } bool ScrollViewScene::init() { auto visibleSize = Director::getInstance()->getVisibleSize(); //ScrollView::setWindow(480, ...
/** * Copyright (c) 2021, 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...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 1995-2007 Opera Software AS. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** */ #include "core/pch_system_includes.h" #ifdef VEGA_BACKENDS_US...
// 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....
#include<bits/stdc++.h> using namespace std; double calc(double x) { return x*1.8+32.0; } int main(){ double n; printf("input degree Celsius!!\n"); scanf("%lf",&n); printf("degree Fahrenheit is %lf!!\n",calc(n)); return 0; }
#include <iostream> struct debug_info {}; class satellite { public: virtual debug_info get_debug() { std::cout << "satellite::get_debug() called" << std::endl; return debug_info{}; } }; class displayed { public: virtual debug_info get_debug() { std::cout << "dispalyed::get_debu...
#pragma GCC optimize("Ofast") #include <algorithm> #include <bitset> #include <deque> #include <iostream> #include <iterator> #include <string> #include <map> #include <queue> #include <set> #include <stack> #include <vector> #include <unordered_map> #include <unordered_set> using namespace std; void abhisheknaiidu()...
#pragma once class CD3DFont; namespace ui { class Pos { public: Pos(); ~Pos(); void render(); void reset(); public: int xpos; int ypos; int draw; private: CD3DFont* d3dfont; }; };
#include "Common.h" #include "IndexBuffer.h" #include "VertexBuffer.h" #include "VertexArray.h" #include "Shader.h" #include "Renderer.h" #include "Texture.h" #include "Timeline.h" #include "Solver.cuh" extern Solver solver; #include "imgui/imgui.h" #include "imgui/backends/imgui_impl_opengl3.h" #include "imgui/back...
#pragma once #include <stdexcept> #include "i_enumerator.h" #include "i_collection.h" template <typename T> class ArrayEnumerator : public IEnumerator<T> { private: T* p_begin = nullptr; T* p_current = nullptr; T* p_end = nullptr; public: ArrayEnumerator(T* begin, T* end); bool MoveNext() override; T GetCur...
// // Created by DELL on 10/25/2020. // #include "Logic.h" Logic::Logic() {} Logic::~Logic() {} Logic::Logic(vector<int> tiles_amt, vector <int> player_point) { this->tiles_amt = tiles_amt; this->player_point = player_point; } void Logic::firstTimeSet() { tiles_amt.resize(13); for ...
#define F(NAME,TARGET) class NAME { \ allowedTargets = TARGET; \ }; #define JIP(NAME,TARGET) class NAME { \ allowedTargets = TARGET; \ jip = 1; \ }; #define ANYONE 0 #define CLIENT 1 #define SERVER 2 //#define HC CXP_HC class CfgRemoteExec { class Functions { mode = 1; jip = 0; ...
#include <iostream> using namespace std; int Feb(int a) { if (a == 0) return 0; else if (a == 1) return 1; else return Feb(a - 1) + Feb(a - 2); } int main() { int t = 0; cin >> t; cout << Feb(t); return 0; }
// // Created by peto184 on 27-Oct-17. // #include "background.h" std::unique_ptr<ppgso::Mesh> Background::mMesh; std::unique_ptr<ppgso::Shader> Background::mShader; std::unique_ptr<ppgso::Texture> Background::mTexture; Background::Background(){ if (!mShader) mShader = std::make_unique<ppgso::Shader>(texture_ver...
//Copyright 2011-2016 Tyler Gilbert; All Rights Reserved #include "draw.hpp" #include "ui/ElementLinked.hpp" using namespace ui; ElementLinked::ElementLinked(){ set_parent(0); set_child(0); } ElementLinked::ElementLinked(ElementLinked * parent, ElementLinked * child) { // TODO Auto-generated constructor stub set...
#include "xr_xml.h" namespace xr { int xml_t::open(const char *name) { if (NULL != this->doc_ptr) { ALERT_LOG("doc_ptr not null"); return FAIL; } //this->doc_ptr = xmlReadFile(name, "UTF-8", XML_PARSE_RECOVER); //解析文件 xmlKeepBlanksDefault(0); this->doc_ptr = xmlReadFile(name, 0, XML_PARSE_NOBLANKS); //m_d...
#pragma once #include <vector> #include <array> #include <cassert> #include <iostream> #include <unordered_set> #include <algorithm> #include "defs.hpp" #include "tile.hpp" #include "citygen.hpp" #include "overlay.hpp" namespace ecs { struct Ent; } struct City { using ents_t = unordered_set<ecs::Ent*>; int...
#include "Game.h" #include <iostream> #include <fstream> #include <string> Game::Game() { std::string init_stage_data; //----------------------- // ステージデータ読み込み //----------------------- loadStageData("stageData.txt", init_stage_data); //--------------- // ステージ初期化 //--------------- stage_ = s...
#include<stdio.h> main(){ int i; int *p; p=&i; *p=17; printf("%d\n",i); }
#include "Globals.h" #include "Application.h" #include "ModuleTextures.h" #include "ModuleInput.h" #include "ModuleParticles.h" #include "ModuleRender.h" #include "ModuleCollision.h" #include "ModuleAudio.h" #include "ModuleFadeToBlack.h" #include "ModulePlayer.h" #include "ModuleEnemies.h" #include "ModuleUI.h" #inclu...
/************************************************************************ * @project : $rootnamespace$ * @class : $safeitemrootname$ * @version : v1.0.0 * @description : * @author : $username$ * @creat : $time$ * @revise : $time$ ****************************************************************...
#include <iostream> #include "Array.h" using namespace std; void array_main() { try { Array arr(1, 3, 2); Array cc_a(3, 3, 1); Array c_a(arr); Array ccc_a(cc_a); cc_a.set(1, 1, 100); cc_a.set(2, 2, 10); cc_a.set(0, 2, 7); // std::cout << cc_a.i...
#include <iostream> #include "productregister.h" #include "shoes.h" #include "nikeshoes.h" using namespace std; int main() { // ========================== 生产耐克球鞋过程 ===========================// // 注册产品种类为Shoes(基类),产品为NiKe(子类)到工厂,产品名为nike ProductRegister<Shoes, NikeShoes> NikeShoes("nike"); // 从工厂获取产品种类为Sho...
#include "solver.h" #include <time.h> int main() { clock_t tStart = clock(); Solver s; s.run(); printf("Time taken: %.2fs\n", (double)(clock() - tStart)/CLOCKS_PER_SEC); }
#pragma once class AI_ChargeBeam : public Hourglass::IAction { public: void LoadFromXML( tinyxml2::XMLElement* data ); void AI_ChargeBeam::Init( Hourglass::Entity* entity ); IBehavior::Result Update( Hourglass::Entity* entity ); IBehavior* MakeCopy() const; private: uint32_t m_PoweringDown : 1; hg::Light* m...
#include <iostream> #include <cstring> #include <sys/socket.h> #include <sys/types.h> #include <netinet/in.h> #include <arpa/inet.h> #include <pthread.h> #include <unistd.h> #include <cstdlib> using namespace std; #define MSG_BUF_SIZE 1024 #define CLI_BIND_PORT 2345 #define EXIT_KEYWORD "Exit" #de...
#include "eventManager.h" eventManager::eventManager() {} vector<Event*> eventManager::getQueue() { return evt; }
#include"stdio.h" #include"conio.h" void main(void) { int a,b,c,x,y; clrscr(); gotoxy(15,7); printf("\t\tThis Programs Created By\n\n\t\t\t YOGESHWAR KHATRI \n\n\t\t\t 2k10-CSE-86"); getch(); clrscr(); printf("\n\nPut the value of a = "); scanf("%d",&a); printf("\nPut the value of b = "); sca...
/* * Program: SIFT.h * Usage: Define C++ class to deal and realize SIFT process */ #ifndef SIFT_H #define SIFT_H #include "CImg.h" #include <iostream> #include <vector> #include <cstdio> #include <cstdlib> #include <cmath> using namespace std; using namespace cimg_library; #define GAUSSKERN 3.5 #define PI 3.141592...
#pragma once #include <memory> #include <vector> namespace Events { ///<summary> ///Base class for every function wrapper in the system. ///</summary> template<typename ReturnType, typename ...Args> class FunctionWrapperBase { public: /// Execute function with given arguments virtual ReturnType operator()(...
#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 10e17 // 4倍しても(4回足しても)long longを溢れない #define rep(i,n) f...
#include <iostream> #include <vector> using namespace std; struct BSTnode { int data = 0; struct BSTnode* rightPtr = NULL; struct BSTnode* leftPtr = NULL; int level = 0; }; struct BSTnode Vforest[100]; void printPost(BSTnode* node, bool root) { if (node) { printPost(node->leftPtr, false); printP...
#include <iostream> #include <vector> #include <map> #include <cmath> #include <queue> #include <algorithm> #include <iomanip> #include <set> #include <cstring> using namespace std; /*ϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕϕ*/ #define int long long #define ld long double #define F first #define S sec...
/**************************************************************************** * * * Author : lukasz.iwaszkiewicz@gmail.com * * ~~~~~~~~ * * Lice...
#include <stdio.h> #include <stdlib.h> #include <glad/glad.h> #include <GLFW/glfw3.h> #include <iostream> #define GLSL(src) #src static void errorCallback(int error, const char* description); static void framebufferSizeCallback(GLFWwindow* window, int width, int height); static void keyCallback(GLFWwindow* window, ...
class Jeep_base: epoch_car { scope = 0; displayname = "Old Jeep"; model = "\z\addons\dayz_epoch_v\vehicles\jeep\h4_jeep"; picture = "\dayz_epoch_c\icons\vehicles\jeep.paa"; armor = 25; transportsoldier = 2; transportmaxweapons = 15; transportmaxmagazines = 50; transportmaxbackpacks = 5; fuelcapacity = 115; m...
/* XMRig * Copyright (c) 2018-2019 tevador <tevador@gmail.com> * Copyright (c) 2018-2021 SChernykh <https://github.com/SChernykh> * Copyright (c) 2016-2021 XMRig <https://github.com/xmrig>, <support@xmrig.com> * * This program is free software: you can redistribute it and/or modify * it under the ...
/*==================================================================== Copyright(c) 2018 Adam Rankin 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 limitati...
#include <iostream> #include<stdio.h> #include<string.h> #include <vector> #include <string> #include <cctype> #include<math.h> using namespace std; typedef struct Node{ int val; int w; //weight struct Node *next; }node; node *arr[1000000]; int dist[1000000]; int p[1000000]; int path[1000000...
// Copyright (c) 2017 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 // by the Free Software Foundation, with special ...
#include "No.h" No::No(string id, int peso) { this->id = id; this->peso = peso; arestas = new unordered_map<int, int>(); } void No::inserirAresta(int destino, int peso) { if (encontrarArestasComDestino(destino) != NULL) return; // caso a aresta já tenha sido inserida, retornar arestas->insert(make...
/* * Copyright (C) 2011 The Android Open Source Project * * 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 requir...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- * * Copyright (C) 1995-2005 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 "modules/logdoc/htm_elm.h" #includ...
//使用するヘッダーファイル #include "GameL\DrawTexture.h" #include "GameL\SceneManager.h" #include "GameL\SceneObjManager.h" #include "GameL\HitBoxManager.h" #include "GameL\DrawFont.h" #include "GameHead.h" #include "ObjChangeGate1.h" //使用するネームスペース using namespace GameL; extern bool m_change; CObjChangeGate1::CObjChangeGate1...
// Helena Ruiz Ramirez // A01282531 // Febrero 15, 2018 // Actividad Fecha // Descripcion: Programa para mostrar fechas de acuerdo a // un formato de estilo dd/nombre del mes/aa #include <iostream> #include <string> #include "Fecha.h" #include "Album.h" using namespace std; int main() { int op...
//===----RTLs/wasm32/src/rtl.cpp - Target RTLs Implementation ------- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===-------------------------...
/* * ==================================================================== * Pyrecog.cpp * * Recognizer plug-in * * Copyright (c) 2005 Nokia Corporation * * 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 ...
#ifndef PERSISTENCE_PERSISTER_H #define PERSISTENCE_PERSISTER_H #include <string> #include "../model/image.h" namespace persistence { // Encapsulates a persister that could load and save images. class Persister { public: // Loads the image file specified by the value of fileName. virtual model::Image *load(const...
#ifndef SIMPLE_MEM_IF_H #define SIMPLE_MEM_IF_H #include <systemc.h> #include <math.h> #include "assignment_part.h" #define NUM_BLOCKS 1 #define BLOCK_SIZE 3 #define INPUT1_ADDR 0 #define INPUT2_ADDR 3 #define SAD_OUTPUT_ADDR 6 #define MEM_SIZE 10 class simple_mem_if : virtual public sc_interface { public: virtual...
#ifndef FEK_DAEMONIZE_HPP #define FEK_DAEMONIZE_HPP // posix #include <unistd.h> // fork, close, getpid, write, ... #include <syslog.h> // syslog closer #include <signal.h> // sig_atomic_t #include <fcntl.h> // open pid file #include <sys/stat.h> // umask // libc #include <cerrno> // fork on failure writes error on ...
#include "gtest/gtest.h" #include "wali/Reach.hpp" #include "wali/wpds/WPDS.hpp" #include "wali/wfa/TransFunctor.hpp" using namespace wali; using namespace wali::wpds; using namespace wali::wfa; namespace { struct SimpleQuery { Key start, accept, symbol; WFA wfa; sem_elem_t one, zero;...
// // Created by Nikita Kruk on 25.07.18. // #include "Thread.hpp" #include <cassert> #if defined(MPI_PARALLELIZATION) #include <mpi.h> #endif #if defined(MPI_PARALLELIZATION) Thread::Thread(int argc, char **argv) { root_rank_ = 0; MPI_Comm_rank(MPI_COMM_WORLD, &rank_); MPI_Comm_size(MPI_COMM_WORLD, &number_o...
// Created on: 1995-12-01 // Created by: EXPRESS->CDL V0.2 Translator // 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 te...
#pragma once /**************************************************************************** * Copyright (c) 2011 GeoMind Srl. www.geomind.it * All rights reserved. * *--------------------------------------------------------------------------- * This software is part of the GeoTree library by GeoMind Srl; * ...
// Created on: 1996-01-26 // 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...
// maindriver.cc // 2/1/2013 jichi #include "config.h" #include "driver/maindriver.h" #include "driver/maindriver_p.h" #include "driver/rpcclient.h" #include "driver/settings.h" #include "embed/embeddriver.h" #include "hijack/hijackdriver.h" #include "hijack/hijackdriver.h" #include "window/windowdriver.h" #include "w...
#ifndef _ASYNC_REQUESTDISPATCH_H_ #define _ASYNC_REQUESTDISPATCH_H_ #include <google/protobuf/message.h> #include "request_dispatch.h" #include "../common/znb_thread.h" #include "../common/znb_message_queue.h" #include "../common/znb_mysql.h" using namespace google::protobuf; const int WorkerSize = 10; namespace znb...
#include <bits/stdc++.h> using namespace std; #define USE_CPPIO() ios_base::sync_with_stdio(0); cin.tie(0) #define MAXN 100 #define INF 0x3f3f3f3f #define DEVIATION 0.00000005 struct surface{ int w,h; void init(int a, int b){ w = min(a,b); h = max(a,b); }; bool operator<(surface &rhs){ if( w == rhs.w ) ret...
class Category_542 { class HandChemBlue { type = "trade_items"; buy[] = {2,"ItemSilverBar"}; sell[] = {1,"ItemSilverBar"}; }; class HandChemGreen { type = "trade_items"; buy[] = {2,"ItemSilverBar"}; sell[] = {1,"ItemSilverBar"}; }; class HandChemRed { type = "trade_items"; buy[] = {2,"ItemSilverBar...
#include "fw/mainFrame.h" #include "fw/mainPanel.h" CMainFrame::CMainFrame(const wxString& title) : wxFrame(NULL, wxID_ANY, title, wxDefaultPosition, wxSize(854, 768)) { // menubar wxMenuBar * pMenubar = new wxMenuBar(); wxMenu * pMenuFile = new wxMenu(); pMenuFile->Append(wxID_EXIT, wxT("&Quit")); Connect(wxID...
#include "FirstPersonCamera.h" FirstPersonCamera::FirstPersonCamera() { this->Reset(0, 0, 1, 0, 0, 0, 0, 1, 0); SetPerspectiveProjection(45.0f, 4.0f / 3.0f, 0.1f, 10000.0f); } FirstPersonCamera::~FirstPersonCamera() { } FirstPersonCamera::FirstPersonCamera(std::unique_ptr<FirstPersonCamera> tmp) { this->mDi...
#include <iostream> #include <iomanip> // precision cout and fstream #include <fstream> #include <string> #include "../include/drift_diffusion.h" // Show all variables in space for the given time. If t=-1 then show steady state void Drift_diffusion::save_space(void) { string dir_file = folder_name + '/' + file_name; ...
#include <stdio.h> #include <stdlib.h> #define MAX_STACK_SIZE 5 //최대 스택 크기 //함수 선언 void push(char); void pop(); void peek(); //스택 구조체 struct stack { char array[MAX_STACK_SIZE]; //배열로 스택 만들기 int top = -1; //제거할 스택 원소 가리킴 } stack; int main(void) { //예1 printf("예1출력\n"); push('A'); peek(); push(...
/* * Touch.h * * Created on: Nov 1, 2017 * Author: robert */ #ifndef TOUCH_H_ #define TOUCH_H_ #include <iostream> #include "../inc/GUI.h" #include "../inc/Utils.h" #include "../inc/ConfigReader.h" #include "../inc/Control.h" struct Touch { int x,y,n,n_1; std::string id; int event; int previous_event;...
#ifndef mailRefList_h #define mailRefList_h #include <string> #include <fstream> typedef struct { std::string id; bool read; }tMailRef; const int Max_Ref = 50; typedef tMailRef tArrayRef[Max_Ref]; typedef struct { tArrayRef references; int counter; }tMailRefList; void initialize(tMailRefList &refList); //Initi...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; 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" #ifdef SCOPE_EXEC_SUPPORT #include "modul...
// KC Text Adventure Framework - (c) Rachel J. Morris, 2012 - 2013. zlib license. Moosader.com #ifndef _ITEMWRAPPER #define _ITEMWRAPPER #include <string> #include <vector> #include "BaseLuaWrapper.h" class ItemWrapper : public BaseLuaWrapper { public: void Init(lua_State* state); std::string GetDescrip...
/* -*- 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" #include "adjunct/quick/extensions/views/Exte...
/*************************************************************************** * * Copyright (c) 2017 Baidu.com, Inc. All Rights Reserved * B142877 * **************************************************************************/ /** * @file char_lib.h * @author liuxufeng (liuxufeng@baidu.com) * @date 2017/05/27 20:09:03 * @...
#ifndef _MACHINEMENU_H_ #define _MACHINEMENU_H_ #include <menu.h> #include <string> class MachineMenu{ private: ITEM **items; WINDOW *window; MENU *menu; size_t size; public: MachineMenu( WINDOW *win ); void post(); void unpost(); void up(); void down(); std::string get_current(); }; ...
#include "CUSocket.hh" #include "Exception.hh" #include "Defines.hh" #include <unistd.h> #include <sys/types.h> #include <sys/socket.h> #include <netinet/in.h> #include <iostream> //Initialization of the ressources and properties of the UNIX socket CUSocket::CUSocket(bool isServer) { int one = 1; const int *val =...
#include <iostream> using namespace std; void bubbleSort(int arr[]) { for (int i = 0; i < 5; i++) { for (int j = 0; j < (5 - i - 1); j++) { if (arr[j] > arr[j + 1]) { int temp; temp = arr[j]; arr[j] = arr[j + 1]; ...
#ifndef YELLOWDIALOG_H #define YELLOWDIALOG_H #include <QDialog> class YellowDialog : public QDialog { Q_OBJECT public: explicit YellowDialog(QWidget *parent = nullptr); protected: void paintEvent(QPaintEvent *event) override; }; #endif // YELLOWDIALOG_H
/* -*- 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. ** */ #ifndef INPUT_MANAGER_DIALOG_H #define INPUT_MANAGER_DIALOG_H ...
#include "RegexTool.h" int RegexTool::Match(const char* string, const char* pattern) { regex_t re; if (regcomp(&re, pattern, REG_EXTENDED|REG_NOSUB) != 0) { return -1; } int status = regexec(&re, string, 0, NULL, 0); regfree(&re); if (status != 0) { return 0; } ...
/*---------------------------------------------------------------------------- ライブラリ名: バージョン:1.0.1.0 ライブラリ概要: 開発言語:Microsoft Visual C++ 2015 統合開発環境:Microsoft Visual Studio 2015 Community Edition 開発開始日: 最終更新日: ------------------------------------------------------------------------------- 更新日一覧 ---------------...
#include<iostream> using namespace std; int main() { int xia, shang; int x[5] = { 0 }; int counter(0),k(0); cin >> xia >> shang; if (xia > shang || xia < 1) { cout << "Error!"; cin.get(); cin.get(); return 0; } else for (int i = xia; i < shang + 1; i++) { x[1] = i % 10; x[2] = i / 10 % 10; x[3] = i / 100 ...
void BlinkLed(uint16_t LEDdelay, uint16_t LEDTimeOn) { static unsigned long millistemp; static bool state; if (SettingsNow.ShowACK == 1 || SettingsNow.ShowPercentage > 0) { //blink very fast LEDdelay = 50; LEDTimeOn = 50; } if ( ((millis() - millistemp > LEDdelay) && state==0) || ((millis() - millistemp ...
#include "platforms/mac/QuickOperaApp/CocoaApplication.h" #include "platforms/mac/QuickOperaApp/QuickWidgetLibHandler.h" #include "platforms/mac/QuickOperaApp/QuickWidgetManager.h" #include <string.h> #include "platforms/mac/embrowser/EmBrowserInit.h" #include "platforms/mac/bundledefines.h" #include "adjunct/quick/ma...
#include "ActionInitialization.hh" #include "B1PrimaryGeneratorAction.hh" #include "B1RunAction.hh" #include "B1EventAction.hh" #include "B1SteppingAction.hh" ActionInitialization::ActionInitialization() : G4VUserActionInitialization() {} ActionInitialization::~ActionInitialization() {} void ActionInitialization:...
#include <controller.h> void Controller::control() { if (!reset_n.read()) { sel_const.write(0); sel_in_1.write(0); sel_in_2.write(0); sel_op.write(0); we_n.write("1111"); s_sel_op_mem.write(0); s_we_mem1_n.write("1111"); s_we_mem2_n.write("1111"); } else { sel_in_1.write(static_cast< sc_b...
#include <mycanvas.h> #include <vector> MyCanvas::MyCanvas(QWidget *parent) : QWidget (parent) { int scene_height = 631; int scene_width = 711; scene.main_scene = QImage(scene_width, scene_height, QImage::Format_RGB32); scene.main_scene.fill(QColor(Qt::white)); cutter.min_point = {-1, -1}; cut...
#define IONIR_TESTS_ROOT_FILENAME ".root" #include <ionir/test/filesystem.h> #include "pch.h" // Testing environment initialization. int main(int argc, char **argv) { // Ensure root directory anchor file is visible. if (!ionir::test::fs::exists(ionir::test::fs::resolveTestPath(IONIR_TESTS_ROOT_FILENAME))) { ...
/** * Copyright (c) 2020, 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 __VIVADO_SYNTH__ #include <fstream> using namespace std; // Debug utility ofstream* global_debug_handle; #endif //__VIVADO_SYNTH__ #include "pw16_opt_compute_units.h" #include "hw_classes.h" struct input_input_update_0_write0_merged_banks_1_cache { // RAM Box: {[0, 299], [0, 299]} // Capacity: 1 // #...
#include"ProjetC++2(ClassObject).h" set<Object*>Object::_pool; Object::Object (const string& nom) : _nom(nom) // registerObject { _pool.insert(this); cout << "enregistrer " << _nom << endl; } static void viderPool() { // vider Pool set<Object*>::iterator it; while ( (it ...
struct Point { int x; int y; bool operator==(const Point& o) { return x == o.x && y == o.y; } bool operator!=(const Point& o) { return !(*this == o); } Point operator=(const Point& o) { x = o.x; y = o.y; return *this; } bool operator<(const Point& o) const { return (this->x ...
#include <iostream> using namespace std; class File { private: /* data */ public: File(/* args */); ~File(); }; File::File(/* args */) { } File::~File() { }
#include<iostream> int main(){ cout<<"huak"<<endl; return 0; }
// Created on: 1993-05-07 // Created by: Jacques GOUSSARD // 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 G...
#ifndef STUDENTINFO_H #define STUDENTINFO_H #include<string> //Replace "Your Name" and "Your ID#"; namespace StudentInfo { std::string name() { return "Se Rang Seo"; } std::string id() { return "1575601"; } }; #endif
#include<bits/stdc++.h> using namespace std; typedef long long ll; typedef unsigned long long ull; //solved. int main(){ ll d; cin>>d; while(d--){ ll a; vector<ll> agnes; cin>>a; while(a){ agnes.push_back(a); cin>>a; //cout<<a<<" "; } ll n = agnes.size(); vector<vector<ll>>...
#ifndef NV_MEMORY_INPUT_STREAM_H #define NV_MEMORY_INPUT_STREAM_H #include <cstdio> #include <string> namespace nv_test { class MemoryInputStream { MemoryInputStream(MemoryInputStream const & other) = delete; MemoryInputStream& operator=(MemoryInputStream const & other) = delete; public: MemoryInputStrea...
#include <math.h> #include <limits.h> int solution(vector<int> &A) { // write your code in C++14 (g++ 6.2.0) int sum = 0; for (int a:A){ sum+=a; } int sum_pre = A[0]; int sum_post = sum-A[0]; int cur_diff = abs(sum_post-sum_pre); int min_diff = cur_diff; for (int P=1; P<A.si...
#ifndef IOREMAP_THEVOID_SERVER_P_HPP #define IOREMAP_THEVOID_SERVER_P_HPP #include "server.hpp" #include "acceptorlist_p.hpp" #include "connection_p.hpp" #include "monitor_connection_p.hpp" #include <signal.h> #include <mutex> #include <set> namespace ioremap { namespace thevoid { int get_connections_counter(); //...