text stringlengths 84 499k | source stringclasses 6
values | slice stringclasses 1
value | est_tokens int32 24 143k | score float32 |
|---|---|---|---|---|
// 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... | code_c | code | 2,596 | null |
#include <stdio.h>
#include <string.h>
#include <math.h>
#include <stdlib.h>
int main() {
char *s;
s = malloc(1024 * sizeof(char));
scanf("%[^\n]", s);
s = realloc(s, strlen(s) + 1);
//Write your logic to print the tokens of the sentence here.
for (int i =0; i < strlen(s); i++){
if (s... | code_c | code | 122 | null |
#pragma once
#include "VisualStyleDefinitions.h"
#include <stdint.h>
namespace libmsstyle
{
#pragma pack(push, 1)
struct PropertyHeader
{
int32_t nameID; // Offset: 0, Size: 4, ID for the property name, described in MSDN
int32_t typeID; // Offset: 4, Size: 4, ID for the type of the property, described in MSD... | code_c | code | 863 | null |
//
// MobileRTCMeetingDelegate.h
// MobileRTC
//
// Created by Robust on 2017/11/14.
// Copyright © 2017年 Zoom Video Communications, Inc. All rights reserved.
//
#import <Foundation/Foundation.h>
typedef void (^RTCJoinMeetingActionBlock)(NSString *, NSString *, BOOL);
#pragma mark - MobileRTCMeetingServiceDelega... | code_c | code | 4,712 | null |
#ifndef OPTIMIZATION_TASK_H
#define OPTIMIZATION_TASK_H
#include <k52/common/disallow_copy_and_assign.h>
#include <k52/parallel/i_task.h>
#include <k52/optimization/params/i_parameters.h>
#include <k52/optimization/i_objective_function.h>
#include <k52/optimization/i_optimizer.h>
#ifdef BUILD_WITH_MPI
#include <k52... | code_c | code | 475 | null |
/* +------------------------------------------------------------------------+
| Mobile Robot Programming Toolkit (MRPT) |
| http://www.mrpt.org/ |
| |
| Cop... | code_c | code | 895 | null |
<reponame>clayne/DirectXShaderCompiler
// Test this without pch.
// RUN: %clang_cc1 -include %S/functions.h -fsyntax-only -verify %s
// Test with pch.
// RUN: %clang_cc1 -emit-pch -o %t %S/functions.h
// RUN: %clang_cc1 -include-pch %t -fsyntax-only -verify %s
int f0(int x0, int y0, ...) { return x0 + y0; }
float *... | code_c | code | 234 | null |
<reponame>koprok/AMQP-CPP
/**
* Poll.h
*
* Class to check or wait for a socket to become readable and/or writable
*
* @copyright 2018 Copernica BV
*/
/**
* Include guard
*/
#pragma once
/**
* Begin of namespace
*/
namespace AMQP {
/**
* Class definition
*/
class Poll
{
private:
/**
* Se... | code_c | code | 795 | null |
<reponame>lukekras/zig<filename>lib/libc/include/any-linux-any/linux/atmioc.h
/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
/* atmioc.h - ranges for ATM-related ioctl numbers */
/* Written 1995-1999 by <NAME>, EPFL LRC/ICA */
/*
* See https://icawww1.epfl.ch/linux-atm/magic.html for the complete l... | code_c | code | 489 | null |
<filename>Tool/Analysis/ViewAnalysis.h<gh_stars>1-10
#ifndef CVIEWANALYSIS_H
#define CVIEWANALYSIS_H
#include "../IToolBase.h"
class CViewAnalysis:public IToolBase
{
public:
public:
CViewAnalysis(ISceneGraph* pSceneGraph,CToolSelector*pToolSelector):IToolBase(pSceneGraph,pToolSelector){}
/**
* @brief 初始化... | code_c | code | 116 | null |
#ifndef BSON_CONFIG_H
#define BSON_CONFIG_H
/*
* Define to 1234 for Little Endian, 4321 for Big Endian.
*/
#define BSON_BYTE_ORDER 1234
/*
* Define to 1 if you have stdbool.h
*/
#define BSON_HAVE_STDBOOL_H 0
#if BSON_HAVE_STDBOOL_H != 1
# undef BSON_HAVE_STDBOOL_H
#endif
/*
* Define to 1 for POSIX-like system... | code_c | code | 436 | null |
// ===============================================================================
// I P A B . H
// ===============================================================================
#ifndef __IPAB_H
#define __IPAB_H
// ===============================================================================
// Dependencie... | code_c | code | 3,805 | null |
/*********************************************************************
This is a library for our Monochrome OLEDs based on SSD1306 drivers
Pick one up today in the adafruit shop!
------> http://www.adafruit.com/category/63_98
These displays use SPI to communicate, 4 or 5 pins are required to
interface
Adafruit i... | code_c | code | 1,646 | null |
//
// GYBViewController.h
// cocoaPods_test
//
// Created by gyb1314 on 01/23/2021.
// Copyright (c) 2021 gyb1314. All rights reserved.
//
@import UIKit;
@interface GYBViewController : UIViewController
@end
| code_c | code | 61 | null |
/* -------------------------------------------------------------------------- *
* This program is a next-event simulation of a queueing network. Topology *
* of the network is described by the transition-matrix P, queues have *
* infinite capacity and a FIFO scheduling discipline. Different interarrival *... | code_c | code | 2,946 | null |
//------------------------------------------------------------------------------
/*
This file is part of rippled: https://github.com/ripple/rippled
Copyright (c) 2012, 2013 Ripple Labs Inc.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby ... | code_c | code | 751 | null |
/*******************************************************************************
*
* Intel Ethernet Controller XL710 Family Linux Driver
* Copyright(c) 2013 - 2014 Intel Corporation.
*
* This program is free software; you can redistribute it and/or modify it
* under the terms and conditions of the GNU General Pub... | code_c | code | 9,974 | null |
<filename>parser/ParseErrorCode.h
#include "ParseInfo.h"
#include "NAMidiParser.h"
#include "ABCParser.h"
#include "MMLParser.h"
static inline const char *ParseErrorCode2String(int code)
{
#define CASE(code) case code: return #code;
switch (code) {
CASE(GeneralParseErrorUnsupportedFileType);
CASE(GeneralPa... | code_c | code | 1,789 | null |
<gh_stars>10-100
/* MdePkg/Include/Uefi/UefiMultiPhase.h */
///
/// Data structure that precedes all of the standard EFI table types.
///
typedef struct {
///
/// A 64-bit signature that identifies the type of table that follows.
/// Unique signatures have been generated for the EFI System Table,
/// the EFI B... | code_c | code | 2,380 | null |
/*
* bxCAN driver for STM32 family processors
*
* 2010 <NAME>
*
*/
#include "platform.h"
#include "stm32f10x.h"
#include <string.h>
#include "can.h"
// TODO: add others
//"1M" "800K" "500K" "250K" "125K" "100K" "50K" "20K" "10K"
#define TIMINGS_NUM (sizeof(CAN_Timings)/sizeof(struct can_timing_t))
static const s... | code_c | code | 2,429 | null |
/*
* Copyright (C) 2009 Google 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 list of conditio... | code_c | code | 3,615 | null |
/*
Copyright © INRIA 2010-2011.
Authors: <NAME> & <NAME>
Contact: <EMAIL> <EMAIL>
This software is a computer program whose purpose is to provide
efficient tools for basic yet computationally demanding tasks,
such as find k-nearest neighbors using exhaustive search
and kmeans clustering.
This software is gover... | code_c | code | 5,589 | null |
<gh_stars>1-10
// -*- C++ -*-
/***************************************************************************
* blitz/array/newet-macros.h Macros for new e.t. implementation
*
* Copyright (C) 1997-2001 <NAME> <<EMAIL>>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of ... | code_c | code | 6,119 | null |
<filename>Tien.h
#pragma once
#include <string>
class Tien
{
public:
enum MA_TIEN
{
VND = 1,
USD,
GBP,
CNY,
EUR
};
Tien();
Tien(double soTien, MA_TIEN maTien = Tien::VND);
Tien operator+(const Tien& tien);
Tien operator+(double amount);
Tien& operator+=(double amount);
Tien operator-(const Tien& ... | code_c | code | 186 | null |
//===- InlineAdvisor.h - Inlining decision making abstraction -*- C++ ---*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===---------------------------... | code_c | code | 3,261 | null |
<reponame>tormoder/fit-benchmarks
////////////////////////////////////////////////////////////////////////////////
// The following FIT Protocol software provided may be used with FIT protocol
// devices only and remains the copyrighted property of Garmin Canada Inc.
// The software is being provided on an "as-is" b... | code_c | code | 552 | null |
<reponame>yammajamma/cFE
/*
** GSC-18128-1, "Core Flight Executive Version 6.7"
**
** Copyright (c) 2006-2019 United States Government as represented by
** the Administrator of the National Aeronautics and Space Administration.
** All Rights Reserved.
**
** Licensed under the Apache License, Version 2.0 (the "Lice... | code_c | code | 11,352 | null |
<gh_stars>1000+
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
/*++
Module Name:
include/pal/utf8.h
Abstract:
Header file for UTF-8 conversion functions.
Revision History:
--*/
#ifndef _PAL_UTF8_H_
#define _PAL_... | code_c | code | 244 | null |
<filename>libs/platform/ebpf_ring_buffer.h<gh_stars>0
// Copyright (c) Microsoft Corporation
// SPDX-License-Identifier: MIT
#pragma once
#include "ebpf_platform.h"
#ifdef __cplusplus
extern "C"
{
#endif
typedef struct _ebpf_ring_buffer_record
{
struct
{
uint8_t locked : 1;
... | code_c | code | 1,469 | null |
<reponame>Gu-Youngfeng/TenSamplingStudy1
/* vi: set sw=4 ts=4: */
/*
* httpd implementation for busybox
*
* Copyright (C) 2002,2003 <NAME> <<EMAIL>>
* Copyright (C) 2003-2006 <NAME> <<EMAIL>>
*
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
*
*********************************************... | code_c | code | 19,707 | null |
<reponame>abhisekkundu-intel/libxsmm
/******************************************************************************
* Copyright (c) Intel Corporation - All rights reserved. *
* This file is part of the LIBXSMM library. *
* ... | code_c | code | 30,346 | null |
//
// Created by wangrl on 18-12-16.
//
#ifndef APPROJECTS_PLANEMODEL_H
#define APPROJECTS_PLANEMODEL_H
#include "VectorTypes.h"
#include "SimpleMatrix.h"
namespace GlesSDK {
/**
* \brief Functions for generating Plane shapes.
*/
class PlaneModel
{
public:
/**
* \brief Get n... | code_c | code | 345 | null |
<filename>history/170204_ARP/170208_1356/AMCBmp.h
/*******************************************************************************
Copyright (C), 2011-2012, <NAME>
File name: AMCBmp.h
Description:
This file provide interfaces to create or modify a simple BMP file
Author: <NAME> (<NAME>)
History:
201... | code_c | code | 943 | null |
<gh_stars>0
#pragma once
#include "../../Helper/FormatHelper.h"
#include "../RosApiCall.h"
namespace rosdiscover {
namespace api_call {
class BareServiceCall : public BareRosApiCall {
public:
using BareRosApiCall::BareRosApiCall;
RosApiCallKind const getKind() const override {
return RosApiCallKind::BareSer... | code_c | code | 348 | null |
<reponame>tmatth/aomanalyzer
/*
* Copyright (c) 2010 The WebM project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the f... | code_c | code | 403 | null |
/*
Parallel algorithm for time series subsequence similarity search under DTW measure.
Execution params.
(c) <NAME>
*/
#ifndef PARAMS_H
#define PARAMS_H
#define LENQUERY (int) 128
#endif
| code_c | code | 54 | null |
#ifdef HAVE_CONFIG_H
#include "../../../ext_config.h"
#endif
#include <php.h>
#include "../../../php_ext.h"
#include "../../../ext.h"
#include <Zend/zend_exceptions.h>
#include "kernel/main.h"
/**
* This file is part of the Phalcon Framework.
*
* (c) <NAME> <<EMAIL>>
*
* For the full copyright and license in... | code_c | code | 289 | null |
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
void scan_data(char *operator, double *right_operand);
void do_next_op(char operator, double right_operand, double *accumulator);
int main(void) {
char operator;
double right_operand, accumulator = 0;
do {
scan_data(&operator, &right_operand);
do... | code_c | code | 310 | null |
#ifndef GAMEAPP_H
#define GAMEAPP_H
#include "d3dApp.h"
class GameApp : public D3DApp
{
public:
GameApp(HINSTANCE hInstance, const std::wstring& windowName, int initWidth, int initHeight);
~GameApp();
bool Init();
void OnResize();
void UpdateScene(float dt);
void DrawScene();
};
#endif | code_c | code | 89 | null |
/*
* The MIT License (MIT)
*
* Copyright (c) 2020 <NAME>
*
* 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... | code_c | code | 4,065 | null |
/*===================================================================
The Medical Imaging Interaction Toolkit (MITK)
Copyright (c) German Cancer Research Center,
Division of Medical and Biological Informatics.
All rights reserved.
This software is distributed WITHOUT ANY WARRANTY; without
even the implied warranty o... | code_c | code | 382 | null |
// Room: /d/taishan/wangheting.c
// Last Modified by Winder on Aug. 25 2001
#include <ansi.h>;
inherit ROOM;
void create()
{
set("short", "望河亭");
set("long", @LONG
玉皇廟西廂就是望河亭。黃河金帶為泰山六大奇觀之一。若新霽無
塵、夕陽西下時,舉目北眺,在泰山西北層層峯巒的盡頭,可看到黃河
象一條金色的帶子閃閃發光,或河水反射到天空,形成蜃景,波光粼粼,
黃白相間,如同金銀鋪就一般,從西南至東北,一直伸向天地交界處。
恰如袁枚在《登泰山詩》... | code_c | code | 175 | null |
//
// Copyright (c) 2003-2020 <NAME> and Rational Discovery LLC
//
// @@ All Rights Reserved @@
// This file is part of the RDKit.
// The contents are covered by the terms of the BSD license
// which is included in the file license.txt, found at the root
// of the RDKit source tree.
//
#include <RDGeneral/export.... | code_c | code | 685 | null |
<reponame>wallace11/DearPyGui
#pragma once
#include <vector>
#include <map>
#include <string>
#include "core/AppItems/mvTypeBases.h"
#include "PythonUtilities/mvPythonParser.h"
namespace Marvel {
class mvDocWindow : public mvBaseWindowAppitem
{
MV_APPITEM_TYPE(mvAppItemType::DocWindow, "add_doc_window")
public... | code_c | code | 543 | null |
<gh_stars>1-10
#include "badwolf.h"
#include <gtk/gtk.h>
struct Download
{
struct Window *window;
GtkWidget *container;
GtkWidget *icon;
GtkWidget *stop_icon;
GtkWidget *file_path;
GtkWidget *progress;
GtkWidget *status;
GError *error;
};
void download_new_entry(WebKitDownload *webkit_download, struct Downl... | code_c | code | 282 | null |
/*
* MUSB OTG driver register defines
*
* Copyright 2005 Mentor Graphics Corporation
* Copyright (C) 2005-2006 by Texas Instruments
* Copyright (C) 2006-2007 Nokia Corporation
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* versi... | code_c | code | 5,115 | null |
#ifndef SHP_H
#define SHP_H
struct Point
{
double x;
double y;
};
struct PolylineRcd
{
double box[4];
int nParts;
int nPoints;
int *parts;
struct Point *points;
};
struct PolygonRcd
{
double box[4];
int nParts;
int nPoints;
int *parts;
struct Point *points;
};
struct PolygonMRcd
{
doubl... | code_c | code | 255 | null |
<filename>Source/GameJoltAPI/Public/AsyncActions/Data-Store/Set.h
// Copyright by <NAME> (2020-2021)
#pragma once
#include "CoreMinimal.h"
#include "GameJoltAsyncBase.h"
#include "Set.generated.h"
DECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam(FSetSuccessDelegate, EGJErrors, Error);
/**
* Sets data in the data store.... | code_c | code | 370 | null |
/*
MIT License
Copyright(c) 2020 Futurewei Cloud
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, p... | code_c | code | 4,246 | null |
<gh_stars>0
/*
Copyright (c) 2009 <EMAIL>
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, d... | code_c | code | 596 | null |
<reponame>olvrou/CCF<gh_stars>0
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the Apache 2.0 License.
#pragma once
#include "tlsendpoint.h"
namespace enclave
{
class FramedTLSEndpoint : public TLSEndpoint
{
protected:
uint32_t msg_size;
size_t count;
public:
Frame... | code_c | code | 554 | null |
/*!
* \file
* \brief Vreg2 Click example
*
* # Description
* This application enables voltage regulation.
*
* The demo application is composed of two sections :
*
* ## Application Init
* Initializes the GPIO driver and configures the PWM
* peripheral for controlling VREG2 voltage output.
*
* ## Appli... | code_c | code | 985 | null |
<reponame>wxinix/pango-windows
/* Pango
* pangocairo-fc.h: Private header file for Cairo/fontconfig combination
*
* Copyright (C) 2005 Red Hat, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License as published by the Free S... | code_c | code | 544 | null |
/*
* Copyright (C) 2013 Google 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 list of conditio... | code_c | code | 1,071 | null |
// Copyright (c) 2021 The Orbit Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef ORBIT_GL_VIEWPORT_H_
#define ORBIT_GL_VIEWPORT_H_
#include "CoreMath.h"
namespace orbit_gl {
// Defines a mapping from a 2D screen into a 2D (... | code_c | code | 961 | null |
<filename>tls/s2n_connection.c
/*
* Copyright 2014 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/apach... | code_c | code | 3,387 | null |
/******************************************************************************
* Copyright 2018 The Apollo Authors. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the License);
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*... | code_c | code | 1,893 | null |
#pragma once
#include "common_header.h"
#include "ImageData.h"
#include "ParagraphData.h"
#include "quest.h"
#include "button.h"
namespace pyrodactyl
{
namespace ui
{
class QuestText : public ParagraphData
{
protected:
//How much the text and bullet positions change per line
Vector2i inc;
//Color of... | code_c | code | 380 | null |
<reponame>lemire/WebAssemblyVSJavaScript<filename>c/spectralnorm.c
#include <emscripten/emscripten.h>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
double eval_A(int i, int j) {
return 1.0 / ((i + j) * (i + j + 1) / 2 + i + 1);
}
void eval_A_times_u(int N, const double u[], double Au[]) {
int i, j;
f... | code_c | code | 326 | null |
/*===---- mm_malloc.h - Implementation of _mm_malloc and _mm_free ----------===
*
* Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
* See https://llvm.org/LICENSE.txt for license information.
* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
*
*===----------------------------... | code_c | code | 385 | null |
/*========================== begin_copyright_notice ============================
Copyright (C) 2020-2021 Intel Corporation
SPDX-License-Identifier: MIT
============================= end_copyright_notice ===========================*/
#ifndef GENX_UTIL_H
#define GENX_UTIL_H
#include "FunctionGroup.h"
#include "GenXR... | code_c | code | 8,180 | null |
<gh_stars>100-1000
/* * SPDX-License-Identifier: BSD-3-Clause
* Copyright 2018-2019 NXP
*/
/**
* @file dpaa2_sparser.h
*
* @brief Soft parser related macros & functions support for DPAA2 device
* framework based applications.
*
*/
#ifndef _DPAA2_SPARSER_H
#define _DPAA2_SPARSER_H
#ifdef __cplusplus
extern ... | code_c | code | 1,794 | null |
#ifndef vcl_typeinfo_h_
#define vcl_typeinfo_h_
#include <typeinfo>
#ifdef _MSC_VER
# include <vcl_msvc_warnings.h>
#endif
#if VXL_LEGACY_FUTURE_REMOVE
# error "Deprecated. Use equivalent C++11 header instead. see: vxl/scripts/UseStandardHeaders.py"
#else
# warning "This header will be removed in future version... | code_c | code | 126 | null |
<gh_stars>1-10
#include "libmx.h"
int mx_list_size(t_list *list) {
t_list *current = list;
int count = 0;
while (current != NULL) {
current = current->next;
count++;
}
return count;
}
| code_c | code | 63 | null |
<filename>mxflutter/ios/Classes/MXFlutterOCFramework/MXJSFlutterDefines.h<gh_stars>0
//
// MXJSFlutter.h
// MXFlutterOCFramework
//
// Created by soapyang on 2019/1/8.
// Copyright © 2019 The MXFlutter Authors. All rights reserved.
//
// Use of this source code is governed by a MIT-style license that can be
// fo... | code_c | code | 363 | null |
<gh_stars>0
#include "TMemory.h"
#include "Core/TString.h"
#include "Core/Logger.h"
#include "Platform/Platform.h"
// TODO: Custom string lib
#include <string.h>
#include <stdio.h>
struct memory_stats
{
u64 totalAllocated;
u64 taggedAllocations[MEMORY_TAG_MAX_TAGS];
};
static const char* memoryTagStrings[MEM... | code_c | code | 1,067 | null |
// Aleth: Ethereum C++ client, tools and libraries.
// Copyright 2014-2019 Aleth Authors.
// Licensed under the GNU General Public License, Version 3.
#pragma once
#ifndef XRAY_BUILD
#include <json/json.h>
#endif
#include <libdevcore/Common.h>
#include <libevm/Instruction.h>
#include <libevm/VMFace.h>
#include <cstdi... | code_c | code | 518 | null |
<reponame>Toromino/chromiumos-platform2
// Copyright 2018 The Chromium OS Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef AUTHPOLICY_GPO_VERSION_CACHE_H_
#define AUTHPOLICY_GPO_VERSION_CACHE_H_
#include <map>
#include <memor... | code_c | code | 892 | null |
/*
* Common library for ADIS16XXX devices
*
* Copyright 2012 Analog Devices Inc.
* Author: <NAME> <<EMAIL>>
*
* Licensed under the GPL-2 or later.
*/
#include <linux/export.h>
#include <linux/interrupt.h>
#include <linux/mutex.h>
#include <linux/kernel.h>
#include <linux/spi/spi.h>
#include <linux/slab.h>
#i... | code_c | code | 1,234 | null |
<reponame>Dbevan/SunderingShadows<filename>cmds/feats/e/_expanded_knowledge_2.c
#include <std.h>
#include <daemons.h>
inherit FEAT;
int expanded_level = 2;
int cmd_expanded_knowledge_2(string args)
{
#include "_expanded_knowledge_common.h";
}
void create() {
::create();
feat_type("permanent");
feat_cate... | code_c | code | 438 | null |
<filename>libav-12.3/libavformat/cafdec.c
/*
* Core Audio Format demuxer
* Copyright (c) 2007 <NAME>
* Copyright (c) 2009 <NAME>
*
* This file is part of Libav.
*
* Libav is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the ... | code_c | code | 4,219 | null |
<gh_stars>10-100
// Fill out your copyright notice in the Description page of Project Settings.
#pragma once
#include "BountyDashObject.h"
#include "BountyDashPowerUp.generated.h"
UCLASS()
class BOUNTYDASH_API ABountyDashPowerUp : public ABountyDashObject
{
GENERATED_BODY()
public:
// Sets default values for this ... | code_c | code | 156 | null |
<reponame>prateek-s/mesos
/*
* Copyright 2010-2016 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
*
... | code_c | code | 1,373 | null |
#include<stdio.h> //using standard input output header file
// This function takes an integer and returns its reverse number
// Ex: 12345 -> 54321 | 20055002 -> 20055002
int reverseNum(int num){ // Lets take num = 105
int rev = 0; //the rev or reverse is initially kept 0
... | code_c | code | 468 | null |
<gh_stars>1-10
/*
* acpi_mmconfig.c - Architecture-Specific Low-Level ACPI Boot Support
*
* Copyright (C) 2001, 2002 <NAME> <<EMAIL>>
* Copyright (C) 2001 <NAME> <<EMAIL>>
*
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*
* This program is free software; you can redistribute i... | code_c | code | 1,040 | null |
<filename>IMG_lbm.c
/*
SDL_image: An example image loading library for use with SDL
Copyright (C) 1997-2013 <NAME> <<EMAIL>>
This software is provided 'as-is', without any express or implied
warranty. In no event will the authors be held liable for any damages
arising from the use of this software.
Perm... | code_c | code | 4,636 | null |
// This file is made available under Elastic License 2.0.
// This file is based on code available under the Apache license here:
// https://github.com/apache/incubator-doris/blob/master/be/src/olap/task/engine_clone_task.h
// Licensed to the Apache Software Foundation (ASF) under one
// or more contributor license a... | code_c | code | 943 | null |
<reponame>wedataintelligence/vivaldi-source<filename>chromium/components/omnibox/browser/omnibox_popup_model.h
// 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.
#ifndef COMPONENTS_OMNIBOX_BROWSER_OMNI... | code_c | code | 1,851 | null |
#ifndef __ASM_AVR32_TERMBITS_H
#define __ASM_AVR32_TERMBITS_H
#include <linux/posix_types.h>
typedef unsigned char cc_t;
typedef unsigned int speed_t;
typedef unsigned int tcflag_t;
#define NCCS 19
struct termios {
tcflag_t c_iflag; /* input mode flags */
tcflag_t c_oflag; /* output mode flags */
tcflag_t c_cfl... | code_c | code | 1,308 | null |
#define __add __add_avx
#define __mul __mul_avx
#define __sqr __sqr_avx
#define __sub __sub_avx
#define __dbl_mp __dbl_mp_avx
#define __dvd __dvd_avx
#define NO___CPY 1
#define NO___MP_DBL 1
#define NO___ACR 1
#define NO__CONST 1
#define SECTION __attribute__ ((section (".text.avx")))
#include <sysdeps/ieee754/dbl-64... | code_c | code | 93 | null |
<filename>NASA SPACEAPPS CHALLENGE/Solution/Software part/Astronomical Data and Python Libraries/Astropy/astropy-1.1.2/cextern/wcslib/C/spc.h
/*============================================================================
WCSLIB 5.14 - an implementation of the FITS WCS standard.
Copyright (C) 1995-2016, <NAME>
T... | code_c | code | 11,189 | null |
<gh_stars>0
/*
* Copyright (C) 2017 by Author: Aroudj, Samir, born in Suhl, Thueringen, Germany
* All rights reserved.
*
* This software may be modified and distributed under the terms
* of the BSD 3-Clause license. See the License.txt file for details.
*/
#ifndef _IWINDOW_LISTENER_H_
#define _IWINDOW_LISTENER_H_... | code_c | code | 237 | null |
/**
* \file plane_orientation.h
* \brief plane orientation
* \author <NAME>
* \date 22.05.2008
* */
#ifndef BS_PLANE_ORIENTATION_H_
#define BS_PLANE_ORIENTATION_H_
namespace blue_sky
{
//! Plane orientations
enum
{
PLANE_ORIENTATION_X = 0,
PLANE_ORIENTATION_Y,
PLANE_ORIENTATION_Z,
PLANE... | code_c | code | 191 | null |
/* Part of SWI-Prolog
Author: <NAME>
E-mail: <EMAIL>
WWW: http://www.swi-prolog.org
Copyright (c) 2011-2015, University of Amsterdam
Vu University Amsterdam
All rights reserved.
Redistribution and use in source and binary forms, with or w... | code_c | code | 6,319 | null |
<gh_stars>0
#pragma once
#include "../../Core/EventListener.h"
#include "../../Core/SignalHandler.h"
#include <memory>
#include <vector>
namespace Bomberman {
class CommandFactory;
class CommandQueue;
class GameLayer;
class PlayerEvents : public EventListener, public SignalHandler {
public:
void listenEvent(... | code_c | code | 215 | null |
// DOM-IGNORE-BEGIN
/*******************************************************************************
* Copyright (C) 2020 Microchip Technology Inc. and its subsidiaries.
*
* Subject to your compliance with these terms, you may use Microchip software
* and any derivatives exclusively with Microchip products. It is your
... | code_c | code | 5,163 | null |
//
// FPFileTransferWindowController.h
// FPPicker
//
// Created by Ruben on 10/10/14.
// Copyright (c) 2014 Filepicker.io. All rights reserved.
//
#import <Cocoa/Cocoa.h>
@class FPFileTransferController;
@protocol FPFileTransferControllerDelegate <NSObject>
- (void)FPFileTransferControllerDidFinish:(FPFileTran... | code_c | code | 284 | null |
<filename>include/aroma/utils/array.h
/********************************************************************[libaroma]*
* Copyright (C) 2011-2015 <NAME> (http://amarullz.com/)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You... | code_c | code | 3,199 | null |
<reponame>lofunz/mieme
/* Konami Ultra Sports hardware
Driver by <NAME>
TODO:
- sound cpu irqs generation is unknown and very prone to get broken (i.e. if 4G and 2G returns as bad in POST screen).
- sound is lagged, reason is probably the same as above.
*/
#include "emu.h"
#include "cpu/m68000/m6800... | code_c | code | 2,598 | null |
<reponame>hstenzel/yugabyte-db
//--------------------------------------------------------------------------------------------------
// Copyright (c) YugaByte, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License. You may obtain a ... | code_c | code | 922 | null |
<filename>external/source/exploits/CVE-2015-2426/dll/src/Exploiter.h
#ifndef EXPLOITER_H
#define EXPLOITER_H
VOID ExploiterInit();
VOID ExploiterDoFengShui();
VOID ExploiterSetupFirstChain(ULONGLONG);
VOID ExploiterSetupSecondChain(ULONGLONG, ULONGLONG);
VOID ExploiterRunFirstChain();
VOID ExploiterRunSecondCh... | code_c | code | 112 | null |
/*
* Copyright (c) 2021 Huawei Device 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 ... | code_c | code | 1,019 | null |
<gh_stars>100-1000
#pragma once
#include "brainflow_constants.h"
#include "concentration_knn_classifier.h"
class RelaxationKNNClassifier : public ConcentrationKNNClassifier
{
public:
RelaxationKNNClassifier (struct BrainFlowModelParams params)
: ConcentrationKNNClassifier (params)
{
}
int pr... | code_c | code | 177 | null |
<reponame>suryanshshukla10/Projects
#include<stdio.h>
main()
{
int a[100],n,dup=0,i;
printf("Enter the no of terms\n");
scanf("%d",&n);
printf("Enter the elements in array");
for(i=1; i<=n; i++){scanf("%d",&a[i]);}
for(i=1;i<=n;i++)
{dup=0;
for(int j=i;j<=n;j++)
{
if(a[i]==a[j]){dup++;}
}
if(... | code_c | code | 122 | null |
<gh_stars>0
/**************************************************************************//**
* @file
* Source module isolating the ECOMP Vendor Event Listener (EVEL) API.
*
* This file implements the EVEL library which is intended to provide a
* simple wrapper around the complexity of AT&T's Vendor Event Listener A... | code_c | code | 4,599 | null |
#ifndef _NSEEL_GLUE_X86_64_H_
#define _NSEEL_GLUE_X86_64_H_
#define GLUE_MAX_FPSTACK_SIZE 8
#define GLUE_JMP_SET_OFFSET(endOfInstruction,offset) (((int *)(endOfInstruction))[-1] = (int) (offset))
#define GLUE_PREFER_NONFP_DV_ASSIGNS
static const unsigned char GLUE_JMP_NC[] = { 0xE9, 0,0,0,0, }; // jmp<offset... | code_c | code | 2,886 | null |
#include <ztest.h>
static void expect_two_parameters(int a, int b)
{
ztest_check_expected_value(a);
ztest_check_expected_value(b);
}
static void parameter_tests(void)
{
ztest_expect_value(expect_two_parameters, a, 2);
ztest_expect_value(expect_two_parameters, b, 3);
expect_two_parameters(2, 3);
}
static int ret... | code_c | code | 194 | null |
#if !defined(SKC_LUA_H) && defined(BASE_EXTERN_LUA)
#define SKC_LUA_H
#include <Skc/lua/macros.h>
BASE_BEGIN_DECLS
SKC_API int luaopen_Skc (lua_State* L);
BASE_END_DECLS
#endif
| code_c | code | 51 | null |
#pragma once
#include <list>
#include <vector>
#include <string>
#include <sstream>
#include <climits>
#include "Edge.h"
#define INF INT_MAX/3
#define null -1
class BellmanFord {
public:
BellmanFord();
bool bellmanFord(std::list<Edge<int,int> > edgeList,
std::list<int> vertexList, int sour... | code_c | code | 205 | null |
/* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil ; -*- */
/*
* (C) 2001 by Argonne National Laboratory.
* See COPYRIGHT in top-level directory.
*/
#include "mpiimpl.h"
#include "mpicomm.h"
#include <stdint.h>
/* This function has multiple phases.
*
* In the first phase, all alive processes must coll... | code_c | code | 1,890 | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.