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
04205fbad60744b3e146777c77753ceac1f8ea25
47ac96eaf7cce620767bcd0b9acba9873fcf05cc
wwwwodddd/Zukunft
/atcoder/abc211_d.cpp
C++
cpp
656
no_license
#include <bits/stdc++.h> using namespace std; int n, m, mod = 1000000007; vector<int> a[200020]; queue<int> q; int d[200020]; int f[200020]; int main() { scanf("%d%d", &n, &m); for (int i = 0; i < m; i++) { int x, y; scanf("%d%d", &x, &y); a[x].push_back(y); a[y].push_back(x); } memset(d, -1, sizeof d); d[...
25c52b2aea56471a2a28779795c759f360831362
97bad158d8c16479c0e00d534142cc00c221662d
kfdykme/cProgram
/Chapter 9/Pro_3.cpp
C++
cpp
487
no_license
#include<stdio.h> int main(void){ int numberArray[10] = {0}; int digit ; long number; re: printf("Enter a number: "); scanf("%ldigit",&number); digit = number%10; if(number >0){ while(digit>0){ digit = number%10; numberArray[digit] ++; number /= 10; } printf("Digit: "); for(int i = 0;i <10;...
ab50aaa0c9771bd7f66f7cf7d10c2c83a1eef480
19db4dda3015423c7ee3d9b44e27c63ea122097a
kmihaylov/Sming_fsTest
/app/SerialReadingDelegateDemo.cpp
C++
cpp
1,610
no_license
/* * SerialReadingDelegateDemo.cpp */ #include "SerialReadingDelegateDemo.h" //*** Example of global callback routine void onDataCallback(Stream& stream, char arrivedChar, unsigned short availableCharsCount) { // Note: we're using the global Serial here, but it may not be the same port as stream Serial....
996832ea2d2bf2d22eca40d5a98f3bab1ebe496a
3a7bba466a62c8f295f8c1e9d57d958c9231afd4
bgohel/Algo
/cpp/frdfn/cl2.cpp
C++
cpp
588
no_license
#include<iostream> using namespace std; class A; class B { public: void fun1(A &); void fun2(A &); void fun3(A &); }; class A { int x,y; public: void set(void) { x=10,y=20; } friend void B::fun2(A &); }; void B::fun1 (A &a) { cout<<"In function 1"<<endl; // cout<<"a.x-"<<a.x<<" a.y-"<<a.y<<endl; } ...
f9077982aab87c03a4c08484595d707e2c3871ee
6723d26a83051c0a638b9e8815151eafab9a2312
pangeneral/z3
/src/smt/smt_conflict_resolution.cpp
C++
cpp
59,238
permissive
/*++ Copyright (c) 2006 Microsoft Corporation Module Name: smt_conflict_resolution.cpp Abstract: <abstract> Author: Leonardo de Moura (leonardo) 2008-02-25. Revision History: --*/ #include "ast/ast_pp.h" #include "ast/ast_ll_pp.h" #include "smt/smt_context.h" #include "smt/smt_conflict_resolution.h...
862eaf0fd6253ec65c95db394bbac0b2441167ab
09951973a198f936a298639e6c68899c4017080f
zaburo-ch/icpc_practice
/atcoder/arc024a.cpp
C++
cpp
678
no_license
#include <iostream> #include <stdio.h> #include <sstream> #include <string> #include <vector> #include <map> #include <queue> #include <algorithm> #include <set> using namespace std; typedef pair<int,int> P; const int INF = (int)((unsigned int)-1>>1) /2; int main(){ int L, R; int l[31], r[31]; cin >> L >>...
d8d13ebd3fa61c863cacec884d655b7a93d8c3ce
f675f9ea7c5219485ba35f31d3084c39d3641525
rethesda/alchemy
/third_party/common/src/RE/BSScript/Class.cpp
C++
cpp
5,598
permissive
#include "RE/BSScript/Class.h" #include "RE/Offsets.h" #include "REL/Relocation.h" namespace RE { namespace BSScript { BSFixedString Class::ScriptFlag::GetFlag() const { auto sanitizedType = flag & ~kUnkFlag; return *reinterpret_cast<BSFixedString*>(&sanitizedType); } UInt32 Class::ScriptState::Get...
01a0ac27ccb0379b10f7f3b4e5beb7fc030e3a5e
18a9f13101b691add169f5703e0efbdb90803ee3
Norskeaksel/My-solutions-to-Kattis-problems
/Toilet_seat.cpp
C++
cpp
538
no_license
#include <iostream> #include <string> using namespace std; int main() { string str; cin >> str; int alwaysu=0, alwaysd=0, asfound=0; if(str[0] == 'D'&&str[1] == 'U') alwaysd+=2; if (str[0] == 'D') alwaysu++; if (str[0] == 'U'&&str[1] == 'D') alwaysu += 2; if (str[0] == 'U')alwaysd++; for (int i = 2; i < str.siz...
762b7a673fa015de36936c9f9491936633af5fa7
13998767710ff6e8dd1f740a2018fee12543aecc
ideak/mesa
/src/gallium/drivers/nv50/codegen/nv50_ir_ra.cpp
C++
cpp
55,470
no_license
/* * Copyright 2011 Christoph Bumiller * * 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, copy, modify, merge, publ...
508787f506ec9932d7ac270de3b4d5360a64664c
b2e457f0d146604089f292478e8343ed4e77ebc3
larics/morus_fuel_sensor
/dsdlc_generated/uavcan/equipment/indication/LightsCommand.hpp
C++
hpp
6,287
no_license
/* * UAVCAN data structure definition for libuavcan. * * Autogenerated, do not edit. * * Source file: C:\Users\Marko\Documents\Development\morus_fuel_sensor\libuavcan\dsdl\uavcan\equipment\indication\1081.LightsCommand.uavcan */ #ifndef UAVCAN_EQUIPMENT_INDICATION_LIGHTSCOMMAND_HPP_INCLUDED #define UAVCAN_EQUIPM...
44c487f213f04f2080da72c23aa147c729f6ac27
a3f8e5232bc3d0d05fc263b33d2d155a3bc27ccd
iRoy7/algo-progs
/bs_stack_ADT.cpp
C++
cpp
1,514
no_license
#include <stdio.h> #define MAXIS 10 struct Stack { int size; int data[MAXIS]; Stack(viod) : size(0) {} void init() { size = 0; } bool isEmpty() { return size == 0; } void push(int x) { data[size++] = x; } int pop() { return (isEmpty())? -1 : data[--size]; } int top() { return (isEmpty())? -1 : data[size - 1]; ...
02d81fdb913d04b722541908a613003f62e0a630
6e7819d70c63ca8b3dc18f11ecfa1e6a21059c8b
svn2github/NCBI_toolkit
/src/objmgr/util/feature.cpp
C++
cpp
126,255
no_license
/* $Id$ * =========================================================================== * * PUBLIC DOMAIN NOTICE * National Center for Biotechnology Information * * This software/database is a "United States Government Work" under the * terms of the United States Copyright Act....
94b661d5298d9de823e8fdee545c3cfaa15dc933
d1e9033e5163bd0111f098217ab97085a605648f
pruthig/algorithms
/design_patterns/Bridge.cpp
C++
cpp
1,740
no_license
// The bridge pattern is a design pattern used in software engineering that is meant to "decouple an abstraction from its implementation so that the two can vary independently", // In Shapes we can have circle, rectangle, square etc. while we also have drawing API which is inherited by concrete class. #include <ios...
e9d2015cb3f0da2da18748aa4b8c4ce05cdac839
b1fe385037920c79a4d0732e026ca045bd258dbb
hejunbok/magenta
/system/utest/mxtl/ref_counted_tests.cpp
C++
cpp
1,837
permissive
// Copyright 2016 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. #include <magenta/cpp.h> #include <pthread.h> #include <unittest/unittest.h> #include <utils/ref_counted.h> #include <utils/ref_ptr.h> class DestructionTr...
8c30947bb88bebd5e24d5a84649a79954e956ff8
3125120e134b9d9f135e251a9c645ac2767fe42d
aliosmanulusoy/Probabilistic-Volumetric-3D-Reconstruction
/contrib/brl/bbas/brad/io/brad_io_atmospheric_parameters.cxx
C++
cxx
1,410
no_license
#include <iostream> #include "brad_io_atmospheric_parameters.h" //: // \file #include <brad/brad_atmospheric_parameters.h> #include <vsl/vsl_binary_io.h> #include <vcl_compiler.h> //: Binary save brad_atmospheric_parameters to stream. void vsl_b_write(vsl_b_ostream &os, const brad_atmospheric_parameters& m) { } //: B...
ef69966e004dc706b298edc91276b1446410ae64
a5ccba4e0db98f1865d0d587332d25d33b2ef4ad
Kourin1996/CompetitiveProgramming
/YNUCPC/20180322/d.cpp
C++
cpp
1,644
no_license
#include<bits/stdc++.h> // Shrotening #define fst first #define snd second #define pb push_back #define REP(i,a) for(long i=0;i<(a);++i) #define EACH(i,a) for(auto (i)=(a).begin(),_END=(a).end();i!=_END;++i) typedef long long Weight; const Weight WEIGHT_INF = std::numeric_limits<Weight>::max()/4; struct Edge { ...
96afa9503a08e7f2399775bd268a75861b1c0585
68672446fd78eb8862431055e78a69ae77ca113f
wanghouhuasteven/luogu
/2019.2.5 P1980 计数问题.cpp
C++
cpp
662
no_license
// luogu-judger-enable-o2 #include <bits/stdc++.h> int judge(long int n,int x) { int result = 0; while(n >= 1) { if(n%10 == x) { result += 1; } n = n/10; } return result; } int main() { long int n; int x; int num = 0; std::cin>>n>>x; ...
858d2a5efe58acb301bc69fb53142787f743da35
fd85f8db28bc6c5a009ae920a12eefb7b68cfeff
renatorqg/sparse-stereo-vision
/surf.cpp
C++
cpp
20,353
no_license
//includes para SURF #include <opencv2/objdetect/objdetect.hpp> #include <opencv2/features2d/features2d.hpp> #include <opencv2/highgui/highgui.hpp> #include <opencv2/calib3d/calib3d.hpp> #include <opencv2/imgproc/imgproc_c.h> #include <iostream> #include <vector> #include <stdio.h> #include "surf.h" using namespace s...
51bdee4792dc8e32c74dc3391f11c340ceb96b1f
460bf5fd51682db3cf576c1901a5a8cb09cf0152
snyh/dui
/Source/WebCore/rendering/FlowThreadController.cpp
C++
cpp
9,749
no_license
/* * Copyright (C) 2012 Adobe Systems Incorporated. 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 ...
8c29dfacc8ceb790612e1abeca980e99de6edfec
77e62065f004aa536ca6ab452b8509cb983a259d
ben-ying/fdbus
/platform/socket/linux/CLinuxSocket.cpp
C++
cpp
5,107
no_license
/* * Copyright (C) 2015 Jeremy Chen jeremy_cz@yahoo.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 a...
9169c1ec182b0edb52a9bb88031f148a6c718053
b4c974a1dcf3b9e395a2fd0f7ba5ad8ee6229ca4
zenoalbisser/chromium
/chrome/browser/media/midi_permission_context_factory.cc
C++
cc
1,284
permissive
// 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 "chrome/browser/media/midi_permission_context_factory.h" #include "chrome/browser/media/midi_permission_context.h" #include "chrome/browser/prof...
ebf3f29a4af0317a2888b81f70f229de1ef87c35
aa663701450284a476ebceefd089aab8b3a492eb
chromium/chromium
/device/vr/test/fake_vr_device.cc
C++
cc
967
permissive
// Copyright 2015 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "device/vr/test/fake_vr_device.h" #include "mojo/public/cpp/bindings/pending_remote.h" #include "ui/gfx/geometry/transform_util.h" namespace device { FakeVRDevice::...
e28a355b2de56d2fb97228e6f21ae049e2291081
1607ebb2d3744be9d90a3b021ec0f44977460820
JanaSabuj/UVa-solutions
/CP3/DS and Libraries/Linear DS with built-in libraries/1D Array Manipulation/482-PermutationArrays.cpp
C++
cpp
1,246
no_license
//Built by Sabuj Jana(greenindia) from Jadavpur University,Kolkata,India // God is Great------------/////\\\\\\\-------------------------------- #include <bits/stdc++.h> using namespace std; #define crap ios::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL) #define int long long int #define endl "\n" #...
f8d9a868c48c928111bbdd6d3c644deb67e8d88f
bbdf0d49b6df41794ba777c015960ecc2c1c1add
ornerymoose/learning_cpp
/prog64.cpp
C++
cpp
673
no_license
#include <iostream> using namespace std; //seeing if someone qualifies for a credit card /* 1) they need to be at their current job for 2+ yrs 2) they need to make at least 17k USD/year */ void qualify(){ cout << "Nice, you qualify!" << endl; } void noQualify(){ cout << "Unfortunately, you do not qualify." << en...
13df3b4a3a7ab769972137b89252f05ed20d577b
1d1b48bb54573256bbbdce3a4be6497d495685e9
romainfrancois/arrow
/r/inst/include/cpp11/protect.hpp
C++
hpp
10,941
permissive
// cpp11 version: 0.3.1.1 // vendored on: 2021-08-11 #pragma once #include <csetjmp> // for longjmp, setjmp, jmp_buf #include <exception> // for exception #include <stdexcept> // for std::runtime_error #include <string> // for string, basic_string #include <tuple> // for tuple, make_tuple // NB: cpp11/R...
fc439075821da784a68146bd86d08fc4bf7a65ef
4aa309592a37d539701a73cb20af13e31d5fb600
gyankos/kShortestPaths
/source/kbest.cpp
C++
cpp
11,442
no_license
// // Created by giacomo on 10/06/21. // #include <kshortestpaths/kbest.h> template<>Node<GraphHeap *> *Node<GraphHeap *>::freeList = nullptr; template<> const int Node<GraphHeap *>::newBlocksize = 64; template<> Node<GraphArc *> *Node<GraphArc *>::freeList = nullptr; template<> const int Node<GraphArc *>::newBlocks...
af02fa6c4fbbc187d786d768305f14b33e10c1db
6ed640193359aeed22a310f7b031332517f0d227
aaleksandar/si4mps
/resenja/dz5z4.cpp
C++
cpp
3,056
no_license
#include <mpi.h> #include <cstdlib> #include <iostream> #include <iomanip> #include <cmath> using namespace std; int rank, size; int line = 0; void pline() { cout << setw(2) << setfill('0') << rank << ":"; cout << setw(3) << setfill('0') << ++line << ":"; } int main(int argc, char* argv[]) { MPI::Init(argc, argv...
bb18b47ff84939224818d0d5e4ecf62a1f54e871
cec34950148bf3de084ac6664a58f2fa104329f3
SimGyuBin/portfolio
/Classes/Widget/PixSelectedImageCell.cpp
C++
cpp
9,817
no_license
// // PixSelectedImageCell.cpp // coco2dx_pixholic // // Created by 심규빈 on 2016. 2. 3.. // // #include "PixSelectedImageCell.h" #include "editor-support/cocostudio/ActionTimeline/CSLoader.h" #include "PixSelectDateCell.h" #include "../Info/UserInfo.h" #include "../Util/PixImageLoader.h" #include "../Util/PixNativeU...
e1475c6b2d0ee7b547f7ecd7345484fd1a02c111
9eb760258d858e3b27feffd9ccaddaeae4d5d144
zweilous/JKSM
/source/shared.cpp
C++
cpp
5,357
no_license
#include <3ds.h> #include <string> #include "shared.h" #include "archive.h" #include "backup.h" #include "restore.h" #include "global.h" #include "menu.h" #include "util.h" #include "ui.h" //I stole these from 3dbrew. Kill me. std::string descs[] = { "Home Menu attempts to open this archive during boot, if FS:Ope...
53aa1746cc74b65122acd359f660ca3ca6c77fea
087785944494d7bac722d6e9dea89294fcdeadb1
PluginCafe/cinema4d_cpp_sdk_extended
/plugins/cinema4dsdk/source/sculpting/pullbrush.cpp
C++
cpp
6,812
permissive
/* This is an example of a brush that is similar to the main Sculpting Pull Brush in Cinema4D. This brush will move points along the normal that has been defined by the brush dab. The brush uses all of the features of the sculpting system. It will handle Stamps, Stencils, Falloffs and Symmetry automatically for you. Al...
02ced3e0bf0527e6038ab71ed2b45750eb86fba3
d63d784ab0bdfb085e3d88e1fbea03395ed16d22
zoadianCollection/LumixEngine
/src/editor/entity_template_system.cpp
C++
cpp
12,202
permissive
#include "entity_template_system.h" #include "core/array.h" #include "core/blob.h" #include "core/crc32.h" #include "core/json_serializer.h" #include "core/math_utils.h" #include "core/string.h" #include "editor/ieditor_command.h" #include "editor/world_editor.h" #include "engine.h" #include "iplugin.h" #include "unive...
4016fd11afc7cc64a3beb69b06238a95b28ed6a3
e41e4b80045fe37528c449b8eb2b2efdeedb643d
maxch0240/dual_lab2
/test/Source.cpp
C++
cpp
267
no_license
#include "Service.h" int main() { Service service; //Service service(yourInputFile, yourResultFile); //example: //"D:\\C++\\test3\\schedule.txt" //"D:\\C++\\test\\result.txt" //Service service("D:\\C++\\test3\\schedule.txt", "D:\\C++\\test\\result.txt"); }
5d06c03564764bd3ea2e6cbe92a0e9da7803f9b0
798dd7c35ca858fd56e8f337eaf33328e14b0d82
dongsoolee2/spike-sorting
/matlab/mac/electrical-recording/sorting/clustering/polygon.cpp
C++
cpp
2,971
no_license
//#define char16_t UINT16_T //#include <uchar.h> #include "mex.h" #include <math.h> #include <vector> //#define char16_t UINT16_T //#include <sstream> using namespace std; vector<int> pointsinpolygon (double *x, double *y,long sizex,double *polx,double *poly,long sizepol); vector<int> pointsinpolygon (double *x, doub...
49869b0b1c497503b25658984f2351afd873f52b
8650c496859041319ab8adcb6151995c40c91d4a
paoqi1997/leetcode
/leetcode/T-010.cpp
C++
cpp
758
no_license
/** * 10. 正则表达式匹配 * https://leetcode-cn.com/problems/regular-expression-matching/ */ #include <string> using namespace std; class Solution { public: bool isMatch(string s, string p) { if (p.empty()) { return s.empty(); } // 匹配第一个字符 bool match = !s.empty() && (p[0] ...
7839b01a2111fdcaa2a0fbd91fc93d654f4fa4fa
a24b6af69d4e60826fdfa55b25ce959fbe78fb33
ndoll1998/FairPT
/src/renderer.cpp
C++
cpp
7,942
no_license
#include "./renderer.hpp" #include "./framebuffer.hpp" #include <thread> #include <threadpool.h> #include <rng.hpp> #include <math.h> /* * Render Args */ RenderArgs::RenderArgs( const size_t& n_rays, const BVH& bvh ) { // allocate memory for contributions of each ray contrib_buffer = new RayContrib...
edbf3fbebe969fa2c1e208e7852eabe199ffe934
7366d4515ae6f0ecc7709de702a3a020a36721af
otaGran/codeForces
/499A.cpp
C++
cpp
522
no_license
#include <bits/stdc++.h> using namespace std; typedef long long L; typedef vector<int> vi; typedef pair<int, int> ii; typedef vector<ii> vii; int main() { vii v; int n, m; int x, y; cin >> n >> m; for (int i = 0 ; i < n ; ++i) { cin >> x >> y; v.push_back(make_pair(x, y)); } int mn = 1; int ...
6cfb982f2ad8f325fb69310c20279dd7c6b393cc
9ed14a5c6467bddaf1f7d87135f649f3eea07fa2
ZYS2019/classwork
/test/main.cpp
C++
cpp
915
no_license
#include<opencv.hpp> using namespace cv; int main() { Mat src = imread("C:/Users/SZJ/Desktop/1.jpg"); //Mat dst(src.rows, src.cols, CV_8UC3); //Mat srcgray = imread("C:/Users/SZJ/Desktop/1.jpg", 0); Mat deepMat; Mat shallowMat; src.copyTo(deepMat); shallowMat = src; int height = src.rows; int weight = src...
5c015d059e2a5fa9e7933a9e22a68020ec2ba4dc
6ba40040aaafdc0fc5876e67c3c057e67ab458ac
camerynd/Coin-Toss
/CoinToss.cpp
C++
cpp
1,014
no_license
#include <iostream> #include <cstdlib>//to allow random number generating function #include <ctime>//to make the random number different each time program is run using namespace std; int coinToss(int& toss);//function prototype //driver program int main() { int tossTimes;//variable for storing user input sr...
1b4a2181cae29f8c3db06bc757ef411093a7fdc3
aa9405e7e9a91137ac51f9331ce075224e9f5247
webosose/chromium84
/src/content/browser/renderer_host/text_input_manager.cc
C++
cc
13,586
permissive
// Copyright 2016 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/renderer_host/text_input_manager.h" #include "content/browser/renderer_host/render_widget_host_impl.h" #include "content/browse...
e81e6fccee955779543fd0410b24d6fe98b90b54
e366b6d4d6d1378b996508fae300b7da3e7182a5
uel-dataexchange/Opencascade_uel
/inc/RWStepBasic_RWIdentificationRole.hxx
C++
hxx
2,263
no_license
// This file is generated by WOK (CPPExt). // Please do not edit this file; modify original file instead. // The copyright and license terms as defined for the original file apply to // this header file considered to be the "object code" form of the original source. #ifndef _RWStepBasic_RWIdentificationRole_Head...
a70ec8a13dc2c779e2e838c4068cb0df5b3a6dee
8adcf7b353dff260efc40ff2ade88df3a5fc9b6d
pmrobotix/DemoFusion
/src/SimuLauncher.Main/BotManager.cpp
C++
cpp
3,743
no_license
/* * BotManager.cpp * * Created on: 31 janv. 2016 * Author: pmx * test */ #include "BotManager.hpp" #include <SDL2/SDL_thread.h> #include <unistd.h> #include <cstdio> #include <string> #include "../Bot-APF9328/APF9328LedBarTest.hpp" #include "../Bot-APF9328/APF9328RobotExtended.hpp" #include "../Bot-Lego...
28bea795a6145be5223fb4aa2417d9c3031dcb3c
c1717acd95ec381ac69167c32a3fdfd75fa8d9d9
cryos/SIMPL
/Source/SVWidgetsLib/FilterParameterWidgets/DataContainerArrayProxyWidget.cpp
C++
cpp
23,260
permissive
/* ============================================================================ * Copyright (c) 2009-2016 BlueQuartz Software, LLC * * 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 ...
aa253ac8f9d429138a17461f45b05602f29cffd4
2b1f38e21e4bf6bfc99a9a0aabfd86bf15ddcc39
dbremner/cxxreflect
/utility/unit_test_tools/ExecuteUnitTestsRemotely.cpp
C++
cpp
8,684
permissive
// Copyright James P. McNellis 2011 - 2013. // // 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) // // CxxRefl...
4fdcb1d4009f8cf1b3500a17f8ce8805f50f06a1
866a6644dbebad10e10f9c6cc51ef346b27265e6
justinchoi/libyuv
/source/convert.cc
C++
cc
75,130
permissive
/* * Copyright 2011 The LibYuv 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 contributing ...
b10ca0f3938fb61046e4141859c92fe489a9a16a
980528c7454d9e0c23c3d82fb39994d3dccbfd5f
Pasonia/GAM350-Temp-Repo-trigger
/TriggerEngine/Source/State.cpp
C++
cpp
700
no_license
/******************************************************************************/ /*! \file state.cpp \author Long Jiquan Joel, TEAM TRIGGER \par email: jiquanjoel.long\@digipen.edu \par email: z.pung\@digipen.edu \par email: kwanyee.leung\@digipen.edu \par email: yunanjoel.lew\@digipen.edu \par email: weiwei.hong\@digi...
aed5593e22ef48f7f2c4a5061f0d491f297f167d
4118341d9d659802c2124bf5fed1dbafe342eba9
ChristianSommer/BIZ
/src/main.cpp
C++
cpp
130,348
permissive
// Copyright (c) 2009-2010 Satoshi Nakamoto // Copyright (c) 2009-2012 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 "alert.h" #include "checkpoints.h" #include "db.h" #include "txdb.h" #inc...
613f460b65558377e34aa76ec137deff43d9f6ad
4587d73fddc479f45bfdd2f0296e9eeb4ebd0869
IIFE/CppSharp
/src/CppParser/ParseExpr.cpp
C++
cpp
128,643
permissive
// ---------------------------------------------------------------------------- // <auto-generated> // This is autogenerated code by CppSharp. // Do not edit this file or all your changes will be lost after re-generation. // </auto-generated> // --------------------------------------------------------------------------...
b3d73f2add106e6a75e3821913a8af7bf37b1720
4d59f742ef7dcdd44a6735b7cee599a38ac6b54c
mordesignx/C-_C
/archivosenC++/sobrecargadefunc.cpp
C++
cpp
956
no_license
#include <iostream> #include <cstdio> using namespace std; void swap(int *x, int*y); void swap(float *x, float *y); int main(){ char c; cout<<"intercambia numeros enteros o reales(e/r) "; cin>>c; switch(c){ case 'e':{ int a,b, *pa, *pb; pa=&a; pb=&b; cout<<...
0b63f2d1decc08988b0db425a4fdb12cdad5c3ee
dcf58c89fbba50784d16b18f03b75c4eb3a0cf4f
rcasiodu/mtfmapper
/src/gui/imgviewer.cc
C++
cc
2,082
permissive
/* Copyright 2011 Frans van den Bergh. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the ...
6670f52a7888ce8ffde288b3cb7fedffcd62eb9d
3c999af4747244a787836323f728abcfc7bac6a9
alexandraback/datacollection
/solutions_5688567749672960_0/C++/langdamao/main.cc
C++
cc
527
no_license
#include <cstring> #include <cstdio> #include <iostream> using namespace std; int f[1000005]; int a[100005]; int n; int reserve(int x){ int ret=0; int now=0; while(x){ a[now++]=x%10; x/=10; } for (int i=0;i<now;i++) ret=ret*10+a[i]; return ret; } int main(){ int T,ca=1; f[1]=1; for (int i=2;i<=1000000;i++)...
4ced9f0864c9c7c297a6ed4f23672d06d904889a
2610e71fcc3c23e4bb4b2eac3a4ae3784116f3ce
jmoellmer/refactoring_a_first_example_cpp
/main.cpp
C++
cpp
989
no_license
#include <nlohmann/json.hpp> #include <iostream> #include "Statement.h" using namespace nlohmann; int main() { auto plays = R"( { "hamlet": {"name": "Hamlet", "type": "tragedy"}, "as-like": {"name": "As You Like It", "type": "comedy"}, "othello": {"name": "Othello", "t...
f5e6adcf8ba6b9a9502a0612cba49c7f42ba688a
1e70c05e1809fbefedd5deeee9039d49f780abbd
chenrui17/cudf
/cpp/src/comms/ipc/ipc.cpp
C++
cpp
893
permissive
#include <arrow/result.h> #include <cudf/ipc.hpp> CudaMessageReader::CudaMessageReader(arrow::cuda::CudaBufferReader* stream, arrow::io::BufferReader* schema) : stream_(stream), host_schema_reader_(schema){}; arrow::Result<std::unique_ptr<arrow::ipc::Message>> CudaMessageReader:...
392d396062fda77797e3aca82211b7769959bd32
ae4872f34efe3922dc4c16040c0c3fcd998aa650
Justice-/MGSmod
/monmove.cpp
C++
cpp
23,159
no_license
// Monster movement code; essentially, the AI #include "monster.h" #include "map.h" #include "game.h" #include "line.h" #include "rng.h" #include "pldata.h" #include <stdlib.h> #include "cursesdef.h" #ifndef SGN #define SGN(a) (((a)<0) ? -1 : 1) #endif #ifndef MIN #define MIN(a, b) ((a) < (b) ? (a) : (b)) #endif #d...
d95b5dbef8c629d8d04b4d46ed0c0c070c2bebad
8dc7ce6d44015ee96ee61d8b5090b26e14b13a72
famus2310/CP
/Template/fastio2.cpp
C++
cpp
1,950
no_license
#include <cstdio> /** Interface */ inline int readChar(); template <class T = int> inline T readInt(); template <class T> inline void writeInt( T x, char end = 0 ); inline void writeChar( int x ); inline void writeWord( const char *s ); /** Read */ static const int buf_size = 4096; inline int getChar() { static...
52aa4cf064f9013275bf25df13b9342f4520e4a2
b4ecbffc33edcc2a389b95bb8735f4f90bb49fbc
shiba090/aoj
/0105.cpp
C++
cpp
644
no_license
#include "bits/stdc++.h" using namespace std; typedef vector<int> vi; typedef pair<int,int> pii; typedef long long ll; #define dump(x) cerr << #x << " = " << (x) << endl #define rep(i,n) for(int i=0;i<(n);i++) #define all(a) (a).begin(),(a).end() #define pb push_back int main(){ string s; int n; map<string,vi>...
b4a52aba3b0f4ecbf22fa88f9570f56ce1cefe52
82e0aebe27947a6aec4fd1d4a20b306e84b5e49b
sankalp1999/Competitive-Programming
/CP/Codeforces/ByName_Before_July_2020/shapes.cpp
C++
cpp
596
no_license
//https://codeforces.com/contest/1339/problem/0 #include<bits/stdc++.h> #define REP(i,n) for (int i = 0; i < n; i++) #define mod 1000000007 #define pb push_back #define ff first #define ss second #define ii pair<int,int> #define vi vector<int> #define vii vector<ii> #define lli long long int #define INF 1000000000 #def...
408a4f4a0b16a1740deeb0be5123c0dbd82a2cc2
814627172d6772c690b4a7321360e1bb1debe691
ckgusqls95/inhaPractice
/FrameWork/FrameWork/GameOverSceneBtnEvent.cpp
C++
cpp
7,637
no_license
#include "stdafx.h" #include "GameOverSceneBtnEvent.h" #include "EventManager.h" #include "PopUp.h" #include "ObjectPool.h" #include "Scene.h" #include "TitleScene.h" void GameOverRetryBtnEvent(EventType message, cPopup* btn) { cButton* button = (cButton*)btn; D3DXVECTOR2 cur = EventManager->GetMouseCurrent(); D3D...
cf8dc95bc9994022e4bbb666bb9cf410e50ef940
451039b98a09dee0a895e72318b0c07d4ead7241
fredgrid/bvs
/libs/chain/include/eosio/chain/permission_object.hpp
C++
hpp
5,786
permissive
/** * @file * @copyright defined in bvs/LICENSE */ #pragma once #include <bvsio/chain/authority.hpp> #include <bvsio/chain/database_utils.hpp> #include "multi_index_includes.hpp" namespace bvsio { namespace chain { class permission_usage_object : public chainbase::object<permission_usage_object_type, permiss...
a496a90afc53548f62aae95ddff112f8b1c29c21
065a4d157d1fd5d8d2bb8f0f09caf693e980a4cc
monk78/Standard-Algorithms
/tree/BinaryTreeFromGivenInorderTraversal.cpp
C++
cpp
1,323
no_license
//special binary Tree such that root>left && root>right #include<bits/stdc++.h> using namespace std; //#define Fast ios::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL); typedef long long ll; typedef vector<ll>Vl; typedef pair<ll,ll>PII; typedef vector<PII>Vll; typedef vector<pair<ll,pair<ll,ll> > >Vlll; typedef pr...
0bacc0075b292904829de50fbd8834c1e82aa1d5
d29bb933d01c8f588ae3d1faec8d9dfc6b59e62e
whitlockjc/envoy
/test/extensions/common/dynamic_forward_proxy/dns_cache_impl_test.cc
C++
cc
57,231
permissive
#include "envoy/config/cluster/v3/cluster.pb.h" #include "envoy/config/core/v3/resolver.pb.h" #include "envoy/extensions/common/dynamic_forward_proxy/v3/dns_cache.pb.h" #include "envoy/extensions/key_value/file_based/v3/config.pb.validate.h" #include "source/common/config/utility.h" #include "source/common/network/res...
a2703253ac529d6f54e75fb74739725c3d80bdef
3000fda7933185f6aeecf944c43e0bb1151ad481
charlesg3/faux
/coreserv/core.cpp
C++
cpp
1,263
no_license
#include <sched.h> #include <common/param.h> #include <config/config.h> #include <iostream> #include <messaging/dispatch.h> #include <utilities/tsc.h> #include <utmpx.h> #include <core/core.h> #include "core_internal.h" Channel *core_chan = NULL; uint64_t core_get(uint64_t group) { if(core_chan == NULL) { ...
0ffc698d54dc4b42e055f869930a0b09617ba82a
f4fe20f84f476f472e86205c6cd4b4a6f84d618d
VJSchneid/wf-700tk
/src/credit_channel.cpp
C++
cpp
361
permissive
#include <wf700tk/credit_channel.hpp> namespace wf700tk { std::optional<credit_channel> make_credit_channel(unsigned char v) { if (v <= 0x20) { const unsigned char lower = v & 0x0f; if (lower == 0x08 || lower == 0x00) { return static_cast<credit_channel>(v); } } return...
1a65efbbf4d77ecd674182ad6da1fde0f34df531
a53fa5a5fdd6b03c9345c8467c2b8da78a44dfec
gem-sw/cmssw
/DQMOffline/Trigger/src/EgHLTOfflineSource.cc
C++
cc
13,755
no_license
#include "DQMOffline/Trigger/interface/EgHLTOfflineSource.h" #include "DQMOffline/Trigger/interface/EgHLTEleHLTFilterMon.h" #include "DQMOffline/Trigger/interface/EgHLTPhoHLTFilterMon.h" #include "DQMOffline/Trigger/interface/EgHLTDebugFuncs.h" #include "DQMOffline/Trigger/interface/EgHLTDQMCut.h" #include "DQMOfflin...
23dd7d76a918786ea975428c4227518809265844
6e5c2793890be8fba418b75037762d1693ef6c73
dudochkin-victor/touch-systemui
/tests/ut_notifiernotificationsink/ut_notifiernotificationsink.cpp
C++
cpp
9,447
no_license
/**************************************************************************** ** ** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). ** All rights reserved. ** Contact: Nokia Corporation (directui@nokia.com) ** ** This file is part of systemui. ** ** If you have questions regarding the use of this file...
9119baeef95bda17420cc8f10a9df5f50762bc0b
986e08b51743950d147b8f1e3a30fbecc269468a
stackprobe/Fairy
/wb/t20190402/t0001/t0001/t0001/Common/Engine.cpp
C++
cpp
4,340
permissive
/* copied the source file by https://github.com/stackprobe/Factory/blob/master/SubTools/CopyLib.c */ #include "all.h" /* copied the source file by https://github.com/stackprobe/Factory/blob/master/SubTools/CopyLib.c */ int IgnoreEscapeKey; // 他のファイルからは read only { /* copied the source file by https://github.com/st...
1c2db78aee2015365b84d2fd52069319f586490a
99e5fd1e4443f17f36cfbba6d43f0f53b9bc1fa9
estersimkova/EPFL-SV-cpp-Projects-Network
/src/network.cpp
C++
cpp
2,706
no_license
#include "network.h" #include "random.h" #include <algorithm> void Network :: resize(const size_t& n) { RandomNumbers ran; values.clear(); for (unsigned int i(0); i< n; ++i) { values.push_back(ran.normal(0.0, 1.0)); } } bool Network:: add_link(const size_t& i, const size_t& j) { if ((values.size() > i) and (v...
1d579ffeb97a45bf9a0414bdb2276a1639ce7b80
821abd945c69fc51e3940f5e18373d0d8692887d
NHambley/Spacey-McSpacefighter
/Game/A06 - Octree/AppClassControls.cpp
C++
cpp
14,261
no_license
#include "AppClass.h" using namespace Simplex; //Mouse void Application::ProcessMouseMovement(sf::Event a_event) { //get global mouse position sf::Vector2i mouse = sf::Mouse::getPosition(); sf::Vector2i window = m_pWindow->getPosition(); m_v3Mouse.x = static_cast<float>(mouse.x - window.x); m_v3Mouse.y = static_ca...
32a8a5d66fab5b3ae9d80fb0fe2f7066b81ad62a
ac3737a3502a181cfcb550c0ad3f25d8f0af2aa4
blockspacer/cobalt-clone-cab7770533804d582eaa66c713a1582f361182d3
/src/cobalt/bindings/testing/sequence_bindings_test.cc
C++
cc
21,662
permissive
// Copyright 2017 The Cobalt 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 ap...
01f30bff2f3497f255dd1d60a1cd5739e31cdeda
255fd7d5a78b2b4d99975dbc2766351de14200ec
MughalUsama/Object-Oriented-Programming
/HOMEWORK 2/Project1/Project1/CString.cpp
C++
cpp
13,655
no_license
#include "CString.h" #include <iostream> using namespace std; CString::CString() { this->size = 0; this->str = nullptr; } CString::CString(char c) { this->size = 1; this->str = new char[2]; this->str[0] = c; this->str[1] = '\0'; } CString::CString(char *s1) { this->size = 0; while (s1[this->size] != '\0') ...
2435db178c88e7bbe1135abcf27a8a620f225661
6bcd9b433b04388222cf54d4a992435cc9724b42
hayoola/archway
/archway/functions_node_processor.cc
C++
cc
2,676
no_license
/** * functions_node_processor.cc * */ #include "functions_node_processor.h" #include "host_program.h" #include "dynamic_function.h" using namespace archway; int FunctionsNodeProcessor::ProcessNode( const YAML::Node& in_node, std::shared_ptr<Archway> archway, std::any in_context ) { int the_result...
1ddf7c174697183b34011aab378d796e7612d3c2
162f655481f601720c7bfa66fa3e8436e1327ec1
moccajoghurt/double_up_bot
/main.cpp
C++
cpp
2,754
no_license
#include <iostream> #include "screen_scraper.hpp" #include "titanpoker.hpp" #include "table.hpp" //using namespace std; /* int wcount = 0; BOOL CALLBACK EnumChildProc(HWND hwnd, LPARAM lParam) { if (IsWindow(hwnd)) { imshow("test", ScreenScraper::window_to_mat(hwnd)); waitKey(0); cout << wcount << endl; } w...
12d8e0d9f7147b36c7181006c339d44eb2eaa1c4
f86fa65c839dd57193725a47bf39737b7fe0073e
lanxb/myRtspClient
/myRtspClient/rtspClient.cpp
C++
cpp
64,209
permissive
// Copyright 2015-2018 Ansersion // // 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 o...
7a8f45f417798429a694c4baa81cc6102a4f7057
6ca14c33a6d0d126bb18a8f2417e493186baab0e
francescog/nt2
/modules/boost_math/include/nt2/toolbox/boost_math/function/ellint_rf.hpp
C++
hpp
1,108
permissive
////////////////////////////////////////////////////////////////////////////// /// Copyright 2003 and onward LASMEA UMR 6602 CNRS/U.B.P Clermont-Ferrand /// Copyright 2009 and onward LRI UMR 8623 CNRS/Univ Paris Sud XI /// /// Distributed under the Boost Software License, Version 1.0 /// ...
489fd813ac312fea8993532bbed35e150f7d3995
dbe425ba38e7ef29be515fa63f5a40bcd3f1a9ff
magicwish/os_exercises
/code/03-3-lab2-spoc-discussion-analyseAddr/analyseAddr.cpp
C++
cpp
1,146
no_license
#include <iostream> #include <fstream> #include <iomanip> #include <cstdio> using namespace std; const int kOffsetWidth = 12; const int kPTEWidth = 10; const int kPDEWidth = 10; const int kPageSize = 4 * 1024; int main() { ifstream in("in.txt"); ofstream out("out.txt"); unsigned int vaddr, paddr; unsigned ...
779e341d45d2c1de9b2b7a2b272d05b1a515350d
58a97ff3c9231ff507f33a588ef761fb867ed2ac
jstavr/Architecture-Relation-Evaluator
/Replication/DataFileSystem/PRODUCT_SOURCE_CODE/itk/Modules/Filtering/ImageFilterBase/include/itkVectorNeighborhoodOperatorImageFilter.hxx
C++
hxx
5,032
no_license
/*========================================================================= * * Copyright Insight Software Consortium * * 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 * * ...
28d803c2eaab40d1ed880fa0ce7bd7b926c17682
999e4b0b08a5f37e50fcfc987edb8693d7d88934
istepping/code
/c++/职工信息统计/职工信息统计/main.cpp
C++
cpp
17,238
no_license
#include "stdio.h" #include "stdlib.h" #include "string.h" int saveflag = 0; /*是否需要存盘的标志变量*/ struct employee { char name[15]; char num[10];/* 工号 */ char sex[4]; char bm[15]; char zc[20]; int gz; }; typedef struct node { struct employee data; struct node *next; }Node, *Link; //Link l (注意是?字母 l 不是数字 1) void Add(L...
c7efc7382457b0851ab0581039c1de54774276f5
e0ef30a721f4c85efdbb13119ae027ad83626647
fahimSiam/Problem-Solving-Done-in-CPP
/I Love Strings!!.cpp
C++
cpp
448
no_license
#include <bits/stdc++.h> #define ll long long using namespace std; int main() { ll int i,j,a,b; string st,s; // a=0; // b=0; cin>>i; while(i--){ cin>>st>>j; while(j--){ cin>>s; if(strstr(st.c_str(),s.c_str())){ cout<<"y"<<endl; ...
780365f6eaa9b956011e207f7b6cbd4f294bc0bb
ec5ce48b09584485aa4efc13359e57bd8dd00121
aishee/hhvm
/hphp/runtime/ext/ldap/ext_ldap.cpp
C++
cpp
51,429
permissive
/* +----------------------------------------------------------------------+ | HipHop for PHP | +----------------------------------------------------------------------+ | Copyright (c) 2010-2016 Facebook, Inc. (http://www.facebook.com) | | Copyrigh...
15acc535d1b61e5c0cce859a9517b0f819c6293e
e46427b09bbd410d4cbaf8abca7ff7a909d9866d
StomatoGod/fluid-engine-OpenVDB
/src.common/surface2.cpp
C++
cpp
2,544
permissive
// Copyright (c) 2018 Doyub Kim // // I am making my contributions/submissions to this project solely in my // personal capacity and am not conveying any rights to any intellectual // property of any third parties. #include "surface2.h" #include <algorithm> using namespace vox; Surface2::Surface2(const Transform2& ...
2ac3f6f96c00c249e8352d40b8bb88fd710a8533
19ff662fc96d115752121412e413e5a7f163456e
parkjungeun/Algorithm-Problem-Code
/BOJ/[BOJ]1475_방번호.cpp
C++
cpp
665
no_license
//https://www.acmicpc.net/problem/1475 #include<iostream> #include<string> #define MAX_SIZE 7 using namespace std; string N; int num[10]; //숫자개수 카운트 int solution() { for (int i = 0; i < N.length(); ++i) { if (N[i] - '0' == 9) num[6]++; else num[N[i] - '0']++; } int maxCnt = -1, maxNum = -1; for (int i = ...
feed9344f6851a076f89d11c177ad98455b2ef37
88fef3bb3ab9efeeda7bd238a70c2a9da0fc233b
xulizhi321/deepflow
/src/nodes/pooling.cpp
C++
cpp
2,093
permissive
#include "nodes/pooling.h" Pooling::Pooling(deepflow::NodeParam *param) : Node(param) { LOG_IF(FATAL, param->has_pooling_param() == false) << "param.has_pooling_param() == false"; } void Pooling::init() { DF_NODE_CUDNN_CHECK(cudnnCreate(&_cudnnHandle)); auto param = _param->pooling_param(); LOG_IF(FATAL, param.wi...
ed501778afe98cc85dbec9555bff8885d1808102
8b17ad947f827c82c89d758377322551cc9664b7
sharif-hossain/uri-online-judge
/uri37/main.cpp
C++
cpp
535
no_license
#include <iostream> using namespace std; int main() { float num; cin >> num; if (num < 0 || num > 100){ cout << "Fora de intervalo" << endl; } else if(num >= 0 && num <= 25){ cout << "Intervalo [0,25]" << endl; } else if(num > 25 && num <= 50){ cout << "Intervalo (2...
d29455e36bbcb2b6a3d2706c59725c3b4181c977
6699c6b56d356f0864ad3f627eaf02fd1e0d0425
Redestroy/MRS
/MRSlib/MRS/MRS/Source/ProtocolParser.cpp
C++
cpp
4,245
no_license
#include "../Include/ProtocolParser.hpp" #include "../Include/SIMPLE_MRS_PARSER.hpp" namespace MRS { namespace Device { const char* ProtocolParser::GenerateFormatString(PROTOCOL_TYPE input, PROTOCOL_TYPE output, std::string arg_template, int num) { std::string output_format = ""; //output_format += GetStart...
17ec168ca23694d96c4f6c42abafb2a2a5908351
26f272396872591318029730d393124a0f4659e3
phuthien0705/OOP-tuan-11
/Bai1-TruongDaiHoc(VD)/Bai1-TruongDaiHoc/main.cpp
C++
cpp
6,446
no_license
#include"TRUONGDH.h" #include <fstream> int main() { ifstream file("Input.txt"); TRUONGDH t; int button = -1; while (button != 0) { cout << " ========MENU========" << endl; cout << setiosflags(ios::left) << setw(50) << "0 - Ket thuc chuong trinh."; cout << setiosflags...
07a1e732be190f95a4fb9e78752f1ee97caab9f6
e98e2a19609be1ceccab743cee77cf23a8b85b84
vindaxcom/vindax-chain
/src/walletdb.cpp
C++
cpp
23,834
permissive
// Copyright (c) 2009-2010 Satoshi Nakamoto // Copyright (c) 2009-2012 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 "walletdb.h" #include "wallet.h" #include <boost/version.hpp> #include <b...
5a938002767e31134dd22ae392e20ed99ca49d7f
6b0a4129d8481e1df99c9b3042792f94877981a2
PaulBautin/spinalcordtoolbox
/dev/isct_propseg/Mesh.cpp
C++
cpp
30,220
permissive
#include "Mesh.h" #include <algorithm> #include <vector> #include <vtkPlane.h> #include <vtkCutter.h> #include <vtkClipPolyData.h> #include <vtkPolyDataWriter.h> #include <vtkCellArray.h> #include <vtkSmartPointer.h> #include <vtkPolyDataReader.h> #include <vtkPoints.h> #include <vtkPolyData.h> #include <vtkPointData.h...
9576a83d4ad301ef1ea444c37cd9c08b34afa940
217be079d12104043bb0777ef128b0dd79a7f0e9
miszazmisza/projekty
/64.3(11 marca) Michał Kałużny.cpp
C++
cpp
416
no_license
#include <iostream> #include <fstream> #include <string> #include <stdlib.h> #include <bitset> #include <cstdlib> using namespace std; int main(int argc, char** argv) { ifstream file; file.open("C:\Users\dane_obrazki.txt"); if (!file.eof()){ for(int i=0; i<7; i++) { string tab[...
7f9fc0616ea5549ae6b1d5a108a85d7ebaef5a3a
827a2b05e22d9f2f267d95aafa328aff66001260
a3845021/MyCStudy
/MyCStudy/MemoryStudy.cpp
C++
cpp
1,381
no_license
#include "MemoryStudy.h" //molloc函数在这里面 void MemoryStudy::run(){ /* 内存的组织方式 内存分为四个区 代码区(存储着程序代码) 数据区(存储静态、全局数据,常量 ) 堆区(存储着动态分配的内存,也是主要清理的区域 ) 栈区(主要存放局部变量 函数参数) */ //静态分配内存 int a = 9; int *p1 = &a; /* 访问方式 *p1; a; */ //动态分配4个字节 会把分配的内存首地址返回 //分配整形变量 int * pInt = (int*)malloc(sizeof(int)); ...
3823c7497444acd7ee23b0d455f6f7189caf5a54
8195b7203bb310d574e70d6ac8fa716c64e30039
MrDans-dev/C-Cpp
/hex_calc/hex_calc.cpp
C++
cpp
3,437
no_license
#include <iostream> #include <math.h> #include <vector> #include <Windows.h> #include <string.h> #include <algorithm> using namespace std; const vector<char>hex_list = { '0' , '1' , '2' , '3' , '4' , '5' , '6' , '7', '8' , '9' , 'A' , 'B', 'C' , 'D' , 'E' , 'F' }; vector<char> string_2_vec(string con) { transform(...
ca30c028681436d05dab90986ce11b929fa311ce
d9c326485f471f8c9b01b1aabf793a3fb974ebe8
SleepySquash/NekoUI.cpp
/NekoUI/Components/NekoUIComponents/Places/Misc/StrangeShopkeeperUI.hpp
C++
hpp
1,622
no_license
// // StrangeShopkeeperUI.hpp // NekoUI // // Created by Никита Исаенко on 25.01.2020. // Copyright © 2020 Melancholy Hill. All rights reserved. // #ifndef StrangeShopkeeperUI_hpp #define StrangeShopkeeperUI_hpp #include <iostream> #include <SFML/Main.hpp> #include <SFML/Graphics.hpp> #include <minEH/Essentials...
4854cd4b038c9f370425842f66c09690cd923c40
91b13ec12fd803ef4d2ab2a203d13c8428935578
Arkozak/CS202
/Homework 2/value.cpp
C++
cpp
1,441
no_license
#include "value.hpp" void queuepush(list<std::shared_ptr<Monster>> enemies, std::shared_ptr<Monster> goblin) { enemies.push_back(goblin); } void queuepop(list<std::shared_ptr<Monster>> enemies) { enemies.pop_front(); } void stackpush(list<std::shared_ptr<Monster>> enemies, std::shared_ptr<Monster> goblin) { enem...
1b7210380e80338fc133f8936e588eb4686cc336
d2341c2dce29b56725b8b0a6bef93f6ae1fd02a5
hutuxian/Paddle
/paddle/fluid/operators/distributed/brpc/brpc_sendrecvop_utils.cc
C++
cc
8,221
permissive
/* Copyright (c) 2016 PaddlePaddle 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...
262d5d9c0d6db2c4384547c68b98dc63ae520e28
16e32b89d4862cdac19d928ea2a866dd4a910492
wiglot/Trabalhos-IA
/vrp-ia/rota.cpp
C++
cpp
2,206
no_license
#include <ostream> #include <istream> #include <iostream> #include <fstream> #include <string> #include <vector> #include <cmath> #include <cstdlib> #include <ctime> using namespace std; #include "point.h" #include "instancevrp.h" #include "rota.h" Rota::Rota():custoRota(0){ } void Rota::setCusto(){ int j; this-...
b24e7c3464e8d4c60684365af4316621a983f0ff
eab1be989140f5b4a5a1ec04b5057e804e65eaca
CamilleINGOUF/MasterMind
/src/NetworkState.cpp
C++
cpp
9,198
no_license
//////////////////////////////////////////////////////////// /// Headers //////////////////////////////////////////////////////////// #include "protocol.hpp" #include "AssetsDeclarations.hpp" #include "AssetManager.hpp" #include "GameStateManager.hpp" #include "GameContext.hpp" #include "MusicPlayer.hpp" #include "Netw...
4e3daf6a0d261f4d5be527d58324d3bbfb0442cc
d7eef08396245204c166c5288c68545331b96fd4
rhomobile/rhodes
/lib/commonAPI/barcode/ext/platform/wm/src/EMDKInterfaceAbstraction.cpp
C++
cpp
13,363
permissive
#include "Scanner.h" #pragma region Scanner_Properties BOOL CScanner::RetrieveScannerParameters(READER_PARAMS* pReaderParams) { // Initialize the structure memset(pReaderParams, 0, sizeof(READER_PARAMS)); SI_INIT(pReaderParams); DWORD dwResult = lpfn_SCAN_GetReaderParams(m_hScanner, pReaderParams); if (dwResul...
5e841ca03bcd5a000697f778dd4a9cb42a56ad53
7baab267bff7f7f461fc814917f4263cdacf7bbc
smithgold53/HMSReportForms
/Pharmacy/MAMaterialUsagebyOriginDept.cpp
C++
cpp
32,480
no_license
#include "stdafx.h" #include "MAMaterialUsagebyOriginDept.h" #include "MainFrame_E10.h" #include "ReportDocument.h" #include "Excel.h" /*static void _OnYearChangeFnc(CWnd *pWnd){ ((CMAMaterialUsagebyOriginDept *)pWnd)->OnYearChange(); } */ /*static void _OnYearSetfocusFnc(CWnd *pWnd){ ((CMAMaterialUsagebyOriginDept ...
c32a9ca55ed8252d52aacf431caaba44539a3c9a
864773cf33962adfb7d556c8ed8d624d29d6e6ac
DSsoto/memory_manager
/src/memory_manager.hpp
C++
hpp
2,004
permissive
#include <string> #include <iostream> #include <sstream> #include <algorithm> #include <cmath> #include <vector> #define nullptr 0 class Program; class MemoryFragment; class MemoryManager; class MemoryFragmentList; class Program{ friend class MemoryManager; public: Program(std::string name, size_t size); ~Prog...
6aef2999b664e3b9469c6b89cda57429fce0760f
8aab72dc7171f0d6eb4ea216ac92df4640441468
sschimper/RayTracingInAWeekend
/main.cpp
C++
cpp
1,535
no_license
#include <iostream> #include <fstream> #include "sphere.h" #include "hitable_list.h" #include "float.h" vec3 colour(const ray& r, hitable *world) { hit_record rec; if(world->hit(r, 0.0, MAXFLOAT, rec)) { return 0.5*vec3(rec.normal.x()+1, rec.normal.y()+1, rec.normal.z()+1); } else { v...
323c090840559a7a56fbf4cb7f6b02e5639ba03c
a450792442ea76ffd1900b4ebea0b5a289323fd2
amapig/Documents
/c++/c++primer第四版本源码/16/use-handle.cpp
C++
cpp
1,934
no_license
/* * This file contains code from "C++ Primer, Fourth Edition", by Stanley B. * Lippman, Jose Lajoie, and Barbara E. Moo, and is covered under the * copyright and warranty notices given in that book: * * "Copyright (c) 2005 by Objectwrite, Inc., Jose Lajoie, and Barbara E. Moo." * * * "The authors an...
8196efeff54c6b78c324052878b22ca1729b93be
d3a27a76675f341ab7c2b14cf19298fd999e9518
el-bart/ACARM-ng
/src/persistency/Persistency/IO/ConnectionHelper.hpp
C++
hpp
2,443
no_license
/* * ConnectionHelper.hpp * */ #ifndef INCLUDE_PERSISTENCY_IO_CONNECTIONHELPER_HPP_FILE #define INCLUDE_PERSISTENCY_IO_CONNECTIONHELPER_HPP_FILE /* public header */ #include "Persistency/IO/Connection.hpp" namespace Persistency { namespace IO { /** \brief Helper class for easier creating basic implementations of...