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 108 | 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 67k ⌀ | 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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
4ee10cf2ef4edf67df6d4bc3679dec9fabbefee4 | 2,112 | cpp | C++ | Vulkan/jni/bor.vulkan.structs.VkMemoryType.cpp | AlessandroBorges/Bor_Vulkan | 3847e6f44ce7f14dfc1e671a6cc51eb4788e4e4b | [
"MIT"
] | 14 | 2016-02-29T12:30:05.000Z | 2020-09-17T11:30:50.000Z | Vulkan/jni/bor.vulkan.structs.VkMemoryType.cpp | AlessandroBorges/Bor_Vulkan | 3847e6f44ce7f14dfc1e671a6cc51eb4788e4e4b | [
"MIT"
] | 2 | 2016-09-13T18:02:55.000Z | 2019-11-03T01:54:20.000Z | Vulkan/jni/bor.vulkan.structs.VkMemoryType.cpp | AlessandroBorges/Bor_Vulkan | 3847e6f44ce7f14dfc1e671a6cc51eb4788e4e4b | [
"MIT"
] | 5 | 2017-09-19T03:09:06.000Z | 2021-11-23T20:20:52.000Z | #include <bor.vulkan.structs.VkMemoryType.h>
//@line:39
#include <BorVulkan.hpp>
JNIEXPORT void JNICALL Java_bor_vulkan_structs_VkMemoryType_setPropertyFlags0(JNIEnv* env, jclass clazz, jobject obj_ptr, jint _propertyFlags) {
unsigned char* ptr = (unsigned char*)(obj_ptr?env->GetDirectBufferAddress(obj_ptr) ... | 30.171429 | 148 | 0.767045 | AlessandroBorges |
4ee1a8522f2f5b0f19dc50c1663d47148182d0fb | 3,492 | cc | C++ | unit_test/operators/maxpool2d.cc | shi510/mlfe | aec8d52ddb54ce6f6e00a6515d7023ffba9d02f0 | [
"MIT"
] | 13 | 2019-01-23T11:21:01.000Z | 2021-06-20T18:25:11.000Z | unit_test/operators/maxpool2d.cc | shi510/mlfe | aec8d52ddb54ce6f6e00a6515d7023ffba9d02f0 | [
"MIT"
] | null | null | null | unit_test/operators/maxpool2d.cc | shi510/mlfe | aec8d52ddb54ce6f6e00a6515d7023ffba9d02f0 | [
"MIT"
] | 4 | 2018-01-08T12:40:22.000Z | 2021-12-02T05:23:36.000Z | #include <gtest/gtest.h>
#include <mlfe/operators/maxpool2d.h>
#include <mlfe/utils/gradient_checker.h>
#include <random>
using namespace mlfe;
using namespace mlfe::operators;
namespace fn = mlfe::functional;
TEST(operator, maxpool2d_k2_s2){
using T = float;
constexpr int B = 1;
constexpr int C = 2;
... | 25.489051 | 53 | 0.471363 | shi510 |
4ee29d5c6af77bc3a98271fac17a1572e89c63c0 | 1,160 | cpp | C++ | catboost/libs/helpers/ut/sample_ut.cpp | jochenater/catboost | de2786fbc633b0d6ea6a23b3862496c6151b95c2 | [
"Apache-2.0"
] | 6,989 | 2017-07-18T06:23:18.000Z | 2022-03-31T15:58:36.000Z | catboost/libs/helpers/ut/sample_ut.cpp | birichie/catboost | de75c6af12cf490700e76c22072fbdc15b35d679 | [
"Apache-2.0"
] | 1,978 | 2017-07-18T09:17:58.000Z | 2022-03-31T14:28:43.000Z | catboost/libs/helpers/ut/sample_ut.cpp | birichie/catboost | de75c6af12cf490700e76c22072fbdc15b35d679 | [
"Apache-2.0"
] | 1,228 | 2017-07-18T09:03:13.000Z | 2022-03-29T05:57:40.000Z | #include <catboost/libs/helpers/sample.h>
#include <util/generic/hash_set.h>
#include <library/cpp/testing/unittest/registar.h>
using namespace NCB;
Y_UNIT_TEST_SUITE(TSampleIndicesTest) {
template<class T>
void CheckOneCase(size_t n, size_t k) {
TRestorableFastRng64 rand(0);
const TVecto... | 26.976744 | 72 | 0.615517 | jochenater |
4ee3fdadfd9b232f59bcc391252582692619b014 | 735 | cpp | C++ | 3. Longest Substring Without Repeating Characters.cpp | TIAN-2001/leetcode | 90374b976a1db24c0cb4ebf25593aad0207e3706 | [
"Apache-2.0"
] | null | null | null | 3. Longest Substring Without Repeating Characters.cpp | TIAN-2001/leetcode | 90374b976a1db24c0cb4ebf25593aad0207e3706 | [
"Apache-2.0"
] | null | null | null | 3. Longest Substring Without Repeating Characters.cpp | TIAN-2001/leetcode | 90374b976a1db24c0cb4ebf25593aad0207e3706 | [
"Apache-2.0"
] | null | null | null | // sliding window / two pointers
class Solution {
public:
int lengthOfLongestSubstring(string s) {
int res = 0;
if(s.length() == 0)
return res;
int left = 0;
int right = 0;
unordered_map<char,int> mp;
char c;
while(right < s.lengt... | 22.96875 | 62 | 0.334694 | TIAN-2001 |
4ee47dc1579a574eed49824fe47fd23fbd770b78 | 6,376 | cc | C++ | components/variations/field_trial_config/field_trial_util.cc | zipated/src | 2b8388091c71e442910a21ada3d97ae8bc1845d3 | [
"BSD-3-Clause"
] | 2,151 | 2020-04-18T07:31:17.000Z | 2022-03-31T08:39:18.000Z | components/variations/field_trial_config/field_trial_util.cc | cangulcan/src | 2b8388091c71e442910a21ada3d97ae8bc1845d3 | [
"BSD-3-Clause"
] | 395 | 2020-04-18T08:22:18.000Z | 2021-12-08T13:04:49.000Z | components/variations/field_trial_config/field_trial_util.cc | cangulcan/src | 2b8388091c71e442910a21ada3d97ae8bc1845d3 | [
"BSD-3-Clause"
] | 338 | 2020-04-18T08:03:10.000Z | 2022-03-29T12:33:22.000Z | // Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "components/variations/field_trial_config/field_trial_util.h"
#include <stddef.h>
#include <string>
#include <vector>
#include "base/command_l... | 35.820225 | 79 | 0.675502 | zipated |
4ee600fac45e55d775f4ed0e974b4dafa265f1c4 | 2,216 | cc | C++ | src/logkafka/file_position_entry.cc | Qihoo360/logkafka | f329b5a9806e0b0f716884759edbe54e72e4dec0 | [
"MIT"
] | 568 | 2015-06-23T07:41:50.000Z | 2022-03-30T11:32:05.000Z | src/logkafka/file_position_entry.cc | Qihoo360/logkafka | f329b5a9806e0b0f716884759edbe54e72e4dec0 | [
"MIT"
] | 26 | 2015-09-27T07:25:31.000Z | 2021-07-25T13:30:09.000Z | src/logkafka/file_position_entry.cc | Qihoo360/logkafka | f329b5a9806e0b0f716884759edbe54e72e4dec0 | [
"MIT"
] | 138 | 2015-06-23T07:41:50.000Z | 2021-12-13T02:31:40.000Z | ///////////////////////////////////////////////////////////////////////////
//
// logkafka - Collect logs and send lines to Apache Kafka v0.8+
//
///////////////////////////////////////////////////////////////////////////
//
// Copyright (c) 2015 Qihoo 360 Technology Co., Ltd. All rights reserved.
//
// Licensed under ... | 30.777778 | 75 | 0.603791 | Qihoo360 |
4ee9a23806391c6723a2a998e4565d221823d456 | 337 | hpp | C++ | src/graphics/TestWindow.hpp | TobiasNienhaus/npp | ff6023ad5c160240cbaa029dce065b2cdf58ae74 | [
"MIT"
] | null | null | null | src/graphics/TestWindow.hpp | TobiasNienhaus/npp | ff6023ad5c160240cbaa029dce065b2cdf58ae74 | [
"MIT"
] | null | null | null | src/graphics/TestWindow.hpp | TobiasNienhaus/npp | ff6023ad5c160240cbaa029dce065b2cdf58ae74 | [
"MIT"
] | null | null | null | //
// Created by Tobias on 1/5/2021.
//
#ifndef NPP_TESTWINDOW_HPP
#define NPP_TESTWINDOW_HPP
#include "Win32Context.hpp"
class TestWindow : public Win32Context<TestWindow> {
public:
[[nodiscard]] LPCWSTR class_name() const override;
LRESULT handle_message(UINT msg, WPARAM wp, LPARAM lp) override;
};
#endif // NP... | 19.823529 | 65 | 0.759644 | TobiasNienhaus |
4eea6555b105295ce9dad341ada76a386bc7f836 | 2,539 | cpp | C++ | src/anytime.cpp | erdos-project/frenet-optimal-trajectory-planner | ba0cb5662a0e2ea668b1c2b2951c0f6b84f44f5b | [
"Apache-2.0"
] | null | null | null | src/anytime.cpp | erdos-project/frenet-optimal-trajectory-planner | ba0cb5662a0e2ea668b1c2b2951c0f6b84f44f5b | [
"Apache-2.0"
] | null | null | null | src/anytime.cpp | erdos-project/frenet-optimal-trajectory-planner | ba0cb5662a0e2ea668b1c2b2951c0f6b84f44f5b | [
"Apache-2.0"
] | 1 | 2020-03-07T01:49:50.000Z | 2020-03-07T01:49:50.000Z | #include "AnytimeFrenetOptimalTrajectory.h"
#include "FrenetPath.h"
#include "py_cpp_struct.h"
#include <iostream>
#include <assert.h>
#include <unistd.h>
using namespace std;
int main() {
double wx [25] = {132.67, 128.67, 124.67, 120.67, 116.67, 112.67, 108.67,
104.67, 101.43, 97.77, 94.84... | 24.413462 | 90 | 0.493895 | erdos-project |
4eeb627169bedae2d2155591f0d9cbfc63e7cb55 | 2,824 | cpp | C++ | vm/external_libs/llvm/tools/llvmc2/llvmc.cpp | marnen/rubinius | 05b3f9789d01bada0604a7f09921c956bc9487e7 | [
"BSD-3-Clause"
] | 1 | 2016-05-08T16:58:14.000Z | 2016-05-08T16:58:14.000Z | vm/external_libs/llvm/tools/llvmc2/llvmc.cpp | taf2/rubinius | 493bfa2351fc509ca33d3bb03991c2e9c2b6dafa | [
"BSD-3-Clause"
] | null | null | null | vm/external_libs/llvm/tools/llvmc2/llvmc.cpp | taf2/rubinius | 493bfa2351fc509ca33d3bb03991c2e9c2b6dafa | [
"BSD-3-Clause"
] | null | null | null | //===--- llvmc.cpp - The LLVM Compiler Driver ------------------*- C++ -*-===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open
// Source License. See LICENSE.TXT for details.
//
//===--------------------------------------------------------... | 27.417476 | 80 | 0.549929 | marnen |
4ef2b7d19d0802d49f65ebbc5eddc3e341ee57eb | 717 | cpp | C++ | src/propagation/types/value_context_ordering.cpp | RMGiroux/clangmetatool | 38071867d56a9c5dfa4fac1eb298b8058a026acd | [
"Apache-2.0"
] | null | null | null | src/propagation/types/value_context_ordering.cpp | RMGiroux/clangmetatool | 38071867d56a9c5dfa4fac1eb298b8058a026acd | [
"Apache-2.0"
] | null | null | null | src/propagation/types/value_context_ordering.cpp | RMGiroux/clangmetatool | 38071867d56a9c5dfa4fac1eb298b8058a026acd | [
"Apache-2.0"
] | null | null | null | #include "value_context_ordering.h"
namespace clangmetatool {
namespace propagation {
namespace types {
void ValueContextOrdering::print(std::ostream &stream, Value value) {
switch (value) {
case ValueContextOrdering::CONTROL_FLOW_MERGE:
stream << "Control flow merge";
break;
case ValueContextOrdering::... | 23.129032 | 80 | 0.728033 | RMGiroux |
4ef3bd8789d4e15e40a9dccdc5743feff5a98df6 | 519 | cpp | C++ | src/util/nm_log.cpp | nolmoonen/pbr | c5ed37795c8e67de1716762206fe7c58e9079ac0 | [
"MIT"
] | null | null | null | src/util/nm_log.cpp | nolmoonen/pbr | c5ed37795c8e67de1716762206fe7c58e9079ac0 | [
"MIT"
] | null | null | null | src/util/nm_log.cpp | nolmoonen/pbr | c5ed37795c8e67de1716762206fe7c58e9079ac0 | [
"MIT"
] | null | null | null | #include "nm_log.hpp"
const char *const nm_log::LEVEL_NAMES[] = {
"TRACE", "INFO ", "WARN ", "ERROR"
};
log_level_e nm_log::m_level = LOG_TRACE;
void nm_log::set_log_level(log_level_e t_level)
{
m_level = t_level;
}
void nm_log::log(log_level_e t_level, const char *t_format, ...)
{
if (t_level >= m_... | 21.625 | 64 | 0.624277 | nolmoonen |
4ef3d0ae2a286a4ee6a1f5480b6113fdbe4af7e5 | 1,303 | cpp | C++ | src/main.cpp | dancol90/wifi-led-clock | d4d391226ddc26ff92fd894e184c5348953b3bfa | [
"MIT"
] | 2 | 2018-10-10T12:37:05.000Z | 2018-12-07T22:36:42.000Z | src/main.cpp | dancol90/wifi-led-clock | d4d391226ddc26ff92fd894e184c5348953b3bfa | [
"MIT"
] | null | null | null | src/main.cpp | dancol90/wifi-led-clock | d4d391226ddc26ff92fd894e184c5348953b3bfa | [
"MIT"
] | null | null | null | /*
Drivers (still services):
- [OK] Led display
- [OK] Time
- [OK] WiFi
- [OK] File System
List of needed services:
- [OK] Scroll management
- [OK] Configuration (over SPIFFS)
- [OK*] HTTP Server (?)
- [OK] NTP
- MQTT handling
*/
#include <Arduino.h>
#include "Service.hpp"
#include "dr... | 19.447761 | 43 | 0.6132 | dancol90 |
4ef4d8b1a1af8be443fee78f25a6ba05823fccf0 | 3,226 | cpp | C++ | cpp/varint/leveldb/varint.cpp | yyyshi/asshole_algorithm | 270460f2afcdb7a00a08979053e8cfb80ef93b5b | [
"Apache-2.0"
] | null | null | null | cpp/varint/leveldb/varint.cpp | yyyshi/asshole_algorithm | 270460f2afcdb7a00a08979053e8cfb80ef93b5b | [
"Apache-2.0"
] | null | null | null | cpp/varint/leveldb/varint.cpp | yyyshi/asshole_algorithm | 270460f2afcdb7a00a08979053e8cfb80ef93b5b | [
"Apache-2.0"
] | null | null | null | // encode
char* EncodeVarint32(char* dst, uint32_t v) {
// Operate on characters as unsigneds
uint8_t* ptr = reinterpret_cast<uint8_t*>(dst);
static const int B = 128;
if (v < (1 << 7)) {
*(ptr++) = v;
} else if (v < (1 << 14)) {
*(ptr++) = v | B;
*(ptr++) = v >> 7;
} else if (v < (1 << 21)) {
... | 26.442623 | 79 | 0.534408 | yyyshi |
4ef5cbcff6de89035266d99fb15b388ad952f900 | 22,080 | cpp | C++ | src/game/server/laserText.cpp | 35niavlys/teeworlds-fng2-mod | d73be893c060fb3832656679d7756a5c42bca7cc | [
"Zlib"
] | null | null | null | src/game/server/laserText.cpp | 35niavlys/teeworlds-fng2-mod | d73be893c060fb3832656679d7756a5c42bca7cc | [
"Zlib"
] | 3 | 2020-05-31T06:36:51.000Z | 2020-09-11T08:34:36.000Z | src/game/server/laserText.cpp | 35niavlys/teeworlds-fng2-mod | d73be893c060fb3832656679d7756a5c42bca7cc | [
"Zlib"
] | 1 | 2021-09-04T11:32:33.000Z | 2021-09-04T11:32:33.000Z | /* (c) Magnus Auvinen. See licence.txt in the root of the distribution for more information. */
/* If you are missing that file, acquire a complete release at teeworlds.com. */
#include <game/generated/protocol.h>
#include <game/server/gamecontext.h>
#include "laserText.h"
#include <string.h>
static con... | 43.722772 | 160 | 0.417029 | 35niavlys |
4ef77cb8295f8f1e90370c72d417ed17e70c0bd2 | 537 | hpp | C++ | engine/generators/crypts/include/ICryptLayoutStrategy.hpp | sidav/shadow-of-the-wyrm | 747afdeebed885b1a4f7ab42f04f9f756afd3e52 | [
"MIT"
] | null | null | null | engine/generators/crypts/include/ICryptLayoutStrategy.hpp | sidav/shadow-of-the-wyrm | 747afdeebed885b1a4f7ab42f04f9f756afd3e52 | [
"MIT"
] | null | null | null | engine/generators/crypts/include/ICryptLayoutStrategy.hpp | sidav/shadow-of-the-wyrm | 747afdeebed885b1a4f7ab42f04f9f756afd3e52 | [
"MIT"
] | null | null | null | #pragma once
#include <tuple>
#include "common.hpp"
#include "Directions.hpp"
#include "Map.hpp"
// Interface for defining crypt layout strategies. These operate on a
// given map and crypt boundary, producing the characteristic look of the
// crypt: pillars, rooms, a central vault, etc.
class ICryptLayoutStrategy
{
... | 29.833333 | 130 | 0.772812 | sidav |
f600003f47e60792dabea9657b35e02919c55e2e | 2,956 | hpp | C++ | common/SoapySSDPEndpoint.hpp | bastille-attic/SoapyRemote | 63664b890ccfe2d5472901b879b1593aacc92ef1 | [
"BSL-1.0"
] | null | null | null | common/SoapySSDPEndpoint.hpp | bastille-attic/SoapyRemote | 63664b890ccfe2d5472901b879b1593aacc92ef1 | [
"BSL-1.0"
] | null | null | null | common/SoapySSDPEndpoint.hpp | bastille-attic/SoapyRemote | 63664b890ccfe2d5472901b879b1593aacc92ef1 | [
"BSL-1.0"
] | null | null | null | // Copyright (c) 2015-2016 Josh Blum
// SPDX-License-Identifier: BSL-1.0
#pragma once
#include "SoapyRPCSocket.hpp"
#include <string>
#include <csignal> //sig_atomic_t
#include <mutex>
#include <vector>
#include <memory>
class SoapyHTTPHeader;
struct SoapySSDPEndpointData;
/*!
* Service an SSDP endpoint to:
* keep... | 31.784946 | 116 | 0.715832 | bastille-attic |
f6005e2eaa3c6d0eeb1b64e27da3234b58af2f2f | 8,489 | cpp | C++ | src/engine.cpp | mbeckem/extpp | 06aa153ebf617c779e66d612cfc11e01869c602a | [
"MIT"
] | 1 | 2018-05-22T15:47:14.000Z | 2018-05-22T15:47:14.000Z | src/engine.cpp | mbeckem/prequel | 06aa153ebf617c779e66d612cfc11e01869c602a | [
"MIT"
] | null | null | null | src/engine.cpp | mbeckem/prequel | 06aa153ebf617c779e66d612cfc11e01869c602a | [
"MIT"
] | null | null | null | #include <prequel/engine.hpp>
#include <prequel/deferred.hpp>
#include <boost/intrusive/list.hpp>
#include <boost/intrusive/list_hook.hpp>
#include <boost/intrusive/set.hpp>
#include <boost/intrusive/set_hook.hpp>
namespace prequel {
namespace detail {
// This is the real implementation of block handles,
// it con... | 31.324723 | 102 | 0.668512 | mbeckem |
f607384ccf495e4bbd424b3041424762de927e46 | 4,460 | cpp | C++ | clicache/src/Execution.cpp | rhoughton-pivot/geode-native | ab6fe7d996e5ec23832f90663d03f1d66b9f5fbd | [
"Apache-2.0"
] | 1 | 2018-09-08T05:05:22.000Z | 2018-09-08T05:05:22.000Z | clicache/src/Execution.cpp | rhoughton-pivot/geode-native | ab6fe7d996e5ec23832f90663d03f1d66b9f5fbd | [
"Apache-2.0"
] | 1 | 2020-10-05T11:41:41.000Z | 2020-10-05T11:41:41.000Z | clicache/src/Execution.cpp | rhoughton-pivot/geode-native | ab6fe7d996e5ec23832f90663d03f1d66b9f5fbd | [
"Apache-2.0"
] | null | null | null | /*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may ... | 33.787879 | 150 | 0.634081 | rhoughton-pivot |
f60875c75cf897e0084395bae0c133aa63f02728 | 1,145 | cpp | C++ | src/tmp/student.cpp | asankagit/wacms | f6ecf9e1c740417a934acb8f6c53e2bb3388b5ee | [
"MIT"
] | 5 | 2021-10-14T07:27:31.000Z | 2022-01-04T17:20:15.000Z | src/tmp/student.cpp | asankagit/wacms | f6ecf9e1c740417a934acb8f6c53e2bb3388b5ee | [
"MIT"
] | null | null | null | src/tmp/student.cpp | asankagit/wacms | f6ecf9e1c740417a934acb8f6c53e2bb3388b5ee | [
"MIT"
] | null | null | null | // similar to MyClass, in this we are testing header file usage
#include <student.h>
#include "emscripten/bind.h"
using namespace emscripten;
Student::Student() {
}
void Student::setName(std::string name) {
this->name = name;
}
const std::string& Student::getName() {
for(int i=0; i<10000; i++) {
... | 21.203704 | 70 | 0.637555 | asankagit |
f60aebecafaaaf52fe9d95041c392350f6185103 | 1,531 | cpp | C++ | common/comline.cpp | yalehwy/linepw | 8e22ffaa49fa49dca44a6a8d6e38a16a64a41aa0 | [
"Apache-2.0"
] | null | null | null | common/comline.cpp | yalehwy/linepw | 8e22ffaa49fa49dca44a6a8d6e38a16a64a41aa0 | [
"Apache-2.0"
] | null | null | null | common/comline.cpp | yalehwy/linepw | 8e22ffaa49fa49dca44a6a8d6e38a16a64a41aa0 | [
"Apache-2.0"
] | null | null | null | #include "comline.hpp"
#define MOVESPACE 1
ComLine::ComLine()
{
map = new std::map<std::string, std::string>;
}
ComLine::~ComLine()
{
if (map)
{
delete map;
map = nullptr;
}
}
std::map<std::string, std::string>*
ComLine::getKeyValue(int argc, char* argv[])
{
for (int i = 1; i < argc; i++)
{
... | 21.263889 | 71 | 0.546048 | yalehwy |
f60b2bff941743aab59e7234d6a06828b5cdebf4 | 2,096 | cpp | C++ | Algorithms/0140.Word_Break_II.cpp | metehkaya/LeetCode | 52f4a1497758c6f996d515ced151e8783ae4d4d2 | [
"MIT"
] | 2 | 2020-07-20T06:40:22.000Z | 2021-11-20T01:23:26.000Z | Problems/LeetCode/Problems/0140.Word_Break_II.cpp | metehkaya/Algo-Archive | 03b5fdcf06f84a03125c57762c36a4e03ca6e756 | [
"MIT"
] | null | null | null | Problems/LeetCode/Problems/0140.Word_Break_II.cpp | metehkaya/Algo-Archive | 03b5fdcf06f84a03125c57762c36a4e03ca6e756 | [
"MIT"
] | null | null | null | typedef vector<int> vi;
typedef vector<string> vs;
class Node {
public:
bool isWord;
vector<Node*> child;
Node() {
isWord = false;
child.resize(26,NULL);
}
}*root;
class Solution {
public:
void solve(int i , int n , string& s , vi& last , string& word , vs& ans) {
if(i == n... | 27.946667 | 79 | 0.354485 | metehkaya |
f60eb6100c61281118c2d2ee25a3127f2f91d7e9 | 228 | cpp | C++ | 010-files/src/FilesBefore.cpp | platisd/refactoring-for-testablity-cpp | 126ee079c73c169bae8a31a2f2ccdc873e819cca | [
"MIT"
] | 33 | 2020-04-18T22:43:57.000Z | 2022-02-01T23:48:34.000Z | 010-files/src/FilesBefore.cpp | platisd/refactoring-for-testablity-cpp | 126ee079c73c169bae8a31a2f2ccdc873e819cca | [
"MIT"
] | null | null | null | 010-files/src/FilesBefore.cpp | platisd/refactoring-for-testablity-cpp | 126ee079c73c169bae8a31a2f2ccdc873e819cca | [
"MIT"
] | 7 | 2020-04-23T00:39:09.000Z | 2021-11-10T15:05:33.000Z | #include "FileEncoder.hpp"
using namespace before;
namespace
{
const auto kFilePath = "write.txt"; // File with some contents
}
int main()
{
FileEncoder f;
const auto r = f.encode(kFilePath);
return r ? 0 : 1;
}
| 13.411765 | 62 | 0.657895 | platisd |
f6121cfdbab82fc640601de7f28d2d1300055ee8 | 8,281 | cpp | C++ | examples/prepared_statement.cpp | tstrutz/sqlite_orm | 1ee0a8653fe57ed4d4f69b5a65839b1861c41d32 | [
"BSD-3-Clause"
] | 1,566 | 2016-12-20T15:31:04.000Z | 2022-03-31T18:17:34.000Z | examples/prepared_statement.cpp | tstrutz/sqlite_orm | 1ee0a8653fe57ed4d4f69b5a65839b1861c41d32 | [
"BSD-3-Clause"
] | 620 | 2017-01-06T13:53:35.000Z | 2022-03-31T12:05:50.000Z | examples/prepared_statement.cpp | tstrutz/sqlite_orm | 1ee0a8653fe57ed4d4f69b5a65839b1861c41d32 | [
"BSD-3-Clause"
] | 274 | 2017-01-07T05:34:24.000Z | 2022-03-27T18:22:47.000Z | /**
* There are two member functions in storage_t class which you need to use to operate with
* prepared statements: storage_t::prepare and storage_t::execute.
* Also if you need to rebind arguments just use get<N>(statement) = ... syntax
* just like you do with std::tuple.
* Once a statement is prepared it h... | 39.433333 | 115 | 0.567685 | tstrutz |
f6158dae5583f50ddac7a7d1cd73e8f50a57350b | 3,903 | cpp | C++ | 7th_100/problem650.cpp | takekoputa/project-euler | 6f434be429bd26f5d0f84f5ab0f5fa2bd677c790 | [
"MIT"
] | null | null | null | 7th_100/problem650.cpp | takekoputa/project-euler | 6f434be429bd26f5d0f84f5ab0f5fa2bd677c790 | [
"MIT"
] | null | null | null | 7th_100/problem650.cpp | takekoputa/project-euler | 6f434be429bd26f5d0f84f5ab0f5fa2bd677c790 | [
"MIT"
] | 1 | 2021-11-02T12:08:46.000Z | 2021-11-02T12:08:46.000Z | // Problem: https://projecteuler.net/problem=650
// g++ problem650.cpp -I$HOME/pari/include/ -L$HOME/pari/lib -lpari -O3
#include<pari/pari.h>
#include<iostream>
#include<vector>
#include<cmath>
#include<unordered_map>
#include<functional>
using namespace std;
#define endl "\n"
typedef int64_t i64;
const i64 N = ... | 22.958824 | 96 | 0.539329 | takekoputa |
f6159135dbe79a3aa7e933e76b3e4ee570096fbd | 1,756 | cpp | C++ | src/Magnum/MeshTools/FlipNormals.cpp | glhrmfrts/magnum | c5d08156eaa03867403c32f4b0ee6a56202331e4 | [
"MIT"
] | 1 | 2019-04-23T07:31:01.000Z | 2019-04-23T07:31:01.000Z | src/Magnum/MeshTools/FlipNormals.cpp | glhrmfrts/magnum | c5d08156eaa03867403c32f4b0ee6a56202331e4 | [
"MIT"
] | null | null | null | src/Magnum/MeshTools/FlipNormals.cpp | glhrmfrts/magnum | c5d08156eaa03867403c32f4b0ee6a56202331e4 | [
"MIT"
] | 1 | 2022-03-31T08:48:52.000Z | 2022-03-31T08:48:52.000Z | /*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
... | 38.173913 | 106 | 0.715831 | glhrmfrts |
f616f24d16b479a5662683750dc5047c412e924e | 49,886 | cpp | C++ | project4/mariadb/server/storage/connect/tabfmt.cpp | jiunbae/ITE4065 | 3b9fcf9317e93ca7c829f1438b85f0f5ea2885db | [
"MIT"
] | 11 | 2017-10-28T08:41:08.000Z | 2021-06-24T07:24:21.000Z | project4/mariadb/server/storage/connect/tabfmt.cpp | jiunbae/ITE4065 | 3b9fcf9317e93ca7c829f1438b85f0f5ea2885db | [
"MIT"
] | null | null | null | project4/mariadb/server/storage/connect/tabfmt.cpp | jiunbae/ITE4065 | 3b9fcf9317e93ca7c829f1438b85f0f5ea2885db | [
"MIT"
] | 4 | 2017-09-07T09:33:26.000Z | 2021-02-19T07:45:08.000Z | /************* TabFmt C++ Program Source Code File (.CPP) **************/
/* PROGRAM NAME: TABFMT */
/* ------------- */
/* Version 3.9.2 */
/* ... | 31.916827 | 77 | 0.434972 | jiunbae |
f617dbf2f2a635fcb5e8a5a3993d00b80ded8790 | 13,969 | cpp | C++ | sources/cpp/wasmint/main.cpp | xunilrj/sandbox | f92c12f83433cac01a885585e41c02bb5826a01f | [
"Apache-2.0"
] | 7 | 2017-04-01T17:18:35.000Z | 2022-01-12T05:23:23.000Z | sources/cpp/wasmint/main.cpp | xunilrj/sandbox | f92c12f83433cac01a885585e41c02bb5826a01f | [
"Apache-2.0"
] | 6 | 2020-05-24T13:36:50.000Z | 2022-02-15T06:44:20.000Z | sources/cpp/wasmint/main.cpp | xunilrj/sandbox | f92c12f83433cac01a885585e41c02bb5826a01f | [
"Apache-2.0"
] | 2 | 2018-09-20T01:07:39.000Z | 2019-02-22T14:55:38.000Z | #define CATCH_CONFIG_MAIN
#include "../catch/catch.hpp"
#include <Windows.h>
#include <string>
#include <stack>
#include <unordered_map>
template <typename T>
T &read(uint8_t *&p)
{
auto *ptr = (T *)p;
p += sizeof(T);
return *ptr;
}
uint32_t readULEB128(uint8_t *&p)
{
uint32_t result = 0;
uint3... | 23.919521 | 129 | 0.455222 | xunilrj |
f619649cdc5f0e650489a927b1e3198de377f5df | 5,105 | cpp | C++ | GlobalIllumination/src/Material.cpp | raptoravis/voxelbasedgi | aaf2b02929edfaf72528c2f029696728c5f1d30f | [
"MIT"
] | null | null | null | GlobalIllumination/src/Material.cpp | raptoravis/voxelbasedgi | aaf2b02929edfaf72528c2f029696728c5f1d30f | [
"MIT"
] | null | null | null | GlobalIllumination/src/Material.cpp | raptoravis/voxelbasedgi | aaf2b02929edfaf72528c2f029696728c5f1d30f | [
"MIT"
] | null | null | null | #include <stdafx.h>
#include <Demo.h>
#include <Material.h>
#define NUM_RENDER_STATES 27 // number of render-states that can be specified in material file
struct MaterialInfo
{
const char *name; // info as string
int mode; // info as int
};
// render-states
static const MaterialInfo renderStateList[NUM_RENDER_STAT... | 26.045918 | 94 | 0.697747 | raptoravis |
f61998985015980fbba5f72e69a6f51ebff9ea8e | 13,031 | cpp | C++ | QP/v5.4.2/qpcpp/examples/lwip/arm-cm/lwip_ek-lm3s6965/lwipmgr.cpp | hyller/GladiatorCots | 36a69df68675bb40b562081c531e6674037192a8 | [
"Unlicense"
] | null | null | null | QP/v5.4.2/qpcpp/examples/lwip/arm-cm/lwip_ek-lm3s6965/lwipmgr.cpp | hyller/GladiatorCots | 36a69df68675bb40b562081c531e6674037192a8 | [
"Unlicense"
] | null | null | null | QP/v5.4.2/qpcpp/examples/lwip/arm-cm/lwip_ek-lm3s6965/lwipmgr.cpp | hyller/GladiatorCots | 36a69df68675bb40b562081c531e6674037192a8 | [
"Unlicense"
] | null | null | null | //****************************************************************************
// Product: lwIP-Manager Active Object
// Last Updated for Version: 5.4.0
// Date of the Last Update: 2015-05-12
//
// Q u a n t u m L e a P s
// ---------------------------
// in... | 37.771014 | 78 | 0.514159 | hyller |
f619fc1aac3f323fb765aa700b3ab4e0cfd251b2 | 2,027 | hpp | C++ | src/configure/Platform.hpp | hotgloupi/configure | 888cf725c93df5a1cf01794cc0a581586a82855c | [
"BSD-3-Clause"
] | 1 | 2015-11-13T10:37:35.000Z | 2015-11-13T10:37:35.000Z | src/configure/Platform.hpp | hotgloupi/configure | 888cf725c93df5a1cf01794cc0a581586a82855c | [
"BSD-3-Clause"
] | 19 | 2015-02-10T17:18:58.000Z | 2015-07-11T11:31:08.000Z | src/configure/Platform.hpp | hotgloupi/configure | 888cf725c93df5a1cf01794cc0a581586a82855c | [
"BSD-3-Clause"
] | null | null | null | #pragma once
#include <iosfwd>
#include <string>
namespace configure {
class Platform
{
public:
enum class Vendor {
unknown,
pc,
apple,
};
enum class Arch {
unknown,
x86,
x86_64,
};
enum class SubArch {
unknown,
};
enum class OS {
unknown,
windows,
linux,
osx,
... | 20.896907 | 71 | 0.660582 | hotgloupi |
f61eada41d605c8284e0bbb196d25322ae8faab8 | 2,103 | cc | C++ | common/config.cc | yonsei-icsl/nebula | 12bc2440978018d27996df6b97180056dddefa6c | [
"BSD-3-Clause"
] | 5 | 2020-02-13T04:12:41.000Z | 2021-02-08T04:53:55.000Z | common/config.cc | yonsei-icsl/Nebula | 12bc2440978018d27996df6b97180056dddefa6c | [
"BSD-3-Clause"
] | 1 | 2020-10-29T10:59:08.000Z | 2020-12-31T04:04:58.000Z | common/config.cc | yonsei-icsl/Nebula | 12bc2440978018d27996df6b97180056dddefa6c | [
"BSD-3-Clause"
] | 2 | 2021-03-21T02:45:40.000Z | 2022-03-10T12:31:06.000Z | #include <algorithm>
#include <assert.h>
#include <cstdlib>
#include <fstream>
#include <iostream>
#include <locale>
#include "config.h"
#include "utils.h"
namespace nebula {
// Configuration section
section_config_t::section_config_t(std::string m_name) :
name(m_name) {
}
section_config_t::~section_config_t() {... | 26.620253 | 94 | 0.603899 | yonsei-icsl |
f6228685796ff7236425071c249c5df5c898b8a9 | 9,517 | cpp | C++ | src/devices/bus/nes/tengen.cpp | Robbbert/messui | 49b756e2140d8831bc81335298ee8c5471045e79 | [
"BSD-3-Clause"
] | 26 | 2015-03-31T06:25:51.000Z | 2021-12-14T09:29:04.000Z | src/devices/bus/nes/tengen.cpp | Robbbert/messui | 49b756e2140d8831bc81335298ee8c5471045e79 | [
"BSD-3-Clause"
] | null | null | null | src/devices/bus/nes/tengen.cpp | Robbbert/messui | 49b756e2140d8831bc81335298ee8c5471045e79 | [
"BSD-3-Clause"
] | 10 | 2015-03-27T05:45:51.000Z | 2022-02-04T06:57:36.000Z | // license:BSD-3-Clause
// copyright-holders:Fabio Priuli
/***********************************************************************************************************
NES/Famicom cartridge emulation for Tengen PCBs
Here we emulate the following PCBs
* Tengen 800008
* Tengen 800032 [mapper 64]
* Tengen 800037 ... | 25.31117 | 170 | 0.65777 | Robbbert |
f622a2d64454d726a5561d310bfe9e66cbfc56c8 | 289 | hpp | C++ | engine/src/Resources/ImageData.hpp | aleksigron/graphics-toolkit | f8e60c57316a72dff9de07512e9771deb3799208 | [
"MIT"
] | 14 | 2017-10-17T16:20:20.000Z | 2021-12-21T14:49:00.000Z | engine/src/Resources/ImageData.hpp | aleksigron/graphics-toolkit | f8e60c57316a72dff9de07512e9771deb3799208 | [
"MIT"
] | null | null | null | engine/src/Resources/ImageData.hpp | aleksigron/graphics-toolkit | f8e60c57316a72dff9de07512e9771deb3799208 | [
"MIT"
] | 1 | 2019-05-12T13:50:23.000Z | 2019-05-12T13:50:23.000Z | #pragma once
#include <cstddef>
#include "Math/Vec2.hpp"
struct ImageData
{
unsigned char* imageData;
size_t imageDataSize;
Vec2i imageSize;
unsigned int pixelFormat;
unsigned int componentDataType;
size_t compressedSize;
bool compressed;
ImageData();
};
| 13.761905 | 33 | 0.705882 | aleksigron |
f624d363ac3f6f847615772a93146521aeef640b | 804 | cpp | C++ | bls_sig.cpp | ANSIIRU/BLS12_381-small_memory_c- | 6109d56c38a4c9243dcbcd0464b50feaa2f70a89 | [
"Unlicense"
] | null | null | null | bls_sig.cpp | ANSIIRU/BLS12_381-small_memory_c- | 6109d56c38a4c9243dcbcd0464b50feaa2f70a89 | [
"Unlicense"
] | null | null | null | bls_sig.cpp | ANSIIRU/BLS12_381-small_memory_c- | 6109d56c38a4c9243dcbcd0464b50feaa2f70a89 | [
"Unlicense"
] | null | null | null | #include "my_pairing.h"
#include <stdio.h>
void KeyGen(const char* s, EC_Fp2* pub, EC_Fp2* Q)
{
G2_SCM(pub, s, Q); // pub = sQ
// printf("pub=\n");
// EC_Fp2_print(pub);
}
void SignGen(EC_Fp *sign, const char* s, const char *m)
{
EC_Fp Hm;
hash_to_curve(&Hm,m);
// EC_Fp_from_Mont(&Hm);
//... | 21.72973 | 61 | 0.588308 | ANSIIRU |
f6252d2cb128d926a9df58446183d716865a9409 | 961 | cc | C++ | aoj/2/2300.cc | eagletmt/procon | adbe503eb3c1bbcc1538b2ee8988aa353937e8d4 | [
"MIT"
] | 1 | 2015-04-17T09:54:23.000Z | 2015-04-17T09:54:23.000Z | aoj/2/2300.cc | eagletmt/procon | adbe503eb3c1bbcc1538b2ee8988aa353937e8d4 | [
"MIT"
] | null | null | null | aoj/2/2300.cc | eagletmt/procon | adbe503eb3c1bbcc1538b2ee8988aa353937e8d4 | [
"MIT"
] | null | null | null | #include <iostream>
#include <cstdio>
#include <vector>
using namespace std;
struct color
{
double L, a, b;
};
inline double sqr(double x) { return x*x; }
inline double operator-(const color& lhs, const color& rhs)
{
return sqr(lhs.L - rhs.L) + sqr(lhs.a - rhs.a) + sqr(lhs.b - rhs.b);
}
int main()
{
int N, M;
... | 18.843137 | 77 | 0.488033 | eagletmt |
f6261d1897d3c4e2b3553ed526b581d863dec20b | 1,628 | cpp | C++ | Algorithms/0040.Combination_Sum_II.cpp | metehkaya/LeetCode | 52f4a1497758c6f996d515ced151e8783ae4d4d2 | [
"MIT"
] | 2 | 2020-07-20T06:40:22.000Z | 2021-11-20T01:23:26.000Z | Problems/LeetCode/Problems/0040.Combination_Sum_II.cpp | metehkaya/Algo-Archive | 03b5fdcf06f84a03125c57762c36a4e03ca6e756 | [
"MIT"
] | null | null | null | Problems/LeetCode/Problems/0040.Combination_Sum_II.cpp | metehkaya/Algo-Archive | 03b5fdcf06f84a03125c57762c36a4e03ca6e756 | [
"MIT"
] | null | null | null | #define fi first
#define se second
#define pb push_back
typedef pair<int,int> pi;
class Solution {
public:
int n,t;
vector<pi> ar;
bool dp[101][31];
vector<int> v[101][31];
vector<vector<int>> ans;
void f(int id , int k , vector<int>& curr) {
if(id == 0) {
vector<int> add;
... | 28.561404 | 66 | 0.355651 | metehkaya |
f626ac1cd81142105101fcf956b89ac1d4f0ee5f | 13,181 | cpp | C++ | test/unit/CopyPropagationTest.cpp | alanyee/redex | 35d261274571b1515e0eaec278cb8ecd79006559 | [
"BSD-3-Clause"
] | null | null | null | test/unit/CopyPropagationTest.cpp | alanyee/redex | 35d261274571b1515e0eaec278cb8ecd79006559 | [
"BSD-3-Clause"
] | null | null | null | test/unit/CopyPropagationTest.cpp | alanyee/redex | 35d261274571b1515e0eaec278cb8ecd79006559 | [
"BSD-3-Clause"
] | null | null | null | /**
* Copyright (c) 2016-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include <... | 22.041806 | 78 | 0.626053 | alanyee |
f628a6f16a9f1056b1989dcb8ae8e675ae08e8a5 | 541 | hpp | C++ | lib/AnimationStation/src/Effects/StaticColor.hpp | ez2torta/GP2040 | 50d2aaec40e02abeb6ef6d27f58de77009b19874 | [
"MIT"
] | 2 | 2021-08-30T23:05:29.000Z | 2021-09-03T04:28:25.000Z | lib/AnimationStation/src/Effects/StaticColor.hpp | ez2torta/GP2040 | 50d2aaec40e02abeb6ef6d27f58de77009b19874 | [
"MIT"
] | null | null | null | lib/AnimationStation/src/Effects/StaticColor.hpp | ez2torta/GP2040 | 50d2aaec40e02abeb6ef6d27f58de77009b19874 | [
"MIT"
] | null | null | null | #ifndef _STATIC_COLOR_H_
#define _STATIC_COLOR_H_
#include <vector>
#include <stdio.h>
#include <stdlib.h>
#include "../Animation.hpp"
#include "../AnimationStation.hpp"
class StaticColor : public Animation {
public:
StaticColor(PixelMatrix &matrix);
StaticColor(PixelMatrix &matrix, std::vector<Pixel> &pixels);
... | 20.807692 | 63 | 0.726433 | ez2torta |
f629287e0571ed47dd294ebfb0d6cda890b59810 | 2,283 | cpp | C++ | codeforces/N - Wires/Wrong answer on test 1.cpp | kzvd4729/Problem-Solving | 13b105e725a4c2f8db7fecc5d7a8f932b9fef4ab | [
"MIT"
] | 1 | 2022-02-11T16:55:36.000Z | 2022-02-11T16:55:36.000Z | codeforces/N - Wires/Wrong answer on test 1.cpp | kzvd4729/Problem-Solving | 13b105e725a4c2f8db7fecc5d7a8f932b9fef4ab | [
"MIT"
] | null | null | null | codeforces/N - Wires/Wrong answer on test 1.cpp | kzvd4729/Problem-Solving | 13b105e725a4c2f8db7fecc5d7a8f932b9fef4ab | [
"MIT"
] | null | null | null | /****************************************************************************************
* @author: kzvd4729 created: Oct/27/2019 19:37
* solution_verdict: Wrong answer on test 1 language: GNU C++14
* run... | 28.5375 | 111 | 0.412615 | kzvd4729 |
f62931072abe30397a2b46e3eac694ac8d57fd71 | 48,597 | cc | C++ | components/payments/core/journey_logger_unittest.cc | metux/chromium-deb | 3c08e9b89a1b6f95f103a61ff4f528dbcd57fc42 | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | null | null | null | components/payments/core/journey_logger_unittest.cc | metux/chromium-deb | 3c08e9b89a1b6f95f103a61ff4f528dbcd57fc42 | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | null | null | null | components/payments/core/journey_logger_unittest.cc | metux/chromium-deb | 3c08e9b89a1b6f95f103a61ff4f528dbcd57fc42 | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | null | null | null | // Copyright 2017 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "components/payments/core/journey_logger.h"
#include "base/metrics/metrics_hashes.h"
#include "base/test/histogram_tester.h"
#include "base/test... | 44.05893 | 96 | 0.73558 | metux |
f62b23f95c442075e0a6cadee50fc25b565bf479 | 4,132 | cpp | C++ | src/download.cpp | toyobayashi/evm-windows | 5734cfe8555ccc492671e15bc30b54467681c749 | [
"MIT"
] | null | null | null | src/download.cpp | toyobayashi/evm-windows | 5734cfe8555ccc492671e15bc30b54467681c749 | [
"MIT"
] | null | null | null | src/download.cpp | toyobayashi/evm-windows | 5734cfe8555ccc492671e15bc30b54467681c749 | [
"MIT"
] | null | null | null | #include <sstream>
#include <math.h>
#include <time.h>
#include "download.h"
#include <curl/curl.h>
#include <iostream>
#include "path.hpp"
//static size_t onDataString(void* buffer, size_t size, size_t nmemb, progressInfo * userp) {
// const char* d = (const char*)buffer;
// // userp->headerString.append(d, size * ... | 27.731544 | 110 | 0.644966 | toyobayashi |
f62ea6aed389d2f91dcc32f5992bb286e7a61b01 | 2,636 | cpp | C++ | modules/core/engine/src/EngineServiceManager.cpp | syl22-00/aac-sdk | 79696da55b0bca09a4c68f361ef1f47efb8f717e | [
"Apache-2.0"
] | 4 | 2018-08-29T08:16:52.000Z | 2019-05-17T02:04:56.000Z | modules/core/engine/src/EngineServiceManager.cpp | syl22-00/aac-sdk | 79696da55b0bca09a4c68f361ef1f47efb8f717e | [
"Apache-2.0"
] | null | null | null | modules/core/engine/src/EngineServiceManager.cpp | syl22-00/aac-sdk | 79696da55b0bca09a4c68f361ef1f47efb8f717e | [
"Apache-2.0"
] | 1 | 2020-05-18T02:02:47.000Z | 2020-05-18T02:02:47.000Z | /*
* Copyright 2017-2018 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License").
* You may not use this file except in compliance with the License.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0/
*
* or in the "... | 31.380952 | 181 | 0.724583 | syl22-00 |
f62f1572f726e6299c7988be717afbe9be20041d | 11,294 | cc | C++ | zircon/system/utest/trace/record_tests.cc | casey/fuchsia | 2b965e9a1e8f2ea346db540f3611a5be16bb4d6b | [
"BSD-3-Clause"
] | null | null | null | zircon/system/utest/trace/record_tests.cc | casey/fuchsia | 2b965e9a1e8f2ea346db540f3611a5be16bb4d6b | [
"BSD-3-Clause"
] | null | null | null | zircon/system/utest/trace/record_tests.cc | casey/fuchsia | 2b965e9a1e8f2ea346db540f3611a5be16bb4d6b | [
"BSD-3-Clause"
] | null | null | null | // Copyright 2018 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 <inttypes.h>
#include <zircon/syscalls.h>
#include <array>
#include <memory>
#include <fbl/algorithm.h>
#include <fbl/string_printf.h>
#include ... | 34.224242 | 100 | 0.658226 | casey |
f62f1a39f186141cf5bcc647a9be7668ac6314ad | 7,801 | cpp | C++ | app/src/main/engine/android/esutil_android.cpp | qige023/learning-opengles3-android | cbe0742637a6eeed41c76756021913cc570cc30e | [
"MIT"
] | 10 | 2015-05-06T17:59:51.000Z | 2019-12-03T10:08:23.000Z | app/src/main/engine/android/esutil_android.cpp | qige023/OpenGL-ES3-Programming-On-Android | cbe0742637a6eeed41c76756021913cc570cc30e | [
"MIT"
] | null | null | null | app/src/main/engine/android/esutil_android.cpp | qige023/OpenGL-ES3-Programming-On-Android | cbe0742637a6eeed41c76756021913cc570cc30e | [
"MIT"
] | null | null | null | //
// This file contains the Android implementation of the windowing functions.
#include <android/log.h>
#include <android/keycodes.h>
#include <android/input.h>
#include <android_native_app_glue.h>
#include <time.h>
#include <iostream>
#include <stdexcept>
using std::cout;
using std::cerr;
using std::endl;
#incl... | 31.329317 | 145 | 0.596077 | qige023 |
f6313322b0b4bc5f88ab1c363dd727cbfc6bd9c6 | 10,729 | cpp | C++ | src/gridding/gridding.cpp | nio1814/3Dcones | 704b78a0d73b25ab59269e60babbd13876f8563e | [
"BSD-3-Clause"
] | 4 | 2019-09-10T13:46:41.000Z | 2022-03-21T20:19:23.000Z | src/gridding/gridding.cpp | nio1814/3Dcones | 704b78a0d73b25ab59269e60babbd13876f8563e | [
"BSD-3-Clause"
] | 1 | 2017-05-17T07:05:00.000Z | 2017-05-17T07:05:38.000Z | src/gridding/gridding.cpp | nio1814/3Dcones | 704b78a0d73b25ab59269e60babbd13876f8563e | [
"BSD-3-Clause"
] | 2 | 2020-04-12T09:39:29.000Z | 2022-03-21T20:19:25.000Z | /***************************************************************************
Copyright (c) 2014 The Board of Trustees of the Leland Stanford Junior University.
All rights reserved.
Contact: Okai Addy <noaddy@alumni.stanford.edu>
This source code is under a BSD 3-Clause License.
See LICENSE for more information.
... | 30.654286 | 144 | 0.721596 | nio1814 |
f6350a75839dd98d27716a02d3fc370e117f9ddf | 1,002 | cpp | C++ | include/h3api/H3AdventureMap/H3MapMine.cpp | Patrulek/H3API | 91f10de37c6b86f3160706c1fdf4792f927e9952 | [
"MIT"
] | 14 | 2020-09-07T21:49:26.000Z | 2021-11-29T18:09:41.000Z | include/h3api/H3AdventureMap/H3MapMine.cpp | Day-of-Reckoning/H3API | a82d3069ec7d5127b13528608d5350d2b80d57be | [
"MIT"
] | 2 | 2021-02-12T15:52:31.000Z | 2021-02-12T16:21:24.000Z | include/h3api/H3AdventureMap/H3MapMine.cpp | Day-of-Reckoning/H3API | a82d3069ec7d5127b13528608d5350d2b80d57be | [
"MIT"
] | 8 | 2021-02-12T15:52:41.000Z | 2022-01-31T15:28:10.000Z | //////////////////////////////////////////////////////////////////////
// //
// Created by RoseKavalier: //
// rosekavalierhc@gmail.com //
// Created or last upda... | 33.4 | 70 | 0.398204 | Patrulek |
f635f72038a3b9c564c0818f258c0b50c0d25c09 | 1,441 | cpp | C++ | EnglishEducator/GameState.cpp | Uno-Bayan/English-Educator | b031086f4fff5e5bcca2212a2b61f9c554f5ca92 | [
"MIT"
] | null | null | null | EnglishEducator/GameState.cpp | Uno-Bayan/English-Educator | b031086f4fff5e5bcca2212a2b61f9c554f5ca92 | [
"MIT"
] | null | null | null | EnglishEducator/GameState.cpp | Uno-Bayan/English-Educator | b031086f4fff5e5bcca2212a2b61f9c554f5ca92 | [
"MIT"
] | null | null | null | #include "stdafx.h"
#include <sstream>
#include "GameState.h"
#include "DEFINITIONS.h"
#include "MainMenuState.h"
#include "GrammarState.h"
#include <iostream>
namespace EnglishEducator
{
GameState::GameState(GameDataRef data) : _data(data)
{
_data->window.setFramerateLimit(30);
}
void GameStat... | 19.739726 | 74 | 0.639833 | Uno-Bayan |
f63801e52141d3566d949e3eabc9309d3d2ec863 | 987 | hpp | C++ | src/point.hpp | xyl1t/Cidr | 48ee260ec4871eddb795ccc0f3aa1fddfc2cd0aa | [
"MIT"
] | 6 | 2020-09-10T17:44:49.000Z | 2021-03-14T16:41:11.000Z | src/point.hpp | xyl1t/Cidr | 48ee260ec4871eddb795ccc0f3aa1fddfc2cd0aa | [
"MIT"
] | 1 | 2021-07-22T20:25:00.000Z | 2021-11-27T19:44:35.000Z | src/point.hpp | xyl1t/Cidr | 48ee260ec4871eddb795ccc0f3aa1fddfc2cd0aa | [
"MIT"
] | null | null | null | /********************************
* Project: Cidr *
* File: point.hpp *
* Date: 12.9.2020 *
********************************/
#ifndef CIDR_POINT_HPP
#define CIDR_POINT_HPP
#include "tensorMath.hpp"
// TODO: ADD CONSTURCTORS!
// In order to keep the code "consice" I just ... | 21.456522 | 94 | 0.616008 | xyl1t |
f63979213498b360b480d39e0eb915fec6641e5c | 4,595 | hpp | C++ | Kuplung/kuplung/objects/ObjectsManager.hpp | supudo/Kuplung | f0e11934fde0675fa531e6dc263bedcc20a5ea1a | [
"Unlicense"
] | 14 | 2017-02-17T17:12:40.000Z | 2021-12-22T01:55:06.000Z | Kuplung/kuplung/objects/ObjectsManager.hpp | supudo/Kuplung | f0e11934fde0675fa531e6dc263bedcc20a5ea1a | [
"Unlicense"
] | null | null | null | Kuplung/kuplung/objects/ObjectsManager.hpp | supudo/Kuplung | f0e11934fde0675fa531e6dc263bedcc20a5ea1a | [
"Unlicense"
] | 1 | 2019-10-15T08:10:10.000Z | 2019-10-15T08:10:10.000Z | //
// ObjectsManager.hpp
// Kuplung
//
// Created by Sergey Petrov on 12/3/15.
// Copyright © 2015 supudo.net. All rights reserved.
//
#ifndef ObjectsManager_hpp
#define ObjectsManager_hpp
#include <functional>
#include <map>
#include <string>
#include <vector>
#include <glm/glm.hpp>
#include "kuplung/objects/Obj... | 36.181102 | 146 | 0.796953 | supudo |
f643a2479b7f181bdcc0a0eb0d546f15490fe208 | 24,468 | cpp | C++ | src/platforms/windows/direct2d.cpp | LinkDoyle/YuKi | 22c7ac495e48985e0f21574b327ee687563a88e5 | [
"Apache-2.0"
] | null | null | null | src/platforms/windows/direct2d.cpp | LinkDoyle/YuKi | 22c7ac495e48985e0f21574b327ee687563a88e5 | [
"Apache-2.0"
] | null | null | null | src/platforms/windows/direct2d.cpp | LinkDoyle/YuKi | 22c7ac495e48985e0f21574b327ee687563a88e5 | [
"Apache-2.0"
] | null | null | null | #include "direct2d.h"
#include <algorithm>
#include <cassert>
#include <exception>
#include <string_view>
#include <utility>
#undef max
#undef min
#pragma comment(lib, "d2d1")
#pragma comment(lib, "d3d11")
#pragma comment(lib, "dwrite.lib")
#pragma comment(lib, "dxguid.lib")
namespace yuki {
namespace platforms {
na... | 33.42623 | 80 | 0.671489 | LinkDoyle |
f6471ae1ea47ecb8a075b971b683f3bf0b55ff21 | 3,364 | cpp | C++ | Cores/FCEU/FCEU/boards/vrc3.cpp | werminghoff/Provenance | de61b4a64a3eb8e2774e0a8ed53488c6c7aa6cb2 | [
"BSD-3-Clause"
] | 3,459 | 2015-01-07T14:07:09.000Z | 2022-03-25T03:51:10.000Z | Cores/FCEU/FCEU/boards/vrc3.cpp | werminghoff/Provenance | de61b4a64a3eb8e2774e0a8ed53488c6c7aa6cb2 | [
"BSD-3-Clause"
] | 1,046 | 2018-03-24T17:56:16.000Z | 2022-03-23T08:13:09.000Z | Cores/FCEU/FCEU/boards/vrc3.cpp | werminghoff/Provenance | de61b4a64a3eb8e2774e0a8ed53488c6c7aa6cb2 | [
"BSD-3-Clause"
] | 549 | 2015-01-07T14:07:15.000Z | 2022-01-07T16:13:05.000Z | /* FCE Ultra - NES/Famicom Emulator
*
* Copyright notice for this file:
* Copyright (C) 2012 CaH4e3
*
* 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 2 of the Licen... | 24.735294 | 82 | 0.630202 | werminghoff |
f64b21354c4953d937430e7b42d5cc6f202faf7b | 15,003 | cxx | C++ | main/unoxml/source/xpath/xpathapi.cxx | Grosskopf/openoffice | 93df6e8a695d5e3eac16f3ad5e9ade1b963ab8d7 | [
"Apache-2.0"
] | 679 | 2015-01-06T06:34:58.000Z | 2022-03-30T01:06:03.000Z | main/unoxml/source/xpath/xpathapi.cxx | Grosskopf/openoffice | 93df6e8a695d5e3eac16f3ad5e9ade1b963ab8d7 | [
"Apache-2.0"
] | 102 | 2017-11-07T08:51:31.000Z | 2022-03-17T12:13:49.000Z | main/unoxml/source/xpath/xpathapi.cxx | Grosskopf/openoffice | 93df6e8a695d5e3eac16f3ad5e9ade1b963ab8d7 | [
"Apache-2.0"
] | 331 | 2015-01-06T11:40:55.000Z | 2022-03-14T04:07:51.000Z | /**************************************************************
*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to y... | 33.192478 | 99 | 0.619076 | Grosskopf |
f64be9f45f8fb11c6d45f13e8c5bf04c7a40ef5e | 4,206 | cpp | C++ | dev/src/BicycleFrontPanel_utest/BicycleFrontPanel_utest/tst_bicyclefrontpanel_utest.cpp | CountrySideEngineer/BicycleFrontPanel | de13a984f726d282f1703f9096dd61ef287806e9 | [
"MIT"
] | null | null | null | dev/src/BicycleFrontPanel_utest/BicycleFrontPanel_utest/tst_bicyclefrontpanel_utest.cpp | CountrySideEngineer/BicycleFrontPanel | de13a984f726d282f1703f9096dd61ef287806e9 | [
"MIT"
] | null | null | null | dev/src/BicycleFrontPanel_utest/BicycleFrontPanel_utest/tst_bicyclefrontpanel_utest.cpp | CountrySideEngineer/BicycleFrontPanel | de13a984f726d282f1703f9096dd61ef287806e9 | [
"MIT"
] | null | null | null | #include <QtTest>
#include <QDebug>
// add necessary includes here
#include "cdatetime.h"
#include "apart.h"
#include "cwheel.h"
#include "cwheelvelocity.h"
class BicycleFrontPanel_utest : public QObject
{
Q_OBJECT
public:
BicycleFrontPanel_utest();
~BicycleFrontPanel_utest();
private s... | 24.887574 | 81 | 0.64194 | CountrySideEngineer |
f64dec40bd138e76dd99b023fda095d959fab0c3 | 149 | cpp | C++ | libng/core/src/libng_core/ui/platform/mac/MacWindow.cpp | gapry/libng | 8fbf927e5bb73f105bddbb618430d3e1bf2cf877 | [
"MIT"
] | null | null | null | libng/core/src/libng_core/ui/platform/mac/MacWindow.cpp | gapry/libng | 8fbf927e5bb73f105bddbb618430d3e1bf2cf877 | [
"MIT"
] | null | null | null | libng/core/src/libng_core/ui/platform/mac/MacWindow.cpp | gapry/libng | 8fbf927e5bb73f105bddbb618430d3e1bf2cf877 | [
"MIT"
] | null | null | null | #include <libng_core/ui/platform/mac/MacWindow.hpp>
namespace libng {
MacWindow::MacWindow() {
}
MacWindow::~MacWindow() {
}
} // namespace libng | 13.545455 | 51 | 0.711409 | gapry |
f64e1d74027d448ea856d893613a9544aa81cacb | 46,045 | cpp | C++ | hi_scripting/scripting/ScriptProcessorModules.cpp | Matt-Dub/HISE | ae2dd1653e1c8d749a9088edcd573de6252b0b96 | [
"Intel"
] | null | null | null | hi_scripting/scripting/ScriptProcessorModules.cpp | Matt-Dub/HISE | ae2dd1653e1c8d749a9088edcd573de6252b0b96 | [
"Intel"
] | null | null | null | hi_scripting/scripting/ScriptProcessorModules.cpp | Matt-Dub/HISE | ae2dd1653e1c8d749a9088edcd573de6252b0b96 | [
"Intel"
] | null | null | null | /* ===========================================================================
*
* This file is part of HISE.
* Copyright 2016 Christoph Hart
*
* HISE 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 Foun... | 28.248466 | 154 | 0.738473 | Matt-Dub |
f65649ca1352400cf3cc53daee9b4085b521cf68 | 572 | cpp | C++ | hackerrank/non-divisible-subset/solution.cpp | SamProkopchuk/coding-problems | fa0ca2c05ac90e41945de1a5751e5545a8459ac4 | [
"MIT"
] | null | null | null | hackerrank/non-divisible-subset/solution.cpp | SamProkopchuk/coding-problems | fa0ca2c05ac90e41945de1a5751e5545a8459ac4 | [
"MIT"
] | null | null | null | hackerrank/non-divisible-subset/solution.cpp | SamProkopchuk/coding-problems | fa0ca2c05ac90e41945de1a5751e5545a8459ac4 | [
"MIT"
] | null | null | null | #include <iostream>
#include <unordered_map>
using namespace std;
int main() {
int n, mod, temp, res;
cin >> n >> mod;
unordered_map<int, int> remcount;
for (int posrem = 0; posrem < mod; posrem++) {
// Simple defaultdict-like behavior
remcount[posrem] = 0;
}
for (int c = 0; c < n; c++) {
cin ... | 22.88 | 64 | 0.547203 | SamProkopchuk |
f657235d328c6925462f7c4b577082034446ce78 | 1,758 | cc | C++ | tsdf_plusplus/src/core/segment.cc | TheMangalex/tsdf-plusplus | aefb7fa40b53475ce424d5082b3045587bbb5de3 | [
"MIT"
] | 91 | 2021-05-18T03:15:18.000Z | 2022-03-28T01:53:02.000Z | tsdf_plusplus/src/core/segment.cc | ali-robot/tsdf-plusplus | 602f2aeec267a82ac3c5d88ef3eabba2ea2f3c04 | [
"MIT"
] | 4 | 2021-05-18T06:10:20.000Z | 2022-01-25T11:38:33.000Z | tsdf_plusplus/src/core/segment.cc | cmrobotics/tsdf-plusplus | 9cb15273b2bd5e7b13f67ef563856d2f92cd34dd | [
"MIT"
] | 16 | 2021-05-18T02:17:48.000Z | 2022-03-07T02:57:01.000Z | // Copyright (c) 2020- Margarita Grinvald, Autonomous Systems Lab, ETH Zurich
// Licensed under the MIT License (see LICENSE for details)
#include "tsdf_plusplus/core/segment.h"
#include <pcl/common/centroid.h>
Segment::Segment(const pcl::PointCloud<InputPointType>& pointcloud_pcl,
const voxblox::Tr... | 33.169811 | 79 | 0.661547 | TheMangalex |
f65767d98e7cbc5ab4836a02bd29a882e9f2f24a | 183 | cpp | C++ | src/GameOptions.cpp | ceilingfans/pnut-butta | d2f5d6f1f1379b4324d2b58edf102e30a6b792cb | [
"MIT"
] | null | null | null | src/GameOptions.cpp | ceilingfans/pnut-butta | d2f5d6f1f1379b4324d2b58edf102e30a6b792cb | [
"MIT"
] | null | null | null | src/GameOptions.cpp | ceilingfans/pnut-butta | d2f5d6f1f1379b4324d2b58edf102e30a6b792cb | [
"MIT"
] | null | null | null | #include "GameOptions.hpp"
bool isValidOption(const GameOptions& opt)
{
return opt.playerCount > 0 && opt.substringLength >= 2 && !opt.options.empty() && opt.options.size() >= 2;
} | 30.5 | 108 | 0.693989 | ceilingfans |
f658eb874ea759e96055caee9956cd764bbd35c7 | 3,889 | cpp | C++ | Libraries/xcassets/Sources/Asset/CubeTextureSet.cpp | djgalloway/xcbuild | 936df10e59e5f5d531efca8bd48e445d88e78e0c | [
"BSD-2-Clause-NetBSD"
] | 9 | 2018-04-30T23:18:27.000Z | 2021-06-20T15:13:38.000Z | Libraries/xcassets/Sources/Asset/CubeTextureSet.cpp | djgalloway/xcbuild | 936df10e59e5f5d531efca8bd48e445d88e78e0c | [
"BSD-2-Clause-NetBSD"
] | null | null | null | Libraries/xcassets/Sources/Asset/CubeTextureSet.cpp | djgalloway/xcbuild | 936df10e59e5f5d531efca8bd48e445d88e78e0c | [
"BSD-2-Clause-NetBSD"
] | 4 | 2018-10-10T19:44:17.000Z | 2020-01-12T11:56:31.000Z | /**
Copyright (c) 2015-present, Facebook, Inc.
All rights reserved.
This source code is licensed under the BSD-style license found in the
LICENSE file in the root directory of this source tree. An additional grant
of patent rights can be found in the PATENTS file in the same directory.
*/
#include <xcassets/Ass... | 28.807407 | 87 | 0.568527 | djgalloway |
f65967a614d415e3dd4256e6d33476b1d14e53de | 2,729 | hpp | C++ | include/tudocomp/compressors/MTFCompressor.hpp | dominiKoeppl/tudocomp | b5512f85f6b3408fb88e19c08899ec4c2716c642 | [
"ECL-2.0",
"Apache-2.0"
] | 17 | 2017-03-04T13:04:49.000Z | 2021-12-03T06:58:20.000Z | include/tudocomp/compressors/MTFCompressor.hpp | dominiKoeppl/tudocomp | b5512f85f6b3408fb88e19c08899ec4c2716c642 | [
"ECL-2.0",
"Apache-2.0"
] | 27 | 2016-01-22T18:31:37.000Z | 2021-11-27T10:50:40.000Z | include/tudocomp/compressors/MTFCompressor.hpp | dominiKoeppl/tudocomp | b5512f85f6b3408fb88e19c08899ec4c2716c642 | [
"ECL-2.0",
"Apache-2.0"
] | 16 | 2017-03-14T12:46:51.000Z | 2021-06-25T18:19:50.000Z | #pragma once
#include <tudocomp/util.hpp>
#include <tudocomp/Compressor.hpp>
#include <tudocomp/Env.hpp>
#include <numeric>
#include <tudocomp/def.hpp>
namespace tdc {
/**
* Encodes a character 'v' by Move-To-Front Coding
* Needs and modifies a lookup table storing the last-used characters
*/
template<class valu... | 28.427083 | 168 | 0.698791 | dominiKoeppl |
2cecaf0734df6cb043c486468da5daace582823e | 1,663 | cc | C++ | paddle/fluid/distributed/collective/NCCLTools.cc | L-Net-1992/Paddle | 4d0ca02ba56760b456f3d4b42a538555b9b6c307 | [
"Apache-2.0"
] | 11 | 2016-08-29T07:43:26.000Z | 2016-08-29T07:51:24.000Z | paddle/fluid/distributed/collective/NCCLTools.cc | L-Net-1992/Paddle | 4d0ca02ba56760b456f3d4b42a538555b9b6c307 | [
"Apache-2.0"
] | null | null | null | paddle/fluid/distributed/collective/NCCLTools.cc | L-Net-1992/Paddle | 4d0ca02ba56760b456f3d4b42a538555b9b6c307 | [
"Apache-2.0"
] | 1 | 2021-09-24T11:23:36.000Z | 2021-09-24T11:23:36.000Z | // Copyright (c) 2022 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... | 34.645833 | 78 | 0.689116 | L-Net-1992 |
2cf243e0ff44f73c7888a0199c24ba62cea38e16 | 3,101 | cpp | C++ | src/thunderbots/software/ai/hl/stp/evaluation/calc_best_shot.cpp | FSXAC/Software | 3754f5ec2c513906f66a05d4399aca516d03ba9f | [
"MIT"
] | null | null | null | src/thunderbots/software/ai/hl/stp/evaluation/calc_best_shot.cpp | FSXAC/Software | 3754f5ec2c513906f66a05d4399aca516d03ba9f | [
"MIT"
] | null | null | null | src/thunderbots/software/ai/hl/stp/evaluation/calc_best_shot.cpp | FSXAC/Software | 3754f5ec2c513906f66a05d4399aca516d03ba9f | [
"MIT"
] | null | null | null | #include "ai/hl/stp/evaluation/calc_best_shot.h"
#include "geom/util.h"
namespace Evaluation
{
std::pair<Point, Angle> calcBestShotOnEnemyGoal(const Field &f,
const std::vector<Point> &obstacles,
const Point &p... | 37.361446 | 88 | 0.538858 | FSXAC |
2cf3c08183e51e9c16b5bc6a416df1032a818c7e | 98 | cpp | C++ | core/utilities.cpp | evias/web-irc-docbot | ffc05223eb580a363188dc361938d23b141c6091 | [
"BSD-3-Clause"
] | 1 | 2021-08-28T01:42:34.000Z | 2021-08-28T01:42:34.000Z | core/utilities.cpp | evias/web-irc-docbot | ffc05223eb580a363188dc361938d23b141c6091 | [
"BSD-3-Clause"
] | null | null | null | core/utilities.cpp | evias/web-irc-docbot | ffc05223eb580a363188dc361938d23b141c6091 | [
"BSD-3-Clause"
] | 1 | 2015-03-24T15:45:04.000Z | 2015-03-24T15:45:04.000Z | #include "utilities.hpp"
using namespace std;
using namespace evias;
using namespace utilities;
| 14 | 26 | 0.795918 | evias |
2cfb9af139ad425a03cf71bd0daefa032bb9e9dd | 1,568 | cpp | C++ | 6 复试/1 机试/资料/清华计算机考研机试/2018/cong.cpp | ladike/912_project | 5178c1c93ac6ca30ffc72dd689f5c6932704b4ab | [
"MIT"
] | 1 | 2022-03-02T16:05:49.000Z | 2022-03-02T16:05:49.000Z | 6 复试/1 机试/资料/清华计算机考研机试/2018/cong.cpp | ladike/912_project | 5178c1c93ac6ca30ffc72dd689f5c6932704b4ab | [
"MIT"
] | null | null | null | 6 复试/1 机试/资料/清华计算机考研机试/2018/cong.cpp | ladike/912_project | 5178c1c93ac6ca30ffc72dd689f5c6932704b4ab | [
"MIT"
] | null | null | null | # include<iostream>
# include<map>
# include<vector>
using namespace std;
typedef struct{int x,y;} position;
typedef struct{int id,f;} idfight;
typedef struct{int id;position p;int d;int f;bool live;} cong;
typedef vector<cong> conglist;
conglist all_cong;
map<int,vector<idfight> >war_map;
int n,m,k,times;
void init(){... | 23.402985 | 87 | 0.586097 | ladike |
2cfe0fd3dda379a720e73736d58c1f0a8eb56baf | 103 | cpp | C++ | src/uniform-initialization-too-few-initializers.cpp | zzlc/cxx11tests | d471b3f8b96548c762be6b7e410abe56a57811ae | [
"MIT"
] | 48 | 2015-01-06T20:50:45.000Z | 2021-02-15T02:48:32.000Z | src/uniform-initialization-too-few-initializers.cpp | zzlc/cxx11tests | d471b3f8b96548c762be6b7e410abe56a57811ae | [
"MIT"
] | 3 | 2016-01-19T15:02:19.000Z | 2019-04-29T08:51:13.000Z | src/uniform-initialization-too-few-initializers.cpp | zzlc/cxx11tests | d471b3f8b96548c762be6b7e410abe56a57811ae | [
"MIT"
] | 24 | 2015-02-13T17:40:04.000Z | 2019-12-03T06:59:03.000Z | // Check if too few initializers are supported
struct Point3D {
int x, y, z;
};
Point3D p = {1, 2};
| 14.714286 | 46 | 0.640777 | zzlc |
2cfe6152d781ead5b251bb4a0c32fc277b8a1c1b | 965 | cpp | C++ | oli/vii2018puzzle/main.cpp | rockoanna/nirvana | 81fadbe66b0a24244feec312c6f7fe5c8effccaa | [
"MIT"
] | null | null | null | oli/vii2018puzzle/main.cpp | rockoanna/nirvana | 81fadbe66b0a24244feec312c6f7fe5c8effccaa | [
"MIT"
] | 12 | 2019-09-04T10:38:24.000Z | 2019-12-08T18:09:41.000Z | oli/vii2018puzzle/main.cpp | rockoanna/nirvana | 81fadbe66b0a24244feec312c6f7fe5c8effccaa | [
"MIT"
] | null | null | null | #include <iostream>
#include <vector>
using namespace std;
int main()
{
int n;
cin >> n;
vector<int> pieces(n);
for(int i = 0; i < n; i++)
{
cin >> pieces[i];
}
int res = 0;
for(int i = 0; i < n - 1; i++)
{
for(int j = i + 1; j < n; j++)
{
bo... | 16.929825 | 44 | 0.288083 | rockoanna |
fa0127da60d6209d0864b825a6f2927fd44126a7 | 318 | cpp | C++ | 5e/C++11/354_bind.cpp | mallius/CppPrimer | 0285fabe5934492dfed0a9cf67ba5650982a5f76 | [
"MIT"
] | null | null | null | 5e/C++11/354_bind.cpp | mallius/CppPrimer | 0285fabe5934492dfed0a9cf67ba5650982a5f76 | [
"MIT"
] | null | null | null | 5e/C++11/354_bind.cpp | mallius/CppPrimer | 0285fabe5934492dfed0a9cf67ba5650982a5f76 | [
"MIT"
] | 1 | 2022-01-25T15:51:34.000Z | 2022-01-25T15:51:34.000Z | #include <iostream>
#include <functional>
using namespace std;
using namespace std::placeholders;
bool check_size(const string& s, string::size_type sz)
{
return s.size() >= sz;
}
int main(void)
{
auto check6 = bind(check_size, _1, 6);
string s = "hello";
bool b1 = check6(s);
cout << b1 << endl;
return 0;
}
| 15.9 | 54 | 0.672956 | mallius |
fa02242491b1549964e6d4be74b9a0df7f604474 | 3,152 | cc | C++ | gpu/ipc/common/gpu_surface_tracker.cc | xzhan96/chromium.src | 1bd0cf3997f947746c0fc5406a2466e7b5f6159e | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | 1 | 2021-01-07T18:51:03.000Z | 2021-01-07T18:51:03.000Z | gpu/ipc/common/gpu_surface_tracker.cc | emilio/chromium.src | 1bd0cf3997f947746c0fc5406a2466e7b5f6159e | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | null | null | null | gpu/ipc/common/gpu_surface_tracker.cc | emilio/chromium.src | 1bd0cf3997f947746c0fc5406a2466e7b5f6159e | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | null | null | null | // Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "gpu/ipc/common/gpu_surface_tracker.h"
#include "base/logging.h"
#include "build/build_config.h"
#if defined(OS_ANDROID)
#include <android/... | 30.901961 | 77 | 0.770939 | xzhan96 |
fa07f64fd2e732f36b583c07f1bc9aa264706f7c | 7,480 | cpp | C++ | lib/djvViewApp/ViewData.cpp | belzecue/DJV | 94fb63a2f56cc0c41ab5d518ef9f2e0590c295c0 | [
"BSD-3-Clause"
] | 456 | 2018-10-06T00:07:14.000Z | 2022-03-31T06:14:22.000Z | lib/djvViewApp/ViewData.cpp | belzecue/DJV | 94fb63a2f56cc0c41ab5d518ef9f2e0590c295c0 | [
"BSD-3-Clause"
] | 438 | 2018-10-31T15:05:51.000Z | 2022-03-31T09:01:24.000Z | lib/djvViewApp/ViewData.cpp | belzecue/DJV | 94fb63a2f56cc0c41ab5d518ef9f2e0590c295c0 | [
"BSD-3-Clause"
] | 54 | 2018-10-29T10:18:36.000Z | 2022-03-23T06:56:11.000Z | // SPDX-License-Identifier: BSD-3-Clause
// Copyright (c) 2020 Darby Johnston
// All rights reserved.
#include <djvViewApp/ViewData.h>
#include <djvImage/Color.h>
using namespace djv::Core;
namespace djv
{
namespace ViewApp
{
bool GridOptions::operator == (const GridOptions& other) const
{
... | 36.487805 | 119 | 0.512299 | belzecue |
fa0916f810206180426544fdf9db4310b2e390a0 | 12,292 | cxx | C++ | xp_comm_proj/rd_shape/shprdpnt.cxx | avs/express-community | c699a68330d3b678b7e6bcea823e0891b874049c | [
"Apache-2.0"
] | 3 | 2020-08-03T08:52:20.000Z | 2021-04-10T11:55:49.000Z | xp_comm_proj/rd_shape/shprdpnt.cxx | avs/express-community | c699a68330d3b678b7e6bcea823e0891b874049c | [
"Apache-2.0"
] | null | null | null | xp_comm_proj/rd_shape/shprdpnt.cxx | avs/express-community | c699a68330d3b678b7e6bcea823e0891b874049c | [
"Apache-2.0"
] | 1 | 2021-06-08T18:16:45.000Z | 2021-06-08T18:16:45.000Z | #include "pnt_gen.h"
#include "gsshape.h"
#include "gsesri.h"
int
ReadShape_ReadShapeMods_ReadShapePoint::ReadShapePoint(OMevent_mask event_mask, int seq_num)
{
// ShapeFileName (OMXstr read req notify)
// FeatureNumber (OMXint read notify)
// Coordinates (OMXdouble_array write)
double *Coordinates_arr;
... | 30.501241 | 92 | 0.537179 | avs |
fa0c2a9138d1544996c4f86726aa3ddd479d5a70 | 1,952 | hpp | C++ | src/tsdf/ewa_viz.hpp | Algomorph/LevelSetFusionExperimentsCPP | f56962f0ad5c62e6706f818062782a2e1660afda | [
"Apache-2.0"
] | 8 | 2019-01-07T14:12:21.000Z | 2021-01-12T01:48:03.000Z | src/tsdf/ewa_viz.hpp | Algomorph/LevelSetFusionExperimentsCPP | f56962f0ad5c62e6706f818062782a2e1660afda | [
"Apache-2.0"
] | 6 | 2018-12-19T16:43:33.000Z | 2019-06-06T19:50:22.000Z | src/tsdf/ewa_viz.hpp | Algomorph/LevelSetFusionExperimentsCPP | f56962f0ad5c62e6706f818062782a2e1660afda | [
"Apache-2.0"
] | 2 | 2019-01-07T14:12:28.000Z | 2019-03-06T06:30:24.000Z | // ================================================================
// Created by Gregory Kramida on 1/30/19.
// Copyright (c) 2019 Gregory Kramida
// 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... | 34.245614 | 96 | 0.696721 | Algomorph |
fa0cc8fd0f23c1f4fa9ba5bd8faf9bdf174fc2fa | 1,205 | cpp | C++ | codebook/code/Matching/Blossom.cpp | NCTU-PCCA/NCTU_Yggdrasill | 4f086c9737502f69044f574514cf191d536aaf22 | [
"MIT"
] | null | null | null | codebook/code/Matching/Blossom.cpp | NCTU-PCCA/NCTU_Yggdrasill | 4f086c9737502f69044f574514cf191d536aaf22 | [
"MIT"
] | null | null | null | codebook/code/Matching/Blossom.cpp | NCTU-PCCA/NCTU_Yggdrasill | 4f086c9737502f69044f574514cf191d536aaf22 | [
"MIT"
] | null | null | null | #define MAXN 505
vector<int>g[MAXN];//用vector存圖
int pa[MAXN],match[MAXN],st[MAXN],S[MAXN],vis[MAXN];
int t,n;
inline int lca(int u,int v){//找花的花托
for(++t;;swap(u,v)){
if(u==0)continue;
if(vis[u]==t)return u;
vis[u]=t;//這種方法可以不用清空vis陣列
u=st[pa[match[u]]];
}
}
#define qpush(u) q.push(u),S[u]=0
inline void fl... | 23.173077 | 52 | 0.559336 | NCTU-PCCA |
fa0d99ae5c5f24a96a0bd0f127c0cedd118144ff | 1,214 | cpp | C++ | Problem201-250/p222_2.cpp | dingqunfei/LeetCode | c74a21ea56ee7b35308d2f387ef24ab29b031e24 | [
"Apache-2.0"
] | null | null | null | Problem201-250/p222_2.cpp | dingqunfei/LeetCode | c74a21ea56ee7b35308d2f387ef24ab29b031e24 | [
"Apache-2.0"
] | null | null | null | Problem201-250/p222_2.cpp | dingqunfei/LeetCode | c74a21ea56ee7b35308d2f387ef24ab29b031e24 | [
"Apache-2.0"
] | null | null | null | /**
* @file p222_2.cpp
* @brief
* @author dingqunfei (dqflying@gmail.com)
* @version 1.0
* @date 2021-04-11
*
* @copyright Copyright (c) 2021 DQFLYING
*
* @par :
*
*
* Date : 2021-04-11
* Version : 1.0
* Author : dqflying
* Lisence :
* Description :
*
*
*
*
*/
/**
... | 19.580645 | 93 | 0.474465 | dingqunfei |
fa0e0437ec04fa419d4d14000c86ed654c7fe6b8 | 1,002 | cpp | C++ | CLASSES/inheritance/practice_question2(absract class).cpp | shauryauppal/Algo-DS-StudyMaterial | 1c481f066d21b33ec2533156e75f45fa9b6a7606 | [
"Apache-2.0"
] | 3 | 2020-12-03T14:52:23.000Z | 2021-12-19T09:26:50.000Z | CLASSES/inheritance/practice_question2(absract class).cpp | shauryauppal/Algo-DS-StudyMaterial | 1c481f066d21b33ec2533156e75f45fa9b6a7606 | [
"Apache-2.0"
] | null | null | null | CLASSES/inheritance/practice_question2(absract class).cpp | shauryauppal/Algo-DS-StudyMaterial | 1c481f066d21b33ec2533156e75f45fa9b6a7606 | [
"Apache-2.0"
] | null | null | null | #include <iostream>
#include <cstdio>
using namespace std;
//give act as a virtual class
class give
{
//protected members
protected:
int width,height;
public:
//pure virtual function used
virtual int getarea()=0;
//use to get data
void getheight()
{
cout<<"\nEn... | 17.892857 | 44 | 0.533932 | shauryauppal |
fa116ab2dba71367016ae32a0d280ef1ceac0c7a | 11,082 | cxx | C++ | src/escape.cxx | jktjkt/replxx | 12f2adee7f9123880db1f870c360a88c1f7ba182 | [
"Apache-2.0"
] | 1 | 2019-06-11T06:49:15.000Z | 2019-06-11T06:49:15.000Z | src/escape.cxx | jktjkt/replxx | 12f2adee7f9123880db1f870c360a88c1f7ba182 | [
"Apache-2.0"
] | null | null | null | src/escape.cxx | jktjkt/replxx | 12f2adee7f9123880db1f870c360a88c1f7ba182 | [
"Apache-2.0"
] | 1 | 2019-06-10T16:48:55.000Z | 2019-06-10T16:48:55.000Z | #include "escape.hxx"
#include "io.hxx"
#include "keycodes.hxx"
#ifndef _WIN32
namespace replxx {
namespace EscapeSequenceProcessing { // move these out of global namespace
// This chunk of code does parsing of the escape sequences sent by various Linux
// terminals.
//
// It handles arrow keys, Home, End and Delet... | 35.748387 | 86 | 0.750135 | jktjkt |
fa145534ed2ca5a09dd724073d7b787b656e1cc4 | 816 | cpp | C++ | Notebook/codes/estruturas/map.cpp | rodrigoAMF7/Notebook---Maratonas | 06b38197a042bfbd27b20f707493e0a19fda7234 | [
"MIT"
] | 4 | 2019-01-25T21:22:55.000Z | 2019-03-20T18:04:01.000Z | Notebook/codes/estruturas/map.cpp | rodrigoAMF/competitive-programming-notebook | 06b38197a042bfbd27b20f707493e0a19fda7234 | [
"MIT"
] | null | null | null | Notebook/codes/estruturas/map.cpp | rodrigoAMF/competitive-programming-notebook | 06b38197a042bfbd27b20f707493e0a19fda7234 | [
"MIT"
] | null | null | null | // Map é uma variação da estrutura set e sua implementação também é feita utilizando Red- Black Trees. A principal diferença entre um set e um map é o segundo armazena os conjuntos chave, valor e o primeiro apenas chave.
map<string, int> M; // Declaração
M.insert(make_pair("Alana", 10)); //Inserimos uma variável do tip... | 74.181818 | 220 | 0.714461 | rodrigoAMF7 |
fa153b29e0dadd67b3f118338572dde64f19b438 | 2,337 | cpp | C++ | Material/RobertLafore_Book/Book_SourceCode/Progs/Ch08/Englconv.cpp | hpaucar/OOP-C-plus-plus-repo | e1fedd376029996a53d70d452b7738d9c43173c0 | [
"MIT"
] | 4 | 2020-12-26T03:17:45.000Z | 2022-01-11T05:54:40.000Z | Material/RobertLafore_Book/Book_SourceCode/Progs/Ch08/Englconv.cpp | hpaucar/OOP-C-plus-plus-repo | e1fedd376029996a53d70d452b7738d9c43173c0 | [
"MIT"
] | null | null | null | Material/RobertLafore_Book/Book_SourceCode/Progs/Ch08/Englconv.cpp | hpaucar/OOP-C-plus-plus-repo | e1fedd376029996a53d70d452b7738d9c43173c0 | [
"MIT"
] | null | null | null | // englconv.cpp
// conversions: Distance to meters, meters to Distance
#include <iostream>
using namespace std;
////////////////////////////////////////////////////////////////
class Distance //English Distance class
{
private:
const float MTF; //meters to feet
int feet;
... | 39.610169 | 95 | 0.451433 | hpaucar |
fa1acb3ec000410176148209f2e3ef08501890b6 | 511 | cpp | C++ | Luogu/P3912.cpp | XenonWZH/involution | 189f6ce2bbfe3a7c5d536bbd769f353e4c06e7c6 | [
"MIT"
] | null | null | null | Luogu/P3912.cpp | XenonWZH/involution | 189f6ce2bbfe3a7c5d536bbd769f353e4c06e7c6 | [
"MIT"
] | null | null | null | Luogu/P3912.cpp | XenonWZH/involution | 189f6ce2bbfe3a7c5d536bbd769f353e4c06e7c6 | [
"MIT"
] | null | null | null | // P3912 素数个数
// WzhDnwzWzh
#include <cstring>
#include <cstdio>
const int MAXN = 100000000;
int main() {
int n;
scanf("%d", &n);
static bool a[MAXN + 1];
memset(a, true, sizeof(a));
for (int i = 2; i * i <= n; i++) {
if (a[i]) {
for (int j = i * i; j <= n; j += i) {
... | 15.484848 | 49 | 0.395303 | XenonWZH |
fa1d427f4907498834b2f85ae3fa22c683432fd1 | 7,916 | cpp | C++ | CodeSnippets/rotateMatrix.cpp | Teabeans/CPP_Learn | a767dd323d67fab5c2baffb5aa6dd3f1e6baa35a | [
"MIT"
] | 1 | 2019-01-31T23:42:59.000Z | 2019-01-31T23:42:59.000Z | CodeSnippets/rotateMatrix.cpp | Teabeans/CPP_Learn | a767dd323d67fab5c2baffb5aa6dd3f1e6baa35a | [
"MIT"
] | null | null | null | CodeSnippets/rotateMatrix.cpp | Teabeans/CPP_Learn | a767dd323d67fab5c2baffb5aa6dd3f1e6baa35a | [
"MIT"
] | 1 | 2020-03-04T18:09:15.000Z | 2020-03-04T18:09:15.000Z | //-----------------------------------------------------------------------------|
// Authorship
//-----------------------------------------------------------------------------|
//
// Tim Lum
// twhlum@gmail.com
// Created: 2018.07.15
// Modified: 2018.08.22
//
/*
1.7 - RotateMatrix() - P.91
Given an image represented ... | 28.681159 | 84 | 0.457302 | Teabeans |
fa1d53c016e8862b1034f23a46c39111cbee4868 | 139 | cc | C++ | tests/data/test-diff-suppr/test22-suppr-removed-var-sym-v1.cc | insilications/libabigail-clr | 1eb5d367686626660d3cc987b473f296b0a59152 | [
"Apache-2.0"
] | 3 | 2021-01-29T20:26:44.000Z | 2021-04-28T07:49:48.000Z | tests/data/test-diff-suppr/test22-suppr-removed-var-sym-v1.cc | insilications/libabigail-clr | 1eb5d367686626660d3cc987b473f296b0a59152 | [
"Apache-2.0"
] | 2 | 2021-03-07T19:31:56.000Z | 2021-03-07T23:26:13.000Z | tests/data/test-diff-suppr/test22-suppr-removed-var-sym-v1.cc | insilications/libabigail-clr | 1eb5d367686626660d3cc987b473f296b0a59152 | [
"Apache-2.0"
] | 1 | 2021-03-07T19:14:08.000Z | 2021-03-07T19:14:08.000Z | // Compile this without debug info with:
// g++ -Wall -c test22-suppr-removed-var-sym-v1.cc
int global_var0 = 0;
double global_var3 = 0;
| 23.166667 | 51 | 0.705036 | insilications |
fa22efbe915b9c31259c8762a991b410db1c96cb | 2,920 | cpp | C++ | client/cpp/src/net/tcp_client.cpp | Heng-W/network | 49e34a51b19f34b443f7a914b45f47acd146d562 | [
"MIT"
] | null | null | null | client/cpp/src/net/tcp_client.cpp | Heng-W/network | 49e34a51b19f34b443f7a914b45f47acd146d562 | [
"MIT"
] | null | null | null | client/cpp/src/net/tcp_client.cpp | Heng-W/network | 49e34a51b19f34b443f7a914b45f47acd146d562 | [
"MIT"
] | null | null | null |
#include "tcp_client.h"
#include "../util/logger.h"
#include "connector.h"
#include "socket.h"
namespace net
{
TcpClient::TcpClient(const InetAddress& serverAddr)
: connector_(new Connector(serverAddr)),
connectionCallback_(defaultConnectionCallback),
messageCallback_(defaultMessageCallback),
... | 21.62963 | 94 | 0.603082 | Heng-W |
fa26334d0dd0ebdc20aba0b1d40e6a776c173f77 | 3,306 | cpp | C++ | benchmark/pubsub.cpp | Watch-Later/shadesmar | be782a0ead538ea74463947a2ca17c94124ab514 | [
"MIT"
] | 298 | 2019-08-05T04:28:05.000Z | 2022-03-28T09:02:18.000Z | benchmark/pubsub.cpp | xian0gang/shadesmar | 041ce70133ad413f3e68645fa5d1ad5800d7354b | [
"MIT"
] | 34 | 2019-11-26T15:52:04.000Z | 2022-03-06T14:04:24.000Z | benchmark/pubsub.cpp | xian0gang/shadesmar | 041ce70133ad413f3e68645fa5d1ad5800d7354b | [
"MIT"
] | 38 | 2019-11-24T14:18:38.000Z | 2022-03-31T01:58:53.000Z | /* MIT License
Copyright (c) 2020 Dheeraj R Reddy
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, publish... | 31.188679 | 80 | 0.699335 | Watch-Later |
fa2773883101d19fb4a9236d013891fd8d8796f5 | 2,172 | cpp | C++ | src/e101_200/q1414.cpp | extremedeckguru/leetcode | e45923ccbca7ae1c5f85d8c996392e8b492c1306 | [
"MIT"
] | 9 | 2020-04-09T12:37:50.000Z | 2021-04-01T14:01:14.000Z | src/e101_200/q1414.cpp | extremedeckguru/leetcode | e45923ccbca7ae1c5f85d8c996392e8b492c1306 | [
"MIT"
] | 3 | 2020-05-05T02:43:54.000Z | 2020-05-20T11:12:16.000Z | src/e101_200/q1414.cpp | extremedeckguru/leetcode | e45923ccbca7ae1c5f85d8c996392e8b492c1306 | [
"MIT"
] | 5 | 2020-04-17T02:32:10.000Z | 2020-05-20T10:12:26.000Z | /*
#面试刷题# 第0101期
#Leetcode# Q1414 找出和为K的斐波那契数的最小个数
难度:中
给定一个数k,返回其总和等于k的斐波那契数的最小值,一个斐波那契数是否可以多次使用。
斐波那契数的定义为。
F1 = 1
F2 = 1
Fn = Fn-1 + Fn-2 ,对于 n > 2。
可以保证,对于给定的约束,我们总是可以找到这样的斐波那契数和k。
约束条件:
1 <= k <= 10^9
示例1:
Input: k = 7
Output: 2
Explanation: The Fibonacci numbers are: 1, 1, 2, 3, 5, 8, 13, ...
For k = 7 we can ... | 21.939394 | 70 | 0.521179 | extremedeckguru |
fa3088878e65c7ab1c033618f5767c58136e9b80 | 215 | cpp | C++ | Dataset/Leetcode/train/9/223.cpp | kkcookies99/UAST | fff81885aa07901786141a71e5600a08d7cb4868 | [
"MIT"
] | null | null | null | Dataset/Leetcode/train/9/223.cpp | kkcookies99/UAST | fff81885aa07901786141a71e5600a08d7cb4868 | [
"MIT"
] | null | null | null | Dataset/Leetcode/train/9/223.cpp | kkcookies99/UAST | fff81885aa07901786141a71e5600a08d7cb4868 | [
"MIT"
] | null | null | null | class Solution {
public:
bool XXX(int x) {
if(x<0) return false;
int a=0,b=x;
while(x&&a<INT_MAX/10){
a=a*10+x%10;
x/=10;
}
return a==b;
}
};
| 15.357143 | 31 | 0.4 | kkcookies99 |
fa3160e3512af74c6b754aca100ddde23e4fb24a | 5,372 | cpp | C++ | 03_Tutorial/T02_XMCocos2D-CookBook/Source/Recipes/Ch7_Waypoints.cpp | mcodegeeks/OpenKODE-Framework | d4382d781da7f488a0e7667362a89e8e389468dd | [
"MIT"
] | 2 | 2017-08-03T07:15:00.000Z | 2018-06-18T10:32:53.000Z | 03_Tutorial/T02_XMCocos2D-CookBook/Source/Recipes/Ch7_Waypoints.cpp | mcodegeeks/OpenKODE-Framework | d4382d781da7f488a0e7667362a89e8e389468dd | [
"MIT"
] | null | null | null | 03_Tutorial/T02_XMCocos2D-CookBook/Source/Recipes/Ch7_Waypoints.cpp | mcodegeeks/OpenKODE-Framework | d4382d781da7f488a0e7667362a89e8e389468dd | [
"MIT"
] | 2 | 2019-03-04T22:57:42.000Z | 2020-03-06T01:32:26.000Z | /* --------------------------------------------------------------------------
*
* File Ch7_Waypoints.cpp
* Ported By Young-Hwan Mun
* Contact xmsoft77@gmail.com
*
* Created By Nate Burba
* Contact Cocos2dCookbook@gmail.com
*
* -------------------... | 31.232558 | 121 | 0.632725 | mcodegeeks |
fa33c7e062e7c5ed1374704d895628d0627ec2a1 | 2,474 | hpp | C++ | include/rcppmath/clamp.hpp | shumov-ag/rcpputils | a7898d98ab684bb5d0cb2c20c823a1b4014fa0dc | [
"Apache-2.0"
] | 14 | 2019-05-05T06:36:41.000Z | 2022-02-11T06:43:37.000Z | include/rcppmath/clamp.hpp | shumov-ag/rcpputils | a7898d98ab684bb5d0cb2c20c823a1b4014fa0dc | [
"Apache-2.0"
] | 125 | 2019-02-26T18:38:18.000Z | 2022-01-21T20:18:59.000Z | include/rcppmath/clamp.hpp | shumov-ag/rcpputils | a7898d98ab684bb5d0cb2c20c823a1b4014fa0dc | [
"Apache-2.0"
] | 39 | 2019-02-26T18:12:29.000Z | 2022-03-11T15:23:01.000Z | // Copyright 2020 PAL Robotics S.L.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed ... | 35.342857 | 98 | 0.710994 | shumov-ag |
fa35dd16f796e2efc6d61495c26e22b135919be9 | 406 | cpp | C++ | src/techniques/lrel.cpp | shibii/nn | 2022ec423c3bfe179997630d6ba705aeaabdd918 | [
"MIT"
] | 1 | 2020-11-17T14:25:28.000Z | 2020-11-17T14:25:28.000Z | src/techniques/lrel.cpp | shibii/nn | 2022ec423c3bfe179997630d6ba705aeaabdd918 | [
"MIT"
] | null | null | null | src/techniques/lrel.cpp | shibii/nn | 2022ec423c3bfe179997630d6ba705aeaabdd918 | [
"MIT"
] | null | null | null | #include "lrel.hpp"
namespace nn {
LReL::LReL(float leak) : leak_(leak) {}
void LReL::forward(Feed &f) {
input_ = f.signal;
f.signal = (input_ > 0.f) * input_ + (input_ <= 0.f) * input_ * leak_;
}
void LReL::backward(Feed &f) {
f.signal = (input_ > 0.f) * f.signal + (input_ <= 0.f) * f.signal * leak_;
}
template... | 25.375 | 76 | 0.618227 | shibii |
fa3601c6cb60c9c0200636a17693bc5d3438e55b | 471 | cpp | C++ | BASIC c++/pointer-and-referencers/pointer1.cpp | jattramesh/Learning_git | 5191ecc6c0c11b69b9786f2a8bdd3db7228987d6 | [
"MIT"
] | null | null | null | BASIC c++/pointer-and-referencers/pointer1.cpp | jattramesh/Learning_git | 5191ecc6c0c11b69b9786f2a8bdd3db7228987d6 | [
"MIT"
] | null | null | null | BASIC c++/pointer-and-referencers/pointer1.cpp | jattramesh/Learning_git | 5191ecc6c0c11b69b9786f2a8bdd3db7228987d6 | [
"MIT"
] | null | null | null | //
// Created by Rahul on 6/5/2019.
//
#include <iostream>
#include<math.h>
using namespace std;
int var,*ptr;
int main()
{
var=100;
ptr=&var;
cout<<"value of var "<<var<<"address of ptr"<<&var<<endl;
cout<<"value pf ptr "<<ptr<<"address od ptr "<<&ptr<<endl;
long a=10,b;
long *ptr;
ptr=&a;... | 17.444444 | 62 | 0.532909 | jattramesh |
fa3685a95830cfa707379fe292adfeb218693d7e | 76,936 | hpp | C++ | snark-logic/libs-source/marshalling/include/nil/marshalling/options.hpp | idealatom/podlodkin-freeton-year-control | 6aa96e855fe065c9a75c76da976a87fe2d1668e6 | [
"MIT"
] | null | null | null | snark-logic/libs-source/marshalling/include/nil/marshalling/options.hpp | idealatom/podlodkin-freeton-year-control | 6aa96e855fe065c9a75c76da976a87fe2d1668e6 | [
"MIT"
] | null | null | null | snark-logic/libs-source/marshalling/include/nil/marshalling/options.hpp | idealatom/podlodkin-freeton-year-control | 6aa96e855fe065c9a75c76da976a87fe2d1668e6 | [
"MIT"
] | 1 | 2021-09-15T20:27:27.000Z | 2021-09-15T20:27:27.000Z | //---------------------------------------------------------------------------//
// Copyright (c) 2017-2021 Mikhail Komarov <nemo@nil.foundation>
// Copyright (c) 2020-2021 Nikita Kaskov <nbering@nil.foundation>
//
// MIT License
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of th... | 56.82127 | 119 | 0.578312 | idealatom |
fa38ac46bc11e9f2e41a8b0f9614b0efcfe90edf | 7,074 | cpp | C++ | src/solvers/refinement/string_constraint_generator_concat.cpp | chrisr-diffblue/cbmc | 854b26fec145ebb345cf45c9512201143c823cd1 | [
"BSD-4-Clause"
] | null | null | null | src/solvers/refinement/string_constraint_generator_concat.cpp | chrisr-diffblue/cbmc | 854b26fec145ebb345cf45c9512201143c823cd1 | [
"BSD-4-Clause"
] | 2 | 2018-06-18T10:34:36.000Z | 2018-07-03T15:43:57.000Z | src/solvers/refinement/string_constraint_generator_concat.cpp | chrisr-diffblue/cbmc | 854b26fec145ebb345cf45c9512201143c823cd1 | [
"BSD-4-Clause"
] | null | null | null | /*******************************************************************\
Module: Generates string constraints for functions adding content
add the end of strings
Author: Romain Brenguier, romain.brenguier@diffblue.com
\*******************************************************************/
/// \file
/// Generates... | 39.082873 | 80 | 0.71063 | chrisr-diffblue |
fa3b963e8bff7662eee819b9d93b379986e5926b | 3,241 | cpp | C++ | tests/utils_test.cpp | louiz/batajelo | 4d8edce8da9d3b17dbad68eb4881d7f6fee2f76e | [
"BSL-1.0",
"BSD-2-Clause",
"Zlib",
"MIT"
] | 7 | 2015-01-28T09:17:08.000Z | 2020-04-21T13:51:16.000Z | tests/utils_test.cpp | louiz/batajelo | 4d8edce8da9d3b17dbad68eb4881d7f6fee2f76e | [
"BSL-1.0",
"BSD-2-Clause",
"Zlib",
"MIT"
] | null | null | null | tests/utils_test.cpp | louiz/batajelo | 4d8edce8da9d3b17dbad68eb4881d7f6fee2f76e | [
"BSL-1.0",
"BSD-2-Clause",
"Zlib",
"MIT"
] | 1 | 2020-07-11T09:20:25.000Z | 2020-07-11T09:20:25.000Z | #include <utils/base64.hpp>
#include <utils/string.hpp>
#include <utils/scopeguard.hpp>
#include <utils/zlib.hpp>
#include <utils/time.hpp>
#include "catch.hpp"
TEST_CASE("Both", "[base64]")
{
std::string hello = "Coucou ici";
CHECK(base64_decode(base64_encode(reinterpret_cast<const unsigned char*>(hello.c_str())... | 24.930769 | 386 | 0.676026 | louiz |
fa3dc8242a4300646a6928fc98e0f9577e9c4499 | 17,909 | cc | C++ | mindspore/lite/src/runtime/kernel/arm/fp32/convolution_fp32.cc | taroxd/mindspore | 9bb620ff2caaac7f1c53c4b104935f22352cb88f | [
"Apache-2.0"
] | 55 | 2020-12-17T10:26:06.000Z | 2022-03-28T07:18:26.000Z | mindspore/lite/src/runtime/kernel/arm/fp32/convolution_fp32.cc | taroxd/mindspore | 9bb620ff2caaac7f1c53c4b104935f22352cb88f | [
"Apache-2.0"
] | null | null | null | mindspore/lite/src/runtime/kernel/arm/fp32/convolution_fp32.cc | taroxd/mindspore | 9bb620ff2caaac7f1c53c4b104935f22352cb88f | [
"Apache-2.0"
] | 14 | 2021-01-29T02:39:47.000Z | 2022-03-23T05:00:26.000Z | /**
* Copyright 2020 Huawei Technologies Co., Ltd
*
* 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... | 37.942797 | 120 | 0.685633 | taroxd |
fa3e9a0bc2dd0bcba79d797ef2269824617ff5b6 | 3,440 | cpp | C++ | genome/genome.cpp | nicodex/lianzifu | 67c08abf0636e85512bfc91ac9ebe43dc2255186 | [
"MIT"
] | 2 | 2018-02-01T04:08:48.000Z | 2018-02-03T16:33:38.000Z | genome/genome.cpp | nicodex/lianzifu | 67c08abf0636e85512bfc91ac9ebe43dc2255186 | [
"MIT"
] | 1 | 2018-02-02T12:28:32.000Z | 2018-02-09T13:13:53.000Z | genome/genome.cpp | nicodex/lianzifu | 67c08abf0636e85512bfc91ac9ebe43dc2255186 | [
"MIT"
] | 1 | 2020-05-20T15:52:21.000Z | 2020-05-20T15:52:21.000Z | //
// Copyright (c) 2018 Nico Bendlin <nico@nicode.net>
//
// 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, mod... | 20.598802 | 80 | 0.623256 | nicodex |
fa41bd932a3d0556d52ae51a1763aa49055ceffe | 2,106 | cc | C++ | kernel/src/arch/x86_64/hal/task/context.cc | igarfieldi/Danaos64 | f4a2df8de5f214af7a4d18e14790740d2c481c48 | [
"Apache-2.0"
] | 2 | 2017-09-16T19:41:14.000Z | 2017-11-04T10:41:38.000Z | kernel/src/arch/x86_64/hal/task/context.cc | igarfieldi/Danaos64 | f4a2df8de5f214af7a4d18e14790740d2c481c48 | [
"Apache-2.0"
] | null | null | null | kernel/src/arch/x86_64/hal/task/context.cc | igarfieldi/Danaos64 | f4a2df8de5f214af7a4d18e14790740d2c481c48 | [
"Apache-2.0"
] | null | null | null | #include "context.h"
#include "hal/interrupts/gdt.h"
#include "main/task/task.h"
namespace hal {
task_context create_context(volatile uint64_t *stack, task::task &task) {
task_context context(&stack[-21]);
// New state
stack[-21] = reinterpret_cast<uint64_t>(&stack[0]); // RBP... | 55.421053 | 101 | 0.395537 | igarfieldi |
fa425c1f643a874587973399f192364a916e82ae | 139,538 | cxx | C++ | SimModel_Python_API/simmodel_swig/SimModel_Dll_lib/framework/SimFlowPlant_ElectricalGenerator_Photovoltaic.cxx | EnEff-BIM/EnEffBIM-Framework | 6328d39b498dc4065a60b5cc9370b8c2a9a1cddf | [
"MIT"
] | 3 | 2016-05-30T15:12:16.000Z | 2022-03-22T08:11:13.000Z | SimModel_Python_API/simmodel_swig/SimModel_Dll_lib/framework/SimFlowPlant_ElectricalGenerator_Photovoltaic.cxx | EnEff-BIM/EnEffBIM-Framework | 6328d39b498dc4065a60b5cc9370b8c2a9a1cddf | [
"MIT"
] | 21 | 2016-06-13T11:33:45.000Z | 2017-05-23T09:46:52.000Z | SimModel_Python_API/simmodel_swig/SimModel_Dll_lib/framework/SimFlowPlant_ElectricalGenerator_Photovoltaic.cxx | EnEff-BIM/EnEffBIM-Framework | 6328d39b498dc4065a60b5cc9370b8c2a9a1cddf | [
"MIT"
] | null | null | null | // Copyright (c) 2005-2014 Code Synthesis Tools CC
//
// This program was generated by CodeSynthesis XSD, an XML Schema to
// C++ data binding compiler.
//
// This program is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License version 2 as
// published by the Fre... | 43.769762 | 195 | 0.725179 | EnEff-BIM |
fa42f7d64228c4762e9e0fc5e8e7546e729a0bb5 | 3,354 | cpp | C++ | src/seraphon/SaurusEternityWarden.cpp | rweyrauch/AoSSimulator | d2bfbbe0fab904cc543f1a01e62e0b82cf67c27b | [
"MIT"
] | 5 | 2019-02-01T01:41:19.000Z | 2021-06-17T02:16:13.000Z | src/seraphon/SaurusEternityWarden.cpp | rweyrauch/AoSSimulator | d2bfbbe0fab904cc543f1a01e62e0b82cf67c27b | [
"MIT"
] | 2 | 2020-01-14T16:57:42.000Z | 2021-04-01T00:53:18.000Z | src/seraphon/SaurusEternityWarden.cpp | rweyrauch/AoSSimulator | d2bfbbe0fab904cc543f1a01e62e0b82cf67c27b | [
"MIT"
] | 1 | 2019-03-02T20:03:51.000Z | 2019-03-02T20:03:51.000Z | /*
* Warhammer Age of Sigmar battle simulator.
*
* Copyright (C) 2019 by Rick Weyrauch - rpweyrauch@gmail.com
*
* This code is licensed under the MIT license (MIT) (http://opensource.org/licenses/MIT)
*/
#include <seraphon/SaurusEternityWarden.h>
#include <UnitFactory.h>
#include "SeraphonPrivate.h"
namespace S... | 40.902439 | 154 | 0.640429 | rweyrauch |
fa436636d8dac56b1c2ef14b9a1b811fc6eae866 | 10,898 | hpp | C++ | include/algebra/array/multi_array.hpp | hyperpower/Nablla | 5a9be9f3b064a235572a1a2c9c5c2c19118697c5 | [
"MIT"
] | null | null | null | include/algebra/array/multi_array.hpp | hyperpower/Nablla | 5a9be9f3b064a235572a1a2c9c5c2c19118697c5 | [
"MIT"
] | null | null | null | include/algebra/array/multi_array.hpp | hyperpower/Nablla | 5a9be9f3b064a235572a1a2c9c5c2c19118697c5 | [
"MIT"
] | null | null | null | /************************
// \file multi_array.hpp
// \brief
//
// \author czhou
// \date 20 janv. 2018
***********************/
#ifndef MULTI_ARRAY_HPP_
#define MULTI_ARRAY_HPP_
#include <iostream>
#include <assert.h>
#include "algebra/algebra_define.hpp"
#include <array>
#include "array_list.hpp"
nam... | 22.751566 | 73 | 0.497706 | hyperpower |
fa43abe574becae19946a822d743f83aaf3c239e | 561 | cpp | C++ | infer/tests/build_systems/deduplicate_template_warnings/src/templates.cpp | JacobBarthelmeh/infer | 12c582a69855e17a2cf9c7b6cdf7f8e9c71e5341 | [
"MIT"
] | 14,499 | 2015-06-11T16:00:28.000Z | 2022-03-31T23:43:54.000Z | infer/tests/build_systems/deduplicate_template_warnings/src/templates.cpp | JacobBarthelmeh/infer | 12c582a69855e17a2cf9c7b6cdf7f8e9c71e5341 | [
"MIT"
] | 1,529 | 2015-06-11T16:55:30.000Z | 2022-03-27T15:59:46.000Z | infer/tests/build_systems/deduplicate_template_warnings/src/templates.cpp | JacobBarthelmeh/infer | 12c582a69855e17a2cf9c7b6cdf7f8e9c71e5341 | [
"MIT"
] | 2,225 | 2015-06-11T16:36:10.000Z | 2022-03-31T05:16:59.000Z | /*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
// we should only report one dead store warning on this file
template <class T>
T* unused_var_template_bad() {
int i = 42;
ret... | 26.714286 | 76 | 0.736185 | JacobBarthelmeh |
fa459b841083b74b712407ef9cafc530e61568f7 | 5,207 | cpp | C++ | TrigBatch.cpp | TheFakeMontyOnTheRun/gles2-renderer | 76ed7aba3fa19cf34ec9ed27ce101d3ebfe1c07f | [
"BSD-2-Clause"
] | 1 | 2018-04-05T14:53:03.000Z | 2018-04-05T14:53:03.000Z | TrigBatch.cpp | TheFakeMontyOnTheRun/gles2-renderer | 76ed7aba3fa19cf34ec9ed27ce101d3ebfe1c07f | [
"BSD-2-Clause"
] | null | null | null | TrigBatch.cpp | TheFakeMontyOnTheRun/gles2-renderer | 76ed7aba3fa19cf34ec9ed27ce101d3ebfe1c07f | [
"BSD-2-Clause"
] | null | null | null | //
// Created by monty on 25/02/16.
//
#include "glm/glm.hpp"
#if defined(__ANDROID__ ) || defined(__EMSCRIPTEN__) || defined(MESA_GLES2) || defined(TARGET_IOS)
#ifdef __APPLE__
#if TARGET_IOS
#import <OpenGLES/ES2/gl.h>
#import <OpenGLES/ES2/glext.h>
#else
#import <OpenGL/OpenGL.h>
#import <OpenGL/gl3.h>
#en... | 29.252809 | 153 | 0.673132 | TheFakeMontyOnTheRun |
fa490073c133f6add5e423d69c2ba6046a6935e4 | 1,636 | cpp | C++ | cpp/subprojects/common/src/common/sampling/weight_vector_dense.cpp | mrapp-ke/SyndromeLearner | ed18c282949bebbc8e1dd5d2ddfb0b224ee71293 | [
"MIT"
] | null | null | null | cpp/subprojects/common/src/common/sampling/weight_vector_dense.cpp | mrapp-ke/SyndromeLearner | ed18c282949bebbc8e1dd5d2ddfb0b224ee71293 | [
"MIT"
] | null | null | null | cpp/subprojects/common/src/common/sampling/weight_vector_dense.cpp | mrapp-ke/SyndromeLearner | ed18c282949bebbc8e1dd5d2ddfb0b224ee71293 | [
"MIT"
] | 1 | 2022-03-08T22:06:56.000Z | 2022-03-08T22:06:56.000Z | #include "common/sampling/weight_vector_dense.hpp"
template<class T>
DenseWeightVector<T>::DenseWeightVector(uint32 numElements)
: DenseWeightVector<T>(numElements, false) {
}
template<class T>
DenseWeightVector<T>::DenseWeightVector(uint32 numElements, bool init)
: vector_(DenseVector<T>(numElements, init)... | 25.169231 | 84 | 0.76956 | mrapp-ke |