text
stringlengths
8
6.88M
#pragma once #include "entity.h" #include "..\\input\input_system.h" #include "..\\renderer\texture.h" #include "..\\audio\audio_system.h" #include "..\\resource\resource_manager.h" class Scene; class EntityEventDispatcher : public EventDispatcher<Event<Entity>> { public: EntityEventDispatcher(Engine* engine) : Eve...
#include "task_widget.h" #include "task_box.h" #include "time_dialog.h" #include <QPushButton> #include <QVBoxLayout> #include <QSpinBox> #include <QCheckBox> #include <QLabel> TaskWidget::TaskWidget( void ) { workTimeBox = new QSpinBox; restTimeBox = new QSpinBox; startButton = new QPushButton( tr("start") ); ...
#include <cstdio> #include <cmath> #include <iostream> using namespace std; const int maxn = 100002; int arr[maxn]; long long quick_mod(long long a, long long b) { long long ans = 1; while(b > 1) { if(b % 2 != 0) { ans = ans * a % 29; b--; } else { ...
//---------------------------------------------------------------- // MultifieldSort.cpp // // Routines for performing multi-field sorts on idList's // // Copyright 2002-2005 Raven Software //---------------------------------------------------------------- #ifndef __MULTIFIELD_SORT_H__ #define __MULTIFIELD_SORT_H__ t...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4; c-file-style:"stroustrup" -*- ** ** 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 COCOAMACOPPLATFORMEVENT_H #def...
/* * File: tcpsocket.h * Author: dangnq * * Created on January 31, 2015, 9:18 PM */ #ifndef TCPSOCKET_H #define TCPSOCKET_H #include <string.h> #include <cstdlib> #include <stdio.h> #include <sys/types.h> #include <sys/socket.h> #include <sys/un.h> #include <unistd.h> #include <sys/stat.h> #include <fcntl.h> #...
#ifndef GETLINE_H #define GETLINE_H #include "opencv2/imgcodecs/imgcodecs.hpp" #include "opencv2/opencv.hpp" #include "opencv2/core/core.hpp" class getline { public: getline(); void getl(); float getD(float,float,float,float,float); float jisuan(float,float,float,float); }; #endif // GE...
#include "sudoku.h" // ---------------------------------------------------------------------- // Klasse Sudoku // Ein-/Ausgabeoperatoren ostream& operator<< (ostream& out, const Sudoku& S) { for (int r=1; r<=9; ++r) { for (int c=1; c<=9; ++c) { const int z= S(r,c); if (z==0) ...
#include "save.h" #include "Timer.h" #include "Entity.h" #include "Terrain.h" #include "graphics.h" #include "camera.h" #include "console.h" #include "unit.h" extern Graphics *renderer; extern Camera * camera; extern Terrain *terrain; extern Console *console; extern Timer *timer; extern EntityContainer *...
#include "stdafx.h" #include "EthernetFrame.h" EthernetFrame::EthernetFrame(void) { memset(m_DestAddress, 0, 6); memset(m_SourceAddress, 0, 6); m_EtherType = 0; m_MACDATA = NULL; } EthernetFrame::EthernetFrame(BYTE *DestAddress,BYTE *SourceAddress,WORD EtherType) { memcpy(m_DestAddress, DestAddress, 6); memcpy(...
#pragma once #include "cocos2d.h" USING_NS_CC; class Enemy : public Sprite { private: DWORD m_UID; public: Enemy(); ~Enemy(); static Enemy* SpriteWithFile(const char* pszFileName); virtual bool init(); };
#include <iostream> #include <algorithm> using namespace std; int main() { int n, a[200001], ans = 0; cin >> n; for(int i = 0; i < n; i++) cin >> a[i]; sort(a, a + n); int k = 1, idx = 0; while(idx < n) { if(a[idx] >= k) { ans++; k++; } idx++; continue; } cout << ans<< endl; }
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 2005-2006 Opera Software AS. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. */ #ifndef SVG_TEXT_ELEMENT_STATE_CONTEXT #define SVG_TEXT_ELEMENT_ST...
#include "MxRenderStateManager.h" #include "../../MixEngine.h" #include "MxGPUParams.h" namespace Mix { std::shared_ptr<GPUPipelineParamsInfo> RenderStateManager::createGPUPipelineParamsInfo(const GraphicsParamsDesc& _desc) const { return std::shared_ptr<GPUPipelineParamsInfo>(new GPUPipelineParamsInfo(_d...
//////////////////////////////////////////////////////// // GUI EDITOR OUTPUT START (by Casperento, v1.063, #Quxufi) //////////////////////////////////////////////////////// class cxp_actualdead_List { idd = 52900; name = "cxp_actualdead_List"; movingEnable = false; enableSimulation = true; class ControlsB...
/*! \file */ //Copyright 2011-2016 Tyler Gilbert; All Rights Reserved #ifndef FMT_HPP_ #define FMT_HPP_ /*! \brief Standard Data Formats * */ namespace fmt { }; #include "fmt/Bmp.hpp" #include "fmt/Wav.hpp" #include "fmt/Xml.hpp" #include "fmt/Son.hpp" using namespace fmt; #endif /* FMT_HPP_ */
#pragma once class UIAnimator; class ModeSelectBack :public GameObject { public: ModeSelectBack(); void OnDestroy(); void Update(); enum eMode { enNone, endundeon, enpvp, ennetpvp, enAIedit }; //切り替え ダンジョン void Dungeon(); //切り替え PVP void PVP(); //切り替え NETPVP void NetPVP(); //切り替え AIEdhit voi...
#include <iostream> typedef long long ll; using namespace std; int main() { ll t, n, b, w, h, p, bestArea, curArea; bool found; cin >> t; for(int i = 0; i < t; i++) { cin >> n >> b; found = false; bestArea = -1; for(int j = 0; j < n; j++) { ...
/* ** EPITECH PROJECT, 2018 ** utils ** File description: ** utils */ #include "include.hpp" #include <string> std::string wchar_to_string(const wchar_t *str); const wchar_t *char_to_wchar(const char *str);
#define _CRT_SECURE_NO_WARNINGS #include <iostream> #define INF 10000000 int n, m; int Map[101][101] = { 0, }; void Floyd() { for (int k = 1; k <= n; k++) { for (int i = 1; i <= n; i++) { for (int j = 1; j <= n; j++) { if (Map[i][j] > Map[i][k] + Map[k][j]) { Map[i][j] = Map[i][k...
#include <bits/stdc++.h> using namespace std; #define MOD 1000000007 #define rep(i, n) for(int i = 0; i < (int)(n); i++) #define show(x) for(auto i: x){cout << i << " ";} typedef long long ll; int main() { int n; cin >> n; vector<int> p; rep(i, n){ int tmp; cin >> tmp; p.push_back(tmp);} int minn...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: nil; 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. * * George Refseth, rfz@opera.com */ #ifndef APPLE_MAIL_IMPORT...
#include<iostream> #include<vector> #include<algorithm> #include<set> #include<map> using namespace std; class Solution { public: int getSum(int a, int b) { //迭代:位运算,a^b是无进位的相加;a&b<<1得到每一位的进位 int carry,sum; sum=a^b; carry=static_cast<unsigned int>(a&b)<<1; while(carry!=0) ...
/** * Description: find sqrt of integer via a prime * Source: http://www.math.vt.edu/people/brown/class_homepages/shanks_tonelli.pdf * Verification: https://www.spoj.com/problems/CRYPTO1 */ int modsqrt(int a) { int p = po(a,(MOD-1)/2); if (p != 1) return p == 0 ? 0 : -1; int s = MOD-1, e = 0; while (s % 2...
#include <bits/stdc++.h> using namespace std; int main() { string s; stringstream ss; double num; scanf("%lE", &num); ss << num; ss >> s; ss.clear(); if(s[0]=='-') printf("%.4lE\n", num); else printf("+%.4lE\n", num); return 0; }
#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()...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 2010 Opera Software AS. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. */ #ifndef SCOPE_DESKTOP_WINDOW_MANAGER_H #define SCOPE_DESKTOP_WIN...
#include <iostream> #include <string> #include <cstring> #include <algorithm> using namespace std; int main() { char a[50]; while(cin >> a && (strcmp(a,"#")!=0)) { if(next_permutation(a,a+strlen(a))) cout << a << endl; else cout << "No Successor" << endl; } return 0; }
#pragma once #include "stdafx.h" #include "DataTypes/vec.h" #include <map> #include <string> #include <GL\gl.h> typedef std::map<std::string, Vec3f> intMap; #define nbFixColor 10 Vec3f fixColor[nbFixColor] = {Vec3f(0,0,1), Vec3f(0,1,0), Vec3f(1,0,0), Vec3f(1,0,1), Vec3f(0,1,1), Vec3f(0,0.5,1), Vec3f(0,1,.5), Vec3f(1,...
#ifndef __VARDECL__ #define __VARDECL__ // Заголовочный файл с описанием параметров переменных // Standard C++ library #include <iostream> #include <fstream> #include <sstream> // Declares clang::SyntaxOnlyAction. #include "clang/Frontend/CompilerInstance.h" #include "clang/Frontend/FrontendActions.h" #include "cla...
#include "_pch.h" #include "ViewFav.h" using namespace wh; //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- //----------------------------------------------------------------------------- class wxDVModel : pu...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup" -*- * * Copyright (C) Opera Software ASA 2012 * * @author Andreas Farre */ #include "core/pch.h" #include "modules/ecmascript/carakan/src/es_pch.h" #include "modules/ecmascript/carakan/src/vm/es_allocation_conte...
#include "stdEntity.h" stdEntity::stdEntity(void) { } stdEntity::~stdEntity(void) { } void stdEntity::Init() { Entity::Init(); RegisterComponent(&tf); RegisterComponent(&render); RegisterComponent(&bc); RegisterComponent(&animComp); } void stdEntity::Update() { Entity::Update(); }
//算法:Floyd求多源最短路 //少有的Floyd的题 //输入数据,用邻接表存边 //然后初始化map[i][i]等于0,即i点到i点的距离为0 //因为可以选择的点包括想去的点,所以要提前初始化,不然Floyd跑一遍后会出错 //然后跑Floyd //之后枚举每一个点,计算他们到达要求点的距离之和, //选出其中和最小的点的编号 //输出即可 #include<cstdio> #include<cstring> #include<algorithm> using namespace std; const int MARX=0xf; int p,f,c,ans; double minn=9999...
#include <vector> #include <string> #include <cmath> #include <fstream> #include <iostream> #include <sstream> #include <list> #include <algorithm> #include <set> #include <map> #include <stack> #include <queue> #include <numeric> #include <bitset> #include <deque> #include <random> #include <stdlib.h> const long long...
#include <QObject> #include <QPainter> #include <stdio.h> #include <math.h> #include "window.h" #include <QLineEdit> #include <QLabel> #include <QHBoxLayout> #include <QSpacerItem> #include <QPushButton> #include <QDebug> #include <QMessageBox> #include <QRadioButton> #define DEFAULT_A -10 #define DEFAULT_B 10 #defin...
#ifndef F3LIB_UTILS_VALUECONVERTER_H_ #define F3LIB_UTILS_VALUECONVERTER_H_ namespace f3 { namespace utils { template<typename T> inline T getValue(const std::string& input, const f3::types::DefineMap& defineMap) { f3::types::DefineMap::const_iterator it = defineMap.find(input); if (it != defineMap....
#include "scran.h" /* This computes the mean and CV2 for every gene, while also dividing through by the size factors. */ template <typename T> SEXP compute_CV2_internal(const T* ptr, const matrix_info& MAT, SEXP subset_row, SEXP size_factors) { subset_values rsubout=check_subset_vector(subset_row, MAT.nrow); c...
#include <signal.h> #include "CDLReactor.h" #include "Configure.h" #include "Logger.h" #include "Version.h" #include "RobotSvrConfig.h" #include "GameServerConnect.h" #include "ClientHandler.h" #include "ProcessManager.h" #include "GameCmd.h" #include "Protocol.h" #include "Packet.h" #include "Util.h" #include "NamePoo...
#include <touchgfx/hal/Types.hpp> FONT_GLYPH_LOCATION_FLASH_PRAGMA KEEP extern const uint8_t unicodes_verdana_40_4bpp_0[] FONT_GLYPH_LOCATION_FLASH_ATTRIBUTE = { // Unicode: [0x0030] 0x00, 0x00, 0x00, 0x00, 0x64, 0x67, 0x25, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0xE9, 0xFF, 0xFF, 0xFF, 0x5C, 0x00, 0x00...
#pragma once #ifndef SCENE_H #define SCENE_H #include "Entity.h" #include "Camera.h" class Scene : public Entity{ public: Scene(); virtual ~Scene(); //update the scene void updateScene(float deltaTime); //update all entities in the scene void updateEntity(Entity* entity, float deltaTime); //check if the scene ...
#include <iostream> #include <stdlib.h> #include "add.h" // import BasicMath::add() using namespace std; int main(void) { system("cls"); cout << BasicMath::add(4, 3) << '\n'; return 0; }
// ---------------------------------------------------------------------------- // Copyright (C) 2002-2006 Marcin Kalicinski // Copyright (C) 2009 Sebastian Redl // // Distributed under the Boost Software License, Version 1.0. // (See accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_...
#include "PlayerInventoryWnd.h" #include "Single/GameInstance/RPGGameInst.h" #include "Single/PlayerManager/PlayerManager.h" #include "Actor/Controller/PlayerController/GamePlayerController/GamePlayerController.h" #include "Actor/Character/PlayerCharacter/PlayerCharacter.h" #include "Widget/BaseSlot/ItemSlot/PlayerI...
#include <iostream> #include <fstream> #include <string.h> #include <stdio.h> #include <stdlib.h> #include <ncurses.h> using namespace std; void printChars(int n, char kitu) { for (int i = 0; i < n; i++) { printf("%C", kitu); } } int main() { int a, b; std:ifstream infile; infile.open("...
#include <iostream> using namespace std; using ll = long long; const ll INF = 1LL << 50; int main() { int N, M; cin >> N >> M; ll asum[N + 1], bsum[M + 1]; asum[0] = bsum[0] = 0; for (int i = 0; i < N; ++i) { ll a; cin >> a; asum[i + 1] = asum[i] + a; } for (int j...
// // Created by zhou.lu on 2021/9/2. // #ifndef XPHONEPLAYER_IRESAMPLE_H #define XPHONEPLAYER_IRESAMPLE_H #include "IObserver.h" #include "XParameter.h" class IResample : public IObserver { public: virtual bool Open(XParameter in, XParameter out = XParameter()) = 0; virtual XData Resample(XData indata) = 0; ...
// Sharna Hossain // CSC 111 // Lab 6 | grades_logical_operator.cpp #include <iostream> using namespace std; int main() { int grade; string letter_grade; cout << "Enter a grade: "; cin >> grade; if (grade >= 60 && grade <= 62) { letter_grade = "D-"; } else if (grade >= 63 && grade <=...
/* ** EPITECH PROJECT, 2018 ** PSU_zappy_2017 ** File description: ** Select.cpp */ #include "Select.hpp" void Select::addFd(int fd) noexcept { _fds.push_back(fd); } void Select::select(int timeOut) { fillFds(); int nfds = getNfds(); struct timeval tv = { timeOut, 0 }; if (::select(nfds, &_rFd, &_wFd, &_eFd, &t...
#include <stdio.h> #include <algorithm> #include <iostream> using namespace std; #define maxs 100000000 using namespace std; bool prime[maxs + 1]; int ret[maxs + 1]; int calc(int x, int y) { for(int i = 1; i <= 100; i++) { int t = i, q = 1; while(t % y == 0) t /= y, q++; x -= q; if...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- * * 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. * * @file * @author Owner: Karianne Ekern (karie) * @author Co...
// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root. #include <vespa/vespalib/testkit/testapp.h> #include <vespa/vespalib/stllike/string.h> #include <vespa/document/base/documentid.h> #include <vespa/vespalib/util/threadstackexecutor.h> #include <vespa/s...
#include <stdio.h> #include <math.h> int IsTheNumber ( const int N ); int main() { int n1, n2, i, cnt; scanf("%d %d", &n1, &n2); cnt = 0; for ( i=n1; i<=n2; i++ ) { if ( IsTheNumber(i) ) cnt++; } printf("cnt = %d\n", cnt); return 0; } int IsTheNumber ( const int N )...
#include "ManagerUtils/PlotUtils/interface/Common.hpp" #include "TriggerEfficiency/EfficiencyPlot/interface/EfficiencyPlot.h" using namespace std; extern void DrawUncEta() { TCanvas* c = mgr::NewCanvas(); TPad* top = mgr::NewTopPad(); top->Draw(); top->cd(); TH1F* h1 = gPad->DrawFrame( -...
// This is the CPP file you will edit and turn in. // Also remove these comments here and add your own. // TODO: remove this comment header #include <fstream> #include <iostream> #include <string> #include "simpio.h" #include "console.h" #include "random.h" #include "strlib.h" #include "vector.h" #include ...
// File: HLRAppli_ReflectLines.cdl // Created: 05.12.12 15:53:35 // Created by: Julia GERASIMOVA // 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...
// // Created by chris on 11/08/2017. // #include <iostream> #include "Model.h" Model::Model() { glGenVertexArrays(1, &h_vao); glGenBuffers(1, &h_vbo); glGenBuffers(1, &h_indexBuffer); } void Model::draw() { draw(GL_TRIANGLES); } void Model::draw(GLenum mode) { if(this->indexCount == 0) { ...
// Author : Gabriel Duarte // Date : 01/30/2018 // Lab # : 02 exercise 1 // Description : We are making a check board. // Include the library #include "EasyBMP.h" using namespace std; int main() { // Create an image BMP AnImage; // Set the image size AnImage.SetSize(256,256); // Set the bit depth...
#include <stdio.h> #include <stdlib.h> #include <iostream> using namespace std; /* 0(Lgn + k) algorithm Input: K = 4, X = 35 arr[] = {12, 16, 22, 30, 35, 39, 42, 45, 48, 50, 53, 55, 56} Output: 30 39 42 45 */ int getMinPosition(int arr[], int i, int j, int k, int n) { if (i < 0) return j; if...
#include "pch.h" #include "game.h" #include <vector> game::game() { Console = new console(); gui = new GUI(*Console); Player = new player(Console, gui); ai = new AI(); } void game::startGame() { Console->cls(); gui->drawGameInterface(Player->getMyField(), Player->getEnemyField()); ai->placeShips(2); Player->p...
#ifndef _MSG_0X28_ENTITYMETADATA_STC_H_ #define _MSG_0X28_ENTITYMETADATA_STC_H_ #include "mcprotocol_base.h" #include "metadata.h" namespace MC { namespace Protocol { namespace Msg { class EntityMetadata : public BaseMessage { public: EntityMetadata(); EntityMetadata(int32_t _entityId, Metadata _metadata); size_...
#include <chuffed/core/propagator.h> #include <chuffed/globals/EdExplFinder.h> #include <iostream> class EditDistance : public Propagator { public: enum ExplLevel { // generate naive explanation if all seq variables are fixed only E_NAIVE, // generate explanation on any domain change, E_FULL, }; int max_c...
#ifndef RTPCLASS_H #define RTPCLASS_H #include <QThread> #include <QUdpSocket> #include <errno.h> #include <QFile> #include <QTime> #include "rtpsession.h" #include "rtpsourcedata.h" #include "rtpudpv4transmitter.h" #include "rtcpcompoundpacket.h" #include "rtcpsrpacket.h" #include "rtpipv4address.h" #include "rtppac...
// Fill out your copyright notice in the Description page of Project Settings. #include "FightWithBlock.h" #include "MyGameState.h" #include "BlockBase.h" #include "MyStructs.h" AMyGameState::AMyGameState() { static ConstructorHelpers::FObjectFinder<UDataTable> GroundTable(TEXT("DataTable'/Game/myBlueprint/DataTab...
//--------------------------------------------------------- // // Project: dada // Module: core // File: common.h // Author: Viacheslav Pryshchepa // // Description: // //--------------------------------------------------------- #ifndef DADA_CORE_COMMON_H #define DADA_CORE_COMMON_H #ifnd...
#include <iostream> #include <cstring> using namespace std; class Solution { public: int lengthOfLastWord(const char *s) { int result = 0; while(*s){ if(*s++ != ' ')/* increment happends here*/{ ++result; }else if(*s && *s != ' '){ result = 0; } ...
#include<iostream> #include<string> using std::cin; using std::cout; using std::endl; using std::string; void swap(int &a,int &b){ a=a^b; b=a^b; a=a^b; } void swap(string &a,string &b){ string temp; temp=a; a=b; b=temp; } int main(){ int a,b; cout<<"Enter a"<<endl;...
// Fill out your copyright notice in the Description page of Project Settings. #include "DRAnimInstance.h" #include "Dragon.h" UDRAnimInstance::UDRAnimInstance() { CurrentDragonSpeed = 0.0f; static ConstructorHelpers::FObjectFinder<UAnimMontage> ATTACK_MONTAGE(TEXT("/Game/AI/SK_DesertDragon_Skeleton_Monta...
#include <iostream> #include "vector.h" using namespace std; int main() { vector vec = {1, 2, 3, 4}; vector not_a_vec = vec; vec.set(3, 1); cout << not_a_vec.get(3) << endl; return 0; }
/***************************************************************** Name :insertion_sort Author :srhuang Email :lukyandy3162@gmail.com History : 20191123 Initial Version *****************************************************************/ #include <iostream> #define DEBUG (0) #define SCALE (10000) using namespac...
#include "field.hh" #include <vector> struct subfield { pos a,b,c,d,e,f; stone A,B,C,D,E,F; subfield(){ a = not_a_position; b = not_a_position; c = not_a_position; d = not_a_position; e = not_a_position; f = not_a_position; A = EMPTY; B = EMPTY; C = EMPTY; D = EMPTY; E = EMPTY; ...
#include <iostream> #include <gL\glew.h> #include <gl\glfw3.h> #include <glm/glm.hpp> #include <glm/gtx/transform.hpp> #include "Game.h" using namespace std; #define RED 1.0f, 0.0f, 0.0f #define GREEN 0.0f, 1.0f, 0.0f #define BLUE 0.0f, 0.0f, 1.0f #define BLACK 0.0f, 0.0f, 0.0f Game *game; int k...
// // main.cpp // 1256 // // Created by Pedro Neves Alvarez on 7/8/17. // Copyright © 2017 Pedro Neves Alvarez. All rights reserved. // #include <iostream> #include <vector> using namespace std; int main(int argc, const char * argv[]) { int tests,cut,tam,n; cout << "Enter the test cases"; cin...
/* * **************************************************************************** * * * * * Copyright 2008, xWorkshop Inc. * * * All rights reserved. * *...
// This file was generated based on /Users/r0xstation/18app/src/.uno/ux13/app18.unoproj.g.uno. // WARNING: Changes might be lost if you edit this file directly. #pragma once #include <Uno.String.h> #include <Uno.UX.Property-1.h> namespace g{namespace Uno{namespace UX{struct PropertyObject;}}} namespace g{namespace Uno...
#include "utils.h" PVOID utility::get_kernel_module_by_name(char* moduleName) { ULONG pool_size = 0; NTSTATUS status = ZwQuerySystemInformation(0xB, nullptr, 0, &pool_size); if (status != STATUS_INFO_LENGTH_MISMATCH) return 0; PSYSTEM_MODULE_INFORMATION system_module_info = (PSYSTEM_MODULE_INFORMATION)ExAlloca...
#include <stdio.h> int main(){ char strings[3][10] = {"Hello","World","Doodle"}; char *p_str[3]; for(int i=0; i<3; i++){ p_str[i] = strings[i]; } for(int i=0; i< 3; i++){ printf("%s", strings[i]); printf("%s", &strings[i][0]); printf("%s", p_str[i]); printf("\n"); } }
#include <iostream> using namespace std; int main(){ int input; cin >> input; if(input > 100000){ return 0; } for(int i = 1; i <= input; i++){ cout << i << "\n"; } return 0; }
/* * @Description: tf监听模块 * @Author: Ren Qian * @Date: 2020-02-06 16:10:31 */ #include "lidar_localization/tf_listener/tf_listener.hpp" #include <Eigen/Geometry> namespace lidar_localization { TFListener::TFListener(ros::NodeHandle& nh, std::string base_frame_id, std::string child_frame_id) :nh_(nh), base_fr...
// // nehe16.cpp // NeheGL // // Created by Andong Li on 9/15/13. // Copyright (c) 2013 Andong Li. All rights reserved. // #include "nehe16.h" const char* NEHE16::TITLE = "NEHE16"; GLfloat NEHE16::sleepTime = 0.0f; int NEHE16::frameCounter = 0; int NEHE16::currentTime = 0; int NEHE16::lastTime = 0; char NEHE16::...
/* IBM_PROLOG_BEGIN_TAG */ /* * Copyright 2003,2016 IBM International Business Machines Corp. * * 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/LIC...
/********************************************************************** * * Filename: timer.h * * Description: Header file for the Intel 8018xEB Timer class. * * Notes: * * * Copyright (c) 1998 by Michael Barr. This software is placed into * the public domain and may be used for any pur...
class CfgPatches { class ad_interaction_sys { units[] = {"adint_logic"}; magazines[] = {}; requiredVersion = 0.1; requiredAddons[] = {"A3_Modules_F","CBA_Extended_EventHandlers","CBA_MAIN","ace_main"}; author= "[101st.AD] Jay"; authorUrl = "http://www.airborne-division.de"; version = 1.0.3; versionStr ...
/* Name: Graham Atlee Course: csc1720 Date: 10/24/19 Location of program: ~/csc1720/Labs/lab9 This is implemenation code for methods in the unordedArrayListType. These functions override pure virtual functions from the base class. */ #include <iostream> #include "unorderedArrayListType.h" usi...
/***************************************************************************************************************** * File Name : minimumDistanceTwoNumbers.h * File Location : C:\Users\AVINASH\Desktop\CC++\Programming\src\sites\geeksforgeeks\arrays\page05\minimumDistanceTwoNumbers.h * Created on : Jan 8, 2...
// Copyright 1998-2014 Epic Games, Inc. All Rights Reserved. #include "FPSpaceInvaders.h" #include "FPSpaceInvaders.generated.inl" IMPLEMENT_PRIMARY_GAME_MODULE( FDefaultGameModuleImpl, FPSpaceInvaders, "FPSpaceInvaders" );
#include<bits/stdc++.h> using namespace std; int main(){ int N,M; cin >> N >> M; int A[N]; double sum = 0; for(int i =0; i<N; i++){ cin >> A[i]; sum += A[i]; } sum /= 4 *M; int count = 0; for(int i =0; i<N; i++){ if(A[i] >= sum)count++; } if(count >= M)cout<< "Y...
#include <iberbar/Utility/Xml/RapidXml.h> #include <iberbar/Utility/String.h> #include <iostream> #include <rapidxml.hpp> #include <rapidxml_print.hpp> #include <rapidxml_utils.hpp> namespace iberbar { namespace Xml { typedef rapidxml::xml_node< TCHAR > RapidContextNode; typedef rapidxml::file< CHAR > ...
#pragma once #include "stdafx.h" #include "dice.h" dice::dice(int val) { value = val; int vl; vl = val; model = models[vl - 1]; } void dice::change_value(double val) { value = val; int vl; vl = val; model = models[vl - 1]; } ostream& operator <<(std::ostream& out, dice& dc) { out << dc.model; return out; }
#include<bits/stdc++.h> #define rep(i, s, n) for (int i = (s); i < (int)(n); i++) #define INF ((1LL<<62)-(1LL<<31)) /*オーバーフローしない程度に大きい数*/ #define MOD 1000000007 using namespace std; using ll = long long; using Graph = vector<vector<int>>; using pint = pair<int,int>; const double PI = 3.14159265358979323846; ...
#pragma once #include "Common/GeomMath.h" #include <yaml-cpp/yaml.h> namespace YAML { template<> struct convert<Vector2f> { static Node encode(const Vector2f& rhs) { Node node; node.push_back(rhs[0]); node.push_back(rhs[1]); node.SetStyle(Emi...
#pragma once /* * Lanq(Lan Quick) * Solodov A. N. (hotSAN) * 2016 * LqPtdArr (LanQ ProTecteD ARRay) - Multithread array. */ #include "LqOs.h" #include "LqAlloc.hpp" #include "LqShdPtr.hpp" #include <vector> #include <type_traits> #include <functional> #pragma pack(push) #pragma pack(LQSTRUCT_ALIGN_MEM) template<...
/////////////////////////////////////////////////////////////////////////// // Copyright (C) 2009 Whit Armstrong // // // // This program is free software: you can redistribute it and/or modify // // it under the ...
/** * 1505080 * Error Detection using CRC checksum * Error Correction using Hamming distance **/ /** * Code to change consol text color: * #include <windows.h> * #include <iostream> * color = 4 RED * color = 10 GREEN * color = 11 CYAN * color = 15 WHITE * SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HAN...
#include <iostream> using namespace std; int main() { long long n, ans = 0, a[200001], next = 1000000001; cin >> n; for (int i = 0; i < n; i++) cin >> a[i]; for (int i = n - 1; i > -1; i--) { if (a[i] < next) { next = a[i]; ans += a[i]; } ...
class Matrix{ int row, col; int [][] storage; public: Matrix(int row, int col); ~Matrix(); void set(int row, int col, int data); int get(int row, int col); }
/**************************************************************************** ** Meta object code from reading C++ file 'CHTTPDownloader.h' ** ** Created by: The Qt Meta Object Compiler version 67 (Qt 5.3.2) ** ** WARNING! All changes made in this file will be lost! *****************************************************...
/* @author Aytaç Kahveci */ #ifndef KRLAXIS_H #define KRLAXIS_H #include <kuka_ros_open_comm/KRLVariable.h> #include <vector> #include <string> #include <map> #include <stdexcept> #include <sstream> #include <algorithm> /** * Represents a Axis Struct variable from the KRL language * * @author Aytac Kahveci */ cl...
#pragma once #include<iostream> #include<vector> using namespace std; void setZeroes(vector<vector<int>> &matrix) { if(matrix.size() == 0) return ; int col = matrix[0].size(); int row = matrix.size(); bool fc = false; bool fr = false; for(int i = 0; i < col; i++) { if(matrix[0][i] == 0)...
/* Create a Class Distance which contains members as Kilometer and Meter. Write C++ program to perform following functions: 1. To accept distance 2. To display distance 3. Overload += operator to add 2 distances. 4. Overload > operator to comapre 2 distances. */ #include<iostream> using namespace std; c...