text stringlengths 5 1.04M |
|---|
//{
#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef double lf;
typedef pair<ll,ll> ii;
#define REP(i,n) for(ll i=0;i<n;i++)
#define REP1(i,n) for(ll i=1;i<=n;i++)
#define FILL(i,n) memset(i,n,sizeof i)
#define X first
#define Y second
#define SZ(_a) (int)_a.size()
#define ALL(_a) _a.begin(),_... |
// Copyright (c) 2013-2015 Vittorio Romeo
// License: Academic Free License ("AFL") v. 3.0
// AFL License page: http://opensource.org/licenses/AFL-3.0
#ifndef SSVU_CORE_MPL_IMPL_REVERSE
#define SSVU_CORE_MPL_IMPL_REVERSE
#include "SSVUtils/Core/MPL/Impl/BaseTypes.hpp"
namespace ssvu
{
namespace MPL
{
namespace Impl
... |
// Copyright (c) 2014-2018 Daniel Kraft
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <names/main.h>
#include <chainparams.h>
#include <coins.h>
#include <consensus/validation.h>
#include <dbwrapper.h>
#include <hash... |
/*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
*/
#include "quic/state/QuicStreamManager.h"
#include <quic/state/QuicStreamUtilities.h>
namespace quic {
/**
* Updates the hea... |
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "build/build_config.h"
#include "base/single_thread_task_runner.h"
#include "ipc/ipc_test_base.h"
#include "base/command_line.h"
#include "... |
#pragma once
// This file is generated from the Game's Reflection data
#include <cstdint>
#include <RED4ext/Common.hpp>
#include <RED4ext/Scripting/Natives/Generated/AI/behavior/TaskDefinition.hpp>
namespace RED4ext
{
namespace AI::behavior {
struct CreateAlertedInfluenceMapTaskDefinition : AI::behavior::TaskDefini... |
/**
* @file AutoRec.hpp
* @brief AutoRec(Automatic Recursion) preprocessor prototype.
* @author zer0
* @date 2017-09-15
*
* @remarks
* In particular, the library must provide reentrance for BOOST_PP_FOR, BOOST_PP_REPEAT, and BOOST_PP_WHILE.
* There are two mechanisms that are used to accomplish this:
* ... |
/*******************************************************************************
* Copyright (c) 2015-2018 Skymind, Inc.
*
* This program and the accompanying materials are made available under the
* terms of the Apache License, Version 2.0 which is available at
* https://www.apache.org/licenses/LICENSE-2.0.
*
*... |
#include <iostream>
#include <cstdio>
using namespace std;
int main()
{
char a;
int b[27]={0};
while(a!='.')
{
cin>>a;
if(a>='a'&&a<='z')
{
b[a-'a'+1]++;
}
}
for(int i=1;i<=26;i++)
{
if(b[i]>0)
cout<<char(i+'a'-1)<<':'<<b[i]<<endl;
}
return 0;
} |
#ifndef EXAMPLE_TYPE_HPP
#define EXAMPLE_TYPE_HPP
// A hand-coded serializable
#include <Fw/Types/BasicTypes.hpp>
#include <Fw/Types/Serializable.hpp>
#include <Autocoders/Python/test/interface1/SomeStruct.hpp>
#if FW_SERIALIZABLE_TO_STRING
#include <Fw/Types/StringType.hpp>
#endif
namespace ANameSpace {
class ... |
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "ui/display/manager/update_display_configuration_task.h"
#include "ui/display/manager/configure_displays_task.h"
#include "ui/display/manager/di... |
INTERNAL void SetupAssetPath ()
{
gAssetPath = "assets/";
}
|
//
// Copyright (c) 2015-2020 Microsoft Corporation and Contributors.
// SPDX-License-Identifier: Apache-2.0
//
#include "mat/config.h"
#pragma once
#include "api/IRuntimeConfig.hpp"
namespace MAT_NS_BEGIN
{
static ILogConfiguration defaultRuntimeConfig{
{CFG_INT_TRACE_LEVEL_MIN, ACTTraceLevel::ACTTraceLe... |
/////////////////////////////////////////////////////////////////////////////
//
// (C) Copyright Ion Gaztanaga 2007-2014
//
// 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)
//
// See http://www.boost... |
/*
* Copyright 2008 by The University of Sheffield
*
* Copyright 2008 by IDIAP Research Institute
* http://www.idiap.ch
*
* See the file COPYING for the licence associated with this software.
*/
#include "SpeakerIDSocketSource.h"
Tracter::SpeakerIDSocketSource::SpeakerIDSocketSource(
voi... |
//
// Created by igor on 26/07/2021.
//
#include "tile.hh"
#include "json_reader.hh"
#include <neutrino/utils/strings/string_tokenizer.hh>
#include <neutrino/utils/strings/number_parser.hh>
namespace neutrino::tiled::tmx {
tile tile::parse (const reader& elt) {
try {
unsigned id = elt.get_uint_attribute (... |
/*
* Copyright 1999-2000,2004 The Apache Software Foundation.
*
* 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
*
* Unle... |
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "content/common/cursors/webcursor.h"
#include <windows.h>
#include "ui/base/cursor/cursor_lookup.h"
#include "ui/base/mojom/cursor_type.moj... |
/****************************************************************************************
* @author: kzvd4729 created: 2018-06-29 21:55:30
* solution_verdict: Accepted language: C++
* run... |
/*
* Author: Marcin Serwach
* License: MIT
*/
#ifndef VEHICLE_HPP
#define VEHICLE_HPP
struct IVehicle
{
virtual ~IVehicle() = default;
virtual void startEngine() = 0;
virtual void stopEngine() = 0;
virtual unsigned int getNumberOfWheels() const = 0;
};
#endif // VEHICLE_HPP
|
//
// Created by Denis Sancov on 29/12/2016.
//
#include "RotationAnimator.h"
using namespace csd;
RotationAnimator::RotationAnimator(Layer *layer, RotationAnimation const animation):_layer(layer), _animation(animation) {
}
void RotationAnimator::progress(uint32_t ticksMS) {
while (ticksMS > _lastTimeStampMS ... |
/*
* Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree.
*
* Referenced from modules/video_capture/video_capture.h
*/
#include "ffmpeg_video_capture_modu... |
#include "Cell.h"
Cell::Cell(int Id){
this->id = Id;
this->noOfPoints = 0;
this->noOfFaces = 0;
// Default order of the defining points
for (Index i=0; i<8; i++){
this->orderedPoints[i] = i;
};
// Default order of the defining faces
for (Index i=0; i<6; i++){
this->orderedFaces[i] = i;
};
this->cellTy... |
// Copyright 2018, Bosch Software Innovations GmbH.
//
// 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 applicabl... |
/*******************************************************************************
Copyright (c) 2020, Fabio Muratore, Honda Research Institute Europe GmbH, and
Technical University of Darmstadt.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted prov... |
#include <iostream>
#include <stdexcept>
#include <limits>
#include "CondFormats/Serialization/interface/Equal.h"
template <typename T>
void same(const T &first, const T &second) {
std::cout << "Same " << typeid(T).name() << std::endl;
if (not cond::serialization::equal(first, second))
throw std::logic_error(... |
/*
* Copyright (c) 2014-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
*/
#in... |
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "cc/output/compositor_frame.h"
#include "cc/quads/render_pass.h"
#include "cc/quads/solid_color_draw_quad.h"
#include "cc/quads/surface_draw_quad... |
// Copyright 2017 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "components/payments/content/utility/payment_manifest_parser.h"
#include "base/json/json_reader.h"
#include "base/strings/string_util.h"
#includ... |
//
// Copyright (c) 2015-2018 The PIVX developers
// Copyright (c) 2020 The Klimatas developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <iostream>
#include "genwit.h"
#include "chainparams.h"
#include "util.h"
... |
// matchertests.cpp : matcher unit tests
//
/**
* Copyright (C) 2008 10gen Inc.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License, version 3,
* as published by the Free Software Foundation.
*
* This program is d... |
#include <fstream>
using namespace std;
ifstream input("../README.md", ios::in);
ofstream output("yourOutputFile.txt", ios::out);
char letter;
int main(){
letter = input.get();
output.put(letter);
output << "David Britt";
input.close();
output.close();
return 0;
} |
// Autogenerated from CppHeaderCreator
// Created by Sc2ad
// =========================================================================
#pragma once
// Begin includes
#include "beatsaber-hook/shared/utils/typedefs.h"
#include "beatsaber-hook/shared/utils/byref.hpp"
#include "beatsaber-hook/shared/utils/il2cpp-ut... |
/*
Copyright 2020 The OneFlow Authors. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agre... |
/*
* Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
* Copyright (c) 2020-2021 Huawei Device Co., Ltd. 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. Redist... |
// Copyright 2013 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "base/memory/ptr_util.h"
#include "base/memory/raw_ptr.h"
#include "base/run_loop.h"
#include "base/test/task_environment.h"
#include "components... |
#include "String.hpp"
namespace FEngine
{
namespace String
{
void PrependZeros(std::string & str, int totalDigits)
{
int zerosToPrepend = totalDigits - str.length();
for(int i = 0; i < zerosToPrepend; i++)
{
str = std::st... |
// Copyright AudioKit. All Rights Reserved. Revision History at http://github.com/AudioKit/AudioKit/
#ifdef __cplusplus
#pragma once
#import "AKSoundpipeKernel.hpp"
#import <vector>
#import "AKBankDSPKernel.hpp"
/*static inline double pow2(double x) {
return x * x;
}*/
#import "AKDSPKernel.hpp"
class AKFilterSy... |
/**********************************************************************
* Copyright (c) 2008-2015, Alliance for Sustainable Energy.
* All rights reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by t... |
#ifndef CPPURSES_DEMOS_PALETTE_COLOR_DISPLAY_HPP
#define CPPURSES_DEMOS_PALETTE_COLOR_DISPLAY_HPP
#include <cppurses/painter/color.hpp>
#include <cppurses/widget/layouts/horizontal.hpp>
#include <cppurses/widget/layouts/vertical.hpp>
#include <cppurses/widget/widget.hpp>
#include <cppurses/widget/widgets/text_display.h... |
//////////////////////////////////////////////////////////////////////////
//
// Copyright (c) 2011-2013, John Haddon. All rights reserved.
// Copyright (c) 2012, Image Engine Design Inc. All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted pro... |
/*
* If not stated otherwise in this file or this component's LICENSE file the
* following copyright and licenses apply:
*
* Copyright 2020 RDK Management
*
* 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 cop... |
/*
Copyright (c) 2005-2019, University of Oxford.
All rights reserved.
University of Oxford means the Chancellor, Masters and Scholars of the
University of Oxford, having an administrative office at Wellington
Square, Oxford OX1 2JD, UK.
This file is part of Chaste.
Redistribution and use in source and binary forms... |
/*
Copyright 2019 Alain Dargelas
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 writing, softwar... |
/**
* @file
* @author __AUTHOR_NAME__ <mail@host.com>
* @copyright 2021 __COMPANY_LTD__
* @license <a href="https://opensource.org/licenses/MIT">MIT License</a>
*/
/**
* The Pointer Down Input Event.
*
* This event is dispatched by the InputPlugin belonging to a Scene if a pointer
* is pressed down anywhere... |
//---------------------------------------------------------------------------
#include "uSfgMetaData.h"
#pragma hdrstop
#include "uSfgBrowseObf.h"
//---------------------------------------------------------------------------
#pragma package(smart_init)
namespace SfgBrowse {
//-------------------------------------------... |
#include "random_c8.h"
random_c8::random_c8() {
random_engine = std::mt19937_64(rddev());
}
uint8_t random_c8::get() {
return distribution(random_engine);
} |
//
// Copyright 2018 Google LLC
//
// 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 ... |
#include <iostream>
using namespace std;
int main()
{
int n,r,sum=0,t;
cout<<"Enter the Number= ";
cin>>n;
t=n;
while(n>0)
{
r=n%10;
sum=sum+(r*r*r);
n=n/10;
}
if(t==sum)
cout<<"Armstrong Number.";
else
cout<<"Not Armstrong Number.";
return 0;
}
|
// Distributed under the MIT License.
// See LICENSE.txt for details.
#include "Framework/TestingFramework.hpp"
#include <cstddef>
#include <memory>
#include <string>
#include <tuple>
#include <utility>
#include <vector>
#include "DataStructures/DataBox/DataBox.hpp"
#include "DataStructures/DataBox/Tag.hpp"
#include... |
// RUN: %clang_cc1 -fsyntax-only -verify %s
// expected-no-diagnostics
enum gcc_type_class {
no_type_class = -1,
void_type_class, integer_type_class, char_type_class,
enumeral_type_class, boolean_type_class,
pointer_type_class, reference_type_class, offset_type_class,
real_type_class, complex_type_class,
... |
// ------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License (MIT). See License.txt in the repo root for license information.
// ------------------------------------------------------------
#include "stdafx.h"
using na... |
#include "dense-reconstruction/aslam-cv-interface.h"
#include <algorithm>
#include <iostream>
#include <iterator>
#include <string>
#include <vector>
#include <Eigen/Dense>
#include <aslam/cameras/camera-pinhole.h>
#include <aslam/cameras/camera.h>
#include <aslam/cameras/distortion.h>
#include <aslam/common/pose-typ... |
#ifndef STAN_MATH_PRIM_PROB_POISSON_BINOMIAL_LCCDF_HPP
#define STAN_MATH_PRIM_PROB_POISSON_BINOMIAL_LCCDF_HPP
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/err.hpp>
#include <stan/math/prim/fun/binomial_coefficient_log.hpp>
#include <stan/math/prim/fun/log.hpp>
#include <stan/math/prim/fun/log1m.hpp>
#in... |
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// ---
// Author: Sainbayar Sukhbaatar
// Dai Mikurube
//
#include "deep-heap-profile.h"
#ifdef DEEP_HEAP_PROFILE
#include <algorithm>
#incl... |
/*
* Copyright (c) Contributors to the Open 3D Engine Project.
* For complete copyright and license terms please see the LICENSE at the root of this distribution.
*
* SPDX-License-Identifier: Apache-2.0 OR MIT
*
*/
// Description : Implementation of IAnimSequence interface.
#include "Maestro_precompiled.h"
#... |
#include <bits/stdc++.h>
using namespace std;
using pii = pair<int, int>;
const int inf=1e9+3;
#define all(x) (x).begin(),(x).end()
#define sync() {ios_base::sync_with_stdio(0); cin.tie(0);cout.tie(0);} //do not use
int n,m;
int state[32003];
vector<int> ed[32003];
vector<int> ans;
bool hascycle=false;
void dfs(int cu... |
/* Copyright 2019 The Apollo Authors. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agree... |
#include "simulation/ElementCommon.h"
static int update(UPDATE_FUNC_ARGS);
static int graphics(GRAPHICS_FUNC_ARGS);
void Element::Element_PUMP()
{
Identifier = "DEFAULT_PT_PUMP";
Name = "PUMP";
Colour = PIXPACK(0x0A0A3B);
MenuVisible = 1;
MenuSection = SC_POWERED;
Enabled = 1;
Advection = 0.0f;
AirDrag = 0.0... |
#include "stdafx.h"
#include "sphere.h"
bool sphere::hit(const ray& r, float t_min, float t_max, hit_record& rec) const {
vec3 oc = r.origin() - center;
float a = dot(r.direction(), r.direction());
float b = dot(oc, r.direction());
float c = dot(oc, oc) - radius * radius;
float discriminant = b * b - a * c;
if (... |
#pragma once
// ARKSurvivalEvolved (329.9) SDK
#ifdef _MSC_VER
#pragma pack(push, 0x8)
#endif
#include "ARKSurvivalEvolved_DinoDropInventoryComponent_Carnivore_Huge_Leed_Alpha_structs.hpp"
namespace sdk
{
//---------------------------------------------------------------------------
//Classes
//--------------------... |
#include <iostream>
//#include <core/ctti/ctti.hpp>
//#include <core/rtti/type.hpp>
using namespace std;
//using namespace core::collections;
//using namespace core::ctti;
//using namespace core;
namespace Game {
class Entity {
// DECLARE_STRUCT(Game::Entity)
// DECLARE_PROPERTY(m_int, attr::Name("dupea... |
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required... |
// Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
#include "bin/dfe.h"
#include <memory>
#include "bin/abi_version.h"
#include "bin/dartutils.h"
#inclu... |
// Copyright (c) 2013-2015 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
// Unit tests for alert system
#include "alert.h"
#include "chain.h"
#include "chainparams.h"
#include "clientversion.h"
#in... |
#include <math.h>
#include <algorithm>
#include <DDImage/Row.h>
#include <DDImage/NukeWrapper.h>
#include "LayerSet.h"
#include "LayerSetKnob.h"
namespace GradeBeauty {
static const char* const HELP =
"Provides artist friendly controls to manipulate multichannel cg render passes\n\n"
"GradeBeauty wi... |
// Copyright (c) 2011-2014 The Bitcoin developers
// Copyright (c) 2014-2015 The Dash developers
// Copyright (c) 2015-2017 The Altair developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "guiutil.h"
#include... |
////////////////////////////////////////////////////////////////////////////////////////
//
// Nestopia - NES/Famicom emulator written in C++
//
// Copyright (C) 2003-2008 Martin Freij
//
// This file is part of Nestopia.
//
// Nestopia is free software; you can redistribute it and/or modify
// it under the te... |
// Copyright (c) 2011-2013 The Bitcoin developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "signverifymessagedialog.h"
#include "ui_signverifymessagedialog.h"
#include "addressbookpage.h"
#include "base58.h"... |
//------------------------------------------------------------
// snakeoil (c) Alexis Constantin Link
// Distributed under the MIT license
//------------------------------------------------------------
#ifndef _SNAKEOIL_COLLIDE_2D_COLLISION_CIRCLE_LINE_HPP_
#define _SNAKEOIL_COLLIDE_2D_COLLISION_CIRCLE_LINE_HPP_
#incl... |
template<class T>
CompactSoaPool<T>::CompactSoaPool(Scope& a, uint size)
: m_pool(a,size)
, m_map(a,size)
, m_data(a,size)
{
}
template<class T>
typename CompactSoaPool<T>::Proxy CompactSoaPool<T>::operator[](uint handle)
{
eiDEBUG( m_pool.Dbg_ValidateIndex(handle) );
uint physical = m_map.ToPhysical(handle);
retu... |
// RUN: %dexter -- -fno-unroll-loops
int
lul(int i, int other)
{
volatile int foo = i;
return foo + other;
}
int
somearray[] = {
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 };
int
main()
{
int sum = 0;
int *ptr1 = &somearray[0];
int *ptr2 = &somearray[1];
int i = 0;
for (i = 0; i < 10; i++, ptr1++, ptr2++) {
... |
// ***************************************************************************
// TcpSocketEngine_p.cpp (c) 2011 Derek Barnett
// Marth Lab, Department of Biology, Boston College
// ---------------------------------------------------------------------------
// Last modified: 8 December 2011 (DB)
// --------------------... |
#if defined(_DEBUG) || defined(DEBUG)
#include "sys/sock.h"
#include "http-client.h"
static void http_client_test_onreply(void* param, int code)
{
http_client_t* http = (http_client_t*)param;
if(0 == code)
{
const char* server = http_client_get_header(http, "Server");
if(server)
printf("http server: %s\n", s... |
//=================================================================================================
/*!
// \file src/mathtest/smatsmatmult/SCbMCa.cpp
// \brief Source file for the SCbMCa sparse matrix/sparse matrix multiplication math test
//
// Copyright (C) 2012-2019 Klaus Iglberger - All Rights Reserved
//
// Th... |
// Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2016 The PlanBcoin developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "sync.h"
#include "clientversion.h"
#include "util.h"
#include "warnings.h"... |
/* -*- Mode: C++; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */
/*
* Copyright 2015 Couchbase, Inc.
*
* 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
*
* ... |
#include<vector>
#include<algorithm>
#include<iostream>
using namespace std;
class Solution {
public:
int findMinMoves(vector<int>& machines) {
int len = machines.size();
int sum = 0;
for (auto &num : machines)
sum += num;
if (sum % len != 0) return -1;
int avg =... |
#include <_gm_msg_gmcall_list_response_zocl.hpp>
START_ATF_NAMESPACE
void _gm_msg_gmcall_list_response_zocl::Init()
{
using org_ptr = void (WINAPIV*)(struct _gm_msg_gmcall_list_response_zocl*);
(org_ptr(0x1402ab6a0L))(this);
};
void _gm_msg_gmcall_list_response_zocl::_call_node::Init()... |
// See the file "COPYING" in the main distribution directory for copyright.
#include "Component.h"
#include "Manager.h"
#include "../Desc.h"
#include "../util.h"
namespace zeek::logging {
Component::Component(const std::string& name, factory_callback arg_factory)
: plugin::Component(plugin::component::WRITER, name)... |
/* TEMPLATE GENERATED TESTCASE FILE
Filename: CWE590_Free_Memory_Not_on_Heap__delete_struct_static_10.cpp
Label Definition File: CWE590_Free_Memory_Not_on_Heap__delete.nonpointer.label.xml
Template File: sources-sink-10.tmpl.cpp
*/
/*
* @description
* CWE: 590 Free Memory Not on Heap
* BadSource: static Data... |
/*
* Copyright 2000-2021, ArmyKnife Team. All rights reserved.
* Distributed under the terms of the MIT License.
*/
#include "musicbrainzquery.h"
#include <exception>
#include <Debug.h>
#include <musicbrainz5/Artist.h>
#include <musicbrainz5/ArtistCredit.h>
#include <musicbrainz5/Medium.h>
#include <musicbrainz5/... |
//-----------------------------------------------------------------------------
//
// File: uniqid.inl
// Copyright (C) 1994-1997 Microsoft Corporation
// All rights reserved.
//
// Inline function definitions for the Espresso Unique ID. This file should
// ONLY be included by uniqid.h.
//
//------... |
/*
Copyright The Overlaybd Authors
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 i... |
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the file PATENTS. All contribut... |
//============================================================================//
// //
// FluidProp C++ interface //
// ----------------------- ... |
/*
* Copyright 2011-2013 Blender Foundation
*
* 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 ag... |
#include <bits/stdc++.h>
using namespace std;
const int N = 2005;
char s[N], t[N];
int na[N][26], nb[N][26], nxt[26];
int n, m, a[N], b[N], tot = 1, p = 1, f[N][N << 1];
struct SAM {
int par, ch[26], len;
} sam[N << 1];
void insert(int x) {
int np = ++tot;
sam[np].len = sam[p].len + 1;
while (p && !sam[... |
#include "modmanager.h"
#include "ui_modmanager.h"
#include <QMessageBox>
#include <QSettings>
ModManager::ModManager(QWidget *parent) :
QWidget(parent),
ui(new Ui::ModManager)
{
ui->setupUi(this);
}
ModManager::~ModManager()
{
delete ui;
}
void ModManager::AddRoot(QString name, QString version, QS... |
//
// Project Name: Kratos
// Last Modified by: $Author: gcasas $
// Date: $Date: 2016-03-08 08:56:42 $
//
//
#include "derivative_recovery.h"
namespace Kratos
{
template <std::size_t TDim>
void DerivativeRecovery<TDim>::RecoverGradientOfAScalar(const VariableData& origin_variable, cons... |
#include "commands/CmdDriveWithXbox.h"
#include "GamepadMap.h"
#include "frc/smartdashboard/SmartDashboard.h"
//Local Prototypes
void Drive_Tank(Drivetrain *drivetrain, float left, float right);
void Drive_Test1(Drivetrain *drivetrain, float l_y, float l_x, float r_x);
void Drive_Test2(Drivetrain *drivetrain, float ... |
// Copyright 2012 Viewfinder. All rights reserved.
// Author: Ben Darnell
//
// See ImageIndex.mm for comments. This file contains the core of the fingerprinting algorithm,
// extracted into a separate file so it can be used in other contexts.
#include <Accelerate/Accelerate.h>
#include <CoreGraphics/CGContext.h>
#in... |
#ifndef FUNNYOS_STDLIB_SRC_PLATFORM_HPP
#define FUNNYOS_STDLIB_SRC_PLATFORM_HPP
#include "File.hpp"
#include "Functional.hpp"
#include "IntegerTypes.hpp"
#ifdef F_STDLIB_PLATFORM_EXTERN
#define _EXTERN extern
#else
#define _EXTERN
#endif
/**
* Platform-specific functions
*/
namespace FunnyOS::_Platform {
[[no... |
/* Copyright 2019 The TensorFlow Authors. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or a... |
#include "askpassphrasedialog.h"
#include "ui_askpassphrasedialog.h"
#include "guiconstants.h"
#include "walletmodel.h"
#include <QMessageBox>
#include <QPushButton>
#include <QKeyEvent>
AskPassphraseDialog::AskPassphraseDialog(Mode mode, QWidget *parent) :
QDialog(parent),
ui(new Ui::AskPassphraseDialog),
... |
// Copyright (c) 2011-present, Facebook, Inc. All rights reserved.
// This source code is licensed under the BSD-style license found in the
// LICENSE file in the root directory of this source tree. An additional grant
// of patent rights can be found in the PATENTS file in the same directory.
//
// Copyright (c) ... |
#include <iostream>
#include <boost/filesystem.hpp>
#include "../Includes/IParserApi.h"
#include "../Includes/WTSVariant.hpp"
#include "../Includes/WTSContractInfo.hpp"
#include "../Includes/WTSDataDef.hpp"
#include "../Share/DLLHelper.hpp"
#include "../Share/StrUtil.hpp"
#include "../WTSTools/WTSBaseData... |
//$Id$
//------------------------------------------------------------------------------
// SolarRadiationPressure
//------------------------------------------------------------------------------
// GMAT: General Mission Analysis Tool.
//
// Copyright (c) 2002 - 2015 United States Gove... |
// Copyright 2017 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include <algorithm>
#include <array>
#include <string>
#include "base/bind.h"
#include "base/logging.h"
#include "base/metrics/histogram_functions.h"
#i... |
////////////////////////////////////////////////////////////////////////////
// Module : script_binder_object_script.cpp
// Created : 29.03.2004
// Modified : 29.03.2004
// Author : Dmitriy Iassenev
// Description : Script object binder script export
///////////////////////////////////////////////////////////////... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.