hexsha stringlengths 40 40 | size int64 7 1.05M | ext stringclasses 13
values | lang stringclasses 1
value | max_stars_repo_path stringlengths 4 269 | max_stars_repo_name stringlengths 5 109 | max_stars_repo_head_hexsha stringlengths 40 40 | max_stars_repo_licenses listlengths 1 9 | max_stars_count int64 1 191k ⌀ | max_stars_repo_stars_event_min_datetime stringlengths 24 24 ⌀ | max_stars_repo_stars_event_max_datetime stringlengths 24 24 ⌀ | max_issues_repo_path stringlengths 4 269 | max_issues_repo_name stringlengths 5 116 | max_issues_repo_head_hexsha stringlengths 40 40 | max_issues_repo_licenses listlengths 1 9 | max_issues_count int64 1 48.5k ⌀ | max_issues_repo_issues_event_min_datetime stringlengths 24 24 ⌀ | max_issues_repo_issues_event_max_datetime stringlengths 24 24 ⌀ | max_forks_repo_path stringlengths 4 269 | max_forks_repo_name stringlengths 5 116 | max_forks_repo_head_hexsha stringlengths 40 40 | max_forks_repo_licenses listlengths 1 9 | max_forks_count int64 1 105k ⌀ | max_forks_repo_forks_event_min_datetime stringlengths 24 24 ⌀ | max_forks_repo_forks_event_max_datetime stringlengths 24 24 ⌀ | content stringlengths 7 1.05M | avg_line_length float64 1.21 330k | max_line_length int64 6 990k | alphanum_fraction float64 0.01 0.99 | author_id stringlengths 2 40 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
651162572aa7b7cbd753b2f7fd25c25e50ba7b26 | 3,601 | hpp | C++ | ivarp/include/ivarp/refactor_constraint_system/bound_and_simplify/bounded.hpp | phillip-keldenich/squares-in-disk | 501ebeb00b909b9264a9611fd63e082026cdd262 | [
"MIT"
] | null | null | null | ivarp/include/ivarp/refactor_constraint_system/bound_and_simplify/bounded.hpp | phillip-keldenich/squares-in-disk | 501ebeb00b909b9264a9611fd63e082026cdd262 | [
"MIT"
] | null | null | null | ivarp/include/ivarp/refactor_constraint_system/bound_and_simplify/bounded.hpp | phillip-keldenich/squares-in-disk | 501ebeb00b909b9264a9611fd63e082026cdd262 | [
"MIT"
] | null | null | null | // The code is open source under the MIT license.
// Copyright 2019-2020, Phillip Keldenich, TU Braunschweig, Algorithms Group
// https://ibr.cs.tu-bs.de/alg
//
// Permission is hereby granted, free of charge, to any person obtaining a copy of
// this software and associated documentation files (the "Software"), to de... | 43.914634 | 121 | 0.679811 | phillip-keldenich |
fb97ad979466ab2667fd371cd3d645500eda19eb | 1,002 | cpp | C++ | progress/herding.cpp | birdhumming/usaco | f011e7bd4b71de22736a61004e501af2b273b246 | [
"OLDAP-2.2.1"
] | null | null | null | progress/herding.cpp | birdhumming/usaco | f011e7bd4b71de22736a61004e501af2b273b246 | [
"OLDAP-2.2.1"
] | null | null | null | progress/herding.cpp | birdhumming/usaco | f011e7bd4b71de22736a61004e501af2b273b246 | [
"OLDAP-2.2.1"
] | null | null | null | #include <iostream>
#include <fstream>
using namespace std;
bool herded(int A, int B, int C) {
if (B-A==1 && C-B==1) return true;
return false;
}
int find_min(int A, int B, int C, int moves) {
if (herded(A, B, C)) {
cout<<moves;
return 0;
}
int ld, rd; //left distance, right distanc... | 18.555556 | 47 | 0.472056 | birdhumming |
fb97e50d4da5b7a44c96164089206351794cec06 | 1,547 | cpp | C++ | ch5/5-11_set_recv_buffer.cpp | JimmyTang178/MyLinuxServer | 12d8b103163566090807469276fe4dcf4cef0b67 | [
"Apache-2.0"
] | null | null | null | ch5/5-11_set_recv_buffer.cpp | JimmyTang178/MyLinuxServer | 12d8b103163566090807469276fe4dcf4cef0b67 | [
"Apache-2.0"
] | null | null | null | ch5/5-11_set_recv_buffer.cpp | JimmyTang178/MyLinuxServer | 12d8b103163566090807469276fe4dcf4cef0b67 | [
"Apache-2.0"
] | null | null | null | #include <sys/socket.h>
#include <arpa/inet.h>
#include <netinet/in.h>
#include <unistd.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#include <stdio.h>
#include <assert.h>
#define BUF_SIZE 1024
int main(int argc, char* argv[]){
if (argc <= 3){
printf("usage: %s ip port recv_buffer_size\n... | 26.672414 | 74 | 0.618617 | JimmyTang178 |
fb990ef5a987bd942b89128aa41020c92c8b31bd | 251 | cpp | C++ | src/UOJ_1060 - (1698051) Accepted.cpp | dreamtocode/URI | 1f402853e8ae43f3761fc3099e7694bff721d5bc | [
"MIT"
] | 1 | 2015-04-26T03:55:07.000Z | 2015-04-26T03:55:07.000Z | src/UOJ_1060 - (1698051) Accepted.cpp | dreamtocode/URI | 1f402853e8ae43f3761fc3099e7694bff721d5bc | [
"MIT"
] | null | null | null | src/UOJ_1060 - (1698051) Accepted.cpp | dreamtocode/URI | 1f402853e8ae43f3761fc3099e7694bff721d5bc | [
"MIT"
] | null | null | null | #include <iostream>
using namespace std;
int main() {
double a;
int b = 0;
for(int i = 0; i < 6; i++) {
cin>>a;
if (a==0) continue;
if(a > 0)
b++;
}
cout<<b<<" valores positivos\n";
return 0;
} | 16.733333 | 36 | 0.446215 | dreamtocode |
fb99bfed6e5eb5e89e24e969ae56f304c12a8651 | 870 | cpp | C++ | AZ3166/src/cores/arduino/system/SerialLog.cpp | duglah/devkit-sdk | 7f016a1b00a25d6133009028c67b75e54495cf93 | [
"MIT"
] | 34 | 2019-05-08T07:36:51.000Z | 2021-11-11T19:40:39.000Z | AZ3166/src/cores/arduino/system/SerialLog.cpp | duglah/devkit-sdk | 7f016a1b00a25d6133009028c67b75e54495cf93 | [
"MIT"
] | 127 | 2018-01-04T10:24:22.000Z | 2019-04-19T15:18:58.000Z | AZ3166/src/cores/arduino/system/SerialLog.cpp | duglah/devkit-sdk | 7f016a1b00a25d6133009028c67b75e54495cf93 | [
"MIT"
] | 30 | 2018-01-15T03:40:57.000Z | 2019-04-18T19:58:19.000Z | // Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license.
#include "Arduino.h"
#ifdef __cplusplus
extern "C" {
#endif
void serial_log(const char* msg)
{
if (msg != NULL)
{
Serial.print(msg);
}
}
void serial_xlog(const char *format, ...)
{
va_list... | 17.755102 | 61 | 0.514943 | duglah |
fb9a663e106034b1524963366ddb62a387e02449 | 2,749 | cpp | C++ | src/core/actions/set_categories_draw_disabled.cpp | svendcsvendsen/judoassistant | 453211bff86d940c2b2de6f9eea2aabcdab830fa | [
"MIT"
] | 3 | 2019-04-26T17:48:24.000Z | 2021-11-08T20:21:51.000Z | src/core/actions/set_categories_draw_disabled.cpp | svendcsvendsen/judoassistant | 453211bff86d940c2b2de6f9eea2aabcdab830fa | [
"MIT"
] | 90 | 2019-04-25T17:23:10.000Z | 2022-02-12T19:49:55.000Z | src/core/actions/set_categories_draw_disabled.cpp | judoassistant/judoassistant | 3b200d3e35d9aff16ba224e6071ee9d888a5a03c | [
"MIT"
] | null | null | null | #include "core/actions/set_categories_draw_disabled.hpp"
#include "core/actions/draw_categories_action.hpp"
#include "core/draw_systems/draw_system.hpp"
#include "core/rulesets/ruleset.hpp"
#include "core/stores/category_store.hpp"
#include "core/stores/tournament_store.hpp"
SetCategoriesDrawDisabled::SetCategoriesDra... | 32.72619 | 123 | 0.720626 | svendcsvendsen |
fba01e0641b67f43f20947fabad68968f2d80333 | 4,484 | cpp | C++ | SocketCode/PyC/serverP.cpp | TeCSAR-UNCC/NVDA_DETEC | 6ec484ec0ef4ad1382056ceb0cd5e4c197c576b9 | [
"Apache-2.0"
] | 12 | 2019-05-10T09:56:39.000Z | 2021-08-09T03:42:28.000Z | SocketCode/PyC/serverP.cpp | TeCSAR-UNCC/Edge-Video-Analytic | 6ec484ec0ef4ad1382056ceb0cd5e4c197c576b9 | [
"Apache-2.0"
] | null | null | null | SocketCode/PyC/serverP.cpp | TeCSAR-UNCC/Edge-Video-Analytic | 6ec484ec0ef4ad1382056ceb0cd5e4c197c576b9 | [
"Apache-2.0"
] | 7 | 2019-06-14T03:38:09.000Z | 2021-08-09T03:43:27.000Z | #include <unistd.h>
#include <stdio.h>
#include <sys/socket.h>
#include <stdlib.h>
#include <netinet/in.h>
#include <string.h>
#define PORT 65432
#define IPADDR INADDR_ANY
#include "opencv2/opencv.hpp"
using namespace cv;
//g++ serverTest.cpp -o server `pkg-config --cflags --libs opencv`
//gcc -shared -Wl,-son... | 18.919831 | 91 | 0.640946 | TeCSAR-UNCC |
fba3edb2e9f0fe48298033d075a4778a8cd50850 | 5,779 | cpp | C++ | RogueEngine/Source/PatrolAI.cpp | silferysky/RogueArcher | 3c77696260f773a0b7adb88b991e09bb35069901 | [
"FSFAP"
] | 1 | 2019-06-18T20:07:47.000Z | 2019-06-18T20:07:47.000Z | RogueEngine/Source/PatrolAI.cpp | silferysky/RogueArcher | 3c77696260f773a0b7adb88b991e09bb35069901 | [
"FSFAP"
] | null | null | null | RogueEngine/Source/PatrolAI.cpp | silferysky/RogueArcher | 3c77696260f773a0b7adb88b991e09bb35069901 | [
"FSFAP"
] | null | null | null | /* Start Header ************************************************************************/
/*!
\file PatrolAI.cpp
\project Exale
\author Chan Wai Kit Terence, c.terence, 440005918 (100%)
\par c.terence\@digipen.edu
\date 1 December,2019
\brief This file contains the... | 30.256545 | 141 | 0.702025 | silferysky |
fba60b470c16f69d924243310f711e871656007b | 1,339 | cpp | C++ | src/connection.cpp | Zack-83/xml2 | e7e87ecb1f3d7ef0f5ce50148644a860ea8125c3 | [
"MIT"
] | 114 | 2017-06-14T07:07:32.000Z | 2022-03-02T00:38:08.000Z | src/connection.cpp | Zack-83/xml2 | e7e87ecb1f3d7ef0f5ce50148644a860ea8125c3 | [
"MIT"
] | 180 | 2017-07-19T21:42:10.000Z | 2022-03-09T09:38:03.000Z | src/connection.cpp | Zack-83/xml2 | e7e87ecb1f3d7ef0f5ce50148644a860ea8125c3 | [
"MIT"
] | 55 | 2017-07-28T21:42:38.000Z | 2022-03-15T03:46:24.000Z | #include <Rinternals.h>
#include <vector>
#include "xml2_utils.h"
// Wrapper around R's read_bin function
SEXP read_bin(SEXP con, size_t bytes) {
SEXP e;
SEXP raw_sxp = PROTECT(Rf_mkString("raw"));
SEXP bytes_sxp = PROTECT(Rf_ScalarInteger(bytes));
PROTECT(e = Rf_lang4(Rf_install("readBin"), con, raw_sxp, byte... | 24.796296 | 79 | 0.695295 | Zack-83 |
fbace5aef821cfaa0ed9b883f8217c9659afc97e | 63,162 | cpp | C++ | RocketPlugin/RocketLobbyWidgets.cpp | Adminotech/meshmoon-plugins | 32043ef783bdf137860d7d01eb22de564628e572 | [
"Apache-2.0"
] | 4 | 2018-05-09T01:55:14.000Z | 2021-12-19T17:46:29.000Z | RocketPlugin/RocketLobbyWidgets.cpp | Adminotech/meshmoon-plugins | 32043ef783bdf137860d7d01eb22de564628e572 | [
"Apache-2.0"
] | null | null | null | RocketPlugin/RocketLobbyWidgets.cpp | Adminotech/meshmoon-plugins | 32043ef783bdf137860d7d01eb22de564628e572 | [
"Apache-2.0"
] | 2 | 2016-03-15T06:12:05.000Z | 2021-06-06T00:18:38.000Z | /**
@author Adminotech Ltd.
Copyright Adminotech Ltd.
All rights reserved.
@file
@brief */
#include "StableHeaders.h"
#include "RocketLobbyWidgets.h"
#include "RocketLobbyWidget.h"
#include "RocketPlugin.h"
#include "utils/RocketAnimations.h"
#include "Math/MathFunc.h"
#include "Framework.... | 32.424025 | 181 | 0.629682 | Adminotech |
fbb3914ba9946d115068326a3cc9138f23ef2b72 | 14,871 | cpp | C++ | src/lib/OpenEXR/ImfMultiPartOutputFile.cpp | remia/openexr | 566087f13259f4429d55125d1001b2696ac2bfc3 | [
"BSD-3-Clause"
] | 587 | 2015-01-04T09:56:19.000Z | 2019-11-21T13:23:33.000Z | third_party/openexr-672c77d7c923402f549371e08b39ece4552cbb85/src/lib/OpenEXR/ImfMultiPartOutputFile.cpp | Vertexwahn/FlatlandRT | 37d09fde38b25eff5f802200b43628efbd1e3198 | [
"Apache-2.0"
] | 360 | 2015-01-04T10:55:17.000Z | 2019-11-21T16:37:22.000Z | third_party/openexr-672c77d7c923402f549371e08b39ece4552cbb85/src/lib/OpenEXR/ImfMultiPartOutputFile.cpp | Vertexwahn/FlatlandRT | 37d09fde38b25eff5f802200b43628efbd1e3198 | [
"Apache-2.0"
] | 297 | 2015-01-11T12:06:42.000Z | 2019-11-19T21:59:57.000Z | //
// SPDX-License-Identifier: BSD-3-Clause
// Copyright (c) Contributors to the OpenEXR Project.
//
#include "ImfMultiPartOutputFile.h"
#include "ImfBoxAttribute.h"
#include "ImfChromaticitiesAttribute.h"
#include "ImfDeepScanLineOutputFile.h"
#include "ImfDeepTiledOutputFile.h"
#include "ImfFloatAttribute.h"
#includ... | 28.653179 | 92 | 0.589671 | remia |
fbb5b2175e5aa94cf133c39edd86958527354dfc | 3,223 | cpp | C++ | src/xray/render/base/sources/render_base_world.cpp | ixray-team/ixray-2.0 | 85c3a544175842323fc82f42efd96c66f0fc5abb | [
"Linux-OpenIB"
] | 3 | 2021-10-30T09:36:14.000Z | 2022-03-26T17:00:06.000Z | src/xray/render/base/sources/render_base_world.cpp | acidicMercury8/ixray-2.0 | 85c3a544175842323fc82f42efd96c66f0fc5abb | [
"Linux-OpenIB"
] | null | null | null | src/xray/render/base/sources/render_base_world.cpp | acidicMercury8/ixray-2.0 | 85c3a544175842323fc82f42efd96c66f0fc5abb | [
"Linux-OpenIB"
] | 1 | 2022-03-26T17:00:08.000Z | 2022-03-26T17:00:08.000Z | ////////////////////////////////////////////////////////////////////////////
// Created : 28.10.2008
// Author : Dmitriy Iassenev
// Copyright (C) GSC Game World - 2009
////////////////////////////////////////////////////////////////////////////
#include "pch.h"
#include <xray/render/base/world.h>
#include <... | 27.547009 | 161 | 0.635433 | ixray-team |
fbbbf35b837bfb822b1cd481242a9f156c485530 | 598 | cpp | C++ | Homeworks/2_ImageWarping/project/src/App/Warp.cpp | Adven-00/USTC_CG_2020 | 7f44197c42305309f2a74418367ace149de04ed8 | [
"MIT"
] | null | null | null | Homeworks/2_ImageWarping/project/src/App/Warp.cpp | Adven-00/USTC_CG_2020 | 7f44197c42305309f2a74418367ace149de04ed8 | [
"MIT"
] | null | null | null | Homeworks/2_ImageWarping/project/src/App/Warp.cpp | Adven-00/USTC_CG_2020 | 7f44197c42305309f2a74418367ace149de04ed8 | [
"MIT"
] | null | null | null | #include "Warp.h"
void Warp::Render(QImage* ptr_image)
{
QImage image_tmp(*(ptr_image));
int width = ptr_image->width();
int height = ptr_image->height();
ptr_image->fill(Qt::lightGray);
for (int i = 0; i < width; i++)
{
for (int j = 0; j < height; j++)
{
QPoint p(i, j);
QPoint po = Output(p);
i... | 18.6875 | 71 | 0.598662 | Adven-00 |
fbbdc5be30f812e4188e6b33e9232e7ca3fd854b | 4,026 | hpp | C++ | src/ltb/cuda/optix/optix.hpp | LoganBarnes/ltb-gvs | b1178e31c35aece434c7d47af955275fca9bb2a5 | [
"MIT"
] | 1 | 2020-04-04T16:57:25.000Z | 2020-04-04T16:57:25.000Z | src/ltb/cuda/optix/optix.hpp | LoganBarnes/ltb-gvs | b1178e31c35aece434c7d47af955275fca9bb2a5 | [
"MIT"
] | null | null | null | src/ltb/cuda/optix/optix.hpp | LoganBarnes/ltb-gvs | b1178e31c35aece434c7d47af955275fca9bb2a5 | [
"MIT"
] | null | null | null | // ///////////////////////////////////////////////////////////////////////////////////////
// LTB Geometry Visualization Server
// Copyright (c) 2020 Logan Barnes - All Rights Reserved
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation fil... | 43.290323 | 118 | 0.615748 | LoganBarnes |
fbc5e23262cc809ca33de49454463093564b0643 | 887 | cpp | C++ | leetcode/751. IP to CIDR/s1.cpp | zhuohuwu0603/leetcode_cpp_lzl124631x | 6a579328810ef4651de00fde0505934d3028d9c7 | [
"Fair"
] | 787 | 2017-05-12T05:19:57.000Z | 2022-03-30T12:19:52.000Z | leetcode/751. IP to CIDR/s1.cpp | aerlokesh494/LeetCode | 0f2cbb28d5a9825b51a8d3b3a0ae0c30d7ff155f | [
"Fair"
] | 8 | 2020-03-16T05:55:38.000Z | 2022-03-09T17:19:17.000Z | leetcode/751. IP to CIDR/s1.cpp | aerlokesh494/LeetCode | 0f2cbb28d5a9825b51a8d3b3a0ae0c30d7ff155f | [
"Fair"
] | 247 | 2017-04-30T15:07:50.000Z | 2022-03-30T09:58:57.000Z | // OJ: https://leetcode.com/problems/ip-to-cidr/
// Author: github.com/lzl124631x
// Time: O()
// Space: O()
class Solution {
private:
unsigned ipToUnsigned(string &ip) {
unsigned ans = 0, val = 0;
for (int i = 0; i < ip.size(); ++i) {
if (ip[i] == '.') {
ans = (ans + val... | 27.71875 | 60 | 0.441939 | zhuohuwu0603 |
fbca1b8a435dd64592063b4f4f8f9625914a75d3 | 748 | cc | C++ | src/libcxx_support.cc | S-YOU/liumos | 5f2335ca293596d645110fe0ab3b09a9246c8366 | [
"MIT"
] | null | null | null | src/libcxx_support.cc | S-YOU/liumos | 5f2335ca293596d645110fe0ab3b09a9246c8366 | [
"MIT"
] | null | null | null | src/libcxx_support.cc | S-YOU/liumos | 5f2335ca293596d645110fe0ab3b09a9246c8366 | [
"MIT"
] | null | null | null | #include "generic.h"
void* operator new(unsigned long, std::align_val_t) {
Panic("void * operator new(unsigned long, std::align_val_t)");
}
void operator delete(void*, std::align_val_t) {
Panic("void operator delete(void*, std::align_val_t)");
}
extern "C" void __cxa_throw() {
Panic("libcxx_support");
}
exter... | 20.777778 | 64 | 0.73262 | S-YOU |
fbcb29fa179ee6d75ccf58657d732a8f18e30748 | 4,592 | cpp | C++ | StructuredProgramming/lab_s02e02/lab_s02e02_main.cpp | Michal-Fularz/ProgrammingCourse | bee3fb5be39902b08a917bb66a891329cf09f70f | [
"MIT"
] | 1 | 2020-05-16T14:10:08.000Z | 2020-05-16T14:10:08.000Z | StructuredProgramming/lab_s02e02/lab_s02e02_main.cpp | Michal-Fularz/ProgrammingCourse | bee3fb5be39902b08a917bb66a891329cf09f70f | [
"MIT"
] | null | null | null | StructuredProgramming/lab_s02e02/lab_s02e02_main.cpp | Michal-Fularz/ProgrammingCourse | bee3fb5be39902b08a917bb66a891329cf09f70f | [
"MIT"
] | null | null | null | #include <fstream>
#include <iostream>
#include <string>
#include <sstream>
#include <vector>
#include "lab_s02e02_MF.h"
void ex_1()
{
std::cout << "Exercise 1" << std::endl;
std::string word = "racecar";
do
{
std::cout << "Enter a word to check if it is a palindrome or type exit to break th... | 28.880503 | 218 | 0.558798 | Michal-Fularz |
fbcdf5842c719c66ba56015813978b2c7befec29 | 1,747 | cpp | C++ | Cpp/164_maximum_gap/solution.cpp | zszyellow/leetcode | 2ef6be04c3008068f8116bf28d70586e613a48c2 | [
"MIT"
] | 1 | 2015-12-19T23:05:35.000Z | 2015-12-19T23:05:35.000Z | Cpp/164_maximum_gap/solution.cpp | zszyellow/leetcode | 2ef6be04c3008068f8116bf28d70586e613a48c2 | [
"MIT"
] | null | null | null | Cpp/164_maximum_gap/solution.cpp | zszyellow/leetcode | 2ef6be04c3008068f8116bf28d70586e613a48c2 | [
"MIT"
] | null | null | null | class Solution
{
public:
// bucket sort
int maximumGap(vector<int>& nums)
{
// min and max element
int minE;
int maxE;
// bucket sort variables
int bucket_size;
int bucket_num;
int bucket_id;
int last_max;
// other variables needed
... | 30.649123 | 81 | 0.439611 | zszyellow |
fbd12afad82e861d4a5b6533e6967db93471353e | 213 | hpp | C++ | oauth/include/oauth/oauth.hpp | zina1995/Twitter-API-C-Library | 87b29c63b89be6feb05adbe05ebed0213aa67f9b | [
"MIT"
] | null | null | null | oauth/include/oauth/oauth.hpp | zina1995/Twitter-API-C-Library | 87b29c63b89be6feb05adbe05ebed0213aa67f9b | [
"MIT"
] | null | null | null | oauth/include/oauth/oauth.hpp | zina1995/Twitter-API-C-Library | 87b29c63b89be6feb05adbe05ebed0213aa67f9b | [
"MIT"
] | null | null | null | #ifndef OAUTH_OAUTH_HPP
#define OAUTH_OAUTH_HPP
#include <oauth/authorize.hpp>
#include <oauth/bearer_token.hpp>
#include <oauth/credentials.hpp>
#include <oauth/read_credentials.hpp>
#endif // OAUTH_OAUTH_HPP
| 21.3 | 37 | 0.798122 | zina1995 |
fbd14e9e9cf0e459d9eb82d6a737d41614a3cc4b | 2,532 | cc | C++ | gcc-gcc-7_3_0-release/libstdc++-v3/testsuite/20_util/is_null_pointer/value.cc | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/libstdc++-v3/testsuite/20_util/is_null_pointer/value.cc | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/libstdc++-v3/testsuite/20_util/is_null_pointer/value.cc | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | // { dg-do compile { target c++11 } }
// 2013-05-02 Paolo Carlini <pcarlini@suse.de>
//
// Copyright (C) 2013-2017 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
// terms of the GNU General Publi... | 45.214286 | 79 | 0.729068 | best08618 |
fbd3c61d5797b7141d70a043ec66039fc62e4b5b | 2,877 | cpp | C++ | base/std/thread.cpp | fengzi01/yamq | f11a0e28b0100b4155c124bb96488046353ec059 | [
"MIT"
] | null | null | null | base/std/thread.cpp | fengzi01/yamq | f11a0e28b0100b4155c124bb96488046353ec059 | [
"MIT"
] | null | null | null | base/std/thread.cpp | fengzi01/yamq | f11a0e28b0100b4155c124bb96488046353ec059 | [
"MIT"
] | null | null | null | #include "base/std/thread.h"
#include <utility> // std::forword
#include <memory>
#include <stdlib.h>
#include <sys/syscall.h>
#include <stdio.h>
namespace std2 {
/* thread data 封装 */
struct Thread::ThreadData {
ThreadFunc _func;
pid_t *_tid;
ThreadData (const ThreadFunc& func,pid_t *tid)
:_func(f... | 22.833333 | 94 | 0.582204 | fengzi01 |
fbd5c8c2a5c54eff5b94ee5091fceb5f2eea1b31 | 762 | cpp | C++ | sample.cpp | as-xjc/LruCache | 060e6f391d42b20926fda7dda354ef66f8037f83 | [
"MIT"
] | null | null | null | sample.cpp | as-xjc/LruCache | 060e6f391d42b20926fda7dda354ef66f8037f83 | [
"MIT"
] | null | null | null | sample.cpp | as-xjc/LruCache | 060e6f391d42b20926fda7dda354ef66f8037f83 | [
"MIT"
] | null | null | null | #include <cstdio>
#include <cstdlib>
#include "lru.hpp"
int main() {
Lru<int, int> lru(5);
for (int i = 1; i <= 10; ++i) {
lru.Push(i, i);
}
auto print = [](int& value) { printf("%d,", value); };
printf("origin: cap %lu, size %lu: ", lru.GetCapacity(), lru.GetSize());
lru.ForEach(print);
for (int i... | 23.090909 | 74 | 0.532808 | as-xjc |
fbd69488570ed328b41585c3eb31d537a7401658 | 383 | hpp | C++ | pythran/pythonic/include/__builtin__/pythran/len_set.hpp | artas360/pythran | 66dad52d52be71693043e9a7d7578cfb9cb3d1da | [
"BSD-3-Clause"
] | null | null | null | pythran/pythonic/include/__builtin__/pythran/len_set.hpp | artas360/pythran | 66dad52d52be71693043e9a7d7578cfb9cb3d1da | [
"BSD-3-Clause"
] | null | null | null | pythran/pythonic/include/__builtin__/pythran/len_set.hpp | artas360/pythran | 66dad52d52be71693043e9a7d7578cfb9cb3d1da | [
"BSD-3-Clause"
] | null | null | null | #ifndef PYTHONIC_INCLUDE_BUILTIN_PYTHRAN_LEN_SET_HPP
#define PYTHONIC_INCLUDE_BUILTIN_PYTHRAN_LEN_SET_HPP
#include "pythonic/include/utils/proxy.hpp"
namespace pythonic
{
namespace __builtin__
{
namespace pythran
{
template <class Iterable>
long len_set(Iterable const &s);
PROXY_DECL... | 15.958333 | 58 | 0.736292 | artas360 |
fbdbf5bad0fec1cdb839700736e273fc05730cd8 | 10,979 | cpp | C++ | AquaEngine/Components/ModelManager.cpp | tiagovcosta/aquaengine | aea6de9f47ba0243b90c144dee4422efb2389cc7 | [
"MIT"
] | 55 | 2015-05-29T20:19:28.000Z | 2022-01-18T21:23:15.000Z | AquaEngine/Components/ModelManager.cpp | tiagovcosta/aquaengine | aea6de9f47ba0243b90c144dee4422efb2389cc7 | [
"MIT"
] | null | null | null | AquaEngine/Components/ModelManager.cpp | tiagovcosta/aquaengine | aea6de9f47ba0243b90c144dee4422efb2389cc7 | [
"MIT"
] | 6 | 2015-09-02T09:51:38.000Z | 2020-08-16T07:54:34.000Z | #include "ModelManager.h"
#include "..\Components\TransformManager.h"
#include "..\Renderer\Camera.h"
#include "..\Renderer\RendererUtilities.h"
#include "..\Renderer\Renderer.h"
#include "..\Core\Allocators\ScopeStack.h"
#include "..\Core\Allocators\SmallBlockAllocator.h"
//#include "..\Utilities\Allocators\LinearA... | 28.968338 | 135 | 0.729301 | tiagovcosta |
fbde4b42b850a97fcc3330f4fc27c795acf2aa93 | 2,881 | hpp | C++ | third_party/boost/simd/arch/x86/avx/simd/function/rec.hpp | SylvainCorlay/pythran | 908ec070d837baf77d828d01c3e35e2f4bfa2bfa | [
"BSD-3-Clause"
] | 6 | 2018-02-25T22:23:33.000Z | 2021-01-15T15:13:12.000Z | third_party/boost/simd/arch/x86/avx/simd/function/rec.hpp | SylvainCorlay/pythran | 908ec070d837baf77d828d01c3e35e2f4bfa2bfa | [
"BSD-3-Clause"
] | null | null | null | third_party/boost/simd/arch/x86/avx/simd/function/rec.hpp | SylvainCorlay/pythran | 908ec070d837baf77d828d01c3e35e2f4bfa2bfa | [
"BSD-3-Clause"
] | 7 | 2017-12-12T12:36:31.000Z | 2020-02-10T14:27:07.000Z | //==================================================================================================
/**
Copyright 2016 NumScale SAS
Distributed under the Boost Software License, Version 1.0.
(See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)
**/
//====================================... | 34.297619 | 100 | 0.562652 | SylvainCorlay |
fbe2d03f32ff439f7b4b88004f4ea2f1aaa1335b | 2,085 | cpp | C++ | test/unit/test_level.cpp | dyle71/hcs-logger | aa3061d160b8bf84e2e4de05c5b29f09a8428bde | [
"MIT"
] | null | null | null | test/unit/test_level.cpp | dyle71/hcs-logger | aa3061d160b8bf84e2e4de05c5b29f09a8428bde | [
"MIT"
] | null | null | null | test/unit/test_level.cpp | dyle71/hcs-logger | aa3061d160b8bf84e2e4de05c5b29f09a8428bde | [
"MIT"
] | null | null | null | /*
* This file is part of the headcode.space logger.
*
* The 'LICENSE.txt' file in the project root holds the software license.
* Copyright (C) 2021 headcode.space e.U.
* Oliver Maurhart <info@headcode.space>, https://www.headcode.space
*/
#include <headcode/logger/logger.hpp>
#include <gtest/gtest.h>
TEST(Le... | 48.488372 | 119 | 0.705516 | dyle71 |
fbe2d2d712649b5a33f1ddc532c7febaa724b36a | 332 | cc | C++ | below2.1/bus.cc | danzel-py/Kattis-Problem-Archive | bce1929d654b1bceb104f96d68c74349273dd1ff | [
"Apache-2.0"
] | null | null | null | below2.1/bus.cc | danzel-py/Kattis-Problem-Archive | bce1929d654b1bceb104f96d68c74349273dd1ff | [
"Apache-2.0"
] | null | null | null | below2.1/bus.cc | danzel-py/Kattis-Problem-Archive | bce1929d654b1bceb104f96d68c74349273dd1ff | [
"Apache-2.0"
] | null | null | null | #include <iostream>
using namespace std;
int main(){
int t;
double x;
cin>>t;
for (int i = 0; i < t; i++)
{
cin>>x;
double sum=0;
for (int j = 0; j < x; j++)
{
sum+= 0.5;
sum*= 2;
}
cout<<int(sum)<<'\n';
}
... | 15.090909 | 35 | 0.35241 | danzel-py |
fbe46e636088ccb38a82290baaadbb4a4b727f6e | 1,809 | hpp | C++ | src/common/utilities/image/rasterbithandles.hpp | squeevee/Addle | 20ec4335669fbd88d36742f586899d8416920959 | [
"MIT"
] | 3 | 2020-03-05T06:36:51.000Z | 2020-06-20T03:25:02.000Z | src/common/utilities/image/rasterbithandles.hpp | squeevee/Addle | 20ec4335669fbd88d36742f586899d8416920959 | [
"MIT"
] | 13 | 2020-03-11T17:43:42.000Z | 2020-12-11T03:36:05.000Z | src/common/utilities/image/rasterbithandles.hpp | squeevee/Addle | 20ec4335669fbd88d36742f586899d8416920959 | [
"MIT"
] | 1 | 2020-09-28T06:53:46.000Z | 2020-09-28T06:53:46.000Z | /**
* Addle source code
* @file
* @copyright Copyright 2020 Eleanor Hawk
* @copyright Modification and distribution permitted under the terms of the
* MIT License. See "LICENSE" for full details.
*/
#ifndef RASTERBITHANDLES_HPP
#define RASTERBITHANDLES_HPP
#include "compat.hpp"
#include <QRect>
#include <QImage... | 22.333333 | 94 | 0.708126 | squeevee |
fbf9442d4e5e1a52d04e6cba433bd136c7e563f3 | 1,328 | cpp | C++ | main.cpp | SmartphoneBrainScanner/smartphonebrainscanner2-Brain3D | 57431b490f4bf780c23e22426233bde3f26e7726 | [
"MIT"
] | 3 | 2016-03-07T12:44:15.000Z | 2016-06-05T23:41:43.000Z | main.cpp | SmartphoneBrainScanner/smartphonebrainscanner2-Brain3D | 57431b490f4bf780c23e22426233bde3f26e7726 | [
"MIT"
] | 3 | 2015-07-24T10:12:02.000Z | 2015-07-24T11:57:06.000Z | main.cpp | SmartphoneBrainScanner/smartphonebrainscanner2-Brain3D | 57431b490f4bf780c23e22426233bde3f26e7726 | [
"MIT"
] | 6 | 2015-07-17T07:52:52.000Z | 2018-07-22T20:16:04.000Z | #include <QApplication>
#include <mycallback.h>
#include <mainwindow.h>
#include <hardware/emocap/sbs2emocapdatareader.h>
#include <hardware/filereader/sbs2filedatareader.h>
#include <hardware/emotiv/sbs2emotivdatareader.h>
Q_DECL_EXPORT int main(int argc, char *argv[])
{
QApplication app(argc, argv);
qDebu... | 28.255319 | 120 | 0.72741 | SmartphoneBrainScanner |
22005d65aad9399764fa2788689486e8352122d9 | 41 | cpp | C++ | RECURSION/tempCodeRunnerFile.cpp | lakshya7878/DSA_practice_self_paced | 54e70a1cef20578e30d02d7fd8cd405b7d26baad | [
"MIT"
] | 1 | 2021-10-02T10:47:56.000Z | 2021-10-02T10:47:56.000Z | RECURSION/tempCodeRunnerFile.cpp | lakshya7878/DSA_practice_self_paced | 54e70a1cef20578e30d02d7fd8cd405b7d26baad | [
"MIT"
] | 1 | 2021-10-07T03:39:34.000Z | 2021-10-07T03:39:34.000Z | RECURSION/tempCodeRunnerFile.cpp | lakshya7878/DSA_practice_self_paced | 54e70a1cef20578e30d02d7fd8cd405b7d26baad | [
"MIT"
] | null | null | null | if(sum==0){
// return 1;
// } | 13.666667 | 20 | 0.317073 | lakshya7878 |
220f841003ca4be1a48f8390a49cb0dcc6052a5d | 55,471 | cpp | C++ | export/release/macos/obj/src/DialogueBox.cpp | Tyrcnex/tai-mod | b83152693bb3139ee2ae73002623934f07d35baf | [
"Apache-2.0"
] | 1 | 2021-07-19T05:10:43.000Z | 2021-07-19T05:10:43.000Z | export/release/macos/obj/src/DialogueBox.cpp | Tyrcnex/tai-mod | b83152693bb3139ee2ae73002623934f07d35baf | [
"Apache-2.0"
] | null | null | null | export/release/macos/obj/src/DialogueBox.cpp | Tyrcnex/tai-mod | b83152693bb3139ee2ae73002623934f07d35baf | [
"Apache-2.0"
] | null | null | null | // Generated by Haxe 4.1.5
#include <hxcpp.h>
#ifndef INCLUDED_Alphabet
#include <Alphabet.h>
#endif
#ifndef INCLUDED_DialogueBox
#include <DialogueBox.h>
#endif
#ifndef INCLUDED_MusicBeatState
#include <MusicBeatState.h>
#endif
#ifndef INCLUDED_Paths
#include <Paths.h>
#endif
#ifndef INCLUDED_PlayState
#include <Play... | 56.258621 | 274 | 0.68699 | Tyrcnex |
22114ee85d794fec97929347707fe3d2d5529b40 | 1,389 | cc | C++ | gcc-gcc-7_3_0-release/libstdc++-v3/testsuite/23_containers/set/cons/61023.cc | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | gcc-gcc-7_3_0-release/libstdc++-v3/testsuite/23_containers/set/cons/61023.cc | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | null | null | null | gcc-gcc-7_3_0-release/libstdc++-v3/testsuite/23_containers/set/cons/61023.cc | best08618/asylo | 5a520a9f5c461ede0f32acc284017b737a43898c | [
"Apache-2.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | // { dg-do run { target c++11 } }
// Copyright (C) 2014-2017 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
// terms of the GNU General Public License as published by the
// Free Software Foundatio... | 24.368421 | 74 | 0.677466 | best08618 |
81faf10543b62f782b6cca1d4980a4a134190613 | 1,018 | cpp | C++ | Data Structures/Dynamic Programming/1-D DP/Frog Jump/Memoization.cpp | ravikjha7/Competitive_Programming | 86df773c258d6675bb3244030e6d71aa32e01fce | [
"MIT"
] | null | null | null | Data Structures/Dynamic Programming/1-D DP/Frog Jump/Memoization.cpp | ravikjha7/Competitive_Programming | 86df773c258d6675bb3244030e6d71aa32e01fce | [
"MIT"
] | null | null | null | Data Structures/Dynamic Programming/1-D DP/Frog Jump/Memoization.cpp | ravikjha7/Competitive_Programming | 86df773c258d6675bb3244030e6d71aa32e01fce | [
"MIT"
] | null | null | null | #include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
#define mod 1000000007
void file()
{
#ifndef ONLINE_JUDGE
freopen("input.txt", "r", stdin);
freopen("output.txt", "w", stdout);
#endif
}
int frogjump(int n, int k, vector<int> &heights, vector<int> &dp)
{
if(n == 0) return 0;
if(... | 17.551724 | 82 | 0.562868 | ravikjha7 |
c304cfdc7ccd40df10f2cced98e36ea067e9e79b | 852 | hpp | C++ | libs/renderer/include/sge/renderer/index/dynamic/format_element.hpp | cpreh/spacegameengine | 313a1c34160b42a5135f8223ffaa3a31bc075a01 | [
"BSL-1.0"
] | 2 | 2016-01-27T13:18:14.000Z | 2018-05-11T01:11:32.000Z | libs/renderer/include/sge/renderer/index/dynamic/format_element.hpp | cpreh/spacegameengine | 313a1c34160b42a5135f8223ffaa3a31bc075a01 | [
"BSL-1.0"
] | null | null | null | libs/renderer/include/sge/renderer/index/dynamic/format_element.hpp | cpreh/spacegameengine | 313a1c34160b42a5135f8223ffaa3a31bc075a01 | [
"BSL-1.0"
] | 3 | 2018-05-11T01:11:34.000Z | 2021-04-24T19:47:45.000Z | // Copyright Carl Philipp Reh 2006 - 2019.
// Distributed under the Boost Software License, Version 1.0.
// (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef SGE_RENDERER_INDEX_DYNAMIC_FORMAT_ELEMENT_HPP_INCLUDED
#define SGE_RENDERER_INDEX_DYNAMIC_F... | 25.058824 | 65 | 0.746479 | cpreh |
c308388811a103318eb43ff5b22c43d248659246 | 4,012 | cpp | C++ | base/Windows/singx86/apic.cpp | sphinxlogic/Singularity-RDK-2.0 | 2968c3b920a5383f7360e3e489aa772f964a7c42 | [
"MIT"
] | null | null | null | base/Windows/singx86/apic.cpp | sphinxlogic/Singularity-RDK-2.0 | 2968c3b920a5383f7360e3e489aa772f964a7c42 | [
"MIT"
] | null | null | null | base/Windows/singx86/apic.cpp | sphinxlogic/Singularity-RDK-2.0 | 2968c3b920a5383f7360e3e489aa772f964a7c42 | [
"MIT"
] | null | null | null | /////////////////////////////////////////////////////////////////////////////
//
// apic.cpp - Extension to inspect APIC
//
// Copyright Microsoft Corporation. All rights reserved.
//
#include "singx86.h"
inline static ULONG ApicRead32(const BYTE* apic, int offsetInBytes)
{
return ((ULONG*) apic)[of... | 28.863309 | 78 | 0.554586 | sphinxlogic |
c3109d2cb6642ea88fafccfa18b824bbb55e58f5 | 4,500 | hpp | C++ | Crisp/GUI/Control.hpp | FallenShard/Crisp | d4cf22c0f9af73a6c4ba2b7d67696f1a188fd423 | [
"MIT"
] | 6 | 2017-09-14T03:26:49.000Z | 2021-09-18T05:40:59.000Z | Crisp/GUI/Control.hpp | FallenShard/Crisp | d4cf22c0f9af73a6c4ba2b7d67696f1a188fd423 | [
"MIT"
] | null | null | null | Crisp/GUI/Control.hpp | FallenShard/Crisp | d4cf22c0f9af73a6c4ba2b7d67696f1a188fd423 | [
"MIT"
] | null | null | null | #pragma once
#include <string>
#include <memory>
#include <CrispCore/Math/Headers.hpp>
#include <CrispCore/Math/Rect.hpp>
#include "RenderSystem.hpp"
#include "GUI/GuiEnums.hpp"
namespace crisp::gui
{
class Form;
class Control
{
public:
Control(Form* form);
virtual ~Control();
... | 31.690141 | 132 | 0.651333 | FallenShard |
c31230820a30e801ae483f1e2440451e186e0360 | 7,551 | cpp | C++ | TomGine/tgCollission.cpp | OpenNurbsFit/OpenNurbsFit | d1ca01437a6da6bbf921466013ff969def5dfe65 | [
"BSD-3-Clause"
] | 14 | 2015-07-06T13:04:49.000Z | 2022-02-06T10:09:05.000Z | TomGine/tgCollission.cpp | OpenNurbsFit/OpenNurbsFit | d1ca01437a6da6bbf921466013ff969def5dfe65 | [
"BSD-3-Clause"
] | 1 | 2020-12-07T03:26:39.000Z | 2020-12-07T03:26:39.000Z | TomGine/tgCollission.cpp | OpenNurbsFit/OpenNurbsFit | d1ca01437a6da6bbf921466013ff969def5dfe65 | [
"BSD-3-Clause"
] | 11 | 2015-07-06T13:04:43.000Z | 2022-03-29T10:57:04.000Z | /*
* Software License Agreement (GNU General Public License)
*
* Copyright (c) 2011, Thomas Mörwald
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, ... | 27.259928 | 118 | 0.628526 | OpenNurbsFit |
c3125e3006efc875a61ec2265e434dfa25a5fb11 | 172 | hpp | C++ | assistant/communication.hpp | mddigaetano/AccessibleHomeAutomation | 1798402e6a8a7826a0e368d58bf171e756320c4b | [
"MIT"
] | null | null | null | assistant/communication.hpp | mddigaetano/AccessibleHomeAutomation | 1798402e6a8a7826a0e368d58bf171e756320c4b | [
"MIT"
] | null | null | null | assistant/communication.hpp | mddigaetano/AccessibleHomeAutomation | 1798402e6a8a7826a0e368d58bf171e756320c4b | [
"MIT"
] | null | null | null | const byte BUFFER_SIZE = 128;
char buffer[BUFFER_SIZE];
char START_CHAR= '<';
char END_CHAR = '>';
bool newData = false;
void full_receive();
const char * full_read();
| 15.636364 | 29 | 0.697674 | mddigaetano |
c31c3ea656b0b93b60dfde8a202169b96958ee6d | 2,076 | cpp | C++ | abserv/abserv/actions/AiGoHome.cpp | pablokawan/ABx | 064d6df265c48c667ce81b0a83f84e5e22a7ff53 | [
"MIT"
] | null | null | null | abserv/abserv/actions/AiGoHome.cpp | pablokawan/ABx | 064d6df265c48c667ce81b0a83f84e5e22a7ff53 | [
"MIT"
] | null | null | null | abserv/abserv/actions/AiGoHome.cpp | pablokawan/ABx | 064d6df265c48c667ce81b0a83f84e5e22a7ff53 | [
"MIT"
] | null | null | null | /**
* Copyright 2017-2020 Stefan Ascher
*
* 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, pub... | 31.938462 | 91 | 0.699422 | pablokawan |
c31da2cb72cad0727c99ce0dba079413bdcee7c5 | 372 | hpp | C++ | meld/core/uses_config.hpp | knoepfel/sand-art | 8b4d7eccc5f2d3b926c94c3cf98be6e6d25bb9eb | [
"Apache-2.0"
] | null | null | null | meld/core/uses_config.hpp | knoepfel/sand-art | 8b4d7eccc5f2d3b926c94c3cf98be6e6d25bb9eb | [
"Apache-2.0"
] | null | null | null | meld/core/uses_config.hpp | knoepfel/sand-art | 8b4d7eccc5f2d3b926c94c3cf98be6e6d25bb9eb | [
"Apache-2.0"
] | null | null | null | #ifndef meld_core_uses_config_hpp
#define meld_core_uses_config_hpp
#include "boost/json.hpp"
#include <type_traits>
namespace meld {
template <typename Module>
concept with_config = std::is_constructible<Module, boost::json::object const&>();
template <typename Module>
concept without_config = !with_config... | 21.882353 | 84 | 0.771505 | knoepfel |
c31db249b93141973b4d3260d408ccc0caf31712 | 1,429 | cpp | C++ | USACO/training/chapter-1/barn1.cpp | eugli/competitive-programming | 908b903da7f12333ecc4dd0491da3fad35d1db97 | [
"MIT"
] | null | null | null | USACO/training/chapter-1/barn1.cpp | eugli/competitive-programming | 908b903da7f12333ecc4dd0491da3fad35d1db97 | [
"MIT"
] | null | null | null | USACO/training/chapter-1/barn1.cpp | eugli/competitive-programming | 908b903da7f12333ecc4dd0491da3fad35d1db97 | [
"MIT"
] | null | null | null | /*
ID: lieugen1
TASK: barn1
LANG: C++
*/
#include <bits/stdc++.h>
using namespace std;
int m, s, c, p;
int occ[200];
void make_board() {
int gap = 0, mgap = 0, sgap = 0, egap = 0;
for (int i = 0; i < s; i++) {
if (!occ[i]) {
gap++;
} else {
if (gap > mgap) {
... | 15.532609 | 48 | 0.313506 | eugli |
c324f75dc0d2f75a6024ca6f86abc7eddd471263 | 884 | cpp | C++ | Leetcode/reverse-vowels-of-a-string.cpp | omonimus1/angorithm_AND_dataStructure | 2a6a0cda29cb618a787654b5c66ed6f43fe618e2 | [
"Apache-2.0"
] | 580 | 2020-04-08T16:47:36.000Z | 2022-03-31T15:09:13.000Z | Leetcode/reverse-vowels-of-a-string.cpp | omonimus1/angorithm_AND_dataStructure | 2a6a0cda29cb618a787654b5c66ed6f43fe618e2 | [
"Apache-2.0"
] | 3 | 2020-10-01T08:46:42.000Z | 2020-11-23T17:12:35.000Z | Leetcode/reverse-vowels-of-a-string.cpp | omonimus1/angorithm_AND_dataStructure | 2a6a0cda29cb618a787654b5c66ed6f43fe618e2 | [
"Apache-2.0"
] | 87 | 2020-06-07T16:30:08.000Z | 2022-03-29T19:30:47.000Z | // https://leetcode.com/problems/reverse-vowels-of-a-string/submissions/
class Solution {
public:
char vowel_list[10] = {'a', 'e', 'i', 'o', 'u', 'A', 'E', 'I', 'O', 'U' };
bool is_vowel(char letter)
{
for(int i =0; i < 10; i++)
{
if(letter == vowel_list[i])
... | 22.1 | 78 | 0.357466 | omonimus1 |
c32c6d629a4f6a4d30d81acbb59f683fd1c8c44a | 7,467 | cc | C++ | value/parser.cc | eaugeas/crossroads | 9dc1ea074a9bf59e4b6aa61ce75f93ee953ee05d | [
"MIT"
] | null | null | null | value/parser.cc | eaugeas/crossroads | 9dc1ea074a9bf59e4b6aa61ce75f93ee953ee05d | [
"MIT"
] | null | null | null | value/parser.cc | eaugeas/crossroads | 9dc1ea074a9bf59e4b6aa61ce75f93ee953ee05d | [
"MIT"
] | null | null | null | // Copyright (c) 2019, tlblanc <tlblanc1490 at gmail dot com>
#include "parser.hpp"
#include <errno.h>
#include <string.h>
#include <algorithm>
#include "string_utils.hpp"
static inline size_t _min_pos_len(size_t len1, size_t len2) {
return len1 == 0 ? len2 : len2 == 0 ? len1 : std::min(len1, len2);
}
const cha... | 24.807309 | 72 | 0.559127 | eaugeas |
c32e7a4e04324000c9a031ba3bcde1d4fbc7ab54 | 435 | cpp | C++ | gcd,lcm/9613.cpp | SiverPineValley/algo | 29c75c6b226fdb15a3b6695e763ee49d4871094e | [
"Apache-2.0"
] | null | null | null | gcd,lcm/9613.cpp | SiverPineValley/algo | 29c75c6b226fdb15a3b6695e763ee49d4871094e | [
"Apache-2.0"
] | null | null | null | gcd,lcm/9613.cpp | SiverPineValley/algo | 29c75c6b226fdb15a3b6695e763ee49d4871094e | [
"Apache-2.0"
] | null | null | null | #include <iostream>
using namespace std;
int gcd(int a, int b)
{
int r;
while( b != 0 )
{
r = a%b;
a = b;
b = r;
}
return a;
}
int main(void)
{
int n, s;
long long g = 0;
cin >> n;
for(int i = 0; i < n; i++)
{
cin >> s;
int r[s];
for(int j = 0; j < s; j++) cin >> r[j];
for(int j = 0; j < s-... | 12.083333 | 52 | 0.422989 | SiverPineValley |
c332fee3b43d02194dd596b3f9bb20a596982fe5 | 851 | hpp | C++ | OOP/function.hpp | shaneliu-zf/CodeBook | 0c30e46f5661051d523c621eac9740d6dcbab440 | [
"MIT"
] | 3 | 2020-12-15T12:34:29.000Z | 2020-12-15T21:21:33.000Z | OOP/function.hpp | shane-liu-1010/CodeBook | 0c30e46f5661051d523c621eac9740d6dcbab440 | [
"MIT"
] | null | null | null | OOP/function.hpp | shane-liu-1010/CodeBook | 0c30e46f5661051d523c621eac9740d6dcbab440 | [
"MIT"
] | null | null | null | #include<vector>
class func:std::vector<double>{
public:
func(int n=0){resize(n);}
func(std::vector<double>a){
resize(a.size());
for(int i=0;i<a.size();i++)at(i)=a[i];
}
void print(){
bool first=true;
for(int i=size()-1;i>=0;i--){
if(at(i)){
st... | 23 | 57 | 0.391304 | shaneliu-zf |
c3338047969da3290a6566f5ed93da22e1495e77 | 7,440 | cpp | C++ | tests/utils/test_sinc.cpp | ipc-sim/rigid-ipc | d839af457236e7363b14c2e482a01d8160fa447e | [
"MIT"
] | 71 | 2021-09-08T13:16:43.000Z | 2022-03-27T10:23:33.000Z | tests/utils/test_sinc.cpp | ipc-sim/rigid-ipc | d839af457236e7363b14c2e482a01d8160fa447e | [
"MIT"
] | 4 | 2021-09-08T00:16:20.000Z | 2022-01-05T17:44:08.000Z | tests/utils/test_sinc.cpp | ipc-sim/rigid-ipc | d839af457236e7363b14c2e482a01d8160fa447e | [
"MIT"
] | 2 | 2021-09-18T15:15:38.000Z | 2021-09-21T15:15:38.000Z | #include <catch2/catch.hpp>
#include <iostream>
#include <finitediff.hpp>
#include <igl/PI.h>
#include <autodiff/autodiff_types.hpp>
#include <utils/sinc.hpp>
using namespace ipc;
using namespace ipc::rigid;
TEST_CASE("double sinc", "[sinc][double]")
{
CHECK(sinc(0) == Approx(1));
CHECK(sinc(1e-8) == Appro... | 28.949416 | 80 | 0.570565 | ipc-sim |
c33700a0fdb6262ac15974b8c76579924ea374bb | 625 | cpp | C++ | Sorting_Searching/Sort_0_1_2.cpp | Twinkle0799/Competitive_Programming_Rocks | fb71021e02019004bef59ee1df86687234e36f5a | [
"MIT"
] | 2 | 2021-05-06T17:59:44.000Z | 2021-08-04T12:50:38.000Z | Sorting_Searching/Sort_0_1_2.cpp | Twinkle0799/Competitive_Programming_Rocks | fb71021e02019004bef59ee1df86687234e36f5a | [
"MIT"
] | 1 | 2022-01-14T19:58:34.000Z | 2022-01-14T19:58:34.000Z | Sorting_Searching/Sort_0_1_2.cpp | Twinkle0799/Competitive_Programming_Rocks | fb71021e02019004bef59ee1df86687234e36f5a | [
"MIT"
] | 1 | 2021-02-17T09:48:06.000Z | 2021-02-17T09:48:06.000Z | #include<bits/stdc++.h>
using namespace std;
void sort012(int a[], int n)
{
int low=0;
int high = n-1;
int mid=0;
while(mid<=high)
{
switch(a[mid])
{
case 0:
swap(a[low++],a[mid++]);
break;
case 1:
mid++;... | 16.891892 | 40 | 0.3584 | Twinkle0799 |
c33c2f6fc17328e9cac8270e64e4fd60951f82fc | 9,437 | cpp | C++ | uvccapturecontrols.cpp | erikmwerner/QUVCView | b3c659727a0afbfd2e95239cd8edfb9302011ae8 | [
"BSD-3-Clause"
] | 10 | 2020-02-24T05:37:10.000Z | 2021-10-02T13:42:08.000Z | uvccapturecontrols.cpp | erikmwerner/QUVCView | b3c659727a0afbfd2e95239cd8edfb9302011ae8 | [
"BSD-3-Clause"
] | 2 | 2020-07-28T07:37:11.000Z | 2021-06-25T07:15:04.000Z | uvccapturecontrols.cpp | erikmwerner/QUVCView | b3c659727a0afbfd2e95239cd8edfb9302011ae8 | [
"BSD-3-Clause"
] | 1 | 2020-12-02T12:17:18.000Z | 2020-12-02T12:17:18.000Z | #include "uvccapturecontrols.h"
#include "libuvc/libuvc.h"
#include <QDebug>
UVCCaptureControls::UVCCaptureControls(QObject* parent, uvc_device_handle_t **dev_handle) :
QObject(parent), m_devh(dev_handle)
{}
void UVCCaptureControls::getExposureMode()
{
if(*m_devh == nullptr) {return;}
uint8_t mode;
u... | 27.920118 | 101 | 0.651266 | erikmwerner |
c33ee2c4194a6a8e2ea83e874644bf5a6890cd06 | 226 | cpp | C++ | Game Engine 2D/UtilConstants.cpp | LaPeste/ComposeEngine | 8ae80ec7c49af896978d06371dee96a4d2315372 | [
"Apache-2.0"
] | 1 | 2017-03-13T11:19:40.000Z | 2017-03-13T11:19:40.000Z | Game Engine 2D/UtilConstants.cpp | LaPeste/ComposeEngine | 8ae80ec7c49af896978d06371dee96a4d2315372 | [
"Apache-2.0"
] | null | null | null | Game Engine 2D/UtilConstants.cpp | LaPeste/ComposeEngine | 8ae80ec7c49af896978d06371dee96a4d2315372 | [
"Apache-2.0"
] | null | null | null | //
// UtilConstants.cpp
// GameEngine2D
//
// Created by Andrea Catalini on 11/12/16.
// Copyright © 2016 Andrea Catalini. All rights reserved.
//
#include "UtilConstants.hpp"
const int UtilConstants::NO_COMPONENTS = 0;
| 18.833333 | 58 | 0.712389 | LaPeste |
c3487fd4faaeddb105a642f8f947a2acf2379a2e | 8,984 | cc | C++ | src/solv_smurf/fn_smurf_au/bdd2smurf_au.cc | nerdling/SBSAT | 6328c6aa105b75693d06bf0dae4a3b5ca220318b | [
"Unlicense"
] | 4 | 2015-03-08T07:56:29.000Z | 2017-10-12T04:19:27.000Z | src/solv_smurf/fn_smurf_au/bdd2smurf_au.cc | nerdling/SBSAT | 6328c6aa105b75693d06bf0dae4a3b5ca220318b | [
"Unlicense"
] | null | null | null | src/solv_smurf/fn_smurf_au/bdd2smurf_au.cc | nerdling/SBSAT | 6328c6aa105b75693d06bf0dae4a3b5ca220318b | [
"Unlicense"
] | null | null | null | /* =========FOR INTERNAL USE ONLY. NO DISTRIBUTION PLEASE ========== */
/*********************************************************************
Copyright 1999-2007, University of Cincinnati. All rights reserved.
By using this software the USER indicates that he or she has read,
understood and will comply with the f... | 43.61165 | 167 | 0.743099 | nerdling |
c34b3a25a9c836684578ca95676ad633f260ca7a | 472 | cpp | C++ | 0-1 Knapsack.cpp | abhis2007/Algorithms-1 | 7637209c5aa52c1afd8be1884d018673d26f5c1f | [
"MIT"
] | 26 | 2019-04-05T07:10:15.000Z | 2022-01-08T02:35:19.000Z | 0-1 Knapsack.cpp | abhis2007/Algorithms-1 | 7637209c5aa52c1afd8be1884d018673d26f5c1f | [
"MIT"
] | 2 | 2019-04-25T15:47:54.000Z | 2019-09-03T06:46:05.000Z | 0-1 Knapsack.cpp | abhis2007/Algorithms-1 | 7637209c5aa52c1afd8be1884d018673d26f5c1f | [
"MIT"
] | 8 | 2019-04-05T08:58:50.000Z | 2020-07-03T01:53:58.000Z |
int knapSack(int W,int wt[],int val[],int n){
int dp[n+1][W+1];
rep(i,0,n+1){
rep(j,0,W+1){
if(i==0||j==0) dp[i][j]=0;
else if(wt[i-1] <= j)dp[i][j]=max(val[i-1] + dp[i-1][j-wt[i-1]], dp[i-1][j]);
else dp[i][j] = dp[i-1][j];
}
}
return dp[n][W];
}
int main() {
IOS;
int val[] = {7,5,2,1,3,4};
... | 19.666667 | 81 | 0.459746 | abhis2007 |
c34c1e76dc8f695f198f6e58a19f7c7fbb87f247 | 26,175 | hpp | C++ | client/systems/common.hpp | Exonical/Vanguard_Wasteland.cup_chernarus_A3 | ee8f51807847f35c924bb8bf701e863387b603b8 | [
"MIT"
] | 1 | 2020-07-23T13:49:05.000Z | 2020-07-23T13:49:05.000Z | client/systems/common.hpp | Exonical/Vanguard_Wasteland.cup_chernarus_A3 | ee8f51807847f35c924bb8bf701e863387b603b8 | [
"MIT"
] | null | null | null | client/systems/common.hpp | Exonical/Vanguard_Wasteland.cup_chernarus_A3 | ee8f51807847f35c924bb8bf701e863387b603b8 | [
"MIT"
] | null | null | null | // ******************************************************************************************
// * This project is licensed under the GNU Affero GPL v3. Copyright © 2014 A3Wasteland.com *
// ******************************************************************************************
/*
@file Version: 1.0
@file Name: co... | 26.332998 | 239 | 0.617268 | Exonical |
c34c2beb47f32080e1c940759c5df6a68730d894 | 8,036 | cc | C++ | cl-platform-probe.cc | terminatorul/cl-tool | 2202066a89a97982a49b64cb54e8cb36322ae1b1 | [
"Unlicense"
] | null | null | null | cl-platform-probe.cc | terminatorul/cl-tool | 2202066a89a97982a49b64cb54e8cb36322ae1b1 | [
"Unlicense"
] | null | null | null | cl-platform-probe.cc | terminatorul/cl-tool | 2202066a89a97982a49b64cb54e8cb36322ae1b1 | [
"Unlicense"
] | null | null | null | #include <cstddef>
#include <chrono>
#include <thread>
#include <iterator>
#include <iostream>
#include <memory>
#if defined(__APPLE__) || defined(__MACOSX__)
# include <OpenCL/cl2.hpp>
#else
# include <CL/cl2.hpp>
#endif
#include "cl-platform-info.hh"
#include "cl-double-pendulum.hh"
#include "cl-plat... | 34.48927 | 195 | 0.599054 | terminatorul |
c34f1fe6fbd195c4647af0a53da3e0389cee68d3 | 9,238 | cpp | C++ | Reverse/EasyAlgorithm/obfusGenerator.cpp | B0sS-Tang/moeCTF_2020 | c10fa5663effaf4f0ba774f3766c9eb26cec3200 | [
"MIT"
] | 9 | 2020-10-07T15:14:52.000Z | 2021-07-21T08:50:08.000Z | Reverse/EasyAlgorithm/obfusGenerator.cpp | B0sS-Tang/moeCTF_2020 | c10fa5663effaf4f0ba774f3766c9eb26cec3200 | [
"MIT"
] | null | null | null | Reverse/EasyAlgorithm/obfusGenerator.cpp | B0sS-Tang/moeCTF_2020 | c10fa5663effaf4f0ba774f3766c9eb26cec3200 | [
"MIT"
] | 2 | 2020-10-08T05:08:02.000Z | 2020-10-11T10:35:46.000Z | #include<cstdio>
#include<cstdlib>
#include<ctime>
#include<cstring>
#include<vector>
#include<string>
//#include<windows.h>
#define INT 0
#define LLONG 1
#define CHAR 2
#define SHORT 3
#define MAX_OP_TYPE 2
#define MAX_CODE_LEN 1000
#define MAX_DEOBFU_CODE_NUM 1000
//#define DEBUG_CPP_CODE
#define OUPUT_CONSOLE
using ... | 23.506361 | 174 | 0.621996 | B0sS-Tang |
c351d8408cf1b915b8cc7790a34f5ec401953710 | 1,455 | cpp | C++ | test/delete_var_and_modify.cpp | mtak-/lockfree-stm | 00cd5f9a056e999f0cd140106c1d66b321d6fd47 | [
"MIT"
] | 9 | 2016-11-14T23:35:30.000Z | 2019-01-18T23:21:08.000Z | test/delete_var_and_modify.cpp | mtak-/lockfree-stm | 00cd5f9a056e999f0cd140106c1d66b321d6fd47 | [
"MIT"
] | 3 | 2017-01-09T01:22:57.000Z | 2017-03-20T04:50:05.000Z | test/delete_var_and_modify.cpp | mtak-/lockfree-stm | 00cd5f9a056e999f0cd140106c1d66b321d6fd47 | [
"MIT"
] | null | null | null | #include <lstm/lstm.hpp>
#define STATEFUL_DEBUG_ALLOC
#ifdef NDEBUG
#undef NDEBUG
#include "debug_alloc.hpp"
#define NDEBUG
#else
#include "debug_alloc.hpp"
#endif
#include "simple_test.hpp"
#include "thread_manager.hpp"
static constexpr auto loop_count = LSTM_TEST_INIT(1000000, 100000);
using lstm::atomic;
using l... | 23.852459 | 78 | 0.468041 | mtak- |
c356c7ac7a9f043e7ee67d6661de575b5feab386 | 796 | cpp | C++ | CPP/OJ problems/Word Capitalization.cpp | kratikasinghal/OJ-problems | fc5365cb4db9da780779e9912aeb2a751fe4517c | [
"MIT"
] | null | null | null | CPP/OJ problems/Word Capitalization.cpp | kratikasinghal/OJ-problems | fc5365cb4db9da780779e9912aeb2a751fe4517c | [
"MIT"
] | null | null | null | CPP/OJ problems/Word Capitalization.cpp | kratikasinghal/OJ-problems | fc5365cb4db9da780779e9912aeb2a751fe4517c | [
"MIT"
] | null | null | null |
// Problem: A. Word Capitalization
// Contest: Codeforces - Codeforces Round #172 (Div. 2)
// URL: https://codeforces.com/problemset/problem/281/A
// Memory Limit: 256 MB
// Time Limit: 2000 ms
// Powered by CP Editor (https://github.com/cpeditor/cpeditor)
#include <bits/stdc++.h>
#define F first
#define S second
#de... | 18.952381 | 62 | 0.625628 | kratikasinghal |
c358650ebc3b2b6e4d5b8b677b28a69747b3292c | 320 | cpp | C++ | c-develop/19.Pointers/pointers.cpp | GustiArsyad123/C-Language-Test | 90a2eb45d1db2b039acbe5d3499aaff0aed99f82 | [
"MIT"
] | null | null | null | c-develop/19.Pointers/pointers.cpp | GustiArsyad123/C-Language-Test | 90a2eb45d1db2b039acbe5d3499aaff0aed99f82 | [
"MIT"
] | null | null | null | c-develop/19.Pointers/pointers.cpp | GustiArsyad123/C-Language-Test | 90a2eb45d1db2b039acbe5d3499aaff0aed99f82 | [
"MIT"
] | null | null | null | // ini contoh pointers di bahasa C++
#include <iostream>
using namespace std;
int main(){
string makanan = "Ayam Taliwang"; //variable dengan tipe string
cout << makanan << endl; //hasil keluaran makanan "Ayam Taliwang"
cout << &makanan << endl; //alamat memory keluaran dari makanan "0x7ffe62dab3b0"
} | 32 | 85 | 0.690625 | GustiArsyad123 |
c359a8469d3c3947291595937ea46be32f44a546 | 20 | cpp | C++ | ffsharp/SWScale.cpp | stschake/ffsharp | 506de52dde93d3dcf6c8bf3cbc452284fce8d304 | [
"Net-SNMP",
"Xnet"
] | null | null | null | ffsharp/SWScale.cpp | stschake/ffsharp | 506de52dde93d3dcf6c8bf3cbc452284fce8d304 | [
"Net-SNMP",
"Xnet"
] | null | null | null | ffsharp/SWScale.cpp | stschake/ffsharp | 506de52dde93d3dcf6c8bf3cbc452284fce8d304 | [
"Net-SNMP",
"Xnet"
] | null | null | null | #include "SWScale.h" | 20 | 20 | 0.75 | stschake |
c35a6c50b35a60e49e2399d0445f127faee8b99c | 1,309 | cpp | C++ | main.cpp | NeuronEnix/CSV-Parser | 51f6474ea77e76d22f35aa009d53e8805df63d41 | [
"MIT"
] | 1 | 2020-11-21T05:27:35.000Z | 2020-11-21T05:27:35.000Z | main.cpp | NeuronEnix/CSV-Parser-CPP | 51f6474ea77e76d22f35aa009d53e8805df63d41 | [
"MIT"
] | null | null | null | main.cpp | NeuronEnix/CSV-Parser-CPP | 51f6474ea77e76d22f35aa009d53e8805df63d41 | [
"MIT"
] | null | null | null | #include<iostream>
#include "CSV_Parser/CSV_Parser.hpp"
using namespace std;
int main() {
CSV_Parser parser = CSV_Parser();
parser.readFromFile( "file.csv" );
// Headers : [ "H0", "H1", "H2", "H3" ]
/* Finders */
parser.headerAt( 2 ); // returns: "H2"
parser.headerPos( "H3" ); // returns: 3
... | 29.75 | 114 | 0.553094 | NeuronEnix |
c35f43da82f6f7e7e278dd2e889805087fb7c22b | 103 | cpp | C++ | Chapter12/main.cpp | lixin-sxty/BigTalkDesignPatternForCpp | 8d766bfd05b9e30c626231bb5719638cd8c8893c | [
"MIT"
] | 1 | 2021-08-29T03:20:08.000Z | 2021-08-29T03:20:08.000Z | Chapter12/main.cpp | lixin-sxty/BigTalkDesignPatternForCpp | 8d766bfd05b9e30c626231bb5719638cd8c8893c | [
"MIT"
] | null | null | null | Chapter12/main.cpp | lixin-sxty/BigTalkDesignPatternForCpp | 8d766bfd05b9e30c626231bb5719638cd8c8893c | [
"MIT"
] | null | null | null | #include <iostream>
#include "facade.h"
int main() {
Fund f;
f.Buy();
f.Sell();
return 0;
}
| 8.583333 | 19 | 0.553398 | lixin-sxty |
c35f95c8f53a8420db7fe8a329870bf145d6cf2a | 370 | cpp | C++ | ThreadSanitizer/examples/01_race.cpp | dermojo/presentations | 4f4da0e60c144e735c98bb4c77ce7ccb055bd20b | [
"MIT"
] | 3 | 2017-07-07T13:32:28.000Z | 2020-01-09T20:33:02.000Z | ThreadSanitizer/examples/01_race.cpp | dermojo/presentations | 4f4da0e60c144e735c98bb4c77ce7ccb055bd20b | [
"MIT"
] | null | null | null | ThreadSanitizer/examples/01_race.cpp | dermojo/presentations | 4f4da0e60c144e735c98bb4c77ce7ccb055bd20b | [
"MIT"
] | null | null | null | // TSAN example: race condition
#include <iostream>
#include <thread>
static size_t counter = 0;
static void run()
{
for (int i = 0; i < 10000; ++i)
{
++counter;
}
}
int main()
{
std::thread t1([] { run(); });
std::thread t2([] { run(); });
t1.join();
t2.join();
std::cout <... | 13.214286 | 47 | 0.491892 | dermojo |
c3610798f1258a15dc61894ffbe1f8c8a357441f | 1,559 | cc | C++ | viewer/primitives/box.cc | IJDykeman/experiments-1 | 22badf166b2ea441e953939463f751020b8c251b | [
"MIT"
] | 1 | 2022-02-28T04:19:34.000Z | 2022-02-28T04:19:34.000Z | viewer/primitives/box.cc | IJDykeman/experiments-1 | 22badf166b2ea441e953939463f751020b8c251b | [
"MIT"
] | null | null | null | viewer/primitives/box.cc | IJDykeman/experiments-1 | 22badf166b2ea441e953939463f751020b8c251b | [
"MIT"
] | null | null | null | #include "viewer/primitives/box.hh"
#include <GL/glew.h>
namespace viewer {
void Box::draw() const {
glBegin(GL_QUADS);
// top
glColor3f(1.0f, 0.0f, 0.0f);
glNormal3f(0.0f, 1.0f, 0.0f);
glVertex3f(-0.5f, 0.5f, 0.5f);
glVertex3f(0.5f, 0.5f, 0.5f);
glVertex3f(0.5f, 0.5f, -0.5f);
glVertex3f(-0.5f, 0.5f,... | 20.786667 | 35 | 0.57601 | IJDykeman |
c361adc558c2a60d8be83e739296453fb191a6af | 654 | hpp | C++ | lib/data_structure/partial_sum_2D.hpp | atree-GitHub/competitive-library | 606b444036530b698a6363b1a41cdaa90a7f9578 | [
"CC0-1.0"
] | 1 | 2022-01-25T23:03:10.000Z | 2022-01-25T23:03:10.000Z | lib/data_structure/partial_sum_2D.hpp | atree4728/competitive-library | 1aaa4d2cf9283b9a1a3d4c7f114ff7b867ca2f8b | [
"CC0-1.0"
] | 6 | 2021-10-06T01:17:04.000Z | 2022-01-16T14:45:47.000Z | lib/data_structure/partial_sum_2D.hpp | atree-GitHub/competitive-library | 606b444036530b698a6363b1a41cdaa90a7f9578 | [
"CC0-1.0"
] | null | null | null | #pragma once
#include <vector>
template<class T> struct CumSum2D {
std::vector<std::vector<T>> data;
explicit CumSum2D(const std::vector<std::vector<T>> &a): data(size(a) + 1, std::vector<T>(size(a[0]) + 1, 0)) {
for (size_t i = 0; i + 1 < size(data); i++) copy(begin(a[i]), end(a[i]), begin(data[i + 1... | 46.714286 | 136 | 0.535168 | atree-GitHub |
c36696b62aed7f90167389514f1366cba58ad8a3 | 3,928 | hh | C++ | src/systems/rf_comms/RFComms.hh | Thodoris1999/ign-gazebo | 66fa61a1c2b018fa0a4d1080ef89c7cc9d321cea | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | src/systems/rf_comms/RFComms.hh | Thodoris1999/ign-gazebo | 66fa61a1c2b018fa0a4d1080ef89c7cc9d321cea | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | src/systems/rf_comms/RFComms.hh | Thodoris1999/ign-gazebo | 66fa61a1c2b018fa0a4d1080ef89c7cc9d321cea | [
"ECL-2.0",
"Apache-2.0"
] | null | null | null | /*
* Copyright (C) 2022 Open Source Robotics Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by appl... | 35.071429 | 79 | 0.636202 | Thodoris1999 |
c368efe959a0019419fe40bf0171ec00fa349d8f | 410 | cpp | C++ | brute/add123.cpp | SiverPineValley/algo | 29c75c6b226fdb15a3b6695e763ee49d4871094e | [
"Apache-2.0"
] | null | null | null | brute/add123.cpp | SiverPineValley/algo | 29c75c6b226fdb15a3b6695e763ee49d4871094e | [
"Apache-2.0"
] | null | null | null | brute/add123.cpp | SiverPineValley/algo | 29c75c6b226fdb15a3b6695e763ee49d4871094e | [
"Apache-2.0"
] | null | null | null | // N중 for문 9095
// 10 이하의 양의정수를 1,2,3의 합으로 몇 가지의 경우로 가능한지 나타내는 문제
#include<iostream>
using namespace std;
int answer = 0;
void nfor(int tc)
{
if(tc < 0)
return;
else if(tc == 0)
{
answer++;
return;
}
nfor(tc - 1);
nfor(tc - 2);
nfor(tc - 3);
}
int main(void)
{
int tn;
cin >> tn;
while(tn)
{
tn--;
... | 12.058824 | 49 | 0.543902 | SiverPineValley |
c36c67039a34474891efdbe7a43b063673786c4a | 1,697 | hpp | C++ | include/beluga/http/http_status_code.hpp | Stazer/beluga | 38232796669524c4f6b08f281e5a367390de24d0 | [
"MIT"
] | 1 | 2021-04-16T08:37:37.000Z | 2021-04-16T08:37:37.000Z | include/beluga/http/http_status_code.hpp | Stazer/beluga | 38232796669524c4f6b08f281e5a367390de24d0 | [
"MIT"
] | null | null | null | include/beluga/http/http_status_code.hpp | Stazer/beluga | 38232796669524c4f6b08f281e5a367390de24d0 | [
"MIT"
] | null | null | null | #pragma once
namespace beluga
{
enum class http_status_code
{
CONTINUE = 100,
SWITCHING_PROTOCOLS = 101,
PROCESSING = 102,
OK = 200,
CREATED = 201,
ACCEPTED = 202,
NON_AUTHORITATIVE_INFORMATION = 203,
NO_CONTENT = 204,
RESET_CONTENT = 205,
PARTIAL_CONTENT = 206,
MULTI_STATUS = 207,
ALREADY_REPORT... | 22.038961 | 40 | 0.753094 | Stazer |
c36d9f9fb47f80e792690e402a995eba54b3f0fe | 3,618 | cpp | C++ | src/mxSingleton.cpp | stahta01/Zinjal | 8d1e52c9eab5cde9f7cb96c99a0fbdf97904da42 | [
"OML"
] | 1 | 2019-03-24T00:58:59.000Z | 2019-03-24T00:58:59.000Z | src/mxSingleton.cpp | stahta01/Zinjal | 8d1e52c9eab5cde9f7cb96c99a0fbdf97904da42 | [
"OML"
] | null | null | null | src/mxSingleton.cpp | stahta01/Zinjal | 8d1e52c9eab5cde9f7cb96c99a0fbdf97904da42 | [
"OML"
] | null | null | null | #include <iostream>
using namespace std;
#include "mxSingleton.h"
#include "ConfigManager.h"
#include "mxMainWindow.h"
BEGIN_EVENT_TABLE(mxSingleton,wxEvtHandler)
EVT_SOCKET(wxID_ANY,mxSingleton::OnSocket)
END_EVENT_TABLE()
mxSingleton *g_singleton=nullptr;
mxSingleton::mxSingleton():m_server(nullptr) {
m_calls_co... | 25.478873 | 110 | 0.698176 | stahta01 |
c37af6c0529123d3776dcf7e66e56eeb603fb002 | 1,665 | cpp | C++ | dlls/haj/haj_deployzone.cpp | steveuk/ham-and-jam | 25121bf6302d81e68207706ae5c313c0c84ffc78 | [
"MIT"
] | null | null | null | dlls/haj/haj_deployzone.cpp | steveuk/ham-and-jam | 25121bf6302d81e68207706ae5c313c0c84ffc78 | [
"MIT"
] | null | null | null | dlls/haj/haj_deployzone.cpp | steveuk/ham-and-jam | 25121bf6302d81e68207706ae5c313c0c84ffc78 | [
"MIT"
] | null | null | null | #include "cbase.h"
#include "triggers.h"
#include "haj_player.h"
#include "haj_deployzone.h"
LINK_ENTITY_TO_CLASS( haj_deployzone, CDeployZone );
BEGIN_DATADESC( CDeployZone )
DEFINE_KEYFIELD( m_iStance, FIELD_INTEGER, "stance" ),
DEFINE_KEYFIELD( m_fAngleMax, FIELD_FLOAT, "angle_tolerance" ),
DEFINE_KEYFIELD( m_i... | 27.295082 | 92 | 0.714715 | steveuk |
c37fdb72b1c46c776d6fb8b333ed290761297b3f | 48 | cpp | C++ | c-src/fl_utf8C.cpp | ericu/fltkhs | 3ca521ca30d51a84f8ec87938932f2ce5af8a7c0 | [
"MIT"
] | 222 | 2015-01-11T19:01:16.000Z | 2022-03-25T14:47:26.000Z | c-src/fl_utf8C.cpp | ericu/fltkhs | 3ca521ca30d51a84f8ec87938932f2ce5af8a7c0 | [
"MIT"
] | 143 | 2015-01-13T19:08:33.000Z | 2021-10-10T20:43:46.000Z | c-src/fl_utf8C.cpp | ericu/fltkhs | 3ca521ca30d51a84f8ec87938932f2ce5af8a7c0 | [
"MIT"
] | 36 | 2015-01-14T15:30:18.000Z | 2021-08-11T13:04:28.000Z | #ifdef __cplusplus
#include "fl_utf8C.h"
#endif
| 12 | 21 | 0.770833 | ericu |
c38e83d25a4dcc8241691b845d61c3076723f480 | 1,993 | hpp | C++ | examples/cli.hpp | bytemaster/Boost.RPC | a27795d37481fb5d53774cc8cf4270fff1f84964 | [
"Unlicense"
] | 23 | 2015-03-31T05:54:47.000Z | 2022-02-27T14:30:16.000Z | examples/cli.hpp | bytemaster/Boost.RPC | a27795d37481fb5d53774cc8cf4270fff1f84964 | [
"Unlicense"
] | null | null | null | examples/cli.hpp | bytemaster/Boost.RPC | a27795d37481fb5d53774cc8cf4270fff1f84964 | [
"Unlicense"
] | 13 | 2015-04-22T04:32:26.000Z | 2019-08-29T13:22:21.000Z | #ifndef _BOOST_IDL_CLI_HPP_
#define _BOOST_IDL_CLI_HPP_
#include <sstream>
#include <iomanip>
#include <iostream>
#include <boost/fusion/sequence/io.hpp>
#include <boost/reflect/reflect.hpp>
#include <boost/utility/result_of.hpp>
/**
* Takes any interface object and provides a command line interface for it.
*/
clas... | 32.672131 | 95 | 0.558956 | bytemaster |
c39117e12e132a9b59ca358bca3a57e1d2ffd97c | 1,210 | cpp | C++ | HW1/task03-appox-occurrences/main.cpp | ulyanin/Bioinformatics2019 | b28d9b2ad8a1c41ec9c6ba655cd0aca5a1984662 | [
"MIT"
] | null | null | null | HW1/task03-appox-occurrences/main.cpp | ulyanin/Bioinformatics2019 | b28d9b2ad8a1c41ec9c6ba655cd0aca5a1984662 | [
"MIT"
] | null | null | null | HW1/task03-appox-occurrences/main.cpp | ulyanin/Bioinformatics2019 | b28d9b2ad8a1c41ec9c6ba655cd0aca5a1984662 | [
"MIT"
] | null | null | null | #include <iostream>
#include <vector>
#include <cassert>
#include <fstream>
#include <unordered_set>
template <class C>
void PrintCollection(const C& collection, std::ostream& os = std::cout) {
for (const auto& elem : collection) {
os << elem << " ";
}
os << std::endl;
}
size_t HammingDistance(std... | 25.208333 | 73 | 0.566942 | ulyanin |
c392a1517b49d4e316119887e8b805cb7d78418c | 852 | cpp | C++ | soj/2509.cpp | huangshenno1/project_euler | 8a3c91fd11bcb6a6a830e963b1d5aed3f5ff787d | [
"MIT"
] | null | null | null | soj/2509.cpp | huangshenno1/project_euler | 8a3c91fd11bcb6a6a830e963b1d5aed3f5ff787d | [
"MIT"
] | null | null | null | soj/2509.cpp | huangshenno1/project_euler | 8a3c91fd11bcb6a6a830e963b1d5aed3f5ff787d | [
"MIT"
] | null | null | null | #include <cstdio>
#include <cstring>
#include <cctype>
#include <cstdlib>
#include <ctime>
#include <climits>
#include <cmath>
#include <iostream>
#include <string>
#include <vector>
#include <set>
#include <map>
#include <list>
#include <queue>
#include <stack>
#include <deque>
#include <algorithm>
using namespace std... | 17.387755 | 64 | 0.523474 | huangshenno1 |
c392daa8e5e36f5c8222498c5c292a939df14f58 | 1,560 | cpp | C++ | User_plugins/userapp_plugin.cpp | GreatCong/GUI_EC_PluginSrc | 9194e67b76f3707f782f1fc17ba6e6dcb712c2a5 | [
"MIT"
] | 1 | 2019-12-25T13:36:01.000Z | 2019-12-25T13:36:01.000Z | User_plugins/userapp_plugin.cpp | GreatCong/GUI_EC_PluginSrc | 9194e67b76f3707f782f1fc17ba6e6dcb712c2a5 | [
"MIT"
] | null | null | null | User_plugins/userapp_plugin.cpp | GreatCong/GUI_EC_PluginSrc | 9194e67b76f3707f782f1fc17ba6e6dcb712c2a5 | [
"MIT"
] | 1 | 2020-08-05T14:05:15.000Z | 2020-08-05T14:05:15.000Z | #include "userapp_plugin.h"
#include <QGridLayout>
#include <QPushButton>
UserApp_plugin::UserApp_plugin(QObject *parent) :
QObject(parent),EtherCAT_UserApp()
{
//NOTE:如果要设置图标,在这个位置设置
this->set_AppName("User_App example");
// QPixmap pixmap(":/Controls/Resource/Control/App_icon.png");
// t... | 21.971831 | 67 | 0.655128 | GreatCong |
c399c876fde68b819c1a5810ab342c96fd2a64ff | 5,662 | cpp | C++ | lib/io/src/plain.cpp | solosTec/cyng | 3862a6b7a2b536d1f00fef20700e64170772dcff | [
"MIT"
] | null | null | null | lib/io/src/plain.cpp | solosTec/cyng | 3862a6b7a2b536d1f00fef20700e64170772dcff | [
"MIT"
] | null | null | null | lib/io/src/plain.cpp | solosTec/cyng | 3862a6b7a2b536d1f00fef20700e64170772dcff | [
"MIT"
] | null | null | null | /*
* The MIT License (MIT)
*
* Copyright (c) 2017 Sylko Olzscher
*
*/
#include <cyng/io/serializer/plain.hpp>
#include <cyng/io/serializer.h>
#include <cyng/object.h>
#include <algorithm>
#include <boost/io/ios_state.hpp>
namespace cyng
{
namespace io
{
std::ostream& serializer <tu... | 20.816176 | 142 | 0.512363 | solosTec |
c39ae9639f7d2c74a5adba6d8d9fe5fcd1d0e0aa | 10,276 | cpp | C++ | examples/example-matrices.cpp | kirchnerlab/libpipe | 28f08b9399945bd13329937a9dd0691211826886 | [
"MIT"
] | 1 | 2018-11-08T13:41:18.000Z | 2018-11-08T13:41:18.000Z | examples/example-matrices.cpp | kirchnerlab/libpipe | 28f08b9399945bd13329937a9dd0691211826886 | [
"MIT"
] | null | null | null | examples/example-matrices.cpp | kirchnerlab/libpipe | 28f08b9399945bd13329937a9dd0691211826886 | [
"MIT"
] | null | null | null | /*
* example-rtc.cpp
*
* Copyright (c) 2010 Marc Kirchner
* 2011 David Sichau
*
*/
#include <libpipe/config.hpp>
#include <stdlib.h>
#include <exception>
#include <iostream>
#include <set>
#include <boost/pointer_cast.hpp>
#include <boost/shared_ptr.hpp>
#include <boost/make_shared.hpp>
#include <... | 27.549598 | 82 | 0.617653 | kirchnerlab |
c39c2e3f8e5f6065ff3aa241d03e0908aca052aa | 947 | hpp | C++ | tools/ktx_export/options.hpp | kevin-lesenechal/glare | 774fb6bcd40349ac5a7b9155b97d1dd995b3b5d1 | [
"MIT"
] | null | null | null | tools/ktx_export/options.hpp | kevin-lesenechal/glare | 774fb6bcd40349ac5a7b9155b97d1dd995b3b5d1 | [
"MIT"
] | null | null | null | tools/ktx_export/options.hpp | kevin-lesenechal/glare | 774fb6bcd40349ac5a7b9155b97d1dd995b3b5d1 | [
"MIT"
] | null | null | null | /******************************************************************************
* Copyright © 2020 Kévin Lesénéchal <kevin.lesenechal@gmail.com> *
* *
* This file is part of the GLARE project, published under the terms of the *
... | 31.566667 | 80 | 0.461457 | kevin-lesenechal |
c3a1bc733f8b074bab9228f731cb174ac145b7a4 | 8,330 | cpp | C++ | slackbot/SlackClient.cpp | mogemimi/daily-snippets | d9da3db8c62538e4a37f0f6b69c5d46d55c4225f | [
"MIT"
] | 14 | 2017-06-16T22:52:38.000Z | 2022-02-14T04:11:06.000Z | slackbot/SlackClient.cpp | mogemimi/daily-snippets | d9da3db8c62538e4a37f0f6b69c5d46d55c4225f | [
"MIT"
] | 2 | 2016-03-13T14:50:04.000Z | 2019-04-01T09:53:17.000Z | slackbot/SlackClient.cpp | mogemimi/daily-snippets | d9da3db8c62538e4a37f0f6b69c5d46d55c4225f | [
"MIT"
] | 2 | 2016-03-13T14:05:17.000Z | 2018-09-18T01:28:42.000Z | // Copyright (c) 2015 mogemimi. Distributed under the MIT license.
#include "SlackClient.h"
#include "HttpUtility.h"
#include <rapidjson/document.h>
#include <cstdint>
#include <sstream>
#include <utility>
namespace somera {
namespace {
void fromJson(std::string& output, const rapidjson::Value& value)
{
if (valu... | 29.964029 | 101 | 0.583673 | mogemimi |
ce819104cad0a3594ae55c16dfd8c81fd33b6522 | 301 | cc | C++ | ch02/or/main/or.cc | research-note/deep-learning-from-scratch-using-cpp | 5e11be85fa9c4c7672ce9c3ea2c5ffa8f27defd1 | [
"MIT"
] | 2 | 2021-08-15T12:38:41.000Z | 2021-08-15T12:38:51.000Z | ch02/or/main/or.cc | research-note/deep-learning-from-scratch-using-modern-cpp | 5e11be85fa9c4c7672ce9c3ea2c5ffa8f27defd1 | [
"MIT"
] | null | null | null | ch02/or/main/or.cc | research-note/deep-learning-from-scratch-using-modern-cpp | 5e11be85fa9c4c7672ce9c3ea2c5ffa8f27defd1 | [
"MIT"
] | null | null | null | #include <numeric>
#include <vector>
template<typename T>
T OR(T x1, T x2) {
std::vector<T> x = {x1, x2};
std::vector<T> w = {0.5, 0.5};
T b = -0.2;
T tmp = std::inner_product(x.begin(), x.end(),
w.begin(), b);
if (tmp <= 0)
return 0;
else
return 1;
} | 18.8125 | 50 | 0.491694 | research-note |
ce8c5530c0574c27a47a2c4df8e9350c51493ee4 | 2,030 | cpp | C++ | src/Identifier.cpp | flagarde/YAODAQ | 851df4aa32b8695c4706bb3ec9f353f4461c9cad | [
"MIT"
] | null | null | null | src/Identifier.cpp | flagarde/YAODAQ | 851df4aa32b8695c4706bb3ec9f353f4461c9cad | [
"MIT"
] | 11 | 2021-05-14T19:50:27.000Z | 2022-03-31T07:19:41.000Z | src/Identifier.cpp | flagarde/YAODAQ | 851df4aa32b8695c4706bb3ec9f353f4461c9cad | [
"MIT"
] | 5 | 2021-05-11T13:30:30.000Z | 2021-05-26T19:57:22.000Z | #include "Identifier.hpp"
#include "magic_enum.hpp"
#include <vector>
#include <string>
#include "Exception.hpp"
#include "StatusCode.hpp"
//FIXME try to find a mix between Infos and Identifier
namespace yaodaq
{
bool Identifier::operator<(const Identifier& infos) const
{
return this->getName() < infos.getNa... | 24.756098 | 155 | 0.610345 | flagarde |
ce8ec0386710a0cf77cf8c00f587061a0a796c27 | 4,726 | cpp | C++ | src/scene/spritecomponent.cpp | pniekamp/datum | 4668030b63360f2c14706a9718773f6225273781 | [
"Apache-2.0"
] | 28 | 2016-11-11T15:53:37.000Z | 2021-02-25T08:15:42.000Z | src/scene/spritecomponent.cpp | pniekamp/datum | 4668030b63360f2c14706a9718773f6225273781 | [
"Apache-2.0"
] | 5 | 2017-02-23T06:01:17.000Z | 2018-01-31T03:54:49.000Z | src/scene/spritecomponent.cpp | pniekamp/datum | 4668030b63360f2c14706a9718773f6225273781 | [
"Apache-2.0"
] | 1 | 2017-02-24T01:38:07.000Z | 2017-02-24T01:38:07.000Z | //
// Datum - sprite component
//
//
// Copyright (c) 2016 Peter Niekamp
//
#include "spritecomponent.h"
#include "transformcomponent.h"
#include "debug.h"
using namespace std;
using namespace lml;
//|---------------------- SpriteStorage -------------------------------------
//|-------------------------------------... | 29.354037 | 154 | 0.599027 | pniekamp |
ce8f63fab9ba1aad17e6e2e6bc204bcdc7e599a2 | 212 | cpp | C++ | solutions/1375.bulb-switcher-iii.329765759.ac.cpp | satu0king/Leetcode-Solutions | 2edff60d76c2898d912197044f6284efeeb34119 | [
"MIT"
] | 78 | 2020-10-22T11:31:53.000Z | 2022-02-22T13:27:49.000Z | solutions/1375.bulb-switcher-iii.329765759.ac.cpp | satu0king/Leetcode-Solutions | 2edff60d76c2898d912197044f6284efeeb34119 | [
"MIT"
] | null | null | null | solutions/1375.bulb-switcher-iii.329765759.ac.cpp | satu0king/Leetcode-Solutions | 2edff60d76c2898d912197044f6284efeeb34119 | [
"MIT"
] | 26 | 2020-10-23T15:10:44.000Z | 2021-11-07T16:13:50.000Z | class Solution {
public:
int numTimesAllBlue(vector<int> &A) {
int right = 0, res = 0, n = A.size();
for (int i = 0; i < n; ++i)
res += (right = max(right, A[i])) == i + 1;
return res;
}
};
| 21.2 | 49 | 0.5 | satu0king |
ce90515a01043204a64cacfdcdf531d7c2131953 | 7,156 | cpp | C++ | test/startup/thread_support.cpp | arkantos493/MPICXX | ffbaeaaa3c7248e2087c3716ec71e0612aafe689 | [
"MIT"
] | 1 | 2020-10-20T06:53:05.000Z | 2020-10-20T06:53:05.000Z | test/startup/thread_support.cpp | arkantos493/MPICXX | ffbaeaaa3c7248e2087c3716ec71e0612aafe689 | [
"MIT"
] | null | null | null | test/startup/thread_support.cpp | arkantos493/MPICXX | ffbaeaaa3c7248e2087c3716ec71e0612aafe689 | [
"MIT"
] | 1 | 2020-08-13T17:46:40.000Z | 2020-08-13T17:46:40.000Z | /**
* @file
* @author Marcel Breyer
* @date 2020-07-29
* @copyright This file is distributed under the MIT License.
*
* @brief Test cases for the @ref mpicxx::thread_support enum class.
* @details Testsuite: *StartupTest*
* | test case name | test case description ... | 60.644068 | 252 | 0.597121 | arkantos493 |
ce92176b8a32a92351521aab900db38c508d6644 | 2,505 | cpp | C++ | apps/vaporgui/VGeometry.cpp | StasJ/vapor-formatted | 9fad47d88714ef835b78f6c1dd855d66b6aa90da | [
"BSD-3-Clause"
] | null | null | null | apps/vaporgui/VGeometry.cpp | StasJ/vapor-formatted | 9fad47d88714ef835b78f6c1dd855d66b6aa90da | [
"BSD-3-Clause"
] | null | null | null | apps/vaporgui/VGeometry.cpp | StasJ/vapor-formatted | 9fad47d88714ef835b78f6c1dd855d66b6aa90da | [
"BSD-3-Clause"
] | null | null | null | #include "VGeometry.h"
VGeometry::VGeometry(QWidget *parent, int dim, const std::vector<float> &range) : QWidget(parent) {
VAssert(dim == 2 || dim == 3);
VAssert(range.size() == dim * 2);
for (int i = 0; i < dim; i++)
VAssert(range[i * 2] < range[i * 2 + 1]);
_dim = dim;
_xrange = new VRan... | 33.851351 | 99 | 0.600798 | StasJ |
ce96958b21523cbbf071c9dc263266169b8c056f | 1,117 | cpp | C++ | src/State.cpp | unbgames/Wenova | 4860429d1bdc323b7ab8e7d53876e32de8941f46 | [
"MIT"
] | null | null | null | src/State.cpp | unbgames/Wenova | 4860429d1bdc323b7ab8e7d53876e32de8941f46 | [
"MIT"
] | 3 | 2017-08-28T23:57:45.000Z | 2017-10-08T19:36:41.000Z | src/State.cpp | joaorobson/Wenova | 4860429d1bdc323b7ab8e7d53876e32de8941f46 | [
"MIT"
] | 1 | 2019-04-07T20:19:20.000Z | 2019-04-07T20:19:20.000Z | #include "State.h"
#include "Collision.h"
State::State(){
m_pop_requested = m_quit_requested = false;
}
State::~State(){
}
void State::add_object(GameObject * object){
object_array.emplace_back(object);
}
bool State::pop_requested(){
return m_pop_requested;
}
bool State::quit_requested(){
return m_quit_reques... | 18.616667 | 73 | 0.651746 | unbgames |
ce96d7893c607527df0bc4f93924dfd2cdaee53e | 29,619 | cpp | C++ | gameboy/src/ppu/ppu.cpp | emrsmsrli/gameboi | 6448722529bc64184e30a945f0e5ec4203265e10 | [
"MIT"
] | 23 | 2019-08-27T13:54:27.000Z | 2022-01-21T08:38:14.000Z | gameboy/src/ppu/ppu.cpp | emrsmsrli/gameboi | 6448722529bc64184e30a945f0e5ec4203265e10 | [
"MIT"
] | 21 | 2020-02-22T20:37:16.000Z | 2020-08-30T14:52:48.000Z | gameboy/src/ppu/ppu.cpp | emrsmsrli/gameboi | 6448722529bc64184e30a945f0e5ec4203265e10 | [
"MIT"
] | null | null | null | #include "gameboy/ppu/ppu.h"
#include <cstring>
#include "gameboy/bus.h"
#include "gameboy/cartridge.h"
#include "gameboy/cpu/cpu.h"
#include "gameboy/memory/memory_constants.h"
#include "gameboy/memory/mmu.h"
#include "gameboy/util/variantutil.h"
namespace gameboy {
constexpr auto ly_max = 153u;
constexpr auto lc... | 32.512623 | 122 | 0.595023 | emrsmsrli |
ce977cea3952efc84dfdf9fb7a515787c93be4c2 | 4,823 | hpp | C++ | include/graph/GridGraph.hpp | DarkWingMcQuack/GridGraphPathFinder | d8f9a237f17516141bf58c8c86d468f3559af5e3 | [
"Apache-2.0"
] | null | null | null | include/graph/GridGraph.hpp | DarkWingMcQuack/GridGraphPathFinder | d8f9a237f17516141bf58c8c86d468f3559af5e3 | [
"Apache-2.0"
] | null | null | null | include/graph/GridGraph.hpp | DarkWingMcQuack/GridGraphPathFinder | d8f9a237f17516141bf58c8c86d468f3559af5e3 | [
"Apache-2.0"
] | null | null | null | #pragma once
#include <graph/GridCell.hpp>
#include <graph/GridGraphIterator.hpp>
#include <graph/NeigbourCalculator.hpp>
#include <graph/Node.hpp>
#include <optional>
#include <selection/NodeSelection.hpp>
#include <separation/Separation.hpp>
#include <string_view>
#include <vector>
namespace graph {
class GridGrap... | 30.333333 | 98 | 0.663695 | DarkWingMcQuack |
cea5828e32eb2af2a05e49cd9a65f287b5ba3823 | 37,535 | cpp | C++ | rviz_cinematographer_view_controller/src/rviz_cinematographer_view_controller.cpp | qpc001/rviz_cinematographer | 51fc022524d6ecebf603bac0c8ab39f22fff1a2f | [
"BSD-3-Clause"
] | 113 | 2018-11-02T17:40:30.000Z | 2022-03-08T11:44:00.000Z | rviz_cinematographer_view_controller/src/rviz_cinematographer_view_controller.cpp | tanujthakkar/rviz_cinematographer | 04d66f5fbf2f97ac98d88fb67baabde00e5525f8 | [
"BSD-3-Clause"
] | 11 | 2019-01-22T22:33:27.000Z | 2021-11-26T10:25:11.000Z | rviz_cinematographer_view_controller/src/rviz_cinematographer_view_controller.cpp | tanujthakkar/rviz_cinematographer | 04d66f5fbf2f97ac98d88fb67baabde00e5525f8 | [
"BSD-3-Clause"
] | 17 | 2018-11-05T08:46:49.000Z | 2021-04-14T16:31:31.000Z | /*
* Copyright (c) 2009, Willow Garage, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* * Redistributions of source code must retain the above copyright
* notice, this l... | 42.269144 | 168 | 0.71773 | qpc001 |
cea8c1e43c062e8794dbb0142c6d6e809251a527 | 1,209 | cpp | C++ | src/test.cpp | stestagg/pytubes | 003b2a5045417317667559ce39ddd0a005208e70 | [
"MIT"
] | 166 | 2018-03-05T14:43:26.000Z | 2022-01-01T17:59:37.000Z | src/test.cpp | stestagg/pytubes | 003b2a5045417317667559ce39ddd0a005208e70 | [
"MIT"
] | 14 | 2018-02-27T10:23:33.000Z | 2020-02-04T14:36:16.000Z | src/test.cpp | stestagg/pytubes | 003b2a5045417317667559ce39ddd0a005208e70 | [
"MIT"
] | 15 | 2018-03-06T05:00:30.000Z | 2021-12-04T19:43:12.000Z | #define CATCH_CONFIG_RUNNER
#include <catch2.hpp>
#include <Python.h>
void __Pyx_CppExn2PyErr() {};
struct LogPyErrors : Catch::TestEventListenerBase {
using TestEventListenerBase::TestEventListenerBase; // inherit constructor
void testCaseStarting( Catch::TestCaseInfo const& testInfo ... | 27.477273 | 92 | 0.590571 | stestagg |
cea95b6f8759013aecb938ea98fa77b9b583e2ba | 1,679 | cpp | C++ | source/visual/cGlow.cpp | MausGames/project-one | 157c93e8b4a926528ce5e77efacfcd950ea361f9 | [
"Zlib"
] | 3 | 2015-06-30T00:10:29.000Z | 2021-03-09T21:05:11.000Z | source/visual/cGlow.cpp | MausGames/project-one | 157c93e8b4a926528ce5e77efacfcd950ea361f9 | [
"Zlib"
] | null | null | null | source/visual/cGlow.cpp | MausGames/project-one | 157c93e8b4a926528ce5e77efacfcd950ea361f9 | [
"Zlib"
] | null | null | null | ///////////////////////////////////////////////////////
//*-------------------------------------------------*//
//| Part of Project One (https://www.maus-games.at) |//
//*-------------------------------------------------*//
//| Released under the zlib License |//
//| More information available in the re... | 32.288462 | 221 | 0.449672 | MausGames |
ceb2298d02ed3ec0e649b46a57f97e796ac42fb9 | 710 | cpp | C++ | UVaOnlineJudge/Contest_Volumes(10000...)/Volume122(12200-12299)/12250/code.cpp | luiscbr92/algorithmic-challenges | bc35729e54e4284e9ade1aa61b51a1c2d72aa62c | [
"MIT"
] | 3 | 2015-10-21T18:56:43.000Z | 2017-06-06T10:44:22.000Z | UVaOnlineJudge/Contest_Volumes(10000...)/Volume122(12200-12299)/12250/code.cpp | luiscbr92/algorithmic-challenges | bc35729e54e4284e9ade1aa61b51a1c2d72aa62c | [
"MIT"
] | null | null | null | UVaOnlineJudge/Contest_Volumes(10000...)/Volume122(12200-12299)/12250/code.cpp | luiscbr92/algorithmic-challenges | bc35729e54e4284e9ade1aa61b51a1c2d72aa62c | [
"MIT"
] | null | null | null | #include <iostream>
using namespace std;
int main(){
string line;
int i = 1;
while(getline(cin, line) && line[0] != '#'){
if(line=="HELLO") cout << "Case " << i << ": ENGLISH\n";
else if(line=="HOLA") cout << "Case " << i << ": SPANISH\n";
else if(line=="HA... | 33.809524 | 78 | 0.412676 | luiscbr92 |
ceb2469168f7e815a3e08352b59fe4933b45e6f8 | 2,953 | hpp | C++ | source/hougfx/include/hou/gfx/text_vertex.hpp | DavideCorradiDev/houzi-game-engine | d704aa9c5b024300578aafe410b7299c4af4fcec | [
"MIT"
] | 2 | 2018-04-12T20:59:20.000Z | 2018-07-26T16:04:07.000Z | source/hougfx/include/hou/gfx/text_vertex.hpp | DavideCorradiDev/houzi-game-engine | d704aa9c5b024300578aafe410b7299c4af4fcec | [
"MIT"
] | null | null | null | source/hougfx/include/hou/gfx/text_vertex.hpp | DavideCorradiDev/houzi-game-engine | d704aa9c5b024300578aafe410b7299c4af4fcec | [
"MIT"
] | null | null | null | // Houzi Game Engine
// Copyright (c) 2018 Davide Corradi
// Licensed under the MIT license.
#ifndef HOU_GFX_TEXT_VERTEX_HPP
#define HOU_GFX_TEXT_VERTEX_HPP
#include "hou/gfx/gfx_config.hpp"
#include "hou/cor/pragmas.hpp"
#include "hou/gl/open_gl.hpp"
#include "hou/mth/matrix.hpp"
namespace hou
{
class vertex_... | 22.203008 | 78 | 0.714528 | DavideCorradiDev |
ceb4065c35a9a3cdbaae7aca579120902127c6fe | 397 | cpp | C++ | example/fact.cpp | lisqlql/pyaspp | 06dac7fe42684f6158bef24ac5e4ae4c60c384ab | [
"MIT"
] | null | null | null | example/fact.cpp | lisqlql/pyaspp | 06dac7fe42684f6158bef24ac5e4ae4c60c384ab | [
"MIT"
] | null | null | null | example/fact.cpp | lisqlql/pyaspp | 06dac7fe42684f6158bef24ac5e4ae4c60c384ab | [
"MIT"
] | null | null | null | #py MAX_N = 20
#py{
def cpp_fact(n, res):
return cpp.define('FACT_{}'.format(n), res)
def gen_fact():
acc = 1
yield cpp_fact(0, 1)
for n in range(1, MAX_N + 1):
acc *= n
yield cpp_fact(n, acc)
#py}
#py= gen_fact()
int main() {
std::cout << FACT_1 << std::endl;
std::cout << ... | 15.88 | 47 | 0.536524 | lisqlql |
ceb8c62b11ca0335abff994ee5a866cf731bfff7 | 5,017 | cpp | C++ | src/advphdr.cpp | taviso/mpgravity | f6a2a7a02014b19047e44db76ae551bd689c16ac | [
"BSD-3-Clause"
] | 9 | 2020-04-01T04:15:22.000Z | 2021-09-26T21:03:47.000Z | src/advphdr.cpp | taviso/mpgravity | f6a2a7a02014b19047e44db76ae551bd689c16ac | [
"BSD-3-Clause"
] | 17 | 2020-04-02T19:38:40.000Z | 2020-04-12T05:47:08.000Z | src/advphdr.cpp | taviso/mpgravity | f6a2a7a02014b19047e44db76ae551bd689c16ac | [
"BSD-3-Clause"
] | null | null | null | /*****************************************************************************/
/* SOURCE CONTROL VERSIONS */
/*---------------------------------------------------------------------------*/
/* ... | 39.503937 | 85 | 0.590791 | taviso |
cebc6e04fe03da69388603f3c2d2c6681b23d431 | 6,654 | cpp | C++ | Graphics/tutorials/ParticleEmitter.cpp | LoganPletcher/Year-2 | 827d46ace6230225e2cd5638266f10296d410d77 | [
"MIT"
] | null | null | null | Graphics/tutorials/ParticleEmitter.cpp | LoganPletcher/Year-2 | 827d46ace6230225e2cd5638266f10296d410d77 | [
"MIT"
] | null | null | null | Graphics/tutorials/ParticleEmitter.cpp | LoganPletcher/Year-2 | 827d46ace6230225e2cd5638266f10296d410d77 | [
"MIT"
] | null | null | null | #include "ParticleEmitter.h"
#include "gl_core_4_4.h"
#include <glm/gtc/random.hpp>
using glm::vec3;
using glm::vec4;
using glm::mat4;
ParticleEmitter::ParticleEmitter()
: m_particles(nullptr),
m_aliveParticles(0),
m_maxParticles(0),
m_transform(1),
m_vao(0), m_vbo(0), m_ibo(0),
m_vertices(nullptr) {
}
Particl... | 31.239437 | 110 | 0.70018 | LoganPletcher |
cebdbaa1cce9d0cd9010607b8e0df55d5168894a | 740 | cpp | C++ | Onboard-SDK-ROS/dji_sdk_demo/src/stereo_utility/config.cpp | NMMI/aerial-alter-ego | ba6517ecc1986e4808f6c17df3348dc5637d9cf7 | [
"BSD-3-Clause"
] | 6 | 2020-08-16T07:31:14.000Z | 2022-02-17T06:24:47.000Z | src/Onboard-SDK-ROS-3.6/dji_sdk_demo/src/stereo_utility/config.cpp | isuran/droneautomation | c53017f8c8d4c03e3095ec7b6269d5a2659489e5 | [
"MIT"
] | 1 | 2021-08-18T08:14:19.000Z | 2021-08-18T08:14:19.000Z | src/Onboard-SDK-ROS-3.6/dji_sdk_demo/src/stereo_utility/config.cpp | isuran/droneautomation | c53017f8c8d4c03e3095ec7b6269d5a2659489e5 | [
"MIT"
] | 2 | 2021-05-18T07:04:23.000Z | 2021-05-23T13:22:13.000Z | #include "stereo_utility/config.hpp"
using namespace M210_STEREO;
Config* Config::single_instance_ = NULL;
Config::Config()
{
}
Config::~Config()
{
if (file_.isOpened())
{
file_.release();
}
}
Config&
Config::instance()
{
return *Config::single_instance_;
}
Config*
Config::instancePtr()
{
return Con... | 15.744681 | 85 | 0.664865 | NMMI |
cecb215d2f23a9539d139e354548c199c7a07be9 | 247 | cpp | C++ | src/vega/manipulators/other_byte_manipulator.cpp | project-eutopia/vega | c7b536c5e949094a908fa8f378729dbffc657f4a | [
"MIT"
] | 18 | 2018-01-23T12:28:13.000Z | 2022-02-13T12:23:21.000Z | src/vega/manipulators/other_byte_manipulator.cpp | project-eutopia/vega | c7b536c5e949094a908fa8f378729dbffc657f4a | [
"MIT"
] | 2 | 2018-11-29T01:51:25.000Z | 2022-03-22T14:14:22.000Z | src/vega/manipulators/other_byte_manipulator.cpp | project-eutopia/vega | c7b536c5e949094a908fa8f378729dbffc657f4a | [
"MIT"
] | 6 | 2019-02-01T09:54:44.000Z | 2022-01-09T22:13:54.000Z | #include "vega/manipulators/other_byte_manipulator.h"
namespace vega {
namespace vr {
template <>
bool manipulator_is_valid_for<manipulators::OtherByteManipulator>(VR::value_type value) {
return value == vr::OB_VALUE;
}
}
}
| 22.454545 | 93 | 0.712551 | project-eutopia |
cecbe7d8e521fb986611411236b61392f39eb93f | 1,894 | cpp | C++ | Generator/combination.cpp | 636F57/Algos | 92f0f637391652dfc8baa5c394322b849e590748 | [
"MIT"
] | null | null | null | Generator/combination.cpp | 636F57/Algos | 92f0f637391652dfc8baa5c394322b849e590748 | [
"MIT"
] | null | null | null | Generator/combination.cpp | 636F57/Algos | 92f0f637391652dfc8baa5c394322b849e590748 | [
"MIT"
] | null | null | null | /* combination.cpp
**
** Generates a list of all possible combination of choosing m elements out of the given type-T array.
**
** compiled and tested with g++ 6.2.0 MinGW-W64
**
** MIT License
** Copyright (c) 2017 636F57@GitHub
** See more detail at https://github.com/636F57/Algos/blob/master/LICENSE
*/
#include ... | 23.675 | 111 | 0.63358 | 636F57 |
cecdcd34336b19fa7da0a5a608b34883557d8c79 | 74,610 | cc | C++ | NFComm/NFMessageDefine/NFMsgBaseEx.pb.cc | sosan/NoahGameFrame | 38c54014c5c4620b784b2c1d2cab256f42bae186 | [
"Apache-2.0"
] | 1 | 2016-05-24T12:38:05.000Z | 2016-05-24T12:38:05.000Z | NFComm/NFMessageDefine/NFMsgBaseEx.pb.cc | sosan/NoahGameFrame | 38c54014c5c4620b784b2c1d2cab256f42bae186 | [
"Apache-2.0"
] | null | null | null | NFComm/NFMessageDefine/NFMsgBaseEx.pb.cc | sosan/NoahGameFrame | 38c54014c5c4620b784b2c1d2cab256f42bae186 | [
"Apache-2.0"
] | 1 | 2017-12-29T06:49:20.000Z | 2017-12-29T06:49:20.000Z | // Generated by the protocol buffer compiler. DO NOT EDIT!
// source: NFMsgBaseEx.proto
#define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION
#include "NFMsgBaseEx.pb.h"
#include <algorithm>
#include <google/protobuf/stubs/common.h>
#include <google/protobuf/stubs/once.h>
#include <google/protobuf/io/coded_stream.h>... | 33.547662 | 109 | 0.695858 | sosan |
cedd898b3492da479ae92846e7c2fddeea17057f | 452 | cpp | C++ | android-ndk-r10b/tests/device/test-stlport_static-exception/jni/new23.cpp | perezite/Boost4Android | 9ed03a45815aead156c129da1927cc04b8caa6a3 | [
"BSL-1.0"
] | 7 | 2020-05-02T17:34:05.000Z | 2021-10-17T10:15:18.000Z | android-ndk-r10b/tests/device/test-stlport_static-exception/jni/new23.cpp | perezite/Boost4Android | 9ed03a45815aead156c129da1927cc04b8caa6a3 | [
"BSL-1.0"
] | null | null | null | android-ndk-r10b/tests/device/test-stlport_static-exception/jni/new23.cpp | perezite/Boost4Android | 9ed03a45815aead156c129da1927cc04b8caa6a3 | [
"BSL-1.0"
] | 2 | 2020-07-27T00:22:36.000Z | 2021-04-01T09:41:02.000Z | // PR c++/33025
// { dg-do run }
// { dg-options "-O2" }
typedef __SIZE_TYPE__ size_t;
inline void *operator new (size_t, void *p) throw () { return p; }
extern "C" void abort ();
int
main()
{
const unsigned num = 10;
unsigned *data = new unsigned[2 * num];
unsigned *ptr = data;
for (unsigned i = 0; i < 2 * n... | 21.52381 | 69 | 0.564159 | perezite |
cede86a75074ccbe7e6c963f8307f5f1f8b1a13e | 15,178 | hpp | C++ | test/unit/device/vector_iterator.hpp | mkarunan/rocWMMA | 390a2e793699a1e17c18e46d7fe51e245907f012 | [
"MIT"
] | null | null | null | test/unit/device/vector_iterator.hpp | mkarunan/rocWMMA | 390a2e793699a1e17c18e46d7fe51e245907f012 | [
"MIT"
] | 1 | 2022-03-16T20:41:26.000Z | 2022-03-16T20:41:26.000Z | test/unit/device/vector_iterator.hpp | mkarunan/rocWMMA | 390a2e793699a1e17c18e46d7fe51e245907f012 | [
"MIT"
] | 2 | 2022-03-17T16:47:29.000Z | 2022-03-18T14:12:22.000Z | /*******************************************************************************
*
* MIT License
*
* Copyright 2021-2022 Advanced Micro Devices, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
*... | 33.505519 | 93 | 0.550534 | mkarunan |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.