Dataset Viewer
Auto-converted to Parquet Duplicate
blob_id
large_string
language
large_string
repo_name
large_string
path
large_string
src_encoding
large_string
length_bytes
int64
score
float64
int_score
int64
detected_licenses
large list
license_type
large_string
text
string
download_success
bool
a31cfe4f49e9a27b5916aacf3931ab0badab1f92
C
NanthinideviBalachander/zoho-traning
/skillrack training/lcm of two numbres.c
UTF-8
408
2.609375
3
[]
no_license
call(unsigned long long int a,unsigned long long int b) { /* if(a!=0) call(b%a,a); else{ return b; }or*/ return a==0?b:call(b%a,a); } main() { unsigned long long int a,b; int n,pro; scanf("%d",&n); scanf("%llu%llu",&a,&b); // int pro=call(a,b); for(int i=2;i<n;i++) { ...
true
38a11c5fc471c3a5200ba8cd340a90b593686fa8
C
Ishan2OO1/c-basics
/cmarks.c
UTF-8
1,212
3.078125
3
[]
no_license
#include <stdio.h> #include <stdlib.h> int main() { int a,b,c,d,t,x; float per; printf("Enter the marks of four subjects out of 100 "); scanf("%d %d %d %d",&a,&b,&c,&d); t=a+b+c+d; per=t/4; if((a>b) && (a>c) && (a>d)) { if ((b>c) && (b>d)) printf("%f %d",per,b); else if ((c>b) ...
true
e98fa705dc78baf95bdef7d47671506b335d1af8
C
NtiyisoN/OpenWorld-1
/API/test_time.c
UTF-8
827
3.375
3
[]
no_license
#include "time.c" #include <stdio.h> int main() { Calendar *random_calendar = makeRandomCalendar(); //should be 0000-00-00 char *date_time = getDateTime(random_calendar, "YYYY-MM-DD"); puts(date_time); setDateTimeRandomly(random_calendar); TIME_COUNT date_time_counter = getDateTimeAsCounter(random_calendar...
true
1ac3a61ebd45674c426bdd5d9d6bad093228198f
C
Icelandjack/queue
/tester.c
UTF-8
1,192
3.375
3
[]
no_license
#include "concurrent_queue_2locks.c" /* #include "queue.c" */ #include <pthread.h> void spawnThreads(int n, int x); void *dummy_function(void *arg); #define foo 100000 int main(int argc, char *argv[]) { int n = 6; int x = 100000; srand(time(NULL)); initialize_queue(); for (int i = 0; i < 100; i++) { ...
true
8e4d23e323d366ddfcfa830db415678fb8f07456
C
RobertH1993/AVRLightcontrol
/RF433_SF500.c
UTF-8
1,641
2.59375
3
[]
no_license
/* * RFSwitch433.c * * Created on: Jun 30, 2018 * Author: robert */ #include <avr/io.h> #include <util/delay.h> #include "RF433_SF500.h" //Kudos to the Arduino NewRFSwitch library for the timings and parts of the code //Private, send the stoppulse void send_stoppulse(){ PORTD |= (1<<PD4); _delay_us(PERI...
true
bf84c22cdfef8a88a6abca370b7540d06eda090e
C
noahkurz/SigKillLab
/CLab.C
UTF-8
1,474
3.1875
3
[]
no_license
#include <stdio.h> #include <unistd.h> #include <stdlib.h> #include <signal.h> #include <time.h> int child_pids[1000]; int parent_hp = 0; int MAX_CHILDREN = 10; int numChildren = 0; void sig_handler_parent(int signum) { printf("\nParent: Inside handler function\n"); for(int i = 0; i < numChildren; i ++) { k...
true
1c79fdf7bc019aedd682787c5c19565ad65b9311
C
sokhyg9016/Set_String_separated_by_comma
/test_move.c
UTF-8
318
3.234375
3
[]
no_license
#include<stdio.h> #include<string.h> int main() { int size = 0; int i = 0; char str[50]; char* p_str = NULL; scanf("%s", str); size = strlen(str); p_str = str; for(i = size; i > 0;) { printf("%c", *p_str++); i--; if(i%3 == 0 && i > 0) { printf(","); } } puts(""); return 0; }
true
0fca768fba22111d1b14d782c639810ee225b3f6
C
arup-baral/DSA_LAB-SEM---4-
/circular_queue.c
UTF-8
3,323
4.4375
4
[ "Apache-2.0" ]
permissive
/** * * Implementing Circular Queue * **/ #include <stdio.h> #include <stdlib.h> struct Node { int data; struct Node *next; }; struct CircularQueue { struct Node *front; struct Node *rear; int size; }; struct CircularQueue* createCircularQueue(){ struct CircularQue...
true
3fe5d74c5ad79bc9213354ac5a18201b72268075
C
LacErnest/College-Courses
/code/a4.c
UTF-8
139
3.03125
3
[]
no_license
#include<stdio.h> void main() { char x,y,z; x='A'; y=x+7; printf("the value of x is %c\n",x); printf("the value of y is %c\n",y); }
true
51bba95cf703ee48ff9be6c67d6663028a812a59
C
arazi47/university-projects
/1st year/2nd semester/OS/week11_threads_practice/main3.c
UTF-8
2,098
3.84375
4
[]
no_license
// // lock_3.c - Using a mutex (mutual exclusion lock) // // pthread_mutex_lock() - acquire a lock on the specified mutex variable. If the mutex is already locked by another thread, // this call will block the calling thread until the mutex is unlocked. // // pthread_mutex_unlock() - unlock a...
true
c520d2540cd4ed74fb3d781ae53766dad62309ed
C
Meg531/Lab3
/dicegame.h
UTF-8
326
2.59375
3
[]
no_license
#ifndef DICEGAME_H #define DICEGAME_H typedef enum GuessType { REGULAR, BONUS, ELIMINATION } GuessType; typedef struct Guess { int points; int die1; int die2; GuessType type; } Guess; void printGuess( Guess g ); void getDice( int* d1, int* d2 ); void fillGuesses( Guess* guesses, int length ) ; ...
true
8d071d1ba0c89e63021cfba4c0f36575bab138ee
C
hckrtst/cs-refresh
/problems/P6/p6.c
UTF-8
424
3.625
4
[]
no_license
#include <stdio.h> #include <assert.h> #include <string.h> int _strlen(const char *s) { if (s == NULL) return 0; register const char* c = s; while (*c) { c++; } return (c - s); } int main(int argc, char ** argv) { const char *test = "this is a test"; printf("my strlen is %d\n", _strlen(test));...
true
cedca6fb99819c5db9e7160aeb954ff3a20ecda7
C
erwan-simon/malloc
/malloc.c
UTF-8
1,642
3.078125
3
[ "MIT" ]
permissive
/* ** malloc.c for malloc in /home/erwan/Code/teck/PSU_2016_malloc ** ** Made by erwan ** Login <erwan.simon@epitech.eu> ** ** Started on Thu Jan 26 14:08:12 2017 erwan ** Last update Sat Feb 11 16:09:33 2017 Antoine */ #include <stdio.h> #include <unistd.h> #include <string.h> #include <sys/mman.h> #include <pth...
true
948b6c8b65584810357377616f8de8fbbf7e10cb
C
95ulisse/simplylock
/src/auth.h
UTF-8
265
2.53125
3
[ "LicenseRef-scancode-unknown-license-reference", "MIT" ]
permissive
#ifndef __AUTH_H__ #define __AUTH_H__ /** * Uses PAM to authenticate the given user. * * @param user User to authenticate. * @return `0` if the user successfully authenticated, `-1` otherwise. */ int auth_authenticate_user(char* user); #endif
true
4d98f111b18c01574353a6e9661dd1dc88460654
C
munnellg/Rosalind
/6_mendels_first_law/src/main.c
UTF-8
1,813
3.484375
3
[ "MIT" ]
permissive
#include <stdio.h> #include <stdlib.h> #define NUM_ORGANISMS 3 #define DIMINISHING 0.25 int main(int argc, char* argv[]) { int organisms[NUM_ORGANISMS]; float pr1[NUM_ORGANISMS] = {0}; float pr2[NUM_ORGANISMS * NUM_ORGANISMS] = {0}; float pr_dom, dim; int t, i, j; t = 0; pr_dom = 0; dim = 1; /* Start by ge...
true
265dfb810f26f33b27d5719afa56346831534edb
C
maciek-slon/AES_CTR
/src/main_mpi.c
UTF-8
9,721
2.953125
3
[]
no_license
/* This program sums all rows in an array using MPI parallelism. * The root process acts as a master and sends a portion of the * array to each child process. Master and child processes then * all calculate a partial sum of the portion of the array assigned * to them, and the child processes send their partial sums...
true
fc07c2a2c0cf56fc9cdad208157716c940ae0fd6
C
mikechen66/C-Programming
/C-Standard-Library/C-Standard-Library-v1/stdlib/atexit.c
UTF-8
332
2.984375
3
[]
no_license
/* atexit function */ #include <stdlib.h> /* external declarations */ extern void (*_Atfuns[])(void); extern size_t _Atcount; int (atexit)(void (*func)(void)) { /* function to call at exit */ if (_Atcount == 0) return (-1); /* list is full */ _Atfuns[--_Atcount] = func; retu...
true
de0d496e6927b8dcaa2a85b07cd0e105bfa741f0
C
NaiveSolution/OperatingSystems
/ass2/file.c
UTF-8
17,317
2.5625
3
[]
no_license
#include <types.h> #include <kern/errno.h> #include <kern/fcntl.h> #include <kern/limits.h> #include <kern/stat.h> #include <kern/seek.h> #include <lib.h> #include <uio.h> #include <thread.h> #include <current.h> #include <synch.h> #include <vfs.h> #include <vnode.h> #include <file.h> #include <syscall.h> #include <cop...
true
9403cee52cb42481fe8f7eaa6a209a8aa72df420
C
raduady/Problems
/Data Structures/C/Queue/QueueArray/queue_array.h
UTF-8
494
2.84375
3
[]
no_license
#ifndef __QUEUE_ARRAY_H__ #define __QUEUE_ARRAY_H__ #include <stdio.h> // FIFO Queue using circular arrays typedef struct QueueArray { void** q; int first; int last; int cap; int dim; } QueueArray; // initialize the queue void init_queue_array (QueueArray*, int); // enqueue the queue void enqueue_array (Queue...
true
8e6fc8d76ef0c9d6e5092e3a1e0b8dfe5d9ceeb2
C
lxf2git/quectel_work
/C/C/homework/huangganggui/8_ball.c
UTF-8
257
3.40625
3
[]
no_license
#include<stdio.h> int main() { int times=10; float high=100,lenght=0,temp=0; while(times) { lenght+=2*high; high/=2; times--; } lenght-=100; printf("10th's height is %f\n",high); printf("10th's lenght is %f\n",lenght); return 0; }
true
1e7a158fa9ece7b267024a58d366fa73baa3a5b0
C
ParfenovIgor/OS
/week5/ex1b.c
UTF-8
860
3.8125
4
[]
no_license
#include <stdio.h> #include <stdlib.h> #include <pthread.h> #define N 10 #define NULL_PTHREAD 0 pthread_t tid[N];//Array of threads' id void* thread_do(void *arg){ pthread_t id=pthread_self(); int i; for(i=0;i<N;i++){//Try to find myself in array of threads' id if(pthread_equal(id,tid[i])){ printf("Hello, I'm...
true
8ca85272667525a9426a43b025857cf462d356ce
C
mldelibero/roboCooler
/code/tests/mockFiles/stdlib/stm32f4xx_hal_gpio.h
UTF-8
3,987
2.578125
3
[]
no_license
/* Define to prevent recursive inclusion -------------------------------------*/ #ifndef __STM32F4xx_HAL_GPIO_H #define __STM32F4xx_HAL_GPIO_H #ifdef __cplusplus extern "C" { #endif /* Includes ------------------------------------------------------------------*/ #include "stm32f4xx_hal_def.h" #include "stm32f4xx_hal...
true
f1ba41c5d20c7957b1a8fe2c5890010d88ed5bb1
C
axl411/SimpleDatabase
/SimpleDatabase/Node.c
UTF-8
3,504
2.953125
3
[]
no_license
// // Node.c // SimpleDatabase // // Created by 顾超 on 2020/05/09. // Copyright © 2020 Chao Gu. All rights reserved. // #include <stdlib.h> #include <string.h> #include "Node.h" #include "Row.h" #include "Table.h" #include "Cursor.h" #include "Pager.h" typedef enum NodeType { NODE_INTERNAL, NODE_LEAF } No...
true
c96bc93a66f68194f93cb7c11e124d6e40169e4a
C
SylTi/school
/school/first_year/c/42sh/srcs/rm_good_env.c
UTF-8
577
2.953125
3
[]
no_license
/* ** rm_good_env.c for rm_good_env in /u/epitech_2012/jaspar_y/cu/rendu/c/minishell/v1 ** ** Made by yoann jaspar ** Login <jaspar_y@epitech.net> ** ** Started on Thu Feb 28 15:56:29 2008 yoann jaspar ** Last update Tue Jun 3 17:55:49 2008 yoann jaspar */ #include "sh.h" char **rm_good_env(char **environ, int re...
true
9acfc5efd8e13b9225d84cff7c4b59a7e8f5466e
C
MA806P/ComputerScienceNotes
/AlgorithmDataStructure/LeetCode/69-MySqrt/sqrt.c
UTF-8
1,386
3.984375
4
[ "Apache-2.0" ]
permissive
#include <stdio.h> #include <math.h> //方法一,只要求是整数 int mySqrt0(int x){ if (x < 2) { return x; } int i = 1; while (i*i <= x) { //超过int最大值溢出了为负的 if (i*i <= 0) { break; } i++; } return --i; } //方法二,公式 int mySqrt1(int x){ if (x < 2) { return x; } //sqrt(x) = ...
true
16ec4d534eea8b55d6333386c815144758b85019
C
manojkalambe/C_codes
/array/arr1.c
UTF-8
426
3.3125
3
[]
no_license
#include<stdio.h> int main() { int i; int key; int arr[5]={10,20,30,40,50}; //arr dec //return type array_name[size]; printf("Entered elements that you want to search : \n"); scanf("%d",&key); for(i=0;i<5;i++) { if(arr[i]==key) { printf("fo...
true
6e707ce8ea3bc37755a88707d8b5945f97e80bf0
C
SequinYF/TTMS_C
/1.3/structure/TTMS对照/Persistence/Account_Persist.c
UTF-8
1,581
2.8125
3
[]
no_license
/* * Account_Persist.c * * Created on: 2015年5月8日 * Author: Administrator */ #include "Account_Persist.h" #include "../Service/Account.h" #include "../Common/list.h" #include <stdlib.h> #include <stdio.h> #include<unistd.h> #include <assert.h> #include <string.h> static const char ACCOUNT_DA...
true
267fdbde4bd51f652ed1f2179f20c6eb27039371
C
Hide4ki/course_work
/format.c
UTF-8
2,858
3.09375
3
[]
no_license
#include <stdio.h> #include "format.h" #include "def.h" void strCopyN(char *s1,char *s2, int num); extern int formatFlag; extern int numEnd; extern int numBegin; extern int cntCharacter; void format(char *finalyLine, char *line) { switch(formatFlag) { case 0: strCopyN(finalyLine,line,numEnd-numB...
true
2fdd590c2d2c96b956ff45000fd0cca79d0d2d2e
C
xiexuchao/TraceAnalyzerBackup
/config.c
UTF-8
9,033
2.53125
3
[]
no_license
#include "pool.h" #include "detector.h" void load_parameters(struct pool_info *pool,char *config) { int name,value; char buf[SIZE_BUFFER]; char *ptr; memset(buf,0,sizeof(char)*SIZE_BUFFER); strcpy(pool->filename_config,config); pool->file_config=fopen(pool->filename_config,"r"); ...
true
a0bfd73bcc7164346d1850ea7b9c805489c0de2d
C
ahmedazhar10/shell_os
/ram.c
UTF-8
764
3.15625
3
[]
no_license
#include<stdio.h> #include<string.h> int nextFreeCell = 0; char *ram[1000] = { NULL }; void removeFromRam (int start, int end){ for (int i = start; i <= end; i++) { ram[i] = NULL; } } void addToRAM (FILE *p, int *start, int *end){ *start = nextFreeCell; int i = *start; ...
true
7abbafe3b1afe5bd11a80ec15e8afdb294d98a4b
C
Tbeaumont79/BTS-SNIR
/devel/typd/ascii.c
UTF-8
345
3.546875
4
[]
no_license
#include <stdio.h> int main() { int ligne,colonne; for (ligne = 0; ligne < 16; ++ligne) { for (colonne = 0; colonne < 6; colonne++) { char c = 0x20+(0x10*colonne)+ligne; if (c < 127) printf("%c %d (%02x)\t", c,c,c); } putchar('\n'); ...
true
e4f48c99c023181ddb20c9730ccf83e51270b159
C
hatingthefruit/cs3843
/Lab2/lab2b.c
UTF-8
1,190
3.953125
4
[]
no_license
/* Author: Andrew DiCarlo Assignment Number: Lab 2 File Name: lab2b.c Course/Section: CS 3843 Section 003 Due Date: 02 Mar 2020 Instructor: Dr. Ku Contains the modified code to complete the requirements of lab 2 */ #include <stdio.h> #include <string.h> #define MAX 10 int readArray(int [], int); void printArray(int...
true
4ff0d89ab02fafae2083fdd45255d81555e0ed80
C
edenbarby/metr4810-team5-project
/atmega328/edens_drivers/twi.c
UTF-8
8,615
3.1875
3
[]
no_license
/* * twi.c * * Created: 25/09/2013 6:05:40 PM * Author: Eden Barby */ /* INCLUDES *****************************************************************/ #include <avr/io.h> #include <stdint.h> #include <stdio.h> /* PRIVATE TYPEDEFS *********************************************************/ /* PRIVATE DEFINES ****...
true
155a58f5a72f6942633cdf503f0a76dee9f38757
C
tarfao/Faculdade
/2ano/afn/ConversaoAFN_AFD/testeAfnAfd.c
UTF-8
21,626
3.21875
3
[]
no_license
#include <stdio.h> #include <string.h> #include <stdlib.h> #include <stdio_ext.h> #define true 1 #define false 0 #define vazio -1 typedef struct estado { char Nest[20][5];/*contem os estados*/ int cont; /*conta os estados*/ }Estados; typedef struct NState {/*tem o objetivo de obter os movimentos de um estado (seja...
true
b6563963e38841ed3b52fe6596ec07b5ecd28e72
C
jdelgadoalfonso/efence-example
/my_application/main.c
UTF-8
140
2.890625
3
[]
no_license
#include <stdlib.h> int main(void) { char *buf = malloc(20); int i = 0; buf[-1] = '0'; for (i = 0; i <=20; i++) { buf[i] = '0'; } }
true
f4ddcd5cc86c2f3d50177b6882ade9c2a3c4827e
C
csu-anzai/GeneticLOGIC
/sgac_93a/sga-c/generate.c
UTF-8
1,193
2.90625
3
[]
no_license
/******************************************************************************/ /* generate.c - create a new generation of individuals */ /******************************************************************************/ #include "external.h" generation () { int mate1, mate2, jcross, j = 0;...
true
95b05159e3d452d39da6a61fd5f322f4150a79ff
C
max197616/zerod
/src/speed_meter.c
UTF-8
2,345
3.171875
3
[ "BSD-3-Clause" ]
permissive
#include "speed_meter.h" #include "util.h" /** * Initialize speed meter. * @param[in] speed */ void spdm_init(struct speed_meter *speed) { atomic_init(&speed->i, 0); atomic_init(&speed->speed_aux, 0); atomic_init(&speed->last_update, 0); for (size_t i = 0; i < ARRAYSIZE(speed->backlog); i++) { ...
true
1bc442609122057cb3cd173e7af86d363e5bd899
C
pmodels/mpich
/test/mpi/rma/rget_testall.c
UTF-8
2,085
2.796875
3
[ "mpich2" ]
permissive
/* * Copyright (C) by Argonne National Laboratory * See COPYRIGHT in top-level directory */ #include <stdio.h> #include <mpi.h> #include "mpitest.h" /* This test checks request-based get with MPI_Testall. Both the return value of * MPI_Testall and status.MPI_ERROR should be correctly set. * * Thanks for Jos...
true
848b483e40636b4c726a621079c9d77441f80707
C
fread/pptut-code
/dienstag/10/a3.c
UTF-8
1,560
2.828125
3
[]
no_license
#include <stdio.h> #include <stdlib.h> #include <string.h> #include "mpi.h" /* int MPI_Send(const void *buf, int count, MPI_Datatype datatype, int dest, */ /* int tag, MPI_Comm comm); */ /* int MPI_Recv(void *buf, int count, MPI_Datatype datatype, */ /* int source, int tag, MPI_Comm comm, MPI_Status ...
true
5b8476d5e261740ab257d2adac62b00e11397af2
C
abphilip-vit/College1
/T6/S6.c
UTF-8
3,772
3.75
4
[ "MIT" ]
permissive
#include<stdio.h> struct polynode { int coef; int exp; struct polynode *next; }; typedef struct polynode *polyptr; polyptr createPoly() { polyptr p, tmp, start = NULL; int ch=1; while(ch) { p = (polyptr)malloc(sizeof(struct polynode)); p...
true
e857f709237bcbfac7abef2fb6e84950ecb099b2
C
mark-huynh/Data-Structures
/Assignment5_skeleton_files_W19/spellChecker.c
UTF-8
4,873
3.65625
4
[ "Zlib" ]
permissive
#include "hashMap.h" #include <assert.h> #include <time.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <ctype.h> /** * Allocates a string for the next word in the file and returns it. This string * is null terminated. Returns NULL after reaching the end of the file. * @param file * @return ...
true
3ddffa15627a737015e4725ac305f7ab055f3f65
C
libanesd/ListaRevisaoA2
/Ex07.c
UTF-8
2,738
3.875
4
[]
no_license
/** Utilizando uma estrutura de pilha, Implemente uma calculadora pós-fixada, contendo as operações básicas (+, -, *, /) **/ #include <stdio.h> #include <stdlib.h> #define MAX 10 #define BASE 0 int TOPO=0, OPERACAO=0; float VETOR[MAX], VALOR=0, N1=0, N2=0, RESULTADO=0; void EMPILHAR(float VALOR) { ...
true
edbdecae9a5405202ddeec949cddab8b58bb9ef9
C
mxie33/CS2200_spring16
/micro-project2/gdb_example2.c
UTF-8
554
3.546875
4
[]
no_license
#include <stdio.h> #include <stdlib.h> #include <string.h> #define BUFFERSIZE 100 void setint(int* ip, int i) { *ip = i; } void write_message(char *message) { char buffer[BUFFERSIZE]; memset(buffer, '\0', BUFFERSIZE); strcpy(buffer, message); printf("%s\n", buffer); } int main() { char mes...
true
06909e5ebc0b5ce021d35f4ff3bd9803afa06095
C
patriziocannoni/WaterProject
/WaterSensors/Tasks/TaskRS485Slave.c
UTF-8
2,642
2.734375
3
[]
no_license
/* * TaskRS485.c * * Created on: 10/09/2015 * Author: patrizio */ #include <FreeRTOS.h> #include <queue.h> #include <task.h> #include <rs485.h> #include <TaskRS485Slave.h> // Estado do processo. static unsigned char processState; static xQueueHandle commandQueue; static xQueueHandle responseQueue; enum {...
true
4583741a8edc303a56218790ccdb92cdaeafaceb
C
Ventupath/tolve
/chat-server.c
UTF-8
1,250
2.90625
3
[]
no_license
#include "utils.h" int go = 1; void Server(char* userFile, char* logFile){ printf("server pid: %d\n", getpid()); int sock, newSocket; struct sockaddr_in my_addr; bzero(&my_addr,sizeof(struct sockaddr_in)); sock = socket(AF_INET, SOCK_STREAM, 0); my_addr.sin_family = AF_INET; my_addr.sin_port = htons(5001); my...
true
f9791b3478392e0dedd1814f08b10de95ab21a12
C
akapust1n/SMTP
/client/src/client-run.c
UTF-8
10,698
2.609375
3
[]
no_license
/** \file client-run.c * \brief Основные функции. * * В этом файле описана главная функция программы. */ #include <client-worker-commands.h> #include <time.h> #include "client-run.h" #include "client-logger.h" #include "client-worker.h" #include "smtp_sockets.h" #include "hashtable.h" int scan_dir_for_new_mail(...
true
6563cfc85092ac9888e37d2df0103f327625cc0e
C
Carnagiul/lemin
/lemin/set_file.c
UTF-8
2,438
2.59375
3
[]
no_license
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* set_file.c :+: :+: :+: ...
true
954527313fca17889f758dfad8addf292feef86a
C
Tobias-Schoch/BSYS-HTWG
/Chap_14/vector.c
UTF-8
920
3.671875
4
[]
no_license
#include <stdio.h> #include <stdlib.h> int main(int argc, char *argv[]) { struct vec { int arrSize; int arr[]; }; struct vec *vecArr; vecArr = malloc(sizeof(struct vec)); if (vecArr == NULL) { perror("Error "); return EXIT_FAILURE; } if (argc != 2) { ...
true
01bb4e78736a4d7f820409cde39aa0d372beb27f
C
Kofemolka/TelitAPI
/uart.c
UTF-8
4,378
2.703125
3
[]
no_license
#include <Windows.h> #include <stdio.h> #include <string.h> #include "common.h" #define buffSize 1000 HANDLE hComm; // Handle to the Serial port OVERLAPPED o; void openComPort() { BOOL Status; // Status of the various operations char ComPortName[] = "\\\\.\...
true
c1568e3bf25e52d5d03a01898b0f38514fd86e14
C
sikey647/NetworkAction
/base/c/tcp_client.c
UTF-8
2,017
3.265625
3
[]
no_license
#include <stdio.h> #include <stdlib.h> #include <sys/types.h> #include <sys/socket.h> #include <netinet/in.h> #include <arpa/inet.h> #include <fcntl.h> #include <unistd.h> #include <errno.h> #include <strings.h> #define BUFFER_SIZE 1024 int main(int argc, char **argv) { if (argc != 3) { fprintf(stderr, "u...
true
fdb1428fde09a97ca7b18fe5b25a1198b31c3d74
C
little0brother/C-C-Study
/CLanaugeAdvanced/day08/day08/01_递归的使用.c
GB18030
584
4.125
4
[]
no_license
#include <stdio.h> void fun(int a) { if (a == 1) { printf("a == %d\n", a); return; // жϺҪ } fun(a - 1); printf("a = %d\n", a); } // ݹۼ int add(int n) { if (n < 1) { return n; } return n + add(n - 1); } int add2(int n) { if (n == 100) { return n; } return n + add2(n + 1); } int main() { //...
true
bcb9c0767ed6d9827bd9875d44385e634c5a45b9
C
jmoussu/FDF
/srcs/ligne_img.c
UTF-8
2,637
2.828125
3
[]
no_license
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* ligne_img.c :+: :+: :+: ...
true
fe2ada09c874fa51dcaeeacc87f432a42b5f3c78
C
kah-g/CComp_Repository
/Programacao_2/Trabalho/GeraSemente.c
UTF-8
2,640
3.859375
4
[]
no_license
#include "GeraSemente.h" int SementeMain (char *senha) { int semente=0; if ((senha[0] >= 'A') && (senha[0] <= 'Z')) { //converte com os valores de letra maiuscula semente = ConverteMaiuscula (senha); } else if ((senha[0] >= 'a') && (senha[0] <= 'z')) { //converte com os valores de letra minuscula ...
true
5e613ffa3d624dfa14af24e1a9c379d659cde6b6
C
szabolor/branch-prediction
/test/branch_test.c
UTF-8
2,297
2.9375
3
[]
no_license
#include <stdint.h> #include <unistd.h> #include <signal.h> #include <stdio.h> #include <stdlib.h> #define WITH_PRINT ( 0 ) /* Lorant SZABO Build with: `gcc -Wall -Wextra -pedantic -O0 -ggdb -o branch_test branch_test.c' Inspect assembly code for the critical section (e.g. compiler doesn't optimized ...
true
62f5d7df80ee1a96fbdf0473a6519c0f0eacad8f
C
IDiAlex/Osnovy
/laba10/main_1.c
UTF-8
1,264
3.171875
3
[]
no_license
#include <stdio.h> #include <string.h> #include <malloc.h> #include <stdlib.h> int main(){ char **line=NULL, c; int linenum=0, letternum=0, nword=0, j, i=0; FILE *fpin, *fpout; fpin=fopen("file.txt", "rt"); if(fpin==NULL) return; fpout=fopen("result.txt", "wt"); if(fpout==NULL) ...
true
589e163d618ecaf0b780e8d722a07f069b7c34e6
C
Mekanikles/smuglang
/source/ir/irutils.h
UTF-8
900
2.796875
3
[ "MIT" ]
permissive
#pragma once #include "core.h" #include "ir/ir.h" i64 convertLiteralToInt64(IR::Literal& literal) { auto& primitive = literal.getType()->getPrimitive(); assert(primitive.isConcrete() && primitive.isInteger()); if (primitive.Signed) { switch (primitive.size) { case 8: return literal.readValue<i8>(); ca...
true
1535479f4c427e00ea482dac7b0bba7c6d5bef7b
C
nobodyzxc/OnlineJudge
/zj/a021.c
UTF-8
4,227
2.859375
3
[]
no_license
#include<stdio.h> #include<stdlib.h> #include<string.h> #include<memory.h> int numlen(int al[]); void plus(void); int minus(void); void mutiply(void); void divise(void); void stvnum(int num[]); void rm0(int num[]); void rm1(int num[]); int num1[501]={-1}; int num2[501]={-1}; char non[501]={0}; int main(void){ int ch; ...
true
26e5bb801d8e35efdf99ef5fda607950cdcf5352
C
randipsbh/kandr
/chapter01/exercise1-13.c
UTF-8
703
4
4
[]
no_license
#include <stdio.h> /* prints a histogram of the lengths of words */ main() { int c, i, j; int count = 0; int words[10]; for (i = 0; i < 10; ++i) words[i] = 0; while ((c = getchar()) != EOF) { if (c != ' ' && c != '\n' && c != '\t' && c != '.') { ++count; } else { if (count != 0) ...
true
ed8e70f48dc46fb40c3262a47365c164bfcc5fce
C
pjavier98/P1
/Huxley/295_distancia_entre_dois_pontos.c
UTF-8
213
3.53125
4
[]
no_license
#include <stdio.h> #include <math.h> int main() { int x1, y1, x2, y2; scanf("%d %d %d %d", &x1, &y1, &x2, &y2); double distancia = sqrt(pow((x2 - x1),2) + pow((y2 - y1),2)); printf("%.4lf\n", distancia); }
true
348fd18baaf1bff1d71574fb546d7acba0e2d269
C
admiralu/learn_geek
/dz9/dz9v1.c
UTF-8
717
3.59375
4
[]
no_license
#include <stdio.h> #include <string.h> #include <stdlib.h> void str_sum_digits(const char *cs); int main() { const char cs[100] = { 0 }; printf("enter string with digits\n"); scanf("%[0-9]", &cs); printf("cs %s\n", cs); str_sum_digits(cs); //*cs=getchar(); //printf("Hello World!"); return 0; } void str_sum_...
true
8c6a6d7fb48eb4f85f9a852c63ae3d424862fb05
C
Qvasov/lem-in
/libft/ft_printf/src/ft_formstr_s.c
UTF-8
1,650
2.78125
3
[]
no_license
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* ft_formstr_s.c :+: :+: :+: ...
true
End of preview. Expand in Data Studio

No dataset card yet

Downloads last month
268