blob_id
stringlengths
40
40
content_id
stringlengths
40
40
repo_name
stringlengths
5
114
path
stringlengths
5
318
language
stringclasses
5 values
extension
stringclasses
12 values
length_bytes
int64
200
200k
license_type
stringclasses
2 values
content
stringlengths
143
200k
71c8066253b8c5e815939095641176fa869454d4
41e5529e152fcec4dfd752b164cb96b42b55bef7
Jsiyong/PSS
/purenessscopeserver/FrameCore/CppUnit/Unit_IPAccount.cpp
C++
cpp
2,799
permissive
#include "Unit_IPAccount.h" #ifdef _CPPUNIT_TEST CUnit_IPAccount::CUnit_IPAccount() { m_pIPAccount = NULL; } CUnit_IPAccount::CUnit_IPAccount(const CUnit_IPAccount& ar) { (*this) = ar; } CUnit_IPAccount::~CUnit_IPAccount() { } void CUnit_IPAccount::setUp(void) { m_pIPAccount = new CIPAccount(); m_...
d0bed4e1e0a32065a5e7bbd100d86e92f084bc92
4fce351b4b6927ca5b477f6d0794ce38f75f47c9
shrinivas22/Fall2019
/Image manipulations with c++/DIPCODE_VC/iptool/iptool/iptool.cpp
C++
cpp
24,728
no_license
/************************************************************ * * * This sample project include three functions: * * 1. Add intensity for gray-level image. * * Input: source image, output image name, value * * * * 2. Image thresholding: pixels will become black if the * * ...
c46ca53934539c9e04337bff6766082295fe59c5
5e49d4091a17196b2a894174258ad757f451a58f
mooleetzi/ICPC
/contest/bipartite graph && netflow/km.cpp
C++
cpp
2,414
no_license
#include <cstdio> #include <cstring> #include <iostream> using namespace std; const int qwq = 0x7fffffff; int w[1000][1000]; //w数组记录边权值 int line[1000], usex[1000], usey[1000], cx[1000], cy[1000]; //line数组记录右边端点所连的左端点, usex,usey数组记录是否曾访问过,也是判断是否在增广路上,cx,cy数组就是记录点的顶标 int n, ans, m...
9a2f880ad17cf310d192f21dadc896fc464a9500
550281e2637f40679132ffc17a3176ebadda98e3
triplekill/pkgsrc-wip
/phantomjs/patches/patch-src_qt_src_3rdparty_webkit_Source_JavaScriptCore_heap_MachineStackMarker.cpp
C++
cpp
633
no_license
$NetBSD$ Fix build on SunOS. --- src/qt/src/3rdparty/webkit/Source/JavaScriptCore/heap/MachineStackMarker.cpp.orig 2013-06-03 23:11:50.000000000 +0000 +++ src/qt/src/3rdparty/webkit/Source/JavaScriptCore/heap/MachineStackMarker.cpp @@ -382,6 +382,8 @@ static size_t getPlatformThreadRegisters #if HAVE(PTHREAD_NP_H) ||...
c229bfbb9642826d40374bf2fb424d4627ce89e9
63706e5115797d7293bdded3d95ede2788a59030
Mogileeswaran/LeetCode_problems_solution
/source-code/Shortest_Word_Distance.cpp
C++
cpp
1,920
no_license
class Solution { public: int lowerBound(int left, int right, const int value, vector<int> const& container) { if(left >= right) { return left; } int mid = left + (right - left) / 2; if(value <= container[mid]) { return lowerBound(left, mid, value, container); ...
fd9773a42fd5798c2e34d4474f4f00307050b2dc
defba0c73e0b95a56771948e296400a58b5a3be5
LordRonz/helloworld2
/BaseDeck.cpp
C++
cpp
2,647
permissive
#include "BaseDeck.h" BaseDeck::BaseDeck(std::vector<Deck*>* decks, const float& x, const float& y, sf::Font* font) : Deck(decks, x, y, font) { // self explanatory } // bersih-bersih BaseDeck::~BaseDeck() { while(!this->cards.empty()) { //hapus tiap card, biar ga memory leak delete this->cards.top(); this-...
4daa675dacd04aa2e046e7e25b9076bd24c5e8a7
c8fb7afb539681801b270b034ed03c5f7b823410
otcshare/chromium-src
/chrome/browser/interstitials/enterprise_util.cc
C++
cc
3,793
permissive
// Copyright 2018 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/interstitials/enterprise_util.h" #include "chrome/browser/extensions/api/safe_browsing_private/safe_browsing_private_event_route...
768971a9c619fc54d4cb974eef882868d25ead40
a32d43e249cf7efee8e3f644a1aec30964abd1eb
yachtcaptain23/browser-android-tabs
/chrome/browser/metrics/oom/out_of_memory_reporter_unittest.cc
C++
cc
11,953
permissive
// 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 "chrome/browser/metrics/oom/out_of_memory_reporter.h" #include <memory> #include <set> #include <utility> #include "base/at_exit.h" #include "b...
aeedcb4154f63e083cd2769980caed0959ae281a
ff0fbc007ea2a48aaa9bc5b5efefed7c0007619e
zhipeng-ne/myLeetcode
/53_Maximum_Subarray/main.cpp
C++
cpp
594
no_license
#include <iostream> #include <vector> using namespace std; int maxSubArray(vector<int>& nums) { if(nums.size()==0) return 0; int maxSum=nums[0]; int curSum =0; for(int i=0;i<nums.size();i++) { curSum+=nums[i]; if(curSum>=maxSum) ...
0d06628015e9ca6daf8c66b0bc30bc8570f4e497
6a6a645a397d97ca60e38ea0c974aef7671b9c5b
lukaspustina/io_benchmark
/include/ccbase/dynamic/load.hpp
C++
hpp
4,586
permissive
/* ** File Name: load.hpp ** Author: Aditya Ramesh ** Date: 06/30/2013 ** Contact: _@adityaramesh.com */ #ifndef ZDBB75EFD_5555_4AF8_9C85_102127F45636 #define ZDBB75EFD_5555_4AF8_9C85_102127F45636 #include <functional> #include <stdexcept> #include <type_traits> #include <ccbase/error.hpp> #include <ccbase/platform.h...
415d6a66ece176b0192f5ec0b25f92df6a580783
47776305ddfcd15655e12a37d473f2e03ece4d61
andva/storm
/src/hscore/include/hscore/files/filesys.cpp
C++
cpp
4,588
no_license
#include "filesys.h" #include <stdio.h> #include <sys/stat.h> #include <sys/types.h> #include <hscore/log.h> #include <hscore/assert.h> #ifdef WIN32 #ifndef WIN32_LEAN_AND_MEAN #define WIN32_LEAN_AND_MEAN #endif #include <windows.h> #include <tchar.h> #include <stdio.h> #include <strsafe.h> #includ...
1774b129b2808745542b4754cab639b8dae0f73a
67802bd750f95b1ac49e95d9a763018f24c6d147
opendicom/J2KR
/trash/grok/T1Encoder.cpp
C++
cpp
7,581
no_license
/* * Copyright (C) 2016 Grok Image Compression Inc. * * This source code 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 source code is distributed in the hope that ...
a0acbf1f67a54a5c4e01fe5c05144197709752b9
a09cc96878abca3743c28632290aa18c9920c575
worta/fast-subset-convolution
/Path_Embedding.cpp
C++
cpp
13,571
no_license
// // Created by dominik on 7/4/19. // #include "Path_Embedding.h" #include "Tree.h" #include <unordered_map> #include <vector> #include <algorithm> #include "utility.h" #include <memory> #include "functions.h" #include "FastSubsetConvolution.h" using namespace std; vector<vector<Tree> > get_nodes_by_depth(Tree &tre...
ca56dd125b9472f9c5e8121f3cd48ab8390cb13d
f0e14ba5cd643fd2d4348c5b8b2cf12640959d25
devlek/Dev
/Chapter03_2_class_and_object/Chapter03_2_class_and_object/Car.cpp
C++
cpp
768
no_license
#include<iostream> #include<cstring> #include"Car.h" using namespace std; using namespace CAR_CONST; void Car::InitMember(char *ID, int fuel) { strcpy_s(gameID, sizeof(gameID), ID); fuelGauge = fuel; curSpeed = 0; } void Car::ShowCarState() { cout << "소유자ID: " << gameID << endl; cout << "연 료 량: " << fuelGauge<<"%...
d578c792fc8f7cafd16035f4a4492fb89ee96a05
c06a11d5b80eab93801dfbbfea4bb61da807aaa4
zanzo420/SoT-Python-Offset-Finder
/SDK/SlateCore_functions.cpp
C++
cpp
7,603
no_license
// Name: SoT, Version: 2.2.1.1 #include "../pch.h" /*!!DEFINE!!*/ /*!!HELPER_DEF!!*/ /*!!HELPER_INC!!*/ #ifdef _MSC_VER #pragma pack(push, 0x01) #endif namespace CG { //--------------------------------------------------------------------------- // Functions //----------------------------------------------------...
6d98045e9d79115c2fbe15d1b3a9e22267d8668b
5995d8d15fb1164b8aed3d093e99b389b56152ee
MorielV/TFTP-java-and-cpp
/Client/src/connectionHandler.cpp
C++
cpp
3,408
no_license
#include <connectionHandler.h> using boost::asio::ip::tcp; using std::cin; using std::cout; using std::cerr; using std::endl; using std::string; ConnectionHandler::ConnectionHandler(string host, short port): host_(host), port_(port), io_service_(), socket_(io_service_),lastSent(0){} ConnectionHandler::~Connec...
b7c59043993c2148f801fc1f75d64ab2389969c3
81337d3df7dfec67e0c60429a9007857c8ad0f7d
tpdownes/htcondor
/src/condor_daemon_core.V6/daemon_core_main.cpp
C++
cpp
136,394
permissive
/*************************************************************** * * Copyright (C) 1990-2011, Condor Team, Computer Sciences Department, * University of Wisconsin-Madison, WI. * * Licensed under the Apache License, Version 2.0 (the "License"); you * may not use this file except in compliance with the License. Y...
4e13cff3b8b6ac36bc61ec5958d63b58a08495fd
511e885c0d815b328ae7faaeb1ce560205fc3b29
DawidPi/RaspberryPi-bareMetal
/PiManager/src/Common/ConnectionHandler.hpp
C++
hpp
565
permissive
// // Created by Dawid on 16.10.2016. // #ifndef PIMANAGER_CONNECTIONHANDLER_HPP #define PIMANAGER_CONNECTIONHANDLER_HPP #include <QtCore/QObject> class ConnectionHandler : public QObject { Q_OBJECT public: /*! * Default constructor */ ConnectionHandler(); Q_SLOT void startConnection(const QS...
cb3915f322a983e42b55d53d84be93d0c07d382b
1d6ecb8c0f00dc949c9ebae1c249cf2ba14f90fe
AmristarSolutions/node-gdal
/deps/libgdal/gdal/frmts/wcs/wcsdataset.cpp
C++
cpp
92,903
permissive
/****************************************************************************** * $Id: wcsdataset.cpp 33720 2016-03-15 00:39:53Z goatbar $ * * Project: WCS Client Driver * Purpose: Implementation of Dataset and RasterBand classes for WCS. * Author: Frank Warmerdam, warmerdam@pobox.com * *********************...
81676de06ab590024f910bc79360e413b004d75b
3f555a004460f9735eb72279e5e61b916ba4ba81
besselchain/bessel-core
/src/crypto/impl/ec_key.cpp
C++
cpp
2,087
no_license
//------------------------------------------------------------------------------ //* This file is part of Bessel Chain Project: https://github.com/Besselfoundation/bessel-core Copyright (c) 2018 BESSEL. Permission to use, copy, modify, and/or distribute this software for any purpose with or without f...
850b7463453cf836472c8079d9f0b8a0634374db
653697d99ca384fdb52a2927dee742cbb8123999
23ksw10/LeetCode
/algorithm/463_Island_Perimeter/solution.cpp
C++
cpp
864
no_license
#include <iostream> #include <vector> using namespace std; class Solution { public: int islandPerimeter(vector<vector<int>>& grid) { int result = 0; for (int i = 0; i < grid.size(); i++) { for (int j = 0; j < grid[i].size(); j++) { if (grid[i][j]) result += 4; } } for (int i = 0; i < gr...
e55fa2bc0a15a070eef5a9a9dd92be96921a2cbd
cee29dea7e4f210034fdbe3ddcdb154831cb37c2
sithmartyr/OpenTESArena
/OpenTESArena/src/Assets/TextAssets.cpp
C++
cpp
2,422
permissive
#include <algorithm> #include <sstream> #include <vector> #include "TextAssets.h" #include "../Utilities/Debug.h" #include "../Utilities/String.h" #include "components/vfs/manager.hpp" TextAssets::TextAssets() : templateDat() { // Read in TEMPLATE.DAT, using "#..." as keys and the text as values. this->parseTemp...
d829ba45bd70e981455253da1435e224356a1622
6746b50264a47b7083ab01267d783e28c68e9c6f
FPSG-UIUC/SPT
/src/dev/x86/pc.cc
C++
cc
4,327
permissive
/* * Copyright (c) 2008 The Regents of The University of Michigan * 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, ...
58d5cd18fccc4903ffa5f63dfdebb72586cf4ab0
38c90a3d2acbf21003e2d560f9b37cf349359cc1
kidaak/lhcbsoft
/Online/Online/OnlineBase/src/MBM/mbmmon.cpp
C++
cpp
859
no_license
/*-----------------------------------------------------------------------*/ /* */ /* ASCII BUFFER MANAGER DISPLAY */ /* */ /*--------------...
98b7266aecef45edc560283b24e55b15ec38a712
9f0a6366d1e1f9e42b03b81cf6a77a37124ab52a
adwpc/webrtc
/test/fuzzers/packet_buffer_fuzzer.cc
C++
cc
2,473
permissive
/* * Copyright (c) 2017 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...
335337b882045130c39d8e3b94d40220de4bdcee
370f25b8a22ea0583951400d681ca4b537ceaa96
khotilov/cmssw
/AnalysisExamples/SusyAnalysis/src/SusyAnalyzer.cc
C++
cc
105,202
no_license
#include "AnalysisExamples/SusyAnalysis/interface/SusyAnalyzer.h" #include "FWCore/ServiceRegistry/interface/Service.h" #include "PhysicsTools/UtilAlgos/interface/TFileService.h" using namespace std; using namespace reco; using namespace edm; // // constants, enums and typedefs // // // static data member definiti...
c5c445955237fd048577c191f154712589b96b01
1c16a00629184cc548e4782ccfd638df03b2ec24
triii10/CodefChef-DSA-Learning-Series
/Linear DS/Infix_to_Postfix.cpp
C++
cpp
1,401
no_license
#include<bits/stdc++.h> using namespace std; int priority(char c) { int order; switch (c) { case '+': case '-': order = 1; break; case '*': case '/': order = 2; break; case '^': order = 3; break; default: order = 0; bre...
e3f56abb35e4f8ac055a8259d31d55bdfdf3e0d0
490d3af7ff7bc9385d94ace86fa72d50e71b67aa
WindZQ/CodeUp
/1003.cpp
C++
cpp
256
no_license
#include <iostream> using namespace std; int main() { int N, M, sum; while(cin >> N && N) { sum = 0; while(N--) { cin >> M; sum += M; } cout << sum << endl; } return 0; }
4eccdaebc4b8db7dc1e27287f1aa4222877e81b8
530c22ab3890880a6192f7e366369071ef4da018
yujin0719/Problem-Solving
/프로그래머스/lv1.이상한 문자 만들기.cpp
C++
cpp
426
no_license
// leve1 이상한 문자 만들기 #include <string> #include <vector> using namespace std; string solution(string s) { string answer = ""; int idx = 2 ; for(auto a : s){ if(a == ' ') { answer += a; idx = 2; } else { if(idx%2==0) answer += toupper(a); ...
5f8eb985b5ac5af2031b1fbfb22673bb0aa6ba8d
08b2b009d02b274cb7d1afa6f263782cc4ac6d94
bitzhuwei/ogl-samples4.3
/samples/gl-330-draw-instanced-array.cpp
C++
cpp
5,897
permissive
//********************************** // OpenGL Draw Instanced Array // 28/03/2010 - 06/04/2010 //********************************** // Christophe Riccio // ogl-samples@g-truc.net //********************************** // G-Truc Creation // www.g-truc.net //********************************** #include <glf/glf.hpp> names...
f56d266fdd5415eb5c74f305db7018bf875086f5
94606f8806b8f3f56c7877b8e5818d4a3e5b0826
rlj1202/problemsolving
/baekjoon/15824_capsaicin_is_tasty_in_spring/main.cpp
C++
cpp
610
no_license
#include <cstdio> #include <algorithm> using namespace std; const int MOD = 1e9 + 7; long long powtwo[300005]; int score[300005]; int main() { powtwo[0] = 1; for (int e = 1; e <= 300000; e++) { powtwo[e] = powtwo[e - 1] << 1; powtwo[e] %= MOD; } int N; scanf("%d", &N); for (int n = 0; n < N; n++) { sc...
3d8205c22db882867ad487c26b220e99647334c6
317a348d7a99117f7f7cf2261370679923ab2da5
vivard/dplyr
/src/dplyr.cpp
C++
cpp
67,471
no_license
#include <dplyr.h> using namespace Rcpp ; using namespace dplyr ; typedef dplyr_hash_map<SEXP,HybridHandler> HybridHandlerMap ; bool has_no_class( const RObject& arg) { return RCPP_GET_CLASS(arg) == R_NilValue ; } bool hybridable( RObject arg ){ if( arg.isObject() || arg.isS4() ) return false ; int type...
4128e8adc1b39489a2f518f13f8b12cdf299f2f5
01892fea1d6512c7b358f50c422bc8bd8925c6e0
Shyeok/Algorithm-Programming
/BOJ/2160.cpp
C++
cpp
710
no_license
#include<stdio.h> char picture[50][5][7]; int comp(int a, int b) { int i, j; int diff = 0; for(i = 0; i < 5; i++) { for(j = 0; j < 7; j++) { if(picture[a][i][j] != picture[b][i][j])diff = diff + 1; } } return diff; } int main() { int i, j, k; int n, result; int dap_min, dap_1, dap_2; scanf("%d",&n...
f8d0a69db35a9ca42e8ce666bc232dc7bb0f347c
ff66d53298a7db15d0acf3626218ab9334eeeb0f
AthomsG/FC
/A07/exercicio3/check_limits.cpp
C++
cpp
749
no_license
#include <iostream> #include <climits> #include <cfloat> using namespace std; int main() { cout << "--- int ---\n"; cout << "limite inferior = " << INT_MIN; cout << "\nlimite superior = " << INT_MAX; cout << "\n--- unsigned int ---\n"; cout << "limite inferior = 0"; cout << "\nlimite superior = " << UINT_...
e6063739a2edaa4261f51d841ea2cc7ed448b877
ee1368484728957f64c1c424f52401e70ec4946e
taeany/WorkPlaceCoin
/src/qt/peertablemodel.cpp
C++
cpp
6,424
permissive
// Copyright (c) 2011-2013 The Bitcoin developers // Copyright (c) 2017-2018 The PIVX developers // Copyright (c) 2019 The WorkPlaceCoin developers // Distributed under the MIT/X11 software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #include "peertablemodel.h" ...
7dcbbbb9ca8828e7bf7f37264a35078de3f77e97
401de706778c081b21650b283d4860b27295962b
mamunhpath/leet-code
/sum-root-to-leaf-numbers-2.cpp
C++
cpp
808
no_license
// https://leetcode.com/problems/sum-root-to-leaf-numbers/description/ /** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x), left(NULL), right(NULL) {} * }; */ class Solution { public: int answer; int tem...
1e0ac02b086b4e7ac057002c389ca48b62e2ac8e
a77ddc5a5035ccd25ccdb3a31f03649524e0fca0
aws/aws-sdk-cpp
/generated/src/aws-cpp-sdk-rds/source/model/RevokeDBSecurityGroupIngressResult.cpp
C++
cpp
1,742
permissive
/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #include <aws/rds/model/RevokeDBSecurityGroupIngressResult.h> #include <aws/core/utils/xml/XmlSerializer.h> #include <aws/core/AmazonWebServiceResult.h> #include <aws/core/utils/StringUtils.h> #includ...
f0f94549bf41ab5e9a9770e311a08ae2077883df
f2e7452541cc0b976b90e017e1d05f09d0a06383
Cheese-5040/Comp-2011
/assignment 1/assignment1task5.cpp
C++
cpp
6,130
no_license
#include <iostream> using namespace std; //helper function for power int power(int n, int p) { for (int i = 1; i < p; i++) { n = n * 2; } return n; } // Task 1 int get_min_bits_length(int x) { int number; int negative = 0; int bits = 1; //most significant vlaue included // posti...
71cd593246bc4e823397277da234132095280d6f
00d7c745c2a0b9815ff41021c07ad0d761851285
luqmanarifin/cp
/Facebook Hacker Cup 2021 Round 1/a1.cpp
C++
cpp
776
no_license
#include <bits/stdc++.h> using namespace std; const int N = 8e5 + 5; const int inf = 1e9; // 0 kiri, 1 kanan int dp[N][2]; char s[N]; void upd(int& at, int val) { at = min(at, val); } int main() { int t; scanf("%d", &t); for (int tt = 1; tt <= t; tt++) { for (int i = 0; i < N; i++) { dp[i][0] = d...
c03d23003b5d40c02c38a37c115e11cc8648f9d6
c25d11f8d6cdf96131d697252bcdc22be294d196
danangharissetiawan/C-_Basic
/03_Fungsi/07_Pointer/Main.cpp
C++
cpp
1,521
no_license
#include <iostream> using namespace std; /* - pointer: - variabel yang menyimpan alamat variabel lain sebagai nilainya. - sebuah pointer merujuk pada tipe data (string atau int) dari tipe data yang sama, - dan dibuat dengan operator *. */ int main() { string buah = "anggur"; // variabel ...
bbf738edf2e87a4cb882eef1a67ce488eeb00a13
d2e2efa9e0c5abe23bb291c3afe6a23a955a9431
zxz12/platform_system_core
/logd/LogListener.cpp
C++
cpp
4,076
permissive
/* * Copyright (C) 2012-2014 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required b...
ed82d2df9a2d6ac9bf5c65277641c2fbf82ba120
b3a691fa8d4efffce9119ab82f4ced2b5b030ae2
hellonaro/BOJ
/11053.cpp
C++
cpp
782
no_license
#include <iostream> #include <vector> #include <cmath> using namespace std; /* 수열 A가 주어졌을 때, 가장 긴 증가하는 부분 수열을 구하는 프로그램을 작성하시오. 예를 들어, 수열 A = {10, 20, 10, 30, 20, 50} 인 경우에 가장 긴 증가하는 부분 수열은 A = {10, 20, 10, 30, 20, 50} 이고, 길이는 4이다. */ int main() { ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0); int N;...
8c9e60cc5f2a5430a753ebc1b2fad3acfeb8b11a
78cde8bb349412caa4e2e3d1fba5b8227f89b182
raghavanv97/chromium
/components/performance_manager/decorators/page_live_state_decorator_unittest.cc
C++
cc
10,029
permissive
// Copyright 2019 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/performance_manager/public/decorators/page_live_state_decorator.h" #include "base/bind.h" #include "base/callback_forward.h" #includ...
ad7d03b7c58a7811d8a4aa74c27bcab3b0aff18d
da18ee9ad10bbaf2fb410f42c9476ad087083b64
OpenFEM/Albany
/src/FELIX/evaluators/FELIX_EnthalpyBasalResid.hpp
C++
hpp
2,813
permissive
/* * FELIX_EnthalpyBasalResid.hpp * * Created on: May 31, 2016 * Author: abarone */ #ifndef FELIX_ENTHALPY_BASAL_RESID_HPP_ #define FELIX_ENTHALPY_BASAL_RESID_HPP_ #include "Phalanx_config.hpp" #include "Phalanx_Evaluator_WithBaseImpl.hpp" #include "Phalanx_Evaluator_Derived.hpp" #include "Phalanx_MDField...
933a0de0dea1e4b41b67690661adcf488d1fb19c
45d51e5b6b515d2369074e1198977b1993745a26
jgriffiths/gdk
/src/wamp_transport.cpp
C++
cpp
25,078
permissive
#include <array> #include <cstdio> #include <fstream> #include <map> #include <sys/stat.h> #include <sys/types.h> #ifndef WIN32 #include <unistd.h> #endif #include "session.hpp" #include "autobahn_wrapper.hpp" #include "boost_wrapper.hpp" #include "exception.hpp" #include "http_client.hpp" #include "logging.hpp" #i...
59a29910bdc77cfefcc155c9dfe7031ac7976eca
7c4bd1211c6170df850483eb1b6ed2d1cf1c0131
2015xray/rr
/src/GdbExpression.cc
C++
cc
11,376
permissive
/* -*- Mode: C++; tab-width: 8; c-basic-offset: 2; indent-tabs-mode: nil; -*- */ #include "GdbExpression.h" #include "GdbServer.h" #include "task.h" using namespace std; #define WORKAROUND_GDB_BUGS // Extracted from // https://sourceware.org/gdb/current/onlinedocs/gdb/Bytecode-Descriptions.html enum Opcode { OP_...
6ffa27d50208d23b4ddc45bafa6e07367df256db
f831fa0afb802da48807fbfaefc0ef5b5352fa80
dohse/httpp
/tests/request_parser/headers.cpp
C++
cpp
3,342
permissive
/* * Part of HTTPP. * * Distributed under the 2-clause BSD licence (See LICENCE.TXT file at the * project root). * * Copyright (c) 2013 Thomas Sanchez. All rights reserved. * */ #include "httpp/http/Parser.hpp" #include <sstream> #include <boost/test/unit_test.hpp> #include "httpp/http/Request.hpp" #includ...
01f9b8633ac3a620a26dcc063d738ab9de690337
8f37045d6472567e56cd07c13d6d3d890c08f6cb
Zouhongmei/pointers_on_c
/Prime.cpp
C++
cpp
414
no_license
/* 打印1~100之间的所有质数 */ #include <stdio.h> #include <math.h> // 函数,判断是否是质数 int Isprime( int n ) { if( n == 1 ) return 0; else for( int i = 2; i < sqrt( n ); ++ i ) { if( n % i == 0 ) return 0; } return 1; } int main() { // 打印1~100之间的所有质数 for( int i = 1; i <= 100; ++i ) { if( Isprime( i ) ) ...
9dfcf8530478b54e97337ee8325d47e0b2a8ac27
405bed8bcbe9b9f3e72ba0d7356c652869111f8b
Huijuan-Xu/channelarchiver
/Storage/NameHash.cpp
C++
cpp
9,910
no_license
// -*- c++ -*- // Tools #include <BinIO.h> #include <MsgLogger.h> // Index #include "NameHash.h" FileOffset NameHash::Entry::getSize() const { /// next, id, name.len, ID_txt.len, name, ID_txt return 4 + 4 + 2 + 2 + name.length() + ID_txt.length(); } void NameHash::Entry::write(FILE *f) const { if (fseek(f, ...
75fa8751b2326638269ca82ab1285b93d46f4e90
bd10dbdb0bdb10e2719700178c02d3e59e36dc16
dieuninh1997/spoj-2017
/nam2017A.cpp
C++
cpp
412
no_license
#include <bits/stdc++.h> using namespace std; int dao(int a){ int x=0; while(a!=0){ x=x*10+a%10; a=a/10; } return x; } void solve(){ int t; cin>>t; while(t--){ int x; cin>>x; int dem=0; while(x!=1){ if(dao(x)<x&&x%10!=0){ x=dao(x); }else{ x--; } // cout<<x<<endl; dem++; } co...
c5208c5439f9f40308732a2537c6f9bb8979101e
dd9162292c59845b438245536a4981324c61dc8c
ivan-uskov/computer-graphics-labs
/visual_stats/customtableview.cpp
C++
cpp
319
permissive
#include "customtableview.h" CustomTableView::CustomTableView(QWidget *parent) : QTableView(parent) { } std::set<int> CustomTableView::selectedRows() const { std::set<int> rows; for (const auto &index : selectedIndexes()) { rows.insert(index.row()); } return rows; }
55e2f006b984a8784a36e1e562ddd2459312e978
689a2139169ad7ff9c3a8129b1d542466c712e3a
dianagrigore/Pharmacy-Management-App
/main.cpp
C++
cpp
678
no_license
#include <iostream> #include <fstream> #include "farmacie.h" #include "farmacie_online.h" #include "GestionareFarmacii.h" int main(){ std :: ifstream f("farmacii.in"); std :: ofstream g("farmacii.out"); GestionareFarmacii<farmacie_online> f_online; GestionareFarmacii<farmacie> f_fizice; farmacie_on...
4d2fbb89712cf6b073277066cec52d29c8853c05
15f38d30cd9e6515f1fd15ed08fd464522f18d46
johnsourour/UVA-Solutions
/Ch3/11368 - Nested Dolls.cpp
C++
cpp
815
no_license
#include<bits/stdc++.h> using namespace std; pair<int,int> A[20002]; int L[20002]; struct comp { bool operator()(const std::pair<int,int> &a, const std::pair<int,int> &b) { if(a.second==b.second)return a.first<b.first; return a.second>b.second; } }; int main() { int t,m,ans; scanf("%d",&t); ...
632673aec7ebf7ff514df65951e4357c7e418aea
68ada6424e1fb1259a41c80f55cdcfc0660deba6
xianjimli/Elastos
/Elastos/Framework/Droid/eco/src/core/database/CMatrixCursor.cpp
C++
cpp
1,322
no_license
#include "database/CMatrixCursor.h" ECode CMatrixCursor::constructor( /* [in] */ ArrayOf<String>* columnNames, /* [in] */ Int32 initialCapacity) { return MatrixCursor::Init(columnNames, initialCapacity); } ECode CMatrixCursor::constructor( /* [in] */ ArrayOf<String>* columnNames) { return Matrix...
998eaa6338c1cd787a8e2d98b30862d3dabf4320
14d14027cf8f3a97f3dd81a678316231c1cdfbcd
PMF-MO-NRPDJ/adaptive
/src/estimator.hh
C++
hh
8,816
no_license
#pragma once #include <vector> #include <dune/common/exceptions.hh> #include <dune/common/fvector.hh> #include <dune/geometry/type.hh> #include <dune/geometry/quadraturerules.hh> //#include<dune/pdelab/common/referenceelements.hh> 2.6.0 #include <dune/geometry/referenceelements.hh> //#include<dune/pdelab/common/quad...
4246d40e9b558577aa35ac7209cfe94970c99fd5
94dd294f69beccbdcf85952558ff168328fe874f
NakonechnyiMykhail/cpp1901
/lesson12/string2.cpp
C++
cpp
304
no_license
#include <iostream> #include <cstring> using namespace std; int main(){ char str1[16] = "I write in c++!"; char str2[] = "and I like it!"; char _char = 'Q'; int n = 82; cout << _char << " : " << (int)_char << endl; cout << n << " : " << (char)n << endl; return 0; }
5da5afe546044cd2343a23edace85362a3834544
69c09bf4e6a46addbbfae98896cc34a4ad05c0fb
fagan2888/OTCDerivativesCalculatorModule
/OTCDerivativesCalculatorModule/Project_Cpp/lib_static/FpmlSerialized/GenClass/fpml-confirmation-processes-5-4/ExecutionNotification.hpp
C++
hpp
7,605
no_license
// ExecutionNotification.hpp #ifndef FpmlSerialized_ExecutionNotification_hpp #define FpmlSerialized_ExecutionNotification_hpp #include <fpml-msg-5-4/CorrectableRequestMessage.hpp> #include <fpml-shared-5-4/OriginatingEvent.hpp> #include <fpml-doc-5-4/Trade.hpp> #include <fpml-business-events-5-4/TradeAmendmentConten...
6ced15a8786006241662e0ed25443868fcff0919
bb043934a9a5c7492afeda77b89bf1c98974468d
henviso/libgdx-cpp
/src/gdx-cpp/physics/box2d/joints/PrismaticJoint.hpp
C++
hpp
1,788
permissive
/* Copyright 2011 Aevum Software aevum @ aevumlab.com 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 app...
489fb7c54c80a0080318612c89d5a5e19d04d4db
3b6fa84b2b8c7f356dd84884846a135e1bdb9432
tjd229/Algorithm
/codeforce/1586A.cpp
C++
cpp
1,497
no_license
//greedy, math #include <stdio.h> #include <iostream> #include <string> #include <vector> #include <algorithm> #include <memory.h> #include <set> #include <map> #include <queue> #include <unordered_map> #include <tuple> #include <numeric> #define ll long long #define pii pair<int,int> using namespace st...
a6b501ee943dfc9b4b795008e4ce2665ae0724a3
8373417e3dc53eed56c8c4c8cc5fca4845d86be7
RenatoBorelli/nix
/src/Block.cpp
C++
cpp
870
permissive
// Copyright (c) 2013, German Neuroinformatics Node (G-Node) // // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted under the terms of the BSD License. See // LICENSE file in the root of the Project. #include <nix.hpp> using namespace std; ...
d621b38883a852ed301286bad24240e8298fa312
57d4495a2f3291f2d39ad0576f32e7b50bdd83b1
eXceediDeaL/OI
/Problems/POJ/图论/生成树/2421.cpp
C++
cpp
1,111
no_license
/* Constructing Roads 题意:有n个村庄,编号为1 ,2 ,3 ,,,n 应该建造道路使他们互相可达,有一些边已经建立了 分析:MST */ #include<iostream> #include<cstring> #include<algorithm> #include<vector> using namespace std; const int MAXN=100; struct edge{ int u,v,w; bool operator <(const edge &t)const{ return w<t.w; } edge(int u,int v,int w):u(u),v(v),w(w)...
57d7c42a6e7c12541e90de6c3b98107876174748
61b7aed1e093293431ff47df43d3939d0ce5704e
111116/virtualventure
/tests/3D-int24-prototype/src/genmodel.hpp
C++
hpp
3,350
permissive
#pragma once #include <vector> #include "data_types.hpp" std::vector<Vertex> genrail(real ox, real oy, real oz) { // uv: 30,155 - 426,543 // left front Vertex a = {-1 + ox, 0 + oy, 0 + oz, 1, 30, 543}; // left back Vertex b = {-1 + ox, 0 + oy, 8 + oz, 1, 30, 155}; // right front Vertex c = { 1 + ox, 0 + oy,...
9dcbc3d76b36e138b47034476b420abc188de4b4
93acdf74b30cef1a8b0e967da0d3e838855bb555
amitbanerjee1999/Lab-Assignment-3rd-Sem
/Assignments/Lab Assignment Day-12/factorial.cpp
C++
cpp
271
no_license
#include<iostream> using namespace std; int fact(int n){ if(n==0 || n==1) return 1; else return n*fact(n-1); } int main() { int p; cout<<"Enter the number: "; cin>>p; cout<<"Factorial of the number is: "<<endl; cout<<fact(p); return 0; }
28aec0d10db765fb1e512681785fb59bef9ca21e
f802b7ce86242572595d0bfd925b4c97db220d88
gagika/tensorflow
/tensorflow/tsl/distributed_runtime/rpc/grpc_util_test.cc
C++
cc
1,588
permissive
/* Copyright 2017 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...
9caa0126f002df33a838ff357f53c67297b93888
e50b7a7c10b365349754084534f056a8eea2c19c
wangx23/Spgr
/src/Spgrr.cpp
C++
cpp
4,107
no_license
#include <RcppArmadillo.h> #include "functions.hpp" // [[Rcpp::depends(RcppArmadillo)]] // [[Rcpp::plugins(cpp11)]] using namespace Rcpp; using namespace arma; // repeated measure // [[Rcpp::export]] Rcpp::List Spgrr(arma::vec indexy,arma::vec &y, arma::mat &z, arma::mat &x, arma::vec &weights, ...
cc1852ab953bd9332f91d6157bde985751c31c57
4b774b630a9d0924f72478ba39b2d40b0a2bcb37
nokia/profiling-daemon
/src/perf.hpp
C++
hpp
5,103
permissive
/** * Copyright 2019 Nokia * * Licensed under the BSD 3 Clause license * SPDX-License-Identifier: BSD-3-Clause */ #pragma once #include <linux/perf_event.h> #include <sys/ioctl.h> #include <asm/unistd.h> #include <sys/mman.h> namespace { long perf_event_open(struct perf_event_attr *hw_event, pid_t pid, ...
0cd35c19e4172e64358c4dbd61647877012442c7
16ba286d7ba58c9223af6464665825e680896b0d
tauzero7/MagneticPendulum
/src/OpenGL2d.cpp
C++
cpp
29,430
no_license
/** Copyright (c) 2014, Universitaet Stuttgart, VISUS, SFB 716, Thomas Mueller MPSim is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License. http://creativecommons.org/licenses/by-sa/3.0/deed.en_US @file OpenGL2d.cpp */ #include "OpenGL2d.h" #include "glutils.h" #inclu...
b9e236e34158bd6554a5862ecfb7bb9c918c998c
6bc8bf7eed979fab104769d2afc8b4192a5be722
lineCode/Kyo2D
/Kyo2D/src/FontGlyph.cpp
C++
cpp
229
permissive
#include "FontGlyph.h" namespace Kyo2D { //============================================================================= FontGlyph::FontGlyph(float advance, FontImage* image) : m_advance(advance) , m_image(image) { } }
d50af78c36fd04dc0ed025020a7390725acc4e26
41979372a7baa94c5ca963f212ec4502fc389b91
Scotter-Qian/CNStream
/modules/source/src/data_source.cpp
C++
cpp
7,787
permissive
/************************************************************************* * Copyright (C) [2019] by Cambricon, Inc. 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 a...
336f123cb60f7b338eb892ad33b1494985afb21a
58590ad3bf54f9a27d0c9891a4b080c03a444917
potatoler/OI_Exercise
/lws_1126.cpp
C++
cpp
764
no_license
#include<iostream> #include<cstdio> #include<cstdlib> #include<cmath> #include<cstring> #include<algorithm> #include<climits> #define int long long using namespace std; const int MaxN = 150000; int n, l[MaxN], s[MaxN], ans; char str[MaxN]; inline int Read(){ int num = 0, op = 1; char ch = getchar(); while(!isdigit(...
916bdbe3b7dbd2f11fa32ba022e49626ca670ec9
ac66d69d6575e1f66869009ae5a382318ebab350
bitprim/bitprim-node
/src/configuration.cpp
C++
cpp
1,897
no_license
/** * Copyright (c) 2011-2017 libbitcoin developers (see AUTHORS) * * This file is part of libbitcoin. * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as published by * the Free Software Foundation, either version 3 of the Lic...
bd40ace4780699e5f1f30f47e55ce3f616647ad2
8c1a031e116b92b473733c07b5ff10db987ec40c
andr3wmac/Torque6Editor
/wxWidgets/src/osx/carbon/tooltip.cpp
C++
cpp
5,976
permissive
///////////////////////////////////////////////////////////////////////////// // Name: src/osx/carbon/tooltip.cpp // Purpose: wxToolTip implementation // Author: Stefan Csomor // Copyright: (c) Stefan Csomor // Licence: wxWindows licence ////////////////////////////////////////////////////////////...
aeff9317317d333072ec3bfc4782670ffac44719
c856da58ee7465c495012212e4ec0028938f7b22
mparafin/PROI2_Calc
/Operation.hpp
C++
hpp
243
no_license
#ifndef __OPERATION_HPP__ #define __OPERATION_HPP__ #include "Node.hpp" enum operation_type {PLUS, MINUS, MULTIPLY, DIVIDE, POWER, LN, LOG, STRONG, EXP}; class Operation: public Node { protected: enum operation_type type; }; #endif
936363d6b57319439b1a0105e0dbb849bc9a49da
8ecee81cb25fce680d2012b863db09e77a25239f
somy1997/CPlusPlus-Beginner
/Practical Record Programs/virtno.cpp
C++
cpp
722
no_license
/*prg for implementation of hybrid inheritance with virtual and without virtual. class A member a inherited by class B(a) and class C(c) inthaerited by class D(d)*/ #include <iostream.h> class A { public: int a; A() { cout<<"This is constructor A.\n\n"; } }; class B:public A { public: B() { cout<<"This is con...
da815dce65973c737a10747a5d3df0961338be3f
af29828a001aa90747c4a82aeeed50d7a281d958
vanishblue/OJ
/HDU_2003求绝对值.cpp
C++
cpp
238
no_license
#include <iostream> #include <iomanip> using namespace std ; int main() { double x ; while (cin >> x) { if (x>=0) cout<<fixed<<setprecision(2)<<x<<endl ; else cout<<fixed<<setprecision(2)<<double(-x)<<endl ; } return 0 ; }
f7fc691267783e009bf0067d069510f19b38038c
52f40e18bbd0e7a810ef69d616ea21e375315519
tipcoin-dev/tipcoin
/src/test/getarg_tests.cpp
C++
cpp
5,338
permissive
// Copyright (c) 2012-2018 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 <util.h> #include <test/test_bitcoin.h> #include <string> #include <vector> #include <boost/algorithm/string.hpp> ...
fde3c473e0f66cb8eb636f1702b62df194435c57
9b0ba5971d93be6e6798d08807e6770800159cc4
rmoen/bitbean-core
/src/qt/bitbean.cpp
C++
cpp
9,080
permissive
/* * W.J. van der Laan 2011-2012 */ #include "bitbeangui.h" #include "clientmodel.h" #include "walletmodel.h" #include "optionsmodel.h" #include "guiutil.h" #include "guiconstants.h" #include "init.h" #include "ui_interface.h" #include "qtipcserver.h" #include <QApplication> #include <QMessageBox> #include <QTextCo...
1ad10592c03231597ecdbd9b69b54efc3354d326
485b054318c2daf63df4b62fc5cf5f027692e114
ranadewa/WealthManager
/Server/src/currencyconverter.cpp
C++
cpp
1,561
permissive
#include "currencyconverter.h" #include "uri.h" #include <fstream> #include "nlohmann/json.hpp" using namespace std; CurrencyConverter::CurrencyConverter(HTTPServer& server) : _fileName{"usd_conversions.json"} { server.registerEndpoint(http::methods::POST, URI::currency, std::bind(&CurrencyConverter::update, this...
cbb464a09235df4822f9a49acdddb8233f89da7f
cd22f75cf86ed7f5c527aa52fdcc9abd75f29426
GitRaut/nut
/vosmerich.cpp
C++
cpp
431
no_license
#include "middle.h" long long itc_oct_num(long long number){ int cif; long long result = 0, len = 0, chislo = 0; while(number > 0){ cif = number % 8; chislo = chislo * 10 + cif; number = number / 8; len++; } while(len > 0){ cif = chislo % 10; ...
42f339cabc2994aba366947d0ced6f04a6aa180b
115188656dea09551064e939db26883e2633dac6
AlisaCodeDragon/UCPP
/lexer_test.cpp
C++
cpp
1,882
no_license
#include "lexer.h" #include <gtest/gtest.h> TEST(lexer_tests, no_content_returns_no_tokens) { std::vector<char> c(std::size_t(0)); lexer l; auto result = l.run(c); ASSERT_EQ(result.lexemes.size(), 0); } TEST(lexer_tests, whitespace_does_not_produce_tokens) { std::vector<char> c{ ' ', '\t', '\v', ...
b0910a69dac287b386621bddbfa3b07b8370ab70
32441469cfbbd28559d47812b133244e2880c9d3
qrsforever/yxstb
/middleware/src/app/DataStream/FileStreamDataSource.cpp
C++
cpp
2,326
no_license
#include "FileStreamDataSource.h" #include "RingBuffer.h" #include "DataSink.h" #include "TempFile.h" #include <string> #include <pthread.h> static std::string s_path; namespace Hippo { FileStreamDataSource::FileStreamDataSource() { } FileStreamDataSource::~FileStreamDataSource() {...
90b7675cc24aea17a0a67237184ed5f31bd635fc
254864a56547e256808b33d5cdaa034c30f0c13f
rabbit090/taekwindow
/src/move.cpp
C++
cpp
832
no_license
#include <windows.h> #include "move.hpp" #include "debug.hpp" MoveWorker::MoveWorker(POINT const &mousePos, HWND window) : DeformWorker(mousePos, window) { DEBUGLOG("Starting move action"); d_parent = GetAncestor(d_window, GA_PARENT); RECT rect; GetWindowRect(d_window, &rect); d_windowPos.x = r...
e2605506d38d59fc5d75f4a783e4b16aef2ae74b
9b5d0514ce4ab04e28abe7897dd720b26bc1d0d6
unityairsim/unityairsim
/AirLib/include/vehicles/multirotor/firmwares/simple_flight/firmware/RungKuttaPidIntegrator.hpp
C++
hpp
2,472
no_license
#pragma once #include "interfaces/CommonStructs.hpp" namespace simple_flight { template<typename T> class RungKuttaPidIntegrator : public IPidIntegrator<T> { public: RungKuttaPidIntegrator(const PidConfig<T>& config) : config_(config) { } virtual ~RungKuttaPidIntegrator() {} ...
e407b35db7d3395170c930c555113dfec142aa3f
a4b08a90735208a497a1f4c3f3bbae7a5c2df7e4
hxhb/HotPatcher
/HotPatcher/Source/HotPatcherCore/Public/ThreadUtils/FThreadUtils.hpp
C++
hpp
1,698
permissive
#pragma once #include "HAL/Runnable.h" #include "HAL/RunnableThread.h" DECLARE_MULTICAST_DELEGATE(FThreadWorkerStatusDelegate); namespace EThreadStatus { enum Type { InActive, Busy, Canceling, Canceled, Completed }; } class FThreadWorker : public FRunnable { public: using FCa...
270d63547a4a78b444a604b806517a89a2bcb1f9
884a44cab421b2afc04ab2a79a1ac32f9928de15
pinklite/fio
/fio.contracts/contracts/fio.token/src/fio.token.cpp
C++
cpp
16,481
permissive
/** FioToken implementation file * Description: FioToken is the smart contract that help manage the FIO Token. * @author Adam Androulidakis, Casey Gardiner, Ed Rotthoff * @modifedby * @file fio.token.cpp * @license FIO Foundation ( https://github.com/fioprotocol/fio/blob/master/LICENSE ) */ #define MAXFIOMI...
22a71fdf58a9ba5b3698e1bfec481c370542b7a7
2821c319916182d017a493733c480e3a1c2ed56e
hyrise/hyrise-v1
/src/lib/access/UnionAll.cpp
C++
cpp
1,585
permissive
#include "access/UnionAll.h" #include "helper/vector_helpers.h" #include "storage/PointerCalculator.h" #include "storage/HorizontalTable.h" namespace hyrise { namespace access { namespace { auto _ = QueryParser::registerTrivialPlanOperation<UnionAll>("UnionAll"); } void UnionAll::executePlanOperation() { const au...
080ce0807c363c59d13a2d8d7fba4949136e7d11
e35b0296bb9f3778c177e2561899f3ef038e25af
kystyn/ui
/QtSrc/gui/kernel/qtooltip.cpp
C++
cpp
18,677
no_license
/**************************************************************************** ** ** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (qt-info@nokia.com) ** ** This file is part of the QtGui module of the Qt Toolkit. ** ** $QT_BEGIN_LICENSE:L...
23ca64d585aa37b676bd35d8a56d397bcec1e654
13ea0b61c2da6cbc16171ff428b5ce30f7df4b1c
junxzm1990/ASAN--
/testcases/juliet_test_suite/testcases/CWE78_OS_Command_Injection/s08/CWE78_OS_Command_Injection__wchar_t_listen_socket_execlp_83a.cpp
C++
cpp
2,180
no_license
/* TEMPLATE GENERATED TESTCASE FILE Filename: CWE78_OS_Command_Injection__wchar_t_listen_socket_execlp_83a.cpp Label Definition File: CWE78_OS_Command_Injection.strings.label.xml Template File: sources-sink-83a.tmpl.cpp */ /* * @description * CWE: 78 OS Command Injection * BadSource: listen_socket Read data ...
73a65ea6479aac7a6bbc3d509dfea92d9aafee53
f245dc8a7a585b96e881d371d898bd2066f26097
spplus/Am
/PowerAm/graphicsview.cpp
C++
cpp
819
no_license
#include "graphicsview.h" GraphicsView::GraphicsView(GraphicsScene* scene) { m_scale = 1.0; m_interal = 0.1; setScene(scene); setViewportUpdateMode(QGraphicsView::FullViewportUpdate); } GraphicsView::~GraphicsView() { } void GraphicsView::zoomOut() { m_scale += m_interal; QMatrix oldMatrix = this->matrix()...
9cdc67c55c01f692fb419d11fd3b145d1154c4e1
5600a6e38ce7b2113109e8963c0311ef07a7773f
pj12520/sinking_bim_new
/input_creates/input3_create.cc
C++
cc
3,512
no_license
//Program to create input files for parameter sweep 3 #include <vector> #include <fstream> #include <sstream> #include <sys/stat.h> using std::vector; using std::ofstream; using std::vector; using std::endl; using std::string; using std::ostringstream; int main() { //Create arrays containing the different values ...
d56bbb0707ae099330d8560b2dcd405ad8acd403
a8464b5d690ce26c8c38f53f1805fdaf6b5d5286
SwagSoftware/Kisak-Strike
/dedicated/console/TextConsoleWin32.cpp
C++
cpp
5,764
permissive
//========= Copyright 1996-2005, Valve Corporation, All rights reserved. ============// // // Purpose: // // $NoKeywords: $ // //=============================================================================// // CTextConsoleWin32.cpp: Win32 implementation of the TextConsole class. // //////////////////////////////////...
568811e2a98829b9851f1faf8b16bde8c85a76b8
826f7e37aff6ae6256d509a15c53079f24bf242f
RobertBeckebans/TEKUUM-D3
/tools/compilers/dmap/usurface.cpp
C++
cpp
32,003
no_license
/* =========================================================================== Doom 3 GPL Source Code Copyright (C) 1999-2011 id Software LLC, a ZeniMax Media company. Copyright (C) 2015 Robert Beckebans This file is part of the Doom 3 GPL Source Code (?Doom 3 Source Code?). Doom 3 Source Code is free software: you ...
807c0b134aa0d83101d93cfc5ff831f0af2b397e
538012c376f0b969904f85d66daf982ab8eaf5bb
AlexPC2/My-Projects
/CPP lessons/Contests_Reading_books/Contests_Reading_books/main.cpp
C++
cpp
1,276
permissive
// // main.cpp // Contests_Reading_books // // Created by Alex Noyanov on 19.03.19. // Copyright © 2019 Popoff Developer Studio. All rights reserved. // /* После уроков Настя решила почитать книжку. Книжка состоит из n n глав, идущих друг за другом, при этом каждая страница книги принадлежит ровно одной главе...
896f4982d7be5c213283b1b7a9f02b00780b69df
83e05a166df11baad45e378e0ae70342b39387a2
Rhunosuke/atcoder_cpp
/ABC186/d.cpp
C++
cpp
807
no_license
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); ++i) #define repI(i, d, n) for (int i = (d); i < (n); ++i) #define reps1(i, n) for (int i = 1; i < (n); ++i) using namespace std; template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1; } return 0; } template<class T> inline bool...
0dbab5c2c390ec0308d902cce6c0a567d687979d
96d5889c193105a163e65ef7867e49854390bf41
mario2100/Vivaldi-browser
/chromium/content/browser/media/media_browsertest.cc
C++
cc
13,735
permissive
// 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 "content/browser/media/media_browsertest.h" #include <memory> #include "base/command_line.h" #include "base/strings/string_number_conversio...
8d5ca97bd183a81810d3a1e6df8c3defabfb8c21
0690b24e1082c2c5420069fd54e0ca843f2fbf15
0xeb/detours-cmake
/dllsample/dummy.cpp
C++
cpp
269
permissive
#include <stdio.h> #include <Windows.h> //------------------------------------------------------------------------- int main() { ::Sleep(500); printf("Dummy program started...\n"); ::Beep(200, 1000); printf("Dummy program ended...\n"); return 0; }
3996121e2cd00a7e50f2862627d0342ae21bc770
76b1afa94e9a7572517a452b767e257c3daf6d51
wpumacay/dart
/dart/optimizer/Solver.hpp
C++
hpp
6,802
permissive
/* * Copyright (c) 2011-2022, The DART development contributors * All rights reserved. * * The list of contributors can be found at: * https://github.com/dartsim/dart/blob/master/LICENSE * * This file is provided under the following "BSD-style" License: * Redistribution and use in source and binary forms, w...
8c9967efc29d6776ef4d0fa20f7fc257432ef905
0403ed4da7519368c6247a6d06eb14d2de4820ee
YangZhongLou/unreal.lua
/Plugins/LuaPlugin/Source/LuaPluginEditor/private/LuaFactory.cpp
C++
cpp
964
permissive
// Fill out your copyright notice in the Description page of Project Settings. #include "LuaFactory.h" #include "Misc/FileHelper.h" #include "LuaScript.h" ULuaFactory::ULuaFactory() { SupportedClass = ULuaScript::StaticClass(); bCreateNew = false; bEditorImport = true; bText = true; bEditAfterNew...
420abbcfd132c468ce1d223d04c9eb1c0d639471
32fe337eff4614739b651b83bb16cad6a1086e67
SCIInstitute/fluorender
/FluoRender/FluoRender/Components/CompGenerator.cpp
C++
cpp
59,372
permissive
/* For more information, please see: http://software.sci.utah.edu The MIT License Copyright (c) 2018 Scientific Computing and Imaging Institute, University of Utah. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to d...
169185adb83deedb2129e62535aeeba3268ad6dc
afdbec219760b886ea44c3f5bfadb82a727d8335
eggxp/eggxp_view
/WOWFisher/ClientAuther.cpp
C++
cpp
5,127
no_license
//--------------------------------------------------------------------------- #pragma hdrstop #include "ClientAuther.h" #include "ClientServerShared.h" #include "AThreadLock.h" #include "GameWorld.h" //--------------------------------------------------------------------------- #pragma package(smart_init) #define ...