text stringlengths 7 961k |
|---|
// RUN: clang-cc -fsyntax-only -verify -faccess-control -std=c++0x -Wsign-compare %s
// C++ rules for ?: are a lot stricter than C rules, and have to take into
// account more conversion options.
// This test runs in C++0x mode for the contextual conversion of the condition.
struct ToBool { explicit operator bool(); ... |
//<developer>
// <name>linapex 曹一峰</name>
// <email>linapex@163.com</email>
// <wx>superexc</wx>
// <qqgroup>128148617</qqgroup>
// <url>https://jsq.ink</url>
// <role>pku engineer</role>
// <date>2019-03-16 19:44:15</date>
//</624457041506734080>
/*
*@文件
*@eos/license中定义的版权
**/
#pragma once
... |
#include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <bits/stdc++.h>
using namespace std;
char ch[300][300];
bool sure()
{
if(ch[0][0]=='O'&&ch[0][1]=='O'&&ch[0][2]=='O')return 1;
if(ch[1][0]=='O'&&ch[1][1]=='O'&&ch[1][2]=='O')return 1;
if(ch[2][0]=='O'&&ch[2][1]=='O'&&ch... |
#ifndef LOCIC_SUPPORT_ARRAY_HPP
#define LOCIC_SUPPORT_ARRAY_HPP
#include <cassert>
#include <initializer_list>
#include <stdexcept>
#include <type_traits>
#include <vector>
#include <locic/Support/Copy.hpp>
#include <locic/Support/Hasher.hpp>
namespace locic{
template <typename T, size_t BaseSize>
class ArraySta... |
//
// Created by jhwangbo on 18. 5. 29.
//
#ifndef RAISIM_LOADERS_HPP
#define RAISIM_LOADERS_HPP
#include "ArticulatedSystem.hpp"
#include <map>
namespace raisim {
inline int countNumOfSpaces(const char *str) {
int iSpaces = 0;
for (unsigned int iLoop = 0; iLoop < (sizeof(str) / sizeof(str[0])); iLoop++)
if... |
// Copyright (c) 2019-2020 The Passion developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "qt/passion/settings/settingsexportcsv.h"
#include "qt/passion/settings/forms/ui_settingsexportcsv.h"
#include <QFile>
#i... |
// Copyright (C) 2000, International Business Machines
// Corporation and others. All Rights Reserved.
// This code is licensed under the terms of the Eclipse Public License (EPL).
#if defined(_MSC_VER)
// Turn off compiler warning about long names
#pragma warning(disable : 4786)
#endif
#include "CoinUtilsConfig.h"
... |
#include "pch.h"
#include "SwapChainHelper.hpp"
namespace D3D12TranslationLayer
{
SwapChainHelper::SwapChainHelper( IDXGISwapChain3* swapChain ) : m_swapChain( swapChain )
{
}
HRESULT SwapChainHelper::StandardPresent( ImmediateContext& context, D3DKMT_PRESENT *pKMTPresent, Resource& presentingResource... |
#pragma once
template <typename T, size_t N, size_t M>
std::ostream& operator<<(std::ostream& os, const tmat<T, N, M>& m) {
os << "[";
os << m.data[0];
for (size_t i = 1; i < M; ++i)
os << ", " << m.data[i];
os << "]";
return os;
} |
/* Copyright 2015 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... |
/**
* \file src/tensorrt/impl/tensorrt_opr.cpp
* MegEngine is Licensed under the Apache License, Version 2.0 (the "License")
*
* Copyright (c) 2014-2021 Megvii Inc. All rights reserved.
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
*... |
#include "Globals.h" // NOTE: MSVC stupidness requires this to be the same across all modules
#include "World.h"
#include "BlockInfo.h"
#include "ClientHandle.h"
#include "Physics/Explodinator.h"
#include "Server.h"
#include "Root.h"
#include "IniFile.h"
#include "Generating/ChunkDesc.h"
#include "Generating/Composab... |
//******************************************************************************
// RCF - Remote Call Framework
//
// Copyright (c) 2005 - 2013, Delta V Software. All rights reserved.
// http://www.deltavsoft.com
//
// RCF is distributed under dual licenses - closed source or GPL.
// Consult your particular license for... |
// Copyright (c) 2011-2014 The Bitcoin developers
// Copyright (c) 2014-2015 The Dash developers
// Copyright (c) 2015-2017 The SPLASHFARMS developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#if defined(HAVE_CONFIG_H... |
/*----------------------------------------------------------------------------*/
/* Copyright (c) 2016-2019 FIRST. All Rights Reserved. */
/* Open Source Software - may be modified and shared by FRC teams. The code */
/* must be accompanied by the FIRST BSD license file in the root directory of... |
/*-----------------------------------------------------------------------------------------------
The MIT License (MIT)
Copyright (c) 2015-2021 OSRE ( Open Source Render Engine ) by Kim Kulling
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation f... |
/*
* Copyright 2010-2017 Amazon.com, Inc. or its affiliates. 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.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" fil... |
/*
* Copyright (C) 2005 - 2012 MaNGOS <http://www.getmangos.com/>
*
* Copyright (C) 2008 - 2012 Trinity <http://www.trinitycore.org/>
*
* Copyright (C) 2006 - 2012 ScriptDev2 <http://www.scriptdev2.com/>
*
* Copyright (C) 2012 - 2012 FrenchCORE <http://www.frcore.com/>
*
* This program is free software; you ca... |
#include "pessoa.h"
Pessoa::Pessoa(){
cout << "Instanciando uma pessoa" << endl;
}
void Pessoa::set_nome(const string &nome){
this->nome = nome;
}
void Pessoa::set_cpf(const string &cpf){
this->cpf = cpf;
}
void Pessoa::set_email(const string &email){
this->email = email;
}
string Pessoa::get_email(){
... |
/* Copyright 2015 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... |
//=================================================================================================
/*!
// \file src/mathtest/dmatdmatsub/SHaSHb.cpp
// \brief Source file for the SHaSHb dense matrix/dense matrix subtraction math test
//
// Copyright (C) 2012-2019 Klaus Iglberger - All Rights Reserved
//
// This fil... |
/*
* Copyright (c) 2016, The OpenThread Authors.
* 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 ... |
// ------------------------------------------------------------------------------------------------
#include "ResultSet.hpp"
// ------------------------------------------------------------------------------------------------
#include <cstdlib>
// -----------------------------------------------------------------------... |
/*
* Copyright 2017-2020 Amazon.com, Inc. or its affiliates. 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.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0/
*
* or in the "... |
// Copyright (c) 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 "chrome/browser/chromeos/accessibility/accessibility_manager.h"
#include "ash/audio/sounds.h"
#include "ash/autoclick/autoclick_controller.h... |
// Copyright 2020 Phyronnaz
#include "VoxelTools/VoxelPaintMaterial.h"
#include "VoxelUtilities/VoxelMathUtilities.h"
void FVoxelPaintMaterial::ApplyToMaterial(FVoxelMaterial& Material, float Strength) const
{
// Else goes way beyond target
Strength = FMath::Clamp(Strength, -1.f, 1.f);
switch (Type)
{
case EVo... |
// Copyright (c) 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.
#include <vector>
#include "prevector.h"
#include "random.h"
#include "serialize.h"
#include "streams.h"
#include "test/test_ill... |
/*
* Copyright (c) 2018-present, aliminabc@gmail.com.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
#include "AlMatrix.h"
#include "Logcat.h"
#include <cmath>
#define TAG "AlMatrix"
AlMatrix &AlMatrix::fromArray(float *array) {
st... |
// Copyright (c) 2010 Satoshi Nakamoto
// Copyright (c) 2009-2014 The Bitcoin developers
// Copyright (c) 2014-2015 The Dash developers
// Copyright (c) 2015-2020 The PIVX developers
// Copyright (c) 2021-2022 The DECENOMY Core Developers
// Distributed under the MIT software license, see the accompanying
// file COPYI... |
#include <stdio.h>
#include <iostream>
int main()
{
return 0;
} |
#include "linked_stack.hpp"
#include <stdexcept> // logic_error
namespace itis {
void LinkedStack::Push(Element e) {
SinglyNode *new_node = new SinglyNode(e, top_);
top_=new_node;
size_++;
}
void LinkedStack::Pop() {
if (top_ == nullptr) {
throw std::logic_er... |
/*
* Copyright 2010-2017 Amazon.com, Inc. or its affiliates. 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.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" fil... |
//
// FILE: ADS1X15.cpp
// AUTHOR: Rob Tillaart
// VERSION: 0.3.4
// DATE: 2013-03-24
// PUPROSE: Arduino library for ADS1015 and ADS1115
// URL: https://github.com/RobTillaart/ADS1X15
//
// HISTORY:
// 0.0.0 2013-03-24 initial version
// 0.0.1 2013-03-24 first working version
// 0.1.0 2017-07-31... |
#include "wled.h"
/*
* Color conversion methods
*/
void colorFromUint32(uint32_t in, bool secondary)
{
if (secondary) {
colSec[3] = in >> 24 & 0xFF;
colSec[0] = in >> 16 & 0xFF;
colSec[1] = in >> 8 & 0xFF;
colSec[2] = in & 0xFF;
} else {
col[3] = in >> 24 & 0xFF;
col[0] = in >> 16... |
/*
Copyright (c) 1999 - 2010, Vodafone Group Services 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:
* Redistributions of source code must retain the above copyright notice, this list of condit... |
// ARKSurvivalEvolved (329.9) SDK
#ifdef _MSC_VER
#pragma pack(push, 0x8)
#endif
#include "ARKSurvivalEvolved_DmgType_Melee_Dino_Molerat_parameters.hpp"
namespace sdk
{
//---------------------------------------------------------------------------
//Functions
//-------------------------------------------------------... |
// -*- C++ -*-
//
// ----------------------------------------------------------------------
//
// Brad T. Aagaard, U.S. Geological Survey
//
// This code was developed as part of the Computational Infrastructure
// for Geodynamics (http://geodynamics.org).
//
// Copyright (c) 2010-2017 University of California, Davis
/... |
//===- ConstantPools.cpp - ConstantPool class --*- C++ -*---------===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------... |
#include <common/test/doctest.h>
#include <common/common.hpp>
#include <string>
#include "runtime/runtime-commons.h"
TEST_SUITE("Runtime commons test") {
TEST_CASE("getParamInfo") {
SUBCASE(
"should do nothing if param_value and param_value_size_ret are not "
"set") {
a... |
#include <iostream>
#include <stdlib.h>
using namespace std;
class ChunkCopy
{
int start_;
int len_;
int blockSize_;
int cur_;
public:
ChunkCopy(int start, int len, int blockSize)
{
start_ = start;
len_ = len;
blockSize_ = blockSize;
cur_ = start;
}
... |
#include <iostream>
#include <fstream>
#include <chrono>
#include <string>
#include <memory>
#include <cmath>
#include <gkls_function.hpp>
#include <grishagin_function.hpp>
#include <cmdline.h>
#include "solver.hpp"
using namespace ags;
void saveStatistics(const std::vector<std::vector<unsigned>>& stat, const cmdli... |
/*
* TechFactory.hu
* LCD kijelzőhöz magyar ékezetes karakter támogatás
* (LiquidCrystal_I2C class-hoz készült kiegészítő)
*/
#include "LCDCharConverter.h"
#include "LCDCharmap.h"
LCDCharConverter::LCDCharConverter(LiquidCrystal_I2C* lcd) {
_lcd = lcd;
}
void LCDCharConverter::display(char* message, uint8_t col, ui... |
/**
* File: Task.cpp
* Description:
* SoftTimer library is a lightweight but effective event based timeshare solution for Arduino.
*
* Author: Balazs Kelemen
* Contact: prampec+arduino@gmail.com
* Copyright: 2012 Balazs Kelemen
* Copying permission statement:
This file is part of SoftTimer.
SoftTimer i... |
///////////////////////////////////////////////////////////////
// Copyright 2011 John Maddock. Distributed under the Boost
// Software License, Version 1.0. (See accompanying file
// LICENSE_1_0.txt or copy at https://www.boost.org/LICENSE_1_0.txt
#include "../sf_performance.hpp"
void nct_tests_11()
{
#ifdef TEST... |
/**
* Segmented Sieve (Print Primes in a Range)
*
* Given a range [low, high], print all primes in this range?
* For example, if the given range is [10, 20], then output is 11, 13, 17, 19.
*
* URL: https://www.geeksforgeeks.org/segmented-sieve-print-primes-in-a-range/
*
*/
#include <iostream>
#include <vector>... |
#ifndef BOOST_STATECHART_EVENT_PROCESSOR_INCLUDED
#define BOOST_STATECHART_EVENT_PROCESSOR_INCLUDED
//////////////////////////////////////////////////////////////////////////////
// Copyright 2002-2008 Andreas Huber Doenni
// Distributed under the Boost Software License, Version 1.0. (See accompany-
// ing file LICENSE... |
#include "c/schemas/ModioLogo.h"
#include "Utility.h" // for hasKey
#include "c/ModioC.h" // for ModioDownload
extern "C"
{
void modioInitLogo(ModioLogo* logo, nlohmann::json logo_json)
{
logo->filename = NULL;
if(modio::hasKey(logo_json, "filename"))
{
std::string fi... |
#include <stdio.h>
class c{
public:
char f;
};
class c2{
public:
int f2;
};
static class sss: public c, public c2{
public:
char m;
} sss;
#define _offsetof(st,f) ((char *)&((st *) 16)->f - (char *) 16)
int main (void) {
printf ("++Class with char inhereting classes with char & int:\n");
printf ("size=%d... |
/*
* 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) 2012 The Chromium OS Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Unit tests for VaultKeyset.
#include "cryptohome/vault_keyset.h"
#include <base/files/file_path.h>
#include <base/logging.h>
#include <brillo/... |
// atcoder/abc190/F/main.cpp
// author: @___Johniel
// github: https://github.com/johniel/
#include <bits/stdc++.h>
#define each(i, c) for (auto& i : c)
#define unless(cond) if (!(cond))
using namespace std;
template<typename P, typename Q> ostream& operator << (ostream& os, pair<P, Q> p) { os << "(" << p.first << ... |
#include <random>
#include "catch.hpp"
#include "memory/memory_stat.hpp"
using openperf::memory::internal::task_memory_stat;
auto random_memory_stat()
{
static auto rnd = std::mt19937_64{};
return task_memory_stat{
.timestamp = task_memory_stat::timestamp_t(
std::chrono::system_clock::now(... |
/*=============================================================================
Copyright (c) 2005-2008 Hartmut Kaiser
Copyright (c) 2005-2010 Joel de Guzman
Copyright (c) 2014-2015 John Fletcher
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or co... |
#include "primitive-factory.hpp"
#include "logger/gl-log-handler.hpp"
#include "graphics/vertex-array.hpp"
#include "graphics/shader.hpp"
#include "graphics/texture.hpp"
#include "graphics/texture-array.hpp"
PrimitiveFactory::PrimitiveFactory()
: m_shaderBasic("res/shaders/basic/basic.vert", "res/shaders/basic/basic... |
#include "texture.h"
#include "utils.h"
vec3 checker_texture::value(float u, float v, const vec3 &p) const {
//(0,0,0) = positive -> even
//(0.2,0.2,0.2) = sin(2) * sin(2) * sin(2) = positive ->even
//(0.4,0.4,0.4) = sin(4) * sin(4) * sin(4) = negative -> odd texture
float sin_sign =
std::sin(10 * p.x()... |
// Swap 2 numbers
#include<iostream.h>
#include<conio.h>
void main()
{
clrscr();
int num,mod,new_num=0;
cout<<"Enter a number:";
cin>>num;
while(num!=0)
{
mod=num%10;
new_num=new_num*10+mod;
num/=10;
}
cout<<"The reversed form of the entered no. is: "<<new_num;
getch();
} |
// Copyright 2008-present Contributors to the OpenImageIO project.
// SPDX-License-Identifier: BSD-3-Clause
// https://github.com/OpenImageIO/oiio
extern "C" { // ffmpeg is a C api
#include <cerrno>
#include <libavcodec/avcodec.h>
#include <libavformat/avformat.h>
#include <libswscale/swscale.h>
#if LIBAVCODEC_VERSIO... |
// 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 "chrome/browser/chromeos/policy/device_local_account_policy_service.h"
#include "base/bind.h"
#include "base/bind_helpers.h"
#include "base/... |
/******************************************************************************
* Copyright 2017 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
... |
// Copyright (c) YugaByte, 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
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writ... |
// Copyright (c), Firelight Technologies Pty, Ltd. 2012-2019.
#include "FMODEventControlSectionTemplate.h"
#include "FMODAmbientSound.h"
#include "FMODAudioComponent.h"
#include "Evaluation/MovieSceneEvaluation.h"
#include "IMovieScenePlayer.h"
struct FPlayingToken : IMovieScenePreAnimatedToken
{
FPlayingToken(UO... |
//------------------------------------------------------------
// snakeoil (c) Alexis Constantin Link
// Distributed under the MIT license
//------------------------------------------------------------
#include "win32_window_handle.h"
using namespace so_app ;
using namespace so_app::so_win32 ;
//*********************... |
// Copyright 2017 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#define MAGMA_DLOG_ENABLE 1
#include <fcntl.h>
#include <lib/fdio/directory.h>
#include <lib/zx/channel.h>
#include <poll.h>
#include <thread>
#include ... |
#include <iostream>
#include "Bounds.h"
#include "CSE.h"
#include "Debug.h"
#include "Deinterleave.h"
#include "ExprUsesVar.h"
#include "IR.h"
#include "IREquality.h"
#include "IRMutator.h"
#include "IROperator.h"
#include "IRPrinter.h"
#include "IRVisitor.h"
#include "Param.h"
#include "PurifyIndexMath.h"
#include "S... |
// Copyright (c) 2016-2019 Dalton Hildreth
// This file is under the MIT license. See the LICENSE file for details.
#include "ui.h"
#include <iostream>
namespace ui {
float cursor_sensitivity = 1.f;
glm::vec2 d_cursor_pos = glm::vec2(0.f, 0.f);
glm::vec2 cursor_pos = glm::vec2(0.f, 0.f);
float d_scroll = 0.f;
int key_... |
//#include "Features.h"
//#include "Settings.h"
//#include "Entity.h"
//#include "Interfaces.h"
//#include "Convar.h"
//#include "Resolver.h"
//
//ConVar *sv_unlag;
//ConVar *sv_maxunlag;
//ConVar *sv_lagflushbonecache;
//ConVar *sv_lagpushticks;
//ConVar *sv_client_min_interp_ratio;
//ConVar *sv_client_max_interp_rati... |
/*
By:
Jonathan Freitas
Program in C++ that reads an image, and do a Histogram of it.
*/
#include "header.h"
void Histograma(){
//Recebendo imagem
Mat img = imread("twd.jpg", 0);
//Variáveis Lógicas
int Hist[256];
//Percorrendo o Array
for(int k = 0; k < 256; k++){
Hist[k] = 0;
}
//Colunas e Linhas
... |
/*
Copyright (c) 2019 - 2021 Advanced Micro Devices, Inc. All rights reserved.
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 limitation the rights
to use, ... |
/*
ID: zhaowei10
TASK:
LANG: C++14
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/rope>
using namespace __gnu_cxx;
using namespace __gnu_pbds;
using namespace std;
#ifdef LOCAL
#include <debug.h>
#else
#define debug(...) 0
#endif
#define f fir... |
// Copyright (C) 2015 National ICT Australia (NICTA)
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
// ----------------------------------------------------------... |
// Copyright (c) 2009-2012 Bitcoin Developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <iostream>
#include <fstream>
#include "init.h" // for pwalletMain
#include "bitcoinrpc.h"
#include "ui_interface.h"
#in... |
/**
* 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 <gtest/gtest.h>
#include <yoga/Yoga.h>
using namespace ::testing;
class YogaTest_HadOverflowTests : public Test {
protec... |
#include "Rounds.h"
Rounds::Rounds(sf::RenderWindow& win, sf::Texture& box_, sf::Texture& pointner_, sf::Texture& line_, sf::SoundBuffer& click_):
window(win),
SliderW(win, pointner_, line_, click_)
{
back.setTexture(box_);
min = 10;
max = 60;
number = 10;
nmb.setCharacterSize(50);
nmb.setString("20");
this... |
//-----------------------------------------------------------------------------
// Copyright (c) 2012 GarageGames, LLC
//
// 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 restrictio... |
// Copyright 2010-2021 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 in... |
// Copyright 2018 the V8 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.
#include "src/compiler/js-heap-broker.h"
#ifdef ENABLE_SLOW_DCHECKS
#include <algorithm>
#endif
#include "src/ast/modules.h"
#include "src/bootstrappe... |
/*c++98*/
#include <cstdio>
#include <iostream>
#include <algorithm>
#include <vector>
#include <map>
#include <set>
#include <string>
#include <cstring>
#include <cmath>
#define max(a,b) (a>b)?a:b
using namespace std;
int main(int args, char *argc[]){
int a,b,c,d;
int q,w,e,r;
cin>>a>>b>>c>>d;
cin>>q>>w>>e>>... |
// Copyright (c) 2013-2016 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "consensus/validation.h"
#include "data/sighash.json.h"
#include "hash.h"
#include "script/interpreter.h"
#include "... |
// Copyright (c) 2014-2017 The Dash Core developers
// Copyright (c) 2017-2017 The BitenX Core developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "base58.h"
#include "hash.h"
#include "validation.h" // For s... |
////////////////////////////////////////////////////////////////////////////////
/// DISCLAIMER
///
/// Copyright 2016 by EMC Corporation, 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... |
/*
* Copyright (C) 2017-2020 The Project X-Ray Authors.
*
* Use of this source code is governed by a ISC-style
* license that can be found in the LICENSE file or at
* https://opensource.org/licenses/ISC
*
* SPDX-License-Identifier: ISC
*/
#include <prjxray/xilinx/spartan6/block_type.h>
#include <gtest/gtest.h... |
// Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2014 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 "txdb.h"
#include "util.h"
#include "core.h"
#include "uint256.h"
#includ... |
// Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2015 The Bitcoin developers
// Copyright (c) 2009-2015 The Dash developers
// Copyright (c) 2015-2019 The PIVX developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-li... |
// _ _____ __________
// | | / / _ | / __/_ __/ Visibility
// | |/ / __ |_\ \ / / Across
// |___/_/ |_/___/ /_/ Space and Time
//
// SPDX-FileCopyrightText: (c) 2021 The VAST Contributors
// SPDX-License-Identifier: BSD-3-Clause
#pragma once
#include <vast/format/multi_layout_reader.... |
#include <CppUnitTest.h>
#include <dak/any_op/all.h>
#include <dak/any_op/tests/helpers.h>
using namespace Microsoft::VisualStudio::CppUnitTestFramework;
using namespace dak::any_op;
namespace dak::any_op::tests
{
TEST_CLASS(any_tests)
{
public:
TEST_METHOD(any_default)
{
any_t e;
Asser... |
//
// time_traits.cpp
// ~~~~~~~~~~~~~~~
//
// Copyright (c) 2003-2014 Christopher M. Kohlhoff (chris at kohlhoff dot com)
//
// 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)
//
// Disable autolinking for unit tests... |
/*
* Copyright (c) 2016 The ZLMediaKit project authors. All Rights Reserved.
*
* This file is part of ZLMediaKit(https://github.com/xia-chu/ZLMediaKit).
*
* Use of this source code is governed by MIT license that can be found in the
* LICENSE file in the root of the source tree. All contributing project authors
... |
//#include <cmath>
#if GOOGLE_CUDA
#include "euclidean_dist_grad.h"
//#include "cuda/include/cuda.h"
#include "cuda.h"
//#include "tensorflow/core/platform/stream_executor.h"
#include "tensorflow/core/framework/op.h"
#include "tensorflow/core/framework/shape_inference.h"
namespace tensorflow {
template <typename T... |
// Copyright (C) 2018-2022 Intel Corporation
// SPDX-License-Identifier: Apache-2.0
//
#include <vector>
#include "single_layer_tests/shuffle_channels.hpp"
using namespace LayerTestsDefinitions;
const std::vector<InferenceEngine::Precision> netPrecisions = {
InferenceEngine::Precision::FP32,
InferenceEngine... |
/*
* GridTools
*
* Copyright (c) 2014-2021, ETH Zurich
* All rights reserved.
*
* Please, refer to the LICENSE file in the root directory.
* SPDX-License-Identifier: BSD-3-Clause
*/
#pragma once
#include "../../meta.hpp"
#include "../builtins.hpp"
namespace gridtools::fn::ast {
template <class...>
str... |
// Copyright(c) 2019 - 2020, #Momo
// 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... |
/**
* Copyright (C) 2016-2017 Xilinx, Inc
*
* Licensed under the Apache License, Version 2.0 (the "License"). You may
* not use this file except in compliance with the License. A copy of the
* License is located at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... |
//
// deadline_timer.hpp
// ~~~~~~~~~~~~~~~~~~
//
// Copyright (c) 2003-2021 Christopher M. Kohlhoff (chris at kohlhoff dot com)
//
// 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)
//
#ifndef BOOST_ASIO_DEADLINE_TIM... |
// Copyright 2018 The Beam Team / Copyright 2019 The Grimm Team
//
// 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 b... |
/**
* @file ExtraPref.hpp
* @brief ExtraPref class prototype.
* @author zer0
* @date 2019-11-05
*/
#ifndef __INCLUDE_LIBTBAG__LIBTBAG_PREF_DETAILS_EXTRAPREF_HPP__
#define __INCLUDE_LIBTBAG__LIBTBAG_PREF_DETAILS_EXTRAPREF_HPP__
// MS compatible compilers support #pragma once
#if defined(_MSC_VER) && (_MSC_VE... |
# include <iostream>
using namespace std;
// This define two new constants that can be used as normal
// Directive for the preprocessor: no need for semicolon
#define PI 3.141592
#define NEWLINE '\n'
int main()
{
const double r = 5.0; //constant values cannot be modified
double circle;
circle = 2 * PI * r;
c... |
// Copyright (c) 2009-2014 The Bitcoin developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#if defined(HAVE_CONFIG_H)
#include "config/midori-config.h"
#endif
#include <cstring>
// OSX 10.6 is missing strnlen at runtime,... |
// This is an open source non-commercial project. Dear PVS-Studio, please check it.
// PVS-Studio Static Code Analyzer for C, C++ and C#: http://www.viva64.com
/***********************************************************************************
**
** OrionApplication.cpp
**
** Copyright (C) August 2016 Hotride
**
****... |
// Copyright (c) 2014-2017 The Bitcoin Core developers
// Copyright (c) 2019 The Swyft Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <chain.h>
#include <util.h>
#include <test/test_swyft.h>
#include <... |
#include "memory_txns.hpp"
#include "memory_device.hpp"
#include "memory_device_ram.hpp"
#include "memory_device_uart.hpp"
#include "memory_bus.hpp"
#include "dut_wrapper.hpp"
#ifndef TESTBENCH_HPP
#define TESTBENCH_HPP
class testbench {
public:
//! Create a new testbench.
testbench (
std::stri... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.