source string | code_lang string | content string | idx int64 |
|---|---|---|---|
the-stack-v2-dedup | C | /*************************************************************************
> File Name: pthreadsyn2.c
> Author :miaogen miaogen
> Mail: miaogen_work.163.com
> Created Time: Sun 14 May 2017 09:18:19 AM CST
************************************************************************/
#include<stdio.h>
#inc... | 1,327,700 |
the-stack-v2-dedup | C | #include<stdio.h>
int fun(const char *c)
{
int k = 0;
while (Isdig(*c))
{
k = k*10 + c - '0';
++c;
}
return k;
}
| 1,327,701 |
the-stack-v2-dedup | C | //#include <stdlib.h>
//#include <stdio.h>
//#include <sys/time.h>
//#include <time.h>
//#include <string.h>
#include <assert.h>
#include "hashmap.h"
#include "stack.h"
#include "hashmap.c"
#include "stack.c"
typedef long int __time_t;
typedef long int __suseconds_t;
struct timeval2 {
__time_t tv_sec ;
__susecond... | 1,327,702 |
the-stack-v2-dedup | C | // BlueprintGeneratedClass Prj_Athena_FloppingRabbit_HighTier.Prj_Athena_FloppingRabbit_HighTier_C
// Size: 0xce1 (Inherited: 0xce1)
struct APrj_Athena_FloppingRabbit_HighTier_C : APrj_Athena_FloppingRabbit_C {
};
| 1,327,703 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_memchr.c :+: :+: :+: ... | 1,327,704 |
the-stack-v2-dedup | C | Ticker D3_delay;
Ticker send_delay;
Ticker second_tick;
void update_time (void) {
UnixTimestamp++;
}
void Send_Data (void) {
send_mqtt_data = true;
if (config_dev.ADC_EN) {
ADC_data = analogRead (A0);
Serial.println ("ADC data: " + (String)ADC_data);
}
}
void D3_pressed (void) {
D3_delay.detach ();... | 1,327,705 |
the-stack-v2-dedup | C | /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public License
* Version 1.0 (the "NPL"); you may not use this file except in
* compliance with the NPL. You may obtain a copy of the NPL at
* http://www.mozilla.org/NPL/
*
* So... | 1,327,706 |
the-stack-v2-dedup | C | r[0]=sp[(2*c[0])*2*_N+(2*c[1])]+sp[(2*c[1])*2*_N+(2*c[1]+1)]+sp[(2*c[1]+1)*2*_N+(2*c[2])]+sp[(2*c[2])*2*_N+(2*c[2]+1)]+sp[(2*c[2]+1)*2*_N+(2*c[3])]+sp[(2*c[3])*2*_N+(2*c[3]+1)]+sp[(2*c[3]+1)*2*_N+(2*c[0]+1)];
r[1]=sp[(2*c[0])*2*_N+(2*c[1])]+sp[(2*c[1])*2*_N+(2*c[1]+1)]+sp[(2*c[1]+1)*2*_N+(2*c[2])]+sp[(2*c[2])*2*_N+(2*c... | 1,327,707 |
the-stack-v2-dedup | C | #ifndef COMMON_H
#define COMMON_H __FILE__
#include <stddef.h>
#ifndef ARRAY_SIZE
#define ARRAY_SIZE(a) (sizeof(a) / sizeof(a[0]))
#endif
#ifndef container_of
#define container_of(ptr,type,member) \
((type*)(((const char*)ptr) - offsetof(type,member)))
#endif
#endif /* COMMON_H */
| 1,327,708 |
the-stack-v2-dedup | C | #include <math.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
/* Observer les filiations */
/* En jouant sur la durée d’endormissement, on doit voir ce qui se
* passe quand :
* - quand le père se termine avant le fils,
* - quand le fils se termine avant le père. */
in... | 1,327,709 |
the-stack-v2-dedup | C | #DEFINE GKKDEFINES .T.
*-*
*-* Method types
*-*
#DEFINE METHOD_TYPE_STOCK 1
#DEFINE METHOD_TYPE_CUSTOM 2
#DEFINE METHOD_TYPE_OBJECT 3
#DEFINE METHOD_TYPE_PROPERTY 4
*-*
*-* Method/Property Visibility
*-*
#DEFINE VISIBILITY_PUBLIC 1
#DEFINE VISIBILITY_HIDDEN 2
#DEFINE VISIBILITY_PROTECTED 3
... | 1,327,710 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_fibonacci.c :+: :+: :+: ... | 1,327,711 |
the-stack-v2-dedup | C |
public func IsAmmo() { return true; }
public func MaxAmmo() { return 100; }
| 1,327,712 |
the-stack-v2-dedup | C | #include "../include/importa.h"
#include "../include/imprime.h"
void imprime(){
FILE *btree = abrir_arquivo("btree.dat", "rb");
int raiz, paginas = 0, chaves = 0;
fread(&raiz, START, 1, btree);
printa(btree, raiz, &paginas, &chaves);
printf("\n- - - - - - - - - - - - - -\n");
printf("Estatis... | 1,327,713 |
the-stack-v2-dedup | C | #include <math.h>
#include <stdio.h>
#ifdef __MINGW32__
#define getchar_unlocked getchar
#endif
static inline long long getNum()
{
int c = getchar_unlocked() - '0';
long long res = 0;
while(c < 0 || c > 9)
c = getchar_unlocked() - '0';
res = c;
c = getchar_unlocked... | 1,327,714 |
the-stack-v2-dedup | C | #include <stdio.h>
#include<string.h>
int main()
{
char sum[1000],x;
int i,j,c=0,l=0,a[1000];
gets(sum);
for(i=0;sum[i]!='\0';i++)
{
c=1;
for(j=i+1;sum[j]!='\0';j++)
{
if(sum[i]!='$'&&sum[j]!='$')
{
if(sum[i]==sum[j])
{
c++;
sum[j]='$';
... | 1,327,715 |
the-stack-v2-dedup | C | /*
* The MIT License (MIT)
*
* Copyright (c) 2020-2021 Alexander Chumakov
*
* 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... | 1,327,716 |
the-stack-v2-dedup | C | #include <msp430fr6989.h>
#define true 1
#define false 0
// Peripheral pin assignments
#define ECHO BIT2 // Echo at P2.2
#define TRIG BIT3 // Trigger at P2.3
#define redLED BIT0 // Red LED at P1.0
#define greenLED BIT7 // Green LED at P9.7
unsigned int up_counter ... | 1,327,717 |
the-stack-v2-dedup | C | /*Задача 8.Дефинирайте и инициализирайте променлива и пойнтер към нея.
Отпечатайте адреса на пойнтера с %p с printf.*/
#include <stdio.h>
int main()
{
float f = 5.5;
float *pf = &f;
printf("address of *pf is %p.\n", &pf);
return 0;
} | 1,327,718 |
the-stack-v2-dedup | C | #include<stdio.h>
#include<string.h>
int n,i,j,sry,lhy,lgx[51],lyj;
char srx[51][51],t[51];
int main()
{
scanf("%d",&n);
for(i=1;i<=n;++i)
{scanf("%s",t);
if(sry==0)
{sry++;
strcpy(srx[sry],t);
continue;}
for(j=1;j<=sry;++j)
if(strcmp(srx[j],t)==0)
{lgx[j]++;
lhy=1;
... | 1,327,719 |
the-stack-v2-dedup | C | /**************************************************************************************/
/*Author: Aditya.Kothari */
/*Assignment #2 */
/*Description: - read 2 values from the user
... | 1,327,720 |
the-stack-v2-dedup | C | /********************************************************************/
/* Copyright (C) MC2Lab-USTC, 2012 */
/* */
/* FILE NAME : dbserver.c */
/* PRINCIPAL AUTHOR : M... | 1,327,721 |
the-stack-v2-dedup | C | /*
* Copyright (c) 2021 HPMicro
*
* SPDX-License-Identifier: BSD-3-Clause
*
*/
#include "hpm_ov5640.h"
static const ov5640_reg_val_t ov5640_init_param[] = {
/* system setting */
{0x3008, 0x42}, /* software power down, bit[6] */
{0x3103, 0x03}, /* system clock from PLL, bit[1] */
{0x3037, 0x13}, ... | 1,327,722 |
the-stack-v2-dedup | C | // Программа A принимает из стандартного потока ввода строки, а далее их отправляет программе С. Отправка строк должна производится построчно.
// Затем пересылает B количество отправленных символов
#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
#include <signal.h>
#include <string.h>
#include "get_line/... | 1,327,723 |
the-stack-v2-dedup | C | /*----------------------------------------------------------------------------*/
/* Copyright (c) FIRST 2016. All Rights Reserved. */
/* Open Source Software - may be modified and shared by FRC teams. The code */
/* must be accompanied by the FIRST BSD license file in the root directory of... | 1,327,724 |
the-stack-v2-dedup | C |
#include <18F2550.h>
#fuses HSPLL,NOWDT,NOPROTECT,NOLVP,NODEBUG,USBDIV,PLL5,CPUDIV1,VREGEN,NOMCLR
#use delay(clock=48000000)
#USE RS232(BAUD=9600, XMIT=PIN_B0,INVERT,stream=DEBUG)
#include ".\include\alarme.h"
#include ".\include\sim508.h"
////////////////////////////////////////////////////////////////////////... | 1,327,725 |
the-stack-v2-dedup | C | /* Include files */
#include "blascompat32.h"
#include "Mooventure2016_Rev5_sfun.h"
#include "c10_Mooventure2016_Rev5.h"
#define CHARTINSTANCE_CHARTNUMBER (chartInstance->chartNumber)
#define CHARTINSTANCE_INSTANCENUMBER (chartInstance->instanceNumber)
#include "Mooventure2016_Rev5_sfun_debug_macros.h"
/* Type... | 1,327,726 |
the-stack-v2-dedup | C | /*
* vertex.c - Vertex management functions for P3DC
* $Id: vertex.c,v 1.1 1999/08/18 01:34:04 cmcmanis Exp cmcmanis $
*
* This module implements the vertex functions for p3dc
*
* Change Log:
* $Log: vertex.c,v $
* Revision 1.1 1999/08/18 01:34:04 cmcmanis
* Initial revision
*
* Revision 1.1 1999/08/18 01... | 1,327,727 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* run_cmd.c :+: :+: :+: ... | 1,327,728 |
the-stack-v2-dedup | C | #ifndef _STATISTIC_H_
#define _STATISTIC_H_
void statistics(struct individual *pop);
struct individual *obtiene_individuos_a_enviar(struct individual *opop, struct individual *npop);
int FitnessCompara(struct individual *Indi, struct individual *Indj);
void inserta_individuos_en_poblacion(struct individual *rpo... | 1,327,729 |
the-stack-v2-dedup | C | /* ath.c - A Thread-safeness library.
* Copyright (C) 2002, 2003, 2004, 2011 Free Software Foundation, Inc.
* Copyright (C) 2014 g10 Code GmbH
*
* This file is part of Libgcrypt.
*
* Libgcrypt is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser general Public License ... | 1,327,730 |
the-stack-v2-dedup | C | /* Generated by Nim Compiler v0.17.2 */
/* (c) 2017 Andreas Rumpf */
/* The generated code is subject to the original license. */
/* Compiled for: MacOSX, amd64, clang */
/* Command for C compiler:
clang -c -w -pthread -I/usr/local/Cellar/nim/0.17.2/nim/lib -o /Users/joshuahorwitz/nim/ChatApp/src/nimcache/stdlib... | 1,327,731 |
the-stack-v2-dedup | C | /*
* File: sfr_setters.h
* Author: Ted Salmon <tass2001@gmail.com>
* Description:
* Set various special function registers
*/
#ifndef SFR_SETTERS_H
#define SFR_SETTERS_H
void SetUARTRXIE(unsigned index, unsigned value);
void SetUARTRXIF(unsigned index, unsigned value);
void SetUARTRXIP(unsigned index, unsigned... | 1,327,732 |
the-stack-v2-dedup | C | #include <check.h>
#include <stdio.h>
#include <pthread.h>
#include "../src/debug.h"
#include "ssl_test.h"
#include "../src/gnutls.h"
#define TEST_HOST "localhost"
#define TEST_PORT "8080"
struct mofos_dtls_server *srv;
static void setup(void)
{
int rc = mofos_dtls_global_init();
if (rc)
abort();
}
stat... | 1,327,733 |
the-stack-v2-dedup | C | #include<stdio.h>
#include<stdlib.h>
typedef struct Node{
int data;
struct Node *next;
};
int main(){
//default allocation
struct Node* head=NULL;
struct Node* second=NULL;
struct Node* third=NULL;
head=(struct Node*)malloc(sizeof(struct Node));
second=(struct Node*)malloc(sizeof(st... | 1,327,734 |
the-stack-v2-dedup | C |
#ifndef __LINUX_ILI9320_H
#define __LINUX_ILI9320_H
#include "core/lcdreg.h"
#include "core/fbdbi.h"
#define ILI9320_DRIVER_CODE_READ 0x00
#define ILI9320_START_OSCILLATION 0x00
#define ILI9320_DRIVER_OUTPUT_CONTROL_1 0x01
#define ILI9320_LCD_DRIVING_CONTROL ... | 1,327,735 |
the-stack-v2-dedup | C | #include<stdio.h>
int main(void)
{
int a;
printf("しまじろうのおかあさんがたべたいおにぎりは?\n");
printf("\t1. しお\n");
printf("\t2. さけ\n");
printf("\t3. うめ\n");
printf("答えを入力(1~3) --> ");
scanf("%d", &a);
switch(a) {
case 1:
printf("不正解\n");
break;
case 2:
printf("正解\n");
break;
case 3:
printf("不正解\n");
... | 1,327,736 |
the-stack-v2-dedup | C | /*
* Exported with nin10kit v1.2
* Invocation command was nin10kit -mode=rgb8 -3ds_rotate=1 reggie reggie.bmp
* Time-stamp: Saturday 01/16/2016, 14:38:25
*
* Image Information
* -----------------
* reggie.bmp 400@240
*
* Quote/Fortune of the Day!
* -------------------------
*
* All bug reports / feature... | 1,327,737 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* zzz.c :+: :+: :+: ... | 1,327,738 |
the-stack-v2-dedup | C | #include <stdio.h>
int main()
{
int arr[]={10,12,18,20,33,48,40,50};
int n;
n=sizeof(arr)/sizeof(int);
printf("Number of elements are: %d\n",n);
return 0;
}
| 1,327,739 |
the-stack-v2-dedup | C | #include "systemcall.h"
#include "console.h"
#include "debug.h"
#include "descriptor.h"
#include "interrupthandler.h"
#include "map.h"
#include "memory_config.h"
#include "multiprocessor.h"
#include "page.h"
#include "systemcalllist.h"
#include "thread.h"
#include "types.h"
#include "utility.h"
#include "semaphore.h"
#... | 1,327,740 |
the-stack-v2-dedup | C | #include "signals.h"
#include "utils.h"
#include "logs.h"
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
#include <errno.h>
#include <sys/stat.h>
#include <sys/wait.h>
#include <fcntl.h>
#include <signal.h>
#include <dirent.h>
#include <sys/types.h>
#include <stdbool.h>
extern long tim... | 1,327,741 |
the-stack-v2-dedup | C | /*
Carolina Ramirez
MD Anderson
Kolby Kiesling
ACU Nuclear Physics Research
*/
void curtis_sim() {
TH1F *h1 = new TH1F("h1", "NUDT5 Expression Among Negative Samples; NUDT5; Samples ()", 125, -2, 10);
TH1F *h2 = new TH1F("h2", "NUDT5 Expression Among Positive Samples; NUDT5; Samples ()", 125, -2, 10);
TH2F *h3 = ne... | 1,327,742 |
the-stack-v2-dedup | C | #ifndef __MSG_H
#define __MSG_H
typedef struct msg_t{
int whoami;
int len;
char data[];
}msg_t;
#endif
| 1,327,743 |
the-stack-v2-dedup | C | #include <stdio.h>
#include <cs50.h>
#include <string.h>
#include <ctype.h>
int main(int argc,string argv[])
{
if(argc>1)
{
char key[1000] = {'\0'};
int i=1;
while(i<argc)
{
strcat(key,argv[i]);
i++;
}
int len = strlen(key);
i=0;
... | 1,327,744 |
the-stack-v2-dedup | C | #include <stdio.h>
int main (int argc, char **argv)
{
int depth = 1;
int summaryRasa = 0;
int totalLines = 0;
for (int i = 1; i < argc; i++) {
FILE *fp;
char *filename=argv[i];
fp=fopen(filename, "r");
int rasa = 0;
int lines = 0;
for (int ch = fgetc(fp); ch != EOF; ch = fgetc(fp)) {
char ch1 = (ch... | 1,327,745 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_list_size.c :+: :+: :+: ... | 1,327,746 |
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,327,747 |
the-stack-v2-dedup | C | #include "say.h"
bool ft_check_flag_l(t_config *config, char *arg)
{
if (!ft_is_lng(arg))
return (false);
config->lng = ft_get_lng(arg);
return (true);
}
bool ft_check_flag_s(t_config *config, char *arg)
{
float n;
n = atof(arg);
if (n < 0.5 || n > 1.5)
return (false);
config->speed = n;
return (true);
}... | 1,327,748 |
the-stack-v2-dedup | C | #include "funciones.h"
int pedirEntero (char texto[], int min, int max) // aca si necesito poner el nombre de la variable
{
int retorno;
printf("%s", texto);
scanf("%d", &retorno);
retorno = validarEntero(retorno, min, max);
return retorno;
}
int validarEntero(int dato, int min, int max)
{
while(... | 1,327,749 |
the-stack-v2-dedup | C | #include <stdio.h>
#include <ctype.h>
char starting_address[1200];
char *string_uppercase1(const char *string)
{
int i = 0;
while (*string)
starting_address[i++] = toupper(*string++);
starting_address[i] = '\0';
return starting_address;
}
int main(void)
{
const char *title = "Jamsa's 1001 C/C++ Tips";... | 1,327,750 |
the-stack-v2-dedup | C | #include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
#include <ncurses.h>
#include <pthread.h>
#include <signal.h>
#include <sys/wait.h>
#include "package.h"
#include "network.h"
#include "result.h"
#include "define.h"
void printError(const char* message);
static pid_t *ifstat_pid,*tcpprobe_... | 1,327,751 |
the-stack-v2-dedup | C | #include "al2o3_platform/platform.h"
#include "render_meshmod/vertex/basicdata.h"
#include "render_meshmod/vertex/uv.h"
#include "render_meshmod/registry.h"
// borrow from basic data
AL2O3_EXTERN_C bool MeshMod_VertexVec2FEqual(void const* va, void const* vb, float const epsilon);
AL2O3_EXTERN_C double MeshMod_VertexV... | 1,327,752 |
the-stack-v2-dedup | C | #include "fillit.h"
#include <stdlib.h>
void ft_lstdel(t_list **alst, void (*del)(void *, size_t))
{
t_list *p1;
p1 = *alst;
while (p1 != NULL)
{
del(p1->content, p1->content_size);
*alst = p1->next;
free(p1);
p1 = *alst;
}
*alst = NULL;
}
| 1,327,753 |
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,327,754 |
the-stack-v2-dedup | C | #define _CRT_SECURE_NO_DEPRECATE 1
#include "stdio.h"
#include "stdlib.h"
struct ListNode {
int val;
struct ListNode *next;
};
struct ListNode* removeNthFromEnd(struct ListNode* head, int n) {
if (!head->next)return NULL;
struct ListNode* back = head; //走在后面
struct ListNode* mid = head; //走在中间
struct Lis... | 1,327,755 |
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,327,756 |
the-stack-v2-dedup | C | /*
* author : 谭锦志
* email : apanoo@126.com
* time : 2015 12 09
*/
/*
* 使用数学库必须包含此头文件
*/
#pragma once
#ifndef __MATH_H__
#define __MATH_H__
#include "vec2.h"
#include "vec3.h"
#include "vec4.h"
#include "mat4.h"
#endif // !__MATH_H__ | 1,327,757 |
the-stack-v2-dedup | C | #include "c-spiffe/spiffetls/mode.h"
static spiffetls_DialMode *malloc_dialmode(void)
{
spiffetls_DialMode *mode = malloc(sizeof *mode);
if(mode) {
return mode;
} else {
exit(EXIT_FAILURE);
}
}
static spiffetls_ListenMode *malloc_listenmode(void)
{
spiffetls_ListenMode *mode = mall... | 1,327,758 |
the-stack-v2-dedup | C | #include "Portal.h"
int Portal_Location(char* portals[], SDL_Rect* to_g)
{
if(portals[(to_g->y + 16) / 32][(to_g->x + 16) / 32] != ' ')
{
return portals[(to_g->y + 16) / 32][(to_g->x + 16) / 32] - '0';
}
return -1;
}
| 1,327,759 |
the-stack-v2-dedup | C | #include<reg52.h>
#include "MacroAndConst.h"
#include "18B20.h"
sbit TMDAT=P3^6; //DS1820温度接口
bit f; //负温度标志
bit flag; //DS1820初始化成功标志
unsigned char tempint,tempdf; //温度整数部分和小数部分
void set_ds1820() //初始化DS1820
{
while(1)
{
uchar delay;
flag=0;
TMDAT... | 1,327,760 |
the-stack-v2-dedup | C | #include "modbus_slave.h"
#include "bsp_rs485.h"
#include "bsp_modbus_crc16.h"
#include "bsp_timer.h"
#include "bsp_dataconvert.h"
#include<stdio.h>
#include<string.h>
#include<stdlib.h>
static uint8_t g_mods_timeout = 0;
MODS_T g_tModS; //modbus协议包
VAR_SLAVE g_tVarS; //网关modbus寄存器配置参数
/*
*********************... | 1,327,761 |
the-stack-v2-dedup | C | #define _INCLUDED_CYASCAST_H_
#define cy_cast_int2U_int16(v) \
(cy_as_hal_assert(v < 65536), (uint16_t)(v))
#define cy_cast_int2U_int16(v) ((uint16_t)(v))
| 1,327,762 |
the-stack-v2-dedup | C | /* SPDX-License-Identifier: BSD-3-Clause */
#include <stdarg.h>
#include <stdlib.h>
#include <stdbool.h>
#include <stdio.h>
#include <netinet/in.h>
#include <unistd.h>
#include <string.h>
#include <errno.h>
#include <jansson.h>
#include <ev.h>
#include <evsched.h>
#include <syslog.h>
#include <getopt.h>
#include "ds_... | 1,327,763 |
the-stack-v2-dedup | C | /****************************************************
* Trab 2 : Numeros Primos
* Nome e Matricula: Guilherme Alexandre - 0050015038
* Professor: Alex Salgado
*****************************************************/
#include <stdio.h>
int main()
{
int num, y, x;
printf("\nOla, meu nome eh Guilherme Alexand... | 1,327,764 |
the-stack-v2-dedup | C | #ifndef CGIFLASH_H
#define CGIFLASH_H
#include "httpd.h"
typedef struct {
int espFsPos;
int espFsSize;
} CgiUploadEspfsParams;
int cgiReadFlash(HttpdConnData *connData);
int cgiUploadEspfs(HttpdConnData *connData);
#endif | 1,327,765 |
the-stack-v2-dedup | C | /*
* Consts.h
*
* Created on: 4 lip 2016
* Author: oramus
*/
#ifndef CONSTS_H_
#define CONSTS_H_
const int POSITIONS = 69707;
const int PARTICLES = 43;
//const int PARTICLES = 17;
const int NUMBER_OF_REPETITIONS = 5001;
const int HEARTBEAT = 250;
const double MIN_DISTANCE_BEETWEEN_PARTICLES = 4.3;
const d... | 1,327,766 |
the-stack-v2-dedup | C | ! source file: /raid24/aschmitt/UVic2.9/karin/mobi_with_calcifiers7_nobio/updates/isopyc.h
!======================== include file "isopyc.h" ======================
! isopycnal diffusion variables:
! ahisop = isopycnal tracer mixing coefficient (cm**2/sec)
! drodx = d(rho)/dx local to east face of T cell
... | 1,327,767 |
the-stack-v2-dedup | C | #include "functions.h"
//NewFiles
Files* newFiles(){
Files* files = (Files*) malloc (sizeof(Files));
files->headMat = NULL;
files->headVec = NULL;
return files;
}
//NewVector
Vector* newVec(){
Vector *newVector = (Vector *) malloc (sizeof(Vector));
newVector->next = NULL;
return newVector;
}
//NewMatrix
Mat... | 1,327,768 |
the-stack-v2-dedup | C | #include <stdio.h>
#include <stdlib.h>
#define MAXN 10
typedef int ElementType;
typedef struct TreeNode *Tree;
struct TreeNode {
ElementType Element;
Tree Left;
Tree Right;
};
Tree insert(int x, Tree T);
int compare(Tree T1, Tree T2);
void dispose(Tree T);
int main()
{
int n, l;
Tree T1, T2;
... | 1,327,769 |
the-stack-v2-dedup | C | #include <stdio.h>
#include<string.h>
//L'objectif de cet exercice est de manipuler la notion de structure et de compter le nombre d'elements similaires dans une structure
int main(){
struct Couleur { // creation de la structure
char rouge[50];
char vert[50];
char bleu[50];
ch... | 1,327,770 |
the-stack-v2-dedup | C | #include<stdint.h>;
#include"chuongtrinhcon.h"
#include<stdio.h>
void chuongtrinhcon(int a)
{
printf("Hello world\r\n");
} | 1,327,771 |
the-stack-v2-dedup | C | #include <stdio.h>
#include <stdlib.h>
int main(){
char str[50];
printf("Accept a string from. the keyboard\n");
printf("Input the string : ");
fgets(str, sizeof str, stdin);
printf("The string you entered is : %s\n",str );
return 0;
}
| 1,327,772 |
the-stack-v2-dedup | C | /*! \file compileBST.c
* \brief This implements the applyPatch program.
* \author Lucie Pansart
* \author Jean-Louis Roch
* \version 1.0
* \date 30/9/2016
* \warning Usage: compileBST n originalFile
* \copyright GNU Public License.
*/
#include <stdio.h>
#include <stdlib.h>
#include <l... | 1,327,773 |
the-stack-v2-dedup | C | /* This program reads a number between 2 and 30 and draws
a square of side n.
*/
#include <stdio.h>
#include <stdlib.h>
void printChar(int n, char c) {
int i;
for (i = 0; i < n; i++) printf("%c", c);
}
int main(void) {
int n, i;
do {
printf("\n Enter an integer between 2 and 30 (including): ");
... | 1,327,774 |
the-stack-v2-dedup | C | #pragma once
//unknown
const TCHAR ESTR_UNHANDLEDMSG[] = _T("UNHANDLEDMSG");
//Mouse Event
const TCHAR ESTR_LBUTTONDOWN[] = _T("LBUTTONDOWN");
const TCHAR ESTR_LBUTTONUP[] = _T("LBUTTONUP");
const TCHAR ESTR_RBUTTONDOWN[] = _T("RBUTTONDOWN");
const TCHAR ESTR_RBUTTONUP[] = _T("RBUTTONUP");
// | 1,327,775 |
the-stack-v2-dedup | C | #include <acknex.h>
#include <default.c>
MATERIAL * mtl_nextgen =
{
effect = "fx_default.fx";
technique = "std_lightmapped";
flags = AUTORELOAD | TANGENT;
ambient_red = 100;
ambient_green = 100;
ambient_blue = 100;
diffuse_red = 200;
diffuse_green = 200;
diffuse_blue = 200;
specular_red = 0;
specul... | 1,327,776 |
the-stack-v2-dedup | C | #ifndef exec_command_rec_H
#define exec_command_rec_H
void exec_command_rec(char*tab[],int i, int pipe_entree, int *f);
#endif
| 1,327,777 |
the-stack-v2-dedup | C | /* Code converted from shallow_base.f90 using F2C-ACC program.
* Manually replaced:
* - WRITE statements with printf
* - MOD operator with %
* - system_clock with wtime
* Fixed several of the array references which had x dimension as 1,
* instead of M_LEN.
* Fixed values set using d and e notation.
* (7 J... | 1,327,778 |
the-stack-v2-dedup | C | #include <stdio.h>
int
square (int x)
{
return x*x;
} // square
#define SQUARE(X) ((X)*(X))
int
main (int argc, char *argv[])
{
int a;
a = 2;
printf ("a is %d\n", a);
printf ("square(square(a++)) is %d\n", square(square(a++)));
printf ("a is now %d\n", a);
a = 2;
printf ("a is %d\n", a);
print... | 1,327,779 |
the-stack-v2-dedup | C | #include "display_lib.h"
/* ---------------------< DISPLAY LIBRARY >----------------
* Prepared macros and functions fo displaying numbers on 4x 7-segment display.
* Also display dots. Need use Timer with reload 400 Hz.
* PIN outputs on PORT:
* GPIOB PIN_12 -> DISP_1
* GPIOB PIN_13 -> DISP_2
* GPIOB PIN_14 -> ... | 1,327,780 |
the-stack-v2-dedup | C | #include <stdio.h>
#include <string.h>
#include <stdarg.h>
#include "lua.h"
#include "lauxlib.h"
#include "lualib.h"
void call_va(lua_State* L, const char* func, const char* sig, ...)
{
va_list vl;
int narg, nres;
va_start(vl, sig);
lua_getglobal(L, func);
for(narg = 0; *sig; ++narg)
{
... | 1,327,781 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_strtrim.c :+: :+: :+: ... | 1,327,782 |
the-stack-v2-dedup | C | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* builtin_env.h :+: :+: :+: ... | 1,327,783 |
the-stack-v2-dedup | C | #ifndef IPC_TOOLS_H
#define IPC_TOOLS_H
#include <sys/types.h>
int semalloc(key_t key, int valInit);
void V(int semid);
void P(int semid);
int semfree(int semid);
void *shmalloc(key_t key, int size);
int shmfree(key_t key);
#endif
| 1,327,784 |
the-stack-v2-dedup | C | #include "switch_controller.h"
#pragma once
void pushButton(Button button, int delay_after_pushing_msec, int loop_num=1);
void pushHatButton(Hat button, int delay_after_pushing_msec, int loop_num=1);
void pushHatButtonContinuous(Hat button, int pushing_time_msec);
void tiltJoystick(int lx_per, int ly_per, int rx_per,... | 1,327,785 |
the-stack-v2-dedup | C |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdarg.h>
#include <error.h>
#include <assert.h>
#include "trace-struct.h"
#include "vmbunching_structs.h"
#include "debugg.h"
#include "utils.h"
#include "vmbunching-generic.h"
extern struct ifile_info *iip;
extern char *odir; // Output ... | 1,327,786 |
the-stack-v2-dedup | C |
//{{BLOCK(_0990)
//======================================================================
//
// _0990, 40x40@8,
// + palette 256 entries, not compressed
// + 25 tiles lz77 compressed
// Total size: 512 + 1540 = 2052
//
// Time-stamp: 2014-11-28, 05:19:42
// Exported by Cearn's GBA Image Transmogrifier, v0.8.12
// ( ... | 1,327,787 |
the-stack-v2-dedup | C | #include<stdio.h>
#include<stdlib.h>
#include<sys/socket.h>
#include<sys/types.h>
#include<netinet/in.h>
#include<strings.h>
int main()
{
int c_sock;
c_sock=socket(AF_INET,SOCK_DGRAM,0);
struct sockaddr_in client;
client.sin_family=AF_INET;
client.sin_port=htons(9009);
client.sin_addr.s_addr=INADDR_ANY;
char n[1];
... | 1,327,788 |
the-stack-v2-dedup | C | /* dsdefs.h
*
* This is a "dummy" version of stdio.h etc. for systems which lack one.
* Rename it is stdio.h if needed.
*
* Functions printf() and sprintf() are defined here, but neither
* of them do anything useful.
*
* Version 1.2 Dag Bruck
* 1.3 Dag Bruck Updated for DYMOLA_DSPACE.
*
* Copyrigh... | 1,327,789 |
the-stack-v2-dedup | C | #include<stdio.h>
#include<stdlib.h>
#include<pthread.h>
#include<semaphore.h>
sem_t empty_num, product_num;
pthread_mutex_t mutex;
int buffer[4];
int begin = 0, end = 0, counter = 0, max = 4;
void *producer( void *arg )
{
printf("pthread producer id : %d run \n", *(int *)arg );
srand(1);
while( 1 )
{
sem... | 1,327,790 |
the-stack-v2-dedup | C | /*
* SPDX-FileCopyrightText: 1989 - 1994, Julianne Frances Haugh
* SPDX-FileCopyrightText: 1996 - 1997, Marek Michałkiewicz
* SPDX-FileCopyrightText: 2001 - 2005, Tomasz Kłoczko
* SPDX-FileCopyrightText: 2008 - 2009, Nicolas François
*
* SPDX-License-Identifier: BSD-3-Clause
*/
/*
* Extracted from age.c and ma... | 1,327,791 |
the-stack-v2-dedup | C | /**
Copyright 2017 Google Inc. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in... | 1,327,792 |
the-stack-v2-dedup | C | /*-------------------------------- Arctic Core ------------------------------
* Copyright (C) 2013, ArcCore AB, Sweden, www.arccore.com.
* Contact: <contact@arccore.com>
*
* You may ONLY use this file:
* 1)if you have a valid commercial ArcCore license and then in accordance with
* the terms contained in the writ... | 1,327,793 |
the-stack-v2-dedup | C | #include "ShareMemory.h"
#define CANTIDAD_PIONEER 5
BOOL OpenShareMemory(TCHAR *cpName, int i);
BOOL CloseShareMemory(int i);
BOOL ReadShareMemory(VIRTUAL_DEVICE_SALIDA *pfData, int i);
BOOL WriteShareMemory(VIRTUAL_DEVICE_ENTRADA *pfData, int i); | 1,327,794 |
the-stack-v2-dedup | C | #include "asm.h"
static inline int
readflags()
{
return __builtin_nyuzi_read_control_reg(CR_FLAGS);
}
static inline void
cli(void)
{
__builtin_nyuzi_write_control_reg(CR_FLAGS,
readflags() & ~FLAG_INTERRUPT_EN);
}
static inline void
sti(void)
{
__builtin_nyuzi_write_control_reg(CR_FLAGS,
readflags() | ... | 1,327,795 |
the-stack-v2-dedup | C | /*****************************************************************************
* (C) Copyright 2000-2005, Wintegra. All rights reserved.
* WINTEGRA CONFIDENTIAL PROPRIETARY
* Contains Confidential Proprietary information of Wintegra.
* Reverse engineering is prohibited.
* The copyright notice does not imply public... | 1,327,796 |
the-stack-v2-dedup | C | #include "link_list.h"
#include "data_global.h"
#define LEN_ENV 12
#define LEN_RFID 4
int fd_socket_new;
extern linklist linkHead;
extern linklist slinkHead;
extern pthread_mutex_t mutex_linklist;
extern pthread_mutex_t mutex_slinklist;
extern pthread_mutex_t mutex_analysis;
extern pthread_mutex_t mutex_global;
ex... | 1,327,797 |
the-stack-v2-dedup | C | /*
* Fichier : koch_main.c
* Description : Trace de fractales geometriques - flocon de koch - programme principal
*/
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include "koch_fonctions.h"
#include "koch_ihm.h"
#include "create_image.h"
int main(int argc, char **argv)
{
struct list *koch;
struct ... | 1,327,798 |
the-stack-v2-dedup | C |
/*
CF3
Copyright (c) 2015 ishiura-lab.
Released under the MIT license.
https://github.com/ishiura-compiler/CF3/MIT-LICENSE.md
*/
#include<stdio.h>
#include<stdint.h>
#include<stdlib.h>
#include"test1.h"
int64_t x1 = 1545976LL;
int8_t x12 = INT8_MAX;
volatile uint32_t x18 = UINT32_MAX;
int32_t x20 = -26793;
int32... | 1,327,799 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.