text
stringlengths
8
6.88M
// // SmartSample.hpp // DrumConsole // // Created by Paolo Simonazzi on 23/01/2016. // // #ifndef SmartSample_hpp #define SmartSample_hpp #include <stdio.h> const int numOfVoices = 6; class LayeredSample; class SmartSample { public: SmartSample(const String& sampleName); ~SmartSample(); private: ...
#pragma once #include "Question.h" #include "types.h" #include <loki/Visitor.h> #include "SequenceQuestion_fwd.h" namespace qp { class CSequenceQuestion : public CQuestion { public: LOKI_DEFINE_CONST_VISITABLE(); typedef std::vector<std::string> Sequence; CSequenceQuestion(const std::string & description, double...
#include <iostream> #include <vector> #include <boost/random.hpp> #include <cppmc/cppmc.hpp> using namespace boost; using namespace arma; using namespace CppMC; using std::vector; using std::ofstream; using std::cout; using std::endl; class EstimatedY : public MCMCDeterministic<double,Mat> { private: mat& X_; MCM...
#include "delegatewindow.h" #include "ui_delegatewindow.h" delegateWindow::delegateWindow(QWidget *parent) : QDialog(parent), ui(new Ui::delegateWindow) { ui->setupUi(this); } delegateWindow::~delegateWindow() { delete ui; } void delegateWindow::give_to_another() { QVariant inp = ui->lineEdit->te...
// // SnappaOutput.h // Snappa // // Created by Sam Edson on 6/14/15. // Copyright (c) 2015 Sam Edson. All rights reserved. // #ifndef __Snappa__SnappaOutput__ #define __Snappa__SnappaOutput__ #include <stdio.h> #include <string> class SnappaOutput { public: SnappaOutput() : message_("") {}; std::strin...
#pragma once #include <Poco/Condition.h> #include <Poco/Mutex.h> #include <Poco/Timespan.h> namespace BeeeOn { /** * @brief StopControl implements the stop mechanism generically. */ class StopControl { public: /** * @brief Helper class for managing a common stoppable loop * situation: * <pre> * void run()...
//Ein- und Ausgabe mit Lauflicht (vorläufig -- ruckelt leider) vink Pototyp #include <Adafruit_NeoPixel.h> #ifdef __AVR__ #include <avr/power.h> #endif #define PIN1 5 // Eingabe1 #define PIN2 6 // Eingabe2 #define PIN3 7 // Ausgabe int potPin1 = 2; //Potentiometer ...
#include <iostream> #include <sstream> #include <cstdlib> #include <cstdio> #include <vector> #include <queue> #include <deque> #include <stack> #include <list> #include <map> #include <iomanip> #include <set> #include <climits> #include <ctime> #include <complex> #include <cmath> #include <string> #in...
// this is a crude test of the major functions in Systronix MB85RC256V fram library. Mostly it proves that // Teensy can talk to fram on i2c port0 #include <Systronix_MB85RC256V.h> Systronix_MB85RC256V fram; Systronix_i2c_common i2c_common; uint16_t manuf_id; uint16_t prod_id; //---------------------------< S E T U...
// PingerDlg.h : header file // #if !defined(AFX_PINGERDLG_H__0788E7E9_71EF_11D2_B95A_0060083F73D6__INCLUDED_) #define AFX_PINGERDLG_H__0788E7E9_71EF_11D2_B95A_0060083F73D6__INCLUDED_ #if _MSC_VER > 1000 #pragma once #endif // _MSC_VER > 1000 //////////////////////////////////////////////////////////////////////////...
#include<bits/stdc++.h> using namespace std; int main(){ int b; cin>>b; cout<< (floor(sqrt(b - 1)) - ceil(sqrt(1)) + 1); return 0; }
#pragma once #include "l10n/LocaleManager.h" namespace BeeeOn { class SystemLocaleManager : public LocaleManager { public: Locale parse(const std::string &input) override; Locale chooseBest(const std::vector<std::string> &input) override; }; }
// Font block 'arial13_cyrillic_1bpp_0x401_0x401' definition // // Bitmap data static const esU8 sc_arial13_cyrillic_1bpp_0x401_0x401_data[] = { ________, _XXXXXX_, _X______, _X______, _X______, _XXXXXX_, _X______, _X______, _X______, _XXXXXX_, ________, ________, ________, }; // Font block 'arial13_c...
#include <bits/stdc++.h> using namespace std; /* Prints whether the input was a prime number or not. - if number is 0 or 1: not prime - if the number has a factor of 2: not prime - check all the odd numbers starting from 3 and below sqrt(n) to see if they are factors of n: if so not prime - if the number is 2: prime...
// Example 6.2 : std::vector // Created by Oleksiy Grechnyev 2017 // Class Tjej is used here, it logs Ctors and Dtors #include <iostream> #include <string> #include <vector> #include <algorithm> #include <memory> #include "Tjej.h" using namespace std; //======================================= /// Print a container....
// 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 NNTPRANGE_H #define NNTPRANGE_H #include "modules/util/opstring.h" # include "modules/util/simset.h" #include "adjunct/m2/src/include/defs.h" class NntpBackend; class NNTPRangeItem : public Link { public: INT32 m_from; INT32 m_to; NNTPRangeItem(); private: NNTPRangeItem(const NNTPRangeItem&); ...
#include <algorithm> #include "vtr_assert.h" #include "vtr_log.h" #include "pin_constraints.h" /************************************************************************ * Member functions for class PinConstraints ***********************************************************************/ /***************************...
#include <iostream> #include <vector> //using namespace std; using std::cout; using std::string; class Animal { public: string name = "Animal"; // 「虚函数」告诉编译器不要静态链接到该函数,而是根据所调用的对象类型(Class)去选择调用相应的函数, // 这种操作被称为动态链接或后期绑定,调用函数的方法需要在程序运行过程中查表完成,根据对象中虚指针指向的虚表中的地址 // 那么「纯虚函数」就是父类的virtual没有主体,例如virtual int a...
// // Created by glyphack on 7/11/19. // #include "game.h" GameController::GameController(sf::RenderWindow *window) { } void GameController::start() { } void GameController::cycle() { }
#pragma once #include "IQuizView.h" namespace qp { class CQuizView : public IQuizView { public: CQuizView(); ~CQuizView(); }; }
/* * Copyright 2019 LogMeIn * * 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 w...
#include <iostream> #include <bitset> #include <vector> #include <set> #include <string> #include <cmath> #define INF 300000 using namespace std; set<string> list; class CuttingBitString { public: template <class T> string toStr(T a) { string str; bool isStart = false; for (int i=(int)a.size()-1;i>=0;--i) ...
//: C03:AutoIncrement.cpp // Kod zrodlowy pochodzacy z ksiazki // "Thinking in C++. Edycja polska" // (c) Bruce Eckel 2000 // Informacje o prawie autorskim znajduja sie w pliku Copyright.txt // Prezentacja uzycia operatorow automatycznej // inkrementacji i dekrementacji #include <iostream> using namespace std;...
/* -*- 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. */ #include "core/pch.h" #ifdef SUPPORT_DATA_SYNC #include "modules...
#include "framebuffer.h" #include "image.h" #include "glbuffers.h" #include "consts.h" #include "assertion.h" #include <stdexcept> #include <glad/glad.h> FrameBuffer::FrameBuffer(FrameBuffer&& other) noexcept { id = other.id; other.id = 0; texture = std::move(other.texture); } FrameBuffer& FrameBuffer::operator...
#include <exception> #include <iostream> #include <fstream> #include <string> #include "GameController.h" int main(int, char*[]) { GameController gameController; while (gameController.isRunning) { gameController.Run(); } Renderer::Instance()->~Renderer(); return 0; }
#include<iostream> #include<vector> #include<unordered_map> #include<string> #include<algorithm> using namespace std; struct TreeNode { int val; TreeNode* left; TreeNode* right; TreeNode(int x) : val(x), left(NULL), right(NULL) {} }; #define inf 9999 void Init_TreeNode(TreeNode** T, vector<int>& vec, int& pos) { i...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 2000-2012 Opera Software AS. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** ** Kajetan Switalski ** */ #include "core/pch.h" #ifdef USE_SPDY...
#ifndef MAYA_PLUGIN_TEMPLATE_HELLOWORLD_H #define MAYA_PLUGIN_TEMPLATE_HELLOWORLD_H #include <maya/MArgList.h> #include <maya/MObject.h> #include <maya/MGlobal.h> #include <maya/MPxCommand.h> class HelloWorld : public MPxCommand { public: HelloWorld() {}; virtual MStatus doIt(const MArgList &arg_list); ...
#include <iberbar/RHI/D3D11/EffectReflection.h> iberbar::RHI::D3D11::CEffectReflection::CEffectReflection() : m_ReflectionVarArraySlots() , m_ReflectionCBufferArraySlots() { } iberbar::CResult iberbar::RHI::D3D11::CEffectReflection::Initial( EShaderType eShaderType, ID3D11ShaderReflection* pD3DShaderReflectio...
#include<iostream> #include<stdlib.h> #include<cstdlib> using namespace std; int main(){ int i; cout<<"checking if processor is available ..."; if(system(NULL)) // puts("ok"); i=0; else // exit(EXIT-FAILURE); cout<<"Executing Command DIR...\n"; i=system("dir"); cout<<"the value returned was:%d.\n...
#include <iostream> #include "cinema.h" #include "movie.h" using namespace std; Cinema::Cinema(){ cinemaName = "??"; movies = new Movie[5]; movieNo = 0; } Cinema::Cinema(string cinName){ cinemaName = cinName; } string Cinema::getCinemaName(){ return cinemaName; } int Cinema::getCinemaNo(){ return movieN...
#pragma once #include "../../system.hpp" namespace sbg { struct ResultData : Clonable { virtual std::unique_ptr<ResultData> reverse() const = 0; ResultData* clone() const override = 0; }; }
#include "Ficha.h" #include<math.h> #include <iostream> #include "glut.h" #define M 8 #define PX_X 800 #define PX_Y 800 using namespace std; void Ficha::SetColor(Color col) { color = col; } float Ficha::GetRadio() { return radio; } void Ficha::SetRadio(float rad) { if (rad < 0.1F) rad = 0.1F; radio = rad; ...
#include "OVR_CAPI.h" #include "Kernel/OVR_Math.h" #include <iostream> #include <unistd.h> #include <curses.h> class Rift{ public: Rift(); ~Rift(); void Output(); bool HeadPosition(float&,float&,float&); void ResetSensor(); private: ovrHmd hmd; ovrHmdDesc hmdDesc; ovrFrameTiming fra...
#include <iostream> #include <string> using namespace std; int main() { int a=10; int b=20; int &rn=a; cout<<rn<<endl; return 0; }
#include <bits/stdc++.h> using namespace std; int main(){ vector<int> ans = {1, 2, 3, 4, 5, 6}; int n; cin >> n; n %= 30; for(int i=0; i<n; i++){ int x = i % 5; int y = i % 5 + 1; ans[x] = ans[x] + ans[y]; ans[y] = ans[x] - ans[y]; ans[x] = ans[x...
#include "PointLight.h" const double PI = 3.14159265359; PointLight::PointLight() { radianceScalingFactor = 1; //default scaling factor sampleAmount = 1; radius = 0; } void PointLight::generateSamples() { vector<Point_2D> point2d; pointLightSamples.clear(); int n = (int)sqrt(sampleAmount / 2); for (double y ...
// demo.cpp : 定义控制台应用程序的入口点。 // #include "vector" #include "iostream" #include "numeric" #include "algorithm" #include "math.h" #include "time.h" #include "windows.h" using namespace std; int main() { int MinSize = 1; int MaxSize = 1000; int FishNum = 4; int result = 0; vector<int> FishSize({2, 8, 64, 1000}); ...
/* * This file is part of OpenModelica. * * Copyright (c) 1998-2014, Open Source Modelica Consortium (OSMC), * c/o Linköpings universitet, Department of Computer and Information Science, * SE-58183 Linköping, Sweden. * * All rights reserved. * * THIS PROGRAM IS PROVIDED UNDER THE TERMS OF GPL VERSION 3 LICENSE...
#ifndef BASEPIECE_H_INCLUDED #define BASEPIECE_H_INCLUDED #include <string> //forward declaration class Board; enum Color { Black, White }; struct Position { public: int xpos; int ypos; Position(int x=-1, int y=-1): xpos(x), ypos(y) {} }; class BasePiece { protected: ...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 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 LAYOUT_FIXED_POINT_DEBUG_H #define LAYOUT_FIXED_POINT_DEBUG_H ...
#include "SM_Test.h" #include "SM_Calc.h" namespace { bool is_two_points_same(const sm::vec2& p0, const sm::vec2& p1) { return fabs(p0.x - p1.x) < SM_LARGE_EPSILON && fabs(p0.y - p1.y) < SM_LARGE_EPSILON; } } namespace sm { bool is_point_in_segment(const vec2& pos, const vec2& s0, const vec2& s1) { if (is_two_...
/* -*- 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 OPERA_SINGLETON_COMPONENT_H #define OPERA_SINGLETON_COMPO...
#pragma once #include "../include/Mainmenu.h" Mainmenu::Mainmenu(float width, float height) { try { font.loadFromFile("Fonts/arial.ttf") ? 1 : throw TextureException(); backgroundtexture.loadFromFile("Texture/Menu.png") ? 1 : throw TextureException(); } catch (TextureException & e) { e.what(); } backgrou...
do_configure_prepend() { # Set the path to the binary edje_cc otherwise it will search it in the host rootfs sed -i 's!@edje_cc@!${STAGING_BINDIR_NATIVE}/edje_cc!g' Makefile.am }
#include<bits/stdc++.h> using namespace std; int main() { int condition = 0; float number; float sum = 0.0; float avg; while(1) { cin>>number; if(number>=0.0 && number <=10.0) { sum = sum + number; condition = 1+condition; if(condition=...
// // Created by 钟奇龙 on 2019-05-10. // #include <iostream> #include <string> using namespace std; void reverseWord(string &s,int left,int right){ while(left < right){ swap(s[left++],s[right--]); } } /* * 单词顺序逆序 */ void rotateWord(string &s){ if(s.size() == 0) return; int left = -1; int rig...
#include "stdio.h" #include "windows.h" #include "ipHlpapi.h" #include "tchar.h" #include "iostream" #pragma comment(lib,"iphlpapi.lib") void GetLocalMAC(char * buf); BOOL IsLocalAdapter(char *pAdapterName); void UTF8ToWideChar(IN UCHAR* utfChar, OUT _TCHAR** wideChar) { int len = MultiByteToWideChar(CP_ACP, 0, (LPST...
// Solution 1 using the largestRectangleArea method // 把第0行到第i行形成的矩形看成最大直方图矩形问题的输入 class Solution { public: int maximalRectangle(vector<vector<char>>& matrix) { if (matrix.empty()) return 0; int maxArea = 0; vector<int> heights(matrix.front().size(), 0); for (int i = 0; i < matrix.s...
class Solution{ public: ll dp[1001][1001]; long long combination (int m,int n){ if(m<n) return 0; if(n==0||m==n) return 1; if(dp[m][n]!=-1) return dp[m][n]; else return dp[m][n] = (combination(m-1,n)+combination(m-1,n-1))%1000000007; } vector<ll> nthRowOfPascalTriangle(int n) { memset(dp,-1...
#include "interruptprocess.h" InterruptProcess::InterruptProcess(QObject* parent) { Q_UNUSED(parent) setRect(QRectF(0,0,100,100)); setPen(Qt::PenStyle::DashLine); setBrush(Qt::red); setOpacity(0.5); txt = new QGraphicsTextItem(this); txt->setPlainText("Interrupt"); txt->set...
#pragma once #include "declspec.h" #include <SFML/Graphics/Color.hpp> namespace sf { class VertexArray; template <typename T> class Rect; typedef Rect<float> FloatRect; } namespace pure { PUREENGINE_API sf::VertexArray createVertSquare(const sf::FloatRect& rect, const sf::Color& color = sf::Color::Green); }
#pragma once #include "cmm/cmm.h" #include "mat/mat_base.h" class CMat { public: static void init(void); static const rsfpat_t getPat(emat_t idx) { assert(s_mat[idx]); return s_mat[idx]->get_pat(); } static const CMatBase & getMat(emat_t idx) { assert(s_mat[idx]); return *s_mat[idx]; } private: static...
#ifndef UI_SLIDER_HPP_ #define UI_SLIDER_HPP_ #include "UiObject.hpp" #include "TextRendererFactory.hpp" class UiSlider : public UiObject { private: const double kTopValue; const double kBottomValue; public: UiSlider() : kTopValue(1.0) , kBottomValue(0.0) { label_ = "slider"; ...
//=========================================================================== /* This file is part of the CHAI 3D visualization and haptics libraries. Copyright (C) 2003-2004 by CHAI 3D. All rights reserved. This library is free software; you can redistribute it and/or modify it under the terms o...
/*============================================================================= /*----------------------------------------------------------------------------- /* [JSONSampler.cpp] RapidJSONヘルパークラス /* Author:Kousuke,Ohno. /*----------------------------------------------------------------------------- /* 説明:RapidJSONヘルパ...
// Copyright 1998-2015 Epic Games, Inc. All Rights Reserved. /*============================================================================= OpenGLViewport.cpp: OpenGL viewport RHI implementation. =============================================================================*/ #include "OpenGLDrvPrivate.h" #include <...
/** This file is a linked list implementation. I hate implementing linked lists * by hand. Especialy tough was the part about erasing by "running number" id. * @author Daniel "3ICE" Berezvai * @student_id 262849 * @email daniel.berezvai@student.tut.fi */ #include "queue.hh" #include <iostream> #include <string> u...
// Created on: 1993-01-11 // Created by: CKY / Contract Toubro-Larsen ( Anand NATRAJAN ) // 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...
// Created on: 1996-01-30 // Created by: Jacques GOUSSARD // 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 G...
// boundary_flip.h // Ben Gamari // August 2009 #ifndef _BOUNDARY_FLIP_H #define _BOUDNARY_FLIP_H #include <cpu_vector.h> namespace qcd { void apply_boundary(su3_field &links, int bc[4]); } // qcd namespace #endif
#ifndef _TOWN_ #define _TOWN_ /*---------------------------------------------------------- Handles the info of town. A town is made up of 5 horizontal acres by 4 vertical acres. Each acre is is 16 by 16 units. An array of characters is used to keep track of what is stored where. ----------------------------------------...
#include <bits/stdc++.h> using namespace std; typedef long long ll; struct edge{ int to; ll cost; }; bool visit[100005]; bool ans[100005]; vector<vector<edge>> G(100005); void dfs(int v, ll w){ if(w%2 == 0) ans[v] = true; visit[v] = true; for(int i=0; i<G[v].size(); i++){ ...
// SDDLViewerDlg.cpp : implementation file // #include "Stdafx.h" #include "SDDLViewer.h" #include "SDDLViewerDlg.h" #pragma comment(lib, "Version.lib") #pragma comment(lib, "Aclui.lib") #ifdef _DEBUG #define new DEBUG_NEW #endif // CAboutDlg dialog used for App About class CAboutDlg : public CDialog { public: ...
#include "Renderer.h" #include "Time.h" #include "../include/Mario.h" #include "../include/Dung.h" #include "../include/Restart.h" #include "../include/Bg.h" #include "testNonRenderObj.h" #include "CompositeObj.h" //bool CheckCollision(CompositeObj* one, CompositeObj* two) // AABB - AABB collision //{ // // collisi...
/* -*- 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> #ifdef DOM_EXTENSIONS_TAB_API_SUPPORT #incl...
#include <iostream> using std::cin; using std::cout; using std::endl; #include <string> using std::string; int main() { unsigned cnt = 0; string s, s_next; cin >> s; ++cnt; while(cin >> s_next) { if(s == s_next && isupper(s_next[0])) { ++cnt; break; } else {...
// Copyright (c) 2021 ETH Zurich // // SPDX-License-Identifier: BSL-1.0 // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #pragma once #include <pika/config.hpp> #if defined(PIKA_HAVE_STDEXEC) # include <pika/e...
#include "stdafx.h" #include "ParticleRenderView.h" #include "ParticleDialog.h" #ifdef _DEBUG #define new DEBUG_NEW #undef THIS_FILE static char THIS_FILE[] = __FILE__; #endif ///////////////////////////////////////////////////////////////////////////// // CParticleRenderView IMPLEMENT_DYNCREATE(CPa...
#include "SimpleLogger.h" #include "lock.hpp" #include "threadpool.h" #include <stdio.h> #include <stdlib.h> #include <stdarg.h> #include <time.h> #include <sys/types.h> #include <sys/stat.h> #include <sys/fcntl.h> #include <string> #include <vector> #include <boost/bind.hpp> #include <boost/function.hpp> #include <err...
#include <iostream> #include <string> #include <vector> #include <cstdlib> #include "Video.h" using namespace std; int changeoptions; bool videolist; string temp_name_of_tape, temp_type_of_movie, temp_cost, temp_released_date, temp_location, temp_availability; int main() { vector<Videotape> ...
int quarter(point a) { if(a.x>0 and a.y>=0) return 0; if(a.x<=0 and a.y>0) return 1; if(a.x<0 and a.y<=0) return 2; return 3; } point c; bool comp(point a, point b) //ccw { a=a-c;b=b-c; int qa = quarter(a); int qb = quarter(b); if(qa==qb) return (a^b)>0; else return ...
#ifndef AWS_NODES_EXPRESSION_H #define AWS_NODES_EXPRESSION_H /* * aws/nodes/expression.h * AwesomeScript Expression * Author: Dominykas Djacenka * Email: Chaosteil@gmail.com */ #include "parsernode.h" namespace AwS{ namespace Nodes{ class Expression : public ParserNode{ public: Expression() : ParserN...
#include "stdafx.h" #include "DijkstraMatrixAlgorithm.h" #include <climits> #include <iostream> DijkstraMatrixAlgorithm::DijkstraMatrixAlgorithm(Graph & graph) :shortestPathAlgorithm(graph) { int unvisitedVertrexSize = graph.getNumberOfVertices(); for (int i = 0; i < unvisitedVertrexSize; i++) { unvisitedVertrex...
#include "stgraph.h" #include <fstream> #ifdef __GNUC__ # if __GNUC__ == 3 #include <iterator> # endif #endif //------------------------------------------------------------------------------ void STGraph::AddNode (std::string s) { if (labelled_nodes.find (s) == labelled_nodes.end ()) { node n = new_node ();...
/******************************** * Reef-Life Aquarium Controller * * Versión 3.0.0 - 201506 * * Control de Tiempo * ********************************/ //Imprime la Hora en la TFT y el LCD void getHour() { writeTFTLn(40,225,WHITE,2,getNow()); printLCD(0,3,getNow()); } //Obtiene la Fecha String g...
#include "PIOAdaptor.h" #include "BHTree.h" #include "vtkCellArray.h" #include "vtkCellData.h" #include "vtkCellType.h" #include "vtkDirectory.h" #include "vtkDoubleArray.h" #include "vtkErrorCode.h" #include "vtkFloatArray.h" #include "vtkIdList.h" #include "vtkInformation.h" #include "vtkIntArray.h" #include "vtkMul...
#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()...
// // Contrato.h // Ordenamiento // // Created by Daniel on 04/09/14. // Copyright (c) 2014 Gotomo. All rights reserved. // #ifndef __Ordenamiento__Contrato__ #define __Ordenamiento__Contrato__ #include <iostream> class Contrato{ public: int numero, dia, mes, ano; Contrato(){} Contrato(int _num, int _...
// # include "stdafx.h" # include <iostream> # define ROUND 3 // to define labels # define ROCK 1 # define PAPER 2 # define SCISSORS 2 using namespace std; int main() { int playerOne, playerTwo; int tie=0, winner1=0, winner2=0; char replay; do { //system("cls"); cout << "\n\n ...
/* * (c) copyright 1988 by the Vrije Universiteit, Amsterdam, The Netherlands. * See the copyright notice in the ACK home directory, in the file "Copyright". * * Author: Ceriel J.H. Jacobs */ /* Id: exp.c,v 1.6 1994/06/24 11:43:26 ceriel Exp */ #include "core/pch.h" #ifdef ACK_MATH_LIBRARY #include "modules/std...
#include "CoinConf.h" #include "GameApp.h" #include "Util.h" #include "StrFunc.h" #include "Logger.h" using namespace std; static CoinConf* instance = NULL; CoinCfg CoinConf::sCoinCfg; CoinConf* CoinConf::getInstance() { if(instance==NULL) { instance = new CoinConf(); } return instance; } CoinConf::CoinConf() ...
/* XMRig * Copyright 2018-2020 SChernykh <https://github.com/SChernykh> * Copyright 2016-2020 XMRig <https://github.com/xmrig>, <support@xmrig.com> * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Fr...
// Fill out your copyright notice in the Description page of Project Settings. #include "Dientes.h" // Sets default values ADientes::ADientes() { // Set this actor to call Tick() every frame. You can turn this off to improve performance if you don't need it. PrimaryActorTick.bCanEverTick = true; } ...
// // CryptServer.hpp for cpp_spider in sources/server // // Made by Benoit Hamon // Login <benoit.hamon@epitech.eu> // // Started on Sun Oct 08 22:42:30 2017 Benoit Hamon // Last update Wed Oct 11 01:03:52 2017 Benoit Hamon // #pragma once #include <boost/property_tree/ptree.hpp> #include <boost/asio.hpp> #includ...
#include "StdAfx.h" #include "Place.h" namespace ui { Place* Place::Create(const CPoint& left_top) { Place* ret = new (std::nothrow) Place(); if (ret && ret->InitWithPoint(left_top)) { return ret; } delete ret; return nullptr; } bool Place::InitWithPoint(const CPoint& left_top) { left_top_ = ...
#ifndef ONLYMESH_H #define ONLYMESH_H #include <QWidget> #include "facialmesh.h" namespace Ui { class OnlyMesh; } class OnlyMesh : public QWidget { Q_OBJECT public: explicit OnlyMesh(QWidget *parent = nullptr); ~OnlyMesh(); void init(void); void conectar(void); void desconectar(void); fa...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4; c-file-style:"stroustrup" -*- ** ** Copyright (C) 2003 Opera Software AS. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** ** Morten Stenshorne */ #ifndef __SCALING_H...
#include <iostream> #include <chrono> #include <thread> #include <algorithm> using namespace std; using namespace std::chrono; typedef unsigned long long ll; ll sumOdd = 0; ll sumEven = 0; void findOdd(ll shoro, ll payan) { for(ll i = shoro; i <= payan; i++) { if(i % 2 != 0) // i & ...
/* -*- 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/style/css_collection.h" ...
// // Problem in p-1.6.1-0.png // #include <iostream> #include <cassert> #include <cmath> #include <algorithm> static void do_sort(int n, int* a) { std::qsort(a, n, sizeof(int), [](const void*a, const void* b) { int arg1 = *static_cast<const int*>(a); int arg2 = *static_cast<const int*>(b); ...
#include "number.hpp" Number::Number() { } Number::Number(int val) { this->m_val = val; } /*Number::Number virtual operator+(const Number& obj) { Number tmp; tmp.m_val = this->m_val + obj.m_val; tmp.m_str = ""; return tmp; } Number::Number virtual operator=(const Number& obj) { this->m_val =...
/** Copyright (c) 2015 Eric Bruneton All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the follo...
int func(int A, int B) { // Verify that we have at least c++14 auto mult_func = [](auto a, auto b) { return a * b; }; return mult_func(A, B); }
// Fill out your copyright notice in the Description page of Project Settings. #include "Dragon.h" #include "DRController.h" #include "DRAnimInstance.h" #include "DrawDebugHelpers.h" #include "time.h" #include "NavigationSystem.h" #include "Blueprint/AIBlueprintHelperLibrary.h" #include "FireBall.h" // Set...
/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying file Copyright.txt or https://cmake.org/licensing for details. */ #pragma once #include "cmConfigure.h" // IWYU pragma: keep #include <cstddef> #include <memory> #include <string> #include "cm_uv.h" #include "cmUVHandlePtr.h" class ...
#include<bits/stdc++.h> using namespace std; typedef long long ll; ll a[1000][1000]; main() { ll i, j, sum=0, x, y, z; for(i=0; i<3; i++) { for(j=0; j<3; j++) { cin>>a[i][j]; sum = sum+a[i][j]; } } sum=sum/2; a[0][0] = sum-(a[0][1]+a[0][2]); a[...
#include "pch.h" #include "BubbleSort.h" #include "Swap.h" #include <vector> #include <chrono> BubbleSort::BubbleSort() {} BubbleSort::~BubbleSort() {} int BubbleSort::bubbleSort(std::vector<int> &vec) { std::chrono::time_point<std::chrono::system_clock> now = std::chrono::system_clock::now(); auto ...