source string | code_lang string | content string | idx int64 |
|---|---|---|---|
the-stack-v2-dedup | C |
#include "epoll.h"
struct epoll_event* events;
int epoll_create(int flags){
int fd = epoll_create1(flags);
check(fd>0, "epoll_creat:");
event = (struct epoll_event*)malloc(sizeof(struct epoll_event)*MAXEVENTS);
check(events != NULL, "epoll_create: malloc");
return fd;
}
void epoll_add(int ep... | 1,330,900 |
the-stack-v2-dedup | C | #pragma once
#include "il2cpp-config.h"
#ifndef _MSC_VER
# include <alloca.h>
#else
# include <malloc.h>
#endif
#include <stdint.h>
#include <assert.h>
#include <exception>
// _CameraShake/ShakeState
struct ShakeState_t1303782894;
#include "codegen/il2cpp-codegen.h"
#include "UnityEngine_UnityEngine_Vector3224370... | 1,330,901 |
the-stack-v2-dedup | C | #pragma once
void test_produs(); | 1,330,902 |
the-stack-v2-dedup | C | #include<stdio.h>
#define ROWS 3
#define COLS 5
int main(){
int averages[COLS - 1];
int a[ROWS][COLS] = {
{87, 98, 80, 76, 3},
{99, 89, 90, 90, 0},
{65, 68, 50, 49, 0}
};
int i;
for(i = 0; i < COLS; i++){
double aver;
aver = (a[0][i] + a[1][i] + a[2][i]) / 3;
averages[i] = aver;
}
for(int k = 0; ... | 1,330,903 |
the-stack-v2-dedup | C | /* Generated by Cython 0.20.2 on Wed Jul 16 16:02:06 2014 */
#define PY_SSIZE_T_CLEAN
#ifndef CYTHON_USE_PYLONG_INTERNALS
#ifdef PYLONG_BITS_IN_DIGIT
#define CYTHON_USE_PYLONG_INTERNALS 0
#else
#include "pyconfig.h"
#ifdef PYLONG_BITS_IN_DIGIT
#define CYTHON_USE_PYLONG_INTERNALS 1
#else
#define CYTHON_USE_PYLONG_INTER... | 1,330,904 |
the-stack-v2-dedup | C | #define HTMLBUTCHERVERSION_1 1
#define HTMLBUTCHERVERSION_2 1
#define HTMLBUTCHERVERSION_3 0
#define HTMLBUTCHERVERSION_4 28
#define HTMLBUTCHERVERSION_NUMBER 1,1,0,28
#define HTMLBUTCHERVERSION_STRING "1.1.0.28"
| 1,330,905 |
the-stack-v2-dedup | C | #include<stdio.h>
#include<stdlib.h>
#include<string.h>
char a[26],b[26];
int main() {
char str1[10000],str2[10000];
int i,j;
gets(str1);
gets(str2);
for(i=0;i<strlen(str1);i++) {
a[str1[i]-97]+=1;
}
for(i=0;i<strlen(str2);i++) {
b[str2[i]-97] += 1;
}
int maxi = strlen(str1),c=0;
for(i=0;i<26;i++)... | 1,330,906 |
the-stack-v2-dedup | C |
#include "rectab.h"
#include "bio/seqcoord.h"
#include "bio/seqfeat.h"
#include "util/util.h"
void rectab_check(RecRateTable *rt) {
RecRateBlock *blk, *prev_blk;
long i;
for(i = 0; i < rt->n; i++) {
blk = &rt->blk[i];
if(blk->rate < 0.0) {
g_error("%s:%d: invalid recombination rate %g for bloc... | 1,330,907 |
the-stack-v2-dedup | C | #include "lps.h"
#include "adc.h"
#include "pins.h"
#include <gpio.h>
#include <stddef.h>
#include <stdint.h>
#include <limits.h>
#include <math.h>
#include "tbuf.h"
//LPS0 = PC0
//LPS1 = PC1
//LPS2 = PB4
//LPS3 = PB5
#define LPS_SENSOR_SPACING 2 // cm
//#define LPS_OFFSET 0.03f
#define LPS_MIN 0.001f
#define LPS_THRE... | 1,330,908 |
the-stack-v2-dedup | C | /************************************************************************
*
* copyright(c)2012-20xx Newland Co. Ltd. All rights reserved
* module : 打印模块
* file name : prnt22.c
* Author : linwl
* version :
* DATE : 20130105
* directory :
* description : 测试NDK_PrnGetDotData接口根据输入字符串获取出系统指定打印字体相应的点阵缓冲
* relate... | 1,330,909 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* :::::::: */
/* ft_strtrim.c :+: :+: ... | 1,330,910 |
the-stack-v2-dedup | C | //////////////////////////////////////////////////
/* 9/29/17
* Dana Olcott
* gpio_driver.h
* Header file for gpio driver using the /dev/
* file system.
*/
#ifndef MEMORY_H
#define MEMORY_H
#define MEMORY_WRITE_BUFFER_SIZE 2048
void memory_init(void);
unsigned char* memory_getActiveBuffer(void);
#endif
| 1,330,911 |
the-stack-v2-dedup | C | #define NULL ((void*)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t; typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1
/* Forward d... | 1,330,912 |
the-stack-v2-dedup | C | #pragma once
#include <stdint.h>
struct motor_group;
// pins must be an array of length 8 - it is undefined behavior otherwise
struct motor_group* motor_make_group(const int* pins);
void motor_free_group(struct motor_group* mg);
void motor_forward(struct motor_group* mg);
void motor_stop(struct motor... | 1,330,913 |
the-stack-v2-dedup | C | list_t* listClone(list_t* l, funcDup_t* fn){
listElem_t* aCopiar = l->first;
list_t* nuevaLista = listNew();
while(aCopiar != NULL){
void* dataCopy = fn(aCopiar->data);
listAddLast(nuevaLista, dataCopy);
}
return nuevaLista;
} | 1,330,914 |
the-stack-v2-dedup | C | /**
* Autogenerated by Thrift Compiler (0.9.1)
*
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
* @generated
*/
#include <string.h>
#include <thrift/c_glib/thrift.h>
#include <thrift/c_glib/thrift_application_exception.h>
#include "bulletin_board.h"
gboolean
bulletin_board_if_add (BulletinBoa... | 1,330,915 |
the-stack-v2-dedup | C |
#include <ssw.h>
#include "cust_gpio_usage.h"
/*--------------Feature option---------------*/
#define __ENABLE_SSW_SYSFS 1
/*--------------SIM mode list----------------*/
#define SINGLE_TALK_MDSYS (0x1)
#define SINGLE_TALK_MDSYS_LITE (0x2)
#define DUAL_TALK (0x3)
#de... | 1,330,916 |
the-stack-v2-dedup | C | #ifndef ABOV_BITOP_H
#define ABOV_BITOP_H
#if defined(__cplusplus)
extern "C" {
#endif
#include <stdint.h>
#include <stdbool.h>
static inline void bitop_set(volatile uint32_t *reg, uint32_t pos)
{
*reg |= 1U << pos;
}
static inline void bitop_clear(volatile uint32_t *reg, uint32_t pos)
{
*reg &= ~(1U << pos);
}
... | 1,330,917 |
the-stack-v2-dedup | C | /*
* circular_buffer.c
* Author: Fabio Crestani
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <pthread.h>
#include "circular_buffer.h"
void buffer_init(CircularBuffer *buf, size_t element_size)
{
buf->buffer_size = DEFAULT_BUFFER_SIZE;
buf->element_counter = 0;
buf->idx_prod = 0;... | 1,330,918 |
the-stack-v2-dedup | C | #include<stdio.h>
int main()
{
char s[80],str[80];
printf("输入一个字符串:\n");
gets(s);
int i,l;
char c[80];
l=strlen(s);
for(i=0;i<=l-1;i++)
{
s[l-1-i]=s[i];
}
s[l]='/0';
strcpy(c,s);
if(strcmp(c,s)==0)
printf("%s 是回文",c);
}
| 1,330,919 |
the-stack-v2-dedup | C | #include <msp430.h>
#include "game.h"
#include "lcd.h"
#include "button.h"
void init_timer();
void init_buttons();
int TIMER = 0; //tracks if game is in progress or lost
int LOSE = 0;
int GAMEOVER = 0;
int main(void) {
WDTCTL = WDTPW | WDTHOLD; // Stop watchdog timer
initSPI();
LCDinit();
LCDclea... | 1,330,920 |
the-stack-v2-dedup | C | #include <assert.h>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
int main() {
int i, j, k, l, m, n, t;
int i1, i2;
#pragma scop
for (t = 0; t < T; t++) {
for (i1 = 0; i1 < N; i1++) {
for (i2 = 1; i2 < N; i2++) {
X[i1][i2] = X[i1][i2] - X[i1][i2 - 1] * A[i1][i2] / B[i1][i2 - 1];
... | 1,330,921 |
the-stack-v2-dedup | C | #include <sys/mman.h>
#include <unistd.h>
#include <stdio.h>
int main(){
off_t p, file_size;
int pagesize;
size_t len;
char *mp;
pagesize = getpagesize();
if((file_size = lseek(0, 0, SEEK_END)) < 0){
perror("lseek error");
return 1;
}
len = pagesize;
for(p=0; p<file_size; p+=len){
i... | 1,330,922 |
the-stack-v2-dedup | C | #include <file.h>
#include <mach/io.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <assert.h>
#include <extras.h>
#include "common.h"
struct fs_state {
file_desc* fds[MAX_FDS];
dir_desc* dds[MAX_FDS];
const char * cwd;
};
fs_state* ctor_state() {
fs_state * st = calloc(sizeof(fs_state... | 1,330,923 |
the-stack-v2-dedup | C | #include <linux/init.h>
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/gpio.h> // Required for the GPIO functions
#include <linux/delay.h> // Using this header for the msleep() function
#include<linux/timer.h>
#include <linux/device.h>
#include <asm/uaccess.h>
static struct timer_list m... | 1,330,924 |
the-stack-v2-dedup | C |
extern void __attribute__((noreturn)) hang();
extern void c_start();
#define CODE_SELECTOR 0x08
#define DATA_SELECTOR 0x10
| 1,330,925 |
the-stack-v2-dedup | C | #include <stdio.h>
class foo
{
public:
virtual void fred() { printf("Foo!\n"); }
};
class bar : public foo
{
public:
virtual void fred() { printf("Bar!\n"); }
};
foo x;
bar y;
foo *z;
main()
{
x=y;
(&x)->fred();
z= &y;
z->fred();
}
| 1,330,926 |
the-stack-v2-dedup | C | /*
* MplUtil.h
*
* Created on: Feb 6, 2018
* Author: Aaron
*/
#ifndef MPLUTIL_H_
#define MPLUTIL_H_
typedef enum modeMPL_t {
ALTITUDE_MODE, /**< Set the MPL to output the altitude in meters*/
PRESSURE_MODE /**< Set the MPL to output the absolute pressuire in Pascals*/
} modeMPL_t;
typedef enum measure... | 1,330,927 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_strdel.c :+: :+: :+: ... | 1,330,928 |
the-stack-v2-dedup | C | #pragma bank 8
const unsigned char bank_8_data[] = {
165,47,158,170,3,155,22,231,143,241,32,32,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,165,47,158,44,155,22,0,32,32,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,165,44,158,47,155,22,231,15,32,32,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,165,47,158,44,155,22,0,32,32,32,0,0,0,0,0,0,0,0,0,... | 1,330,929 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_lst_sort.c :+: :+: :+: ... | 1,330,930 |
the-stack-v2-dedup | C | /*************************************************************************
> File Name: src/vector.c
> Author : Wang Xu
> Tips: 1.按F5可以直接编译并执行C、C++、java代码以及执行shell脚本,按“F8”可进行C、C++代码的调试
> Tips: 2.按“F2”可以直接消除代码中的空行、“F3”可列出当前目录文件,打开树状文件目录。按“Ctrl + P”可自动补全
> Tips: 3.使用:sp + 文件名可以水平分割窗口,使用:vs + 文件名可以垂直分割窗口,使用Ctrl + w... | 1,330,931 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* shading.h :+: :+: :+: ... | 1,330,932 |
the-stack-v2-dedup | C | /**************************************************************
Problem: 1695
User: jhyunlee
Language: C++
Result: Success
Time:0 ms
Memory:1092 kb
****************************************************************/
/*
1. N*N 배열에 대해서 기본적으로 순차적으로 검색을 진행한다.
2. 0이 아닌 항목을 만나면 backtrace로 탐색을 한다.
3.... | 1,330,933 |
the-stack-v2-dedup | C | #include<stdio.h>
#include<string.h>
static int n = 3233;
static int e = 17;
static int d = 2753;
static char txt[] = "37|安步荣|男|14243119840524603X|1984-05-23||中国|大学毕业|||海南省洋浦经济开发区新英湾区港务公司宿舍港务公司宿舍临街公寓8楼802||||B2|2007-01-26|||0||4601000020014094737|460000213459|经营性道路货物运输驾驶员|2014-03-20|2020-03-19|海口市道路运输管理处";
#def... | 1,330,934 |
the-stack-v2-dedup | C | /* SPDX-License-Identifier: GPL-2.0
*
* Copyright 2016-2018 HabanaLabs, Ltd.
* All Rights Reserved.
*
*/
/************************************
** This is an auto-generated file **
** DO NOT EDIT BELOW **
************************************/
#ifndef ASIC_REG_CPU_CA53_CFG_REGS_H_
#define ASIC_REG_... | 1,330,935 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_strcmp.c :+: :+: :+: ... | 1,330,936 |
the-stack-v2-dedup | C |
DWORD LdrGetProcAddress(PVOID Image, char *lpszName);
BOOL LdrProcessRelocs(PVOID Image, PVOID NewBase);
BOOL LdrMapImage(PVOID Data, DWORD dwDataSize, PVOID *Image, PDWORD pdwImageSize);
| 1,330,937 |
the-stack-v2-dedup | C | #include "stm32f4xx.h"
#include "delay.h"
#include "ticker.h"
static uint32_t fac_ms = 0;
void delay_init()
{
fac_ms = Ticker_Get_MS_Tickcount();
}
void delay_us(uint32_t nus)
{
uint64_t curtick = Ticker_Get_Tick();
uint64_t endtick = curtick + ((uint64_t)nus * (uint64_t)fac_ms) / 1000;
while(... | 1,330,938 |
the-stack-v2-dedup | C |
#include <stdio.h>
#include <string.h>
void print2D(char af[][50], int n);
void exchange2D(char inputz[][50]);
int main(int argc, char **argv) {
char inputs[30][50];
int current_row = 0;
printf("sizeof inputs: %d\n", sizeof(inputs));
printf("\nEnter string: ");
fgets(inputs[current_row++], 50, stdin);
cha... | 1,330,939 |
the-stack-v2-dedup | C | /* vim: set ts=8 sw=8 sts=8 noet tw=78:
*
* tup - A file-based build system
*
* Copyright (C) 2011-2018 Mike Shal <marfey@gmail.com>
*
* 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 Free Software Foun... | 1,330,940 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* main.c :+: :+: :+: ... | 1,330,941 |
the-stack-v2-dedup | C | #include "net.h"
#include "defines.h"
#include "debug.h"
#include <assert.h>
#include <unistd.h>
int tcp_send(int fd, char *buf, int len)
{
fstart("fd: %d, buf: %p, len: %d", fd, buf, len);
int sent, offset;
struct timeval tv;
time_t curr, limit;
gettimeofday(&tv, NULL);
curr = tv.tv_sec;
limit = curr + ... | 1,330,942 |
the-stack-v2-dedup | C | #include<stdio.h>
#include<conio.h>
#include<math.h>
int checkPrimeNumber(int n);
int main()
{
int i,flag=0,n;
printf("\nEnter a number:");
scanf("%d",&n);
//check for prime
for ( i = 2; i <= n/2; ++i)
{
if (checkPrimeNumber(i)==1)
{
if (checkPrimeNumber(n-i)==... | 1,330,943 |
the-stack-v2-dedup | C | #include "../headers/card.h"
card *create_card(signed short postNumber, signed short workshopNumber, int nbComponent, int reference, int designation, int order){
card *c = malloc(sizeof(card));
c->postNumber = postNumber;
c->workshopNumber = workshopNumber;
c->nbComponent = nbComponent;
c->referen... | 1,330,944 |
the-stack-v2-dedup | C | /* This program takes input from the user through STDIN
* and executes it as a system command using system().
* The output is then printed to the consol.
*/
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
int main(){
printf("Enter a system command\n");
const int STR_SIZE = 1024;
char str[STR_... | 1,330,945 |
the-stack-v2-dedup | C | /**
* Copyright (c) 1998-2009 Nokia Corporation and/or its subsidiary(-ies).
* All rights reserved.
* This component and the accompanying materials are made available
* under the terms of "Eclipse Public License v1.0"
* which accompanies this distribution, and is available
* at the URL "http://www.eclipse.org/legal/epl... | 1,330,946 |
the-stack-v2-dedup | C | /**
histogram.c
Calculates the histogram of a random 2D matrix with integer
values in the range [0..255].
Compilation:
============
g++ histogram.c -fopenmp -o histogram
Execution:
==========
./histogram <n>
**/
#include <cstdio>
#include <cstdlib>
#include <ctime>
#include <cmath>
#include <om... | 1,330,947 |
the-stack-v2-dedup | C | #include <stdio.h>
int main() {
int year, month, day, time;
while(scanf("%d/%d/%d", &year, &month, &day)!=EOF) {
int leap = 0;
if((year%4==0 && year%100!=0) || (year%400==0)) {
leap = 1;
}
if(month < 3) {
time = (month-1)*31 + day;
} else if (month < 8) {
time = leap + 59 + (31*(month>3)... | 1,330,948 |
the-stack-v2-dedup | C | #ifndef v1_rolling_update_stateful_set_strategy_TEST
#define v1_rolling_update_stateful_set_strategy_TEST
// the following is to include only the main from the first c file
#ifndef TEST_MAIN
#define TEST_MAIN
#define v1_rolling_update_stateful_set_strategy_MAIN
#endif // TEST_MAIN
#include <stdlib.h>
#include <string... | 1,330,949 |
the-stack-v2-dedup | C | void gf_regress_logit_init_unw(
ST_double *yptr,
ST_double *wptr,
ST_double *mu,
ST_double *wgt,
ST_double *eta,
ST_double *dev,
ST_double *lhs,
GT_size nj)
{
GT_size i;
ST_double mean = 0;
for (i = 0; i < nj; i++) {
mean += yptr[i];
}
mean /= (ST_double) nj;
... | 1,330,950 |
the-stack-v2-dedup | C | #include <iostream>
using namespace std;
int main ()
{
int n,t,i=0,j=0,max=-1;;
unsigned long long *saida; /*Vetor que armazenará as saídas que serão mostradas*/
unsigned long long *fibon;/*Vetor que armazenará os números de fibonacci*/
int *ent; /*Vetor que armazenará as entradas passadas pelo usuár... | 1,330,951 |
the-stack-v2-dedup | C | /*
* Copyright 2008 Jim Schaad and Paul Hoffman. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this lis... | 1,330,952 |
the-stack-v2-dedup | C | /*
* Copyright (c) 2017 SUSE LLC.
* 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 to ... | 1,330,953 |
the-stack-v2-dedup | C | dimensionedScalar one = dimensionedScalar("one", dimensionSet(0,1,0,0,0,0,0), 1.0);
Info<< "Reading transportProperties\n" << endl;
IOdictionary transportProperties
(
IOobject
(
"transportProperties",
runTime.constant(),
mesh,
IOobject::MUST_READ,
IOobject::NO_WRITE
)
);
dictionary ... | 1,330,954 |
the-stack-v2-dedup | C | /* DO NOT EDIT THIS FILE - it is machine generated */
#include <StubPreamble.h>
/* Stubs for class java_io_File */
/* SYMBOL: java_io_File_exists0()Z */
void
Kaffe_java_io_File_exists0_stub(stack_item* _P_, stack_item* _R_)
{
extern jbool java_io_File_exists0(void*);
jbool ret = java_io_File_exists0(_P_[0].p);
ret... | 1,330,955 |
the-stack-v2-dedup | C | template <bool B> struct A { };
template <class T> void f()
{
A<T::I < T::J>();
}
| 1,330,956 |
the-stack-v2-dedup | C | #include "Header files/md2Loader.h"
#include <stdio.h>
#include <stdlib.h>
#include <assert.h>
md2* loadModel(char* filepath) {
// Funktio lataa MD2-formaatin mallin muistiin. Palauttaa
// tyhjän osoittimen, jos mallin lataaminen epännistuu.
md2* md2_file = malloc(sizeof(md2));
FILE* f =... | 1,330,957 |
the-stack-v2-dedup | C | #include <room.h>
#include <ansi.h>
inherit ROOM;
void create()
{
set("short", HIR"敬师堂"NOR);
set("long", @LONG
这是一间方方正正的屋子,正北挂着千秋文圣孔子像,前面摆着香案,
青烟袅袅。新人可以在这里拜入(baishi)导师门下,接受导师的帮助,以最
快的速度融入北侠。新人经验超过10M ,并且通过实名验证以后,就可以在
这里结业,并给导师评分。(pingfen)
LONG );
set("no_fight", 1);
set("no_... | 1,330,958 |
the-stack-v2-dedup | C | // SPDX-License-Identifier: GPL-2.0-only
/*
* Intel MIC Platform Software Stack (MPSS)
*
* Copyright(c) 2015 Intel Corporation.
*
* Intel MIC Coprocessor State Management (COSM) Driver
*/
#include <linux/kthread.h>
#include <linux/sched/signal.h>
#include "cosm_main.h"
/*
* The COSM driver uses SCIF to communi... | 1,330,959 |
the-stack-v2-dedup | C | #include <stdio.h>
#include <ctype.h>
#define MAXLEN 100
void upperLower(char *word) {
int i = 0;
while(word[i] != '\0') {
if(islower(word[i])) {
word[i] = word[i] - 32;
} else {
word[i] = word[i] + 32;
}
i++;
}
}
int main(int argc, char **argv)
{
... | 1,330,960 |
the-stack-v2-dedup | C | #region Local Var
var uLocal_0 = 7;
var uLocal_1 = 0;
var uLocal_2 = 0;
var uLocal_3 = 0;
var uLocal_4 = 0;
var uLocal_5 = 0;
var uLocal_6 = 0;
var uLocal_7 = 0;
var uLocal_8 = -1;
var uLocal_9 = 0;
var uLocal_10 = 0;
var uLocal_11 = 0;
var uLocal_12 = 0;
var uLocal_13 = 0;
float fLocal_14 = 0f;
float f... | 1,330,961 |
the-stack-v2-dedup | C | #ifndef lint
static const char yysccsid[] = "@(#)yaccpar 1.9 (Berkeley) 02/21/93";
#endif
#define YYBYACC 1
#define YYMAJOR 1
#define YYMINOR 9
#define YYPATCH 20140101
#define YYEMPTY (-1)
#define yyclearin (yychar = YYEMPTY)
#define yyerrok (yyerrflag = 0)
#define YYRECOVERING() (yyerrflag != 0)
... | 1,330,962 |
the-stack-v2-dedup | C | #include <stdio.h>
int main()
{
int aux, aux2;
aux = 1;
for (aux = 1; aux <= 10; aux++)
{
aux2 = aux * 5;
printf ("\n%d * 5 = %d\n", aux, aux2);
}
system ("pause");
return 0;
} | 1,330,963 |
the-stack-v2-dedup | C | // Copyright 2010-2016 Espressif Systems (Shanghai) PTE 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 a... | 1,330,964 |
the-stack-v2-dedup | C | /*++
Copyright (c) 2000, Microsoft Corporation
Module Name:
eldialog.h
Abstract:
Module to handle the communication from 802.1X state machine to netshell
Revision History:
sachins, March 21, 2001, Created
--*/
#ifndef _EAPOL_DIALOG_H_
#define _EAPOL_DIALOG_H_
#pragma once
typedef enum _EAPOL_NCS_ST... | 1,330,965 |
the-stack-v2-dedup | C | #include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <signal.h>
#include "PmodCLS.h"
static int loop_exit;
void sig_handler(int signo)
{
if (signo == SIGINT)
loop_exit = 1;
}
char szInfo1[0x20];
char szInfo2[0x20];
int main()
{
if (signal(SIGINT, sig_handler) == SIG_ERR) {
fprintf(stderr, "can'... | 1,330,966 |
the-stack-v2-dedup | C | #include <stdio.h>
int main()
{
long decimalnum, quotient;
int converted[100], i = 1, j;
int base;
scanf("%ld %d", &decimalnum, &base);
quotient = decimalnum;
do
{
converted[i++] = quotient % base;
quotient = quotient / base;
} while (quotient != 0);
for (j = i - 1; j > 0; j--)
printf("%X", converte... | 1,330,967 |
the-stack-v2-dedup | C | #include "wave.h"
int doNextStep = 1;
int numtasks;
int taskid;
gboolean on_window_configure_event(GtkWidget *da, GdkEventConfigure *event, gpointer user_data)
{
static int oldw = 0;
static int oldh = 0;
if (oldw != event->width || oldh != event->height)
{
GdkPixmap *tmppixmap = gdk_pixmap_ne... | 1,330,968 |
the-stack-v2-dedup | C | /*
+----------------------------------------------------------------------+
| Yet Another Framework |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundl... | 1,330,969 |
the-stack-v2-dedup | C | void music_start();
void music_stop();
void music_processChannel();
#include "modplay.c"
| 1,330,970 |
the-stack-v2-dedup | C | //290207
#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>
struct wezel{
int x;
struct wezel *lewy, *prawy;
};
struct wezel *wstaw(struct wezel *wez, int wartosc){
if (wez==NULL){
struct wezel *tmp;
tmp = (struct wezel *)malloc(sizeof(struct wezel));
tmp->x = wartosc;
... | 1,330,971 |
the-stack-v2-dedup | C | #define DDEBUG 1
#include <lauxlib.h>
#include <stdlib.h>
#include <time.h>
//static const long mask = (1L << 48) - 1;
//static const long multiplier = 0x5DEECE66DL;
//static const long addend = 0xBL;
static const long long multiplier = 25214903917/*0x5DEECE66DL*/;
static const long long addend = 11/*0xBL*/;
stat... | 1,330,972 |
the-stack-v2-dedup | C | /*********************************************************************************************************
**
** 中国软件开源组织
**
** 嵌入式实时操作系统
**
** SylixOS(TM)
**
** Copyright All Rights... | 1,330,973 |
the-stack-v2-dedup | C | #ifndef TIMER_H_
#define TIMER_H_
#include "clock.h"
// Initialize the timer with the user-provided input
void initTimer(ClockType *clock, int minutes, int seconds);
// Run the timer -- print out the time each second
void runTimer();
// Clean up memory (as needed)
void cleanTimer(ClockType *clock);
#e... | 1,330,974 |
the-stack-v2-dedup | C | /**************************************************************************
fichero: minas19.c
Autor: Riberales
Creación: 31/10/05
Descripción: Room en primera planta de las minas, bajada a la segunda.
**************************************************************************/
#include "path.h"
inherit HAB_PRIMERA_M... | 1,330,975 |
the-stack-v2-dedup | C | // finding first or last occurence of a number
#include <bits/stdc++.h>
using namespace std;
ifstream myin("data.in");
ofstream myout("data.out");
int first_occurence( vector<int> &arr, int key ) // O(log n)
{
int l=0;
int r=arr.size()-1;
int result=-1;
while(l<=r)
{
int m=(l+r)/2;
... | 1,330,976 |
the-stack-v2-dedup | C | //Chapter 6 Programming Project #4 from King's Modern C
//add a loop to the broker.c program so that users can enter more than one trade
//and the program will calculate the commission on each
//the program should terminate when the user enters 0 as a trade value
#include <stdio.h>
int main(void)
{
float commission... | 1,330,977 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_flags_hex_three.c :+: :+: :+: ... | 1,330,978 |
the-stack-v2-dedup | C | #include <stdio.h>
#include <errno.h>
#include <string.h>
#include <arpa/inet.h>
#include <netinet/if_ether.h>
#include <linux/netfilter/xt_mac.h>
#include <libiptc/libiptc.h>
static int
insert_rule (const char *table,
const char *chain,
unsigned int src,
int inverted_src,
... | 1,330,979 |
the-stack-v2-dedup | C | // license:BSD-3-Clause
// copyright-holders:etabeta
/***********************************************************************************************************
Fairchild Channel F cart emulation
(through slot devices)
**********************************************************************************... | 1,330,980 |
the-stack-v2-dedup | C | #include "./path.h"
#include <skills.h>
#include <properties.h>
inherit NPC;
create () {
::create();
seteuid(getuid());
SetStandard("Ronn","gigante",([GC_NINGUNO:60]),GENERO_MASCULINO);
SetIds(({"gigante"}));
SetShort("Ronn, el tendero");
SetAlign(-10);
SetWhimpy(0); // O mata o muere
SetAggressive(0);
Ad... | 1,330,981 |
the-stack-v2-dedup | C | /*
* Copyright (c) 2016-2019 Marco Hladik <marco@icculus.org>
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS"... | 1,330,982 |
the-stack-v2-dedup | C | #define _CRT_SECURE_NO_WARNINGS
//page 1~2 xxxxx
//page 3
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <math.h>
#define MaxSymbols 200
#define MaxRules 100
#define MaxNumberOfStates 200
#define EOF_TOK 52 //EOF 토큰 수정
#define URT 48
// URT hw1 에서 추가
typedef struct tkt //하... | 1,330,983 |
the-stack-v2-dedup | C | #pragma once
/**
* Copyright (c) blueback
* Released under the MIT License
* https://github.com/bluebackblue/brownie/blob/master/LICENSE.txt
* http://bbbproject.sakura.ne.jp/wordpress/mitlicense
* @brief gdiplus
*/
/** include
*/
#include <brownie_config/windows_include.h>
/** include
*/
#p... | 1,330,984 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* cli.c :+: :+: :+: ... | 1,330,985 |
the-stack-v2-dedup | C | /* ====================================
File name: exerc_6_1.c
Date: 2019-03-09
Group nr 04
Members that contribute to the solutions
Filip Fatic
Naief Jobsen
David Lindgren
Demonstration code: [7116]
====================================== */
#include <stdio.h>
#include <stdlib.h>
#include <pthread.h>
#define num_elem... | 1,330,986 |
the-stack-v2-dedup | C | /**
* tbxsosd/libcomm/poll_comm.c
* Copyright (C) 2006-2012 Opersys 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 copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unle... | 1,330,987 |
the-stack-v2-dedup | C |
#include <stdio.h>
#include <fcntl.h>
#include <errno.h>
#include <string.h>
#include <unistd.h>
#include <assert.h>
#include "common.h"
#include "classify.h"
//Project 3
//Max Forbang and Martin Quezada
//This work abides by the JMU Honor Code.
int main(int argc, char *argv[])
{
int input_fd;
int classific... | 1,330,988 |
the-stack-v2-dedup | C | #include "mpi.h"
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <stdint.h>
#include <sys/time.h>
#define N 2048 /* grid dimension */
#define SRAND_VALUE 1985 /* seed to generate pseudo-random numbers to fill the first grid*/
#define MAX_IT 2000
/* Auxiliar function to print the matrix */
void Print... | 1,330,989 |
the-stack-v2-dedup | C | #include <stdio.h>
int arr1[] = {7, 1, 5, 2, 3, 6};
int arr2[] = {3, 8, 6, 20, 7};
int m = sizeof(arr1) / sizeof(arr1[0]);
int n = sizeof(arr2) / sizeof(arr2[0]);
void quicksort(int number[],int first,int last)
{
int i, j, pivot, temp;
if(first<last){
pivot=first;
i=first;
j=las... | 1,330,990 |
the-stack-v2-dedup | C | #define DEFAULT_MIDI_PORT 5004
#define DBG_PORT Debug
#define USE_SPI_VS1053
#define VS1053_RESET 15
#define VS1053_MOSI 13
#define VS1053_MISO 12
#define VS1053_SCK 14
#define VS1053_XDCS 5 // 16 doesnt work very well
//void setup_SerialMIDI();
//void setup_AppleMIDI();
//void setup_vs1053();
| 1,330,991 |
the-stack-v2-dedup | C |
#ifndef USART_H
#define USART_H
#include <stdio.h>
#include "stm32f4xx.h"
#include "stm32f4xx_usart.h"
#include "stm32f4xx_rcc.h"
#include "stm32f4xx_gpio.h"
#include "misc.h"
//一文字送信
//void transmit_uart2_c(char c);
//文字列送信
//void transmit_uart2_s(char *s);
//一文字送信
void transmit_uart3_c(char c);
//文字列送信
void tran... | 1,330,992 |
the-stack-v2-dedup | C | /* Mulator - An extensible {e,si}mulator
* Copyright 2011-2020 Pat Pannuto <pat.pannuto@gmail.com>
*
* Licensed under either of the Apache License, Version 2.0
* or the MIT license, at your option.
*/
void mla(uint8_t rd, uint8_t rn, uint8_t rm, uint8_t ra);
void mls(uint8_t rd, uint8_t rn, uint8_t rm, uint8_t ra... | 1,330,993 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_isalpha_up.c :+: :+: :+: ... | 1,330,994 |
the-stack-v2-dedup | C | #ifndef _HK_IMPL_LAYER_H_
#define _HK_IMPL_LAYER_H_
#define _HK_LAYER_STR "HK_LAYER_STD_validation"
#include "utils/layer_utils.h"
PFN_hkVoidFunction hkNextInstanceProcAddr(HkInstance instance, const char* pname);
#endif /*_HK_IMPL_LAYER_H_*/ | 1,330,995 |
the-stack-v2-dedup | C | #ifndef MAIN_H_
#define MAIN_H_
/**************************************
Define the LCD Control Pins
**************************************/
const int IC_A0 = 3; // L:Command,H:Data - Broadcom pin xx, P1 pin x
const int IC_WR = 04; // L: Write, H: Read - Broadcom pin 04, P1 pin 07
const int IC_RD = 17;... | 1,330,996 |
the-stack-v2-dedup | C | #ifndef COMMON_H
#define COMMON_H
#define FONT_PATH "/usr/lib/fonts/MicroHei.ttc"
#define FONT_NAME "WenQuanYi Micro Hei"
#define SSP_SDK_CORE_LIBRARY_PATH "/var/applink/lib/SSP_SDK_Core"
#define SSP_ASSISTANT_LIBRARY_PATH "/var/applink/lib/SSP_Assistant"
#ifndef DEBUG
#define DEBUG 0
#endif
#if DEBUG
#define DEB... | 1,330,997 |
the-stack-v2-dedup | C | /****************************************************************************/
/* */
/* Module Name: DCB.H */
/* */
/* O... | 1,330,998 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* is.c :+: :+: :+: ... | 1,330,999 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.