repo stringlengths 4 140 | commit_id stringlengths 7 7 | rel_path stringlengths 1 3.5k | language stringclasses 37
values | url stringlengths 37 3.56k | raw_url stringlengths 54 3.58k | key stringlengths 20 3.54k | ok bool 1
class | status int64 200 200 | bytes int64 48 425k | content stringlengths 40 425k | worker_id int64 0 7 |
|---|---|---|---|---|---|---|---|---|---|---|---|
Tunji-L/alx-low_level_programming | 3d0bf6b | 0x01-variables_if_else_while/8-print_base16.c | C | www.github.com/Tunji-L/alx-low_level_programming/tree/main/0x01-variables_if_else_while/8-print_base16.c | https://raw.githubusercontent.com/Tunji-L/alx-low_level_programming/3d0bf6b/0x01-variables_if_else_while/8-print_base16.c | Tunji-L/alx-low_level_programming 3d0bf6b 0x01-variables_if_else_while/8-print_base16.c | true | 200 | 297 | #include <stdlib.h>
#include <time.h>
#include <stdio.h>
/**
* main - Print 0 to 9 and a to f
*
* Return: Always 0 (Success / correct)
*/
int main(void)
{
int ch;
for (ch = 0; ch < 10; ch++)
putchar(ch + '0');
for (ch = 'a'; ch <= 'f'; ch++)
putchar(ch);
putchar(10);
return (0);
}
| 0 |
LexxPluss/LexxHard-SensorControlBoard-Firmware | f8a6fa0 | extra/drivers/sensor/maxbotix/maxbotix.c | C | www.github.com/LexxPluss/LexxHard-SensorControlBoard-Firmware/tree/main/extra/drivers/sensor/maxbotix/maxbotix.c | https://raw.githubusercontent.com/LexxPluss/LexxHard-SensorControlBoard-Firmware/f8a6fa0/extra/drivers/sensor/maxbotix/maxbotix.c | LexxPluss/LexxHard-SensorControlBoard-Firmware f8a6fa0 extra/drivers/sensor/maxbotix/maxbotix.c | true | 200 | 6,590 | /*
* Copyright (c) 2022, LexxPluss 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:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of co... | 1 |
FadiAfani/PrimeLang | 94aee97 | src/vm.c | C | www.github.com/FadiAfani/PrimeLang/tree/main/src/vm.c | https://raw.githubusercontent.com/FadiAfani/PrimeLang/94aee97/src/vm.c | FadiAfani/PrimeLang 94aee97 src/vm.c | true | 200 | 12,073 | #include <stdlib.h>
#include <stdio.h>
#include "../include/vm.h"
#include "../include/value.h"
#include "../include/memory.h"
#define DIS_FLAG
VM* init_VM() {
VM* vm;
ALLOCATE(vm, VM, 1);
vm->fp = -1;
vm->ip = 0;
vm->sp = -1;
/* native functions */
NativeFuncObj native_print_int;
... | 2 |
nachorvd02/Ejercicios_programacion_cientifica | 9f58fe1 | torres_hanoi_rec.c | C | www.github.com/nachorvd02/Ejercicios_programacion_cientifica/tree/main/torres_hanoi_rec.c | https://raw.githubusercontent.com/nachorvd02/Ejercicios_programacion_cientifica/9f58fe1/torres_hanoi_rec.c | nachorvd02/Ejercicios_programacion_cientifica 9f58fe1 torres_hanoi_rec.c | true | 200 | 1,967 | /* hanoinorec.c
la quantitat de moviments per a moure n discs és (2**n)-1
*/
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
int main(void)
{
int n, i, j, aux;
char o, f, *ori, *fin;
scanf("%d", &n);
if (n < 1) exit(1);
aux = pow(2, n);
ori = (char *)malloc(aux*sizeof(char));
f... | 4 |
nerdola-de-cartola/GTK | f39f9e5 | icon.c | C | www.github.com/nerdola-de-cartola/GTK/tree/main/icon.c | https://raw.githubusercontent.com/nerdola-de-cartola/GTK/f39f9e5/icon.c | nerdola-de-cartola/GTK f39f9e5 icon.c | true | 200 | 968 | #include <gtk/gtk.h>
GdkPixbuf *create_pixbuf(const gchar * filename) {
GdkPixbuf *pixbuf;
GError *error = NULL;
pixbuf = gdk_pixbuf_new_from_file(filename, &error);
if (!pixbuf) {
fprintf(stderr, "%s\n", error->message);
g_error_free(error);
}
return pixbuf;
}
int main(int a... | 3 |
Rosialdo/memoria_virtual | 7f7eb5a | main.c | C | www.github.com/Rosialdo/memoria_virtual/tree/main/main.c | https://raw.githubusercontent.com/Rosialdo/memoria_virtual/7f7eb5a/main.c | Rosialdo/memoria_virtual 7f7eb5a main.c | true | 200 | 1,185 | #include <stdio.h>
#include <stdlib.h>
#include <fcntl.h>
#include <sys/mman.h>
#include <sys/stat.h>
#include <unistd.h>
#define PAGESIZE 4096
int main() {
int fd;
struct stat fileStat;
char *map;
off_t fileSize;
long pageCount, offsetDiff;
fd = open("kjv.txt", O_RDONLY);
... | 0 |
terryalx/alx-low_level_programming | 1b2dd9b | 0x09-static_libraries/3-strcmp.c | C | www.github.com/terryalx/alx-low_level_programming/tree/main/0x09-static_libraries/3-strcmp.c | https://raw.githubusercontent.com/terryalx/alx-low_level_programming/1b2dd9b/0x09-static_libraries/3-strcmp.c | terryalx/alx-low_level_programming 1b2dd9b 0x09-static_libraries/3-strcmp.c | true | 200 | 307 | #include "main.h"
/**
* _strcmp - compares two strings
* @s1: string 1
* @s2: string 2
* Return: string value
*/
int _strcmp(char *s1, char *s2)
{
int num;
num = 0;
while (s1[num] != '\0' || s2[num] != '\0')
{
if (s1[num] != s2[num])
return (s1[num] - s2[num]);
num++;
}
return (0);
}
| 6 |
RosalindJackson/daily-exercise | 819ba14 | test3/23_2_6.c | C | www.github.com/RosalindJackson/daily-exercise/tree/main/test3/23_2_6.c | https://raw.githubusercontent.com/RosalindJackson/daily-exercise/819ba14/test3/23_2_6.c | RosalindJackson/daily-exercise 819ba14 test3/23_2_6.c | true | 200 | 169 | /*23.02.06_Output odd numbers from 1 to 100*/
#include<stdio.h>
int main()
{
int a=0;
while(a<=100)
{
if(a%2==1)
printf("%d ",a);
a++;
}
return 0;
}
| 1 |
RUPESH-KUMAR24AE019/homework_assignment.cp.gsv | 40fc374 | transposematrix.c | C | www.github.com/RUPESH-KUMAR24AE019/homework_assignment.cp.gsv/tree/main/transposematrix.c | https://raw.githubusercontent.com/RUPESH-KUMAR24AE019/homework_assignment.cp.gsv/40fc374/transposematrix.c | RUPESH-KUMAR24AE019/homework_assignment.cp.gsv 40fc374 transposematrix.c | true | 200 | 1,044 | //transpose of a matrix
#include<stdio.h>
void main()
{
int n,i,j;
printf("enter the size of the matrices(N*N):"); //SIZE OF MATRIX
scanf("%d",&n);
int original[n][n],transpose[n][n];
printf("enter the elements of the original matrices A:\n"); //INPUT
for (i=0;... | 4 |
nithish-it21/GX-Assessment | f3cffd7 | Programs/Assessment3/leap_year.c | C | www.github.com/nithish-it21/GX-Assessment/tree/main/Programs/Assessment3/leap_year.c | https://raw.githubusercontent.com/nithish-it21/GX-Assessment/f3cffd7/Programs/Assessment3/leap_year.c | nithish-it21/GX-Assessment f3cffd7 Programs/Assessment3/leap_year.c | true | 200 | 462 | #include<stdio.h>
int leapyear(int n){
if((n%4==0 && n%100!=0) || n%400==0){
return 1;
}
return 0;
}
void main(){
unsigned int num;
printf("Enter the year: ");
scanf("%d",&num);
int res = leapyear(num);
printf("\n");
printf("OUTPUT\n");
printf("-----------------------------------\n");
if(res){
... | 2 |
lumenofwhy/DataStructureWithC | 833c6a4 | tree/src/bittree/bitTree.c | C | www.github.com/lumenofwhy/DataStructureWithC/tree/main/tree/src/bittree/bitTree.c | https://raw.githubusercontent.com/lumenofwhy/DataStructureWithC/833c6a4/tree/src/bittree/bitTree.c | lumenofwhy/DataStructureWithC 833c6a4 tree/src/bittree/bitTree.c | true | 200 | 6,609 | #include "bitTree.h"
#include <malloc.h>
#include <stdio.h>
// 二叉树线索化
static void InTread(TreeNode*, TreeNode*);
void CreatBitTree(TreeNode* T)
{
// 创建一个二叉树实例
// 1
// 2 3
// 4 5 6 7
// 8 N N 9 N N 10 11
T->data = 1;
T->lchild = (Tree... | 3 |
BPChance/atlas-low_level_programming | 18287e7 | more_singly_linked_lists/10-delete_nodeint.c | C | www.github.com/BPChance/atlas-low_level_programming/tree/main/more_singly_linked_lists/10-delete_nodeint.c | https://raw.githubusercontent.com/BPChance/atlas-low_level_programming/18287e7/more_singly_linked_lists/10-delete_nodeint.c | BPChance/atlas-low_level_programming 18287e7 more_singly_linked_lists/10-delete_nodeint.c | true | 200 | 640 | #include "lists.h"
/**
* delete_nodeint_at_index - deletes the node at index index of a listint_t linked list
* @head: head
* @index: index
* Return: 1 if success, otherwise -1
*/
int delete_nodeint_at_index(listint_t **head, unsigned int index)
{
listint_t *current, *previous;
unsigned int i;
if (head == NULL... | 6 |
Gary-Starling/linux | 08c72f9 | ipc/shmem/solution.c | C | www.github.com/Gary-Starling/linux/tree/main/ipc/shmem/solution.c | https://raw.githubusercontent.com/Gary-Starling/linux/08c72f9/ipc/shmem/solution.c | Gary-Starling/linux 08c72f9 ipc/shmem/solution.c | true | 200 | 1,527 | #include <sys/types.h>
#include <sys/ipc.h>
#include <sys/shm.h>
#include <ctype.h>
#include <stddef.h>
#include <stdlib.h>
#include <stdio.h>
int main(int argc, char const *argv[])
{
int key1_reg = atoi(argv[1]);
int key2_reg = atoi(argv[2]);
int shmid1 = 0, shmid2 = 0, shmid3 = 0; /* IPC де... | 0 |
Dannyross1/simple_shell | 8950a6e | builtin.c | C | www.github.com/Dannyross1/simple_shell/tree/main/builtin.c | https://raw.githubusercontent.com/Dannyross1/simple_shell/8950a6e/builtin.c | Dannyross1/simple_shell 8950a6e builtin.c | true | 200 | 2,644 | #include "shell.h"
/**
* exitShell - this exit the shell
* @info: this is the structure containing potential arguments
* print_error: used to print
* _eput: a function to print a string to the error output stream.
* _eputchar: a function to print a string to the error output stream.
* Return: this exits with a ... | 1 |
brianestadimas/mllm.pp | 6a871b5 | src/backends/xnnpack/third_party/XNNPACK/src/x32-zerob/x32-zerob.h | C | www.github.com/brianestadimas/mllm.pp/tree/main/src/backends/xnnpack/third_party/XNNPACK/src/x32-zerob/x32-zerob.h | https://raw.githubusercontent.com/brianestadimas/mllm.pp/6a871b5/src/backends/xnnpack/third_party/XNNPACK/src/x32-zerob/x32-zerob.h | brianestadimas/mllm.pp 6a871b5 src/backends/xnnpack/third_party/XNNPACK/src/x32-zerob/x32-zerob.h | true | 200 | 1,534 | // Copyright 2024 Google LLC
//
// This source code is licensed under the BSD-style license found in the
// LICENSE file in the root directory of this source tree.
#ifndef XNN_UKERNEL_WITH_PARAMS
#define XNN_UKERNEL_WITH_PARAMS(arch_flags, ukernel, channel_tile, channel_subtile, channel_round, params_type, init_params... | 4 |
Hawa-Hardy/alx-low_level_programming | 9624ed2 | 0x13-more_singly_linked_lists/10-delete_nodeint.c | C | www.github.com/Hawa-Hardy/alx-low_level_programming/tree/main/0x13-more_singly_linked_lists/10-delete_nodeint.c | https://raw.githubusercontent.com/Hawa-Hardy/alx-low_level_programming/9624ed2/0x13-more_singly_linked_lists/10-delete_nodeint.c | Hawa-Hardy/alx-low_level_programming 9624ed2 0x13-more_singly_linked_lists/10-delete_nodeint.c | true | 200 | 676 | #include "lists.h"
/**
* delete_nodeint_at_index - deletes a node at a certain index
* @head: pointer to the first element
* @index: index of the node to be deleted
*
* Return: 1 on Success or -1 when Failed
*/
int delete_nodeint_at_index(listint_t **head, unsigned int index)
{
listint_t *temp = *head;
listint... | 2 |
Yizhi53/linux_module | b49c057 | hello-sysfs/hello-sysfs.c | C | www.github.com/Yizhi53/linux_module/tree/main/hello-sysfs/hello-sysfs.c | https://raw.githubusercontent.com/Yizhi53/linux_module/b49c057/hello-sysfs/hello-sysfs.c | Yizhi53/linux_module b49c057 hello-sysfs/hello-sysfs.c | true | 200 | 1,204 | #include <linux/fs.h>
#include <linux/init.h>
#include <linux/kobject.h>
#include <linux/module.h>
#include <linux/string.h>
#include <linux/sysfs.h>
static struct kobject *mymodule;
static int myvariable = 0;
static ssize_t myvariable_show(struct kobject *kobj, struct kobj_attribute *attr, char *buf)
{
return spri... | 3 |
qmerchant09/cse2421 | df465da | shim lab5/rtest.c | C | www.github.com/qmerchant09/cse2421/tree/main/shim lab5/rtest.c | https://raw.githubusercontent.com/qmerchant09/cse2421/df465da/shim%20lab5/rtest.c | qmerchant09/cse2421 df465da shim lab5/rtest.c | true | 200 | 214 |
/* AU21 CSE 2421 Lab 5 reverse test */
#include <stdio.h>
#include "l5.h"
int main()
{
unsigned int x = 0x12345678u;
printf("Reversing %x\n", x);
x = rshim(x);
printf("Reverse gave %x\n", x);
return 0;
}
| 6 |
deckercjames/Catan-Board-Generator | 753ed47 | src/SoC.c | C | www.github.com/deckercjames/Catan-Board-Generator/tree/main/src/SoC.c | https://raw.githubusercontent.com/deckercjames/Catan-Board-Generator/753ed47/src/SoC.c | deckercjames/Catan-Board-Generator 753ed47 src/SoC.c | true | 200 | 6,154 |
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
/**
* All resource types in the game (used for both ports and hexes)
*/
typedef enum resources
{
WOOD = 'w',
BRICK = 'b',
WHEAT = 'g',
SHEEP = 's',
ORE = 'o',
DESERT = 'd',
ANTHING = 'a',
TERM... | 0 |
echostreams/nucemu | 8bce8dc | include/hw/intc/nuc970_aic.h | C | www.github.com/echostreams/nucemu/tree/main/include/hw/intc/nuc970_aic.h | https://raw.githubusercontent.com/echostreams/nucemu/8bce8dc/include/hw/intc/nuc970_aic.h | echostreams/nucemu 8bce8dc include/hw/intc/nuc970_aic.h | true | 200 | 5,021 | /*
* NUC970 Advanced Interrupt Controller
*
* This code is licensed under the GPL version 2 or later. See
* the COPYING file in the top-level directory.
*
* TODO: implement vectors.
*/
#ifndef NUC970_AIC_H
#define NUC970_AIC_H
#include "hw/sysbus.h"
#include "qom/object.h"
#define TYPE_NUC970_AIC "nuc970.aic... | 1 |
dineshb-exe/My-C-Programs | b88e24d | DS LAB/Week4 Linked Lists/palindrome_linked_list.c | C | www.github.com/dineshb-exe/My-C-Programs/tree/main/DS LAB/Week4 Linked Lists/palindrome_linked_list.c | https://raw.githubusercontent.com/dineshb-exe/My-C-Programs/b88e24d/DS%20LAB/Week4%20Linked%20Lists/palindrome_linked_list.c | dineshb-exe/My-C-Programs b88e24d DS LAB/Week4 Linked Lists/palindrome_linked_list.c | true | 200 | 1,540 | #include<stdio.h>
#include<string.h>
struct node{
char d;
struct node* next;
};
typedef struct node node;
int main(){
char str1[20];
int i;
printf("Enter the string: ");
gets(str1);
node *n1=NULL,*n2=NULL,*t1=NULL,*t2=NULL,*h1=NULL,*h2=NULL;
for(i=0;i<strlen(str1);i++){
n1=(node... | 4 |
priyal0907/c-language | d887e62 | Filament.c/Fm1.c | C | www.github.com/priyal0907/c-language/tree/main/Filament.c/Fm1.c | https://raw.githubusercontent.com/priyal0907/c-language/d887e62/Filament.c/Fm1.c | priyal0907/c-language d887e62 Filament.c/Fm1.c | true | 200 | 315 | #include<stdio.h>
#include<string.h>
int main(){
char str[100],c;
int count=0;
printf("Enter string : ");
gets(str);
for(c='a'; c<='z'; c++){
count=0;
for(i=0; str[i] !=NULL; i++){
if(c==str[i])
count++;
}
if(count>0)
printf("%c %d\n",c,count);
}
return 0;
}
| 2 |
boksram/learn | 30afc9d | 带头双向链表/DSList.c | C | www.github.com/boksram/learn/tree/main/带头双向链表/DSList.c | https://raw.githubusercontent.com/boksram/learn/30afc9d/%E5%B8%A6%E5%A4%B4%E5%8F%8C%E5%90%91%E9%93%BE%E8%A1%A8/DSList.c | boksram/learn 30afc9d 带头双向链表/DSList.c | true | 200 | 1,666 | #define _CRT_SECURE_NO_WARNINGS 1
#include "DSList.h"
ListNode* BuyListNode(LTDataType x)
{
ListNode* list = malloc(sizeof(ListNode));
if (list == NULL)
{
perror("malloc");
exit(-1);
}
else
return list;
}
ListNode* ListCreate()
{
ListNode* list = malloc(sizeof(ListNode));
list->next = list->prev = list;... | 3 |
IbrahimDiab1/ARM-Cortex-M3-Firmware-Modules | b46e40b | HAL/STP/STP_program.c | C | www.github.com/IbrahimDiab1/ARM-Cortex-M3-Firmware-Modules/tree/main/HAL/STP/STP_program.c | https://raw.githubusercontent.com/IbrahimDiab1/ARM-Cortex-M3-Firmware-Modules/b46e40b/HAL/STP/STP_program.c | IbrahimDiab1/ARM-Cortex-M3-Firmware-Modules b46e40b HAL/STP/STP_program.c | true | 200 | 1,716 | /********************************************************************************************/
/* Author : Ibrahim Diab */
/* File Name : STP_program.c */
/* Description : Functions Implemen... | 6 |
FireBite/bitehack_hw | a7b070b | src/net.c | C | www.github.com/FireBite/bitehack_hw/tree/main/src/net.c | https://raw.githubusercontent.com/FireBite/bitehack_hw/a7b070b/src/net.c | FireBite/bitehack_hw a7b070b src/net.c | true | 200 | 7,249 | #include "net.h"
#include "comm.h"
static const char* TAG = "net";
static httpd_handle_t server = NULL;
static EventGroupHandle_t s_wifi_event_group;
static int s_retry_num = 0;
static void event_handler(void* arg, esp_event_base_t event_base,
int32_t event_id, void* event_data)
{
... | 1 |
Aayush077/C-prog | 465f89a | LAB/practice3.2.c | C | www.github.com/Aayush077/C-prog/tree/main/LAB/practice3.2.c | https://raw.githubusercontent.com/Aayush077/C-prog/465f89a/LAB/practice3.2.c | Aayush077/C-prog 465f89a LAB/practice3.2.c | true | 200 | 867 | //wap to add two polynomial.
#include <stdio.h>
void addPoly(int arr1[], int arr2[], int sum[], int n) {
for (int i = 0; i < n; i++) {
sum[i] = arr1[i] + arr2[i];
}
}
int main() {
int n;
printf("Enter the size of arr: ");
scanf("%d", &n);
int arr1[n+1], arr2[n+1], sum[n+1];
print... | 4 |
Epitech-Tech2/Ftp | 00a7eab | src/main.c | C | www.github.com/Epitech-Tech2/Ftp/tree/main/src/main.c | https://raw.githubusercontent.com/Epitech-Tech2/Ftp/00a7eab/src/main.c | Epitech-Tech2/Ftp 00a7eab src/main.c | true | 200 | 1,759 | /*
** EPITECH PROJECT, 2022
** B-NWP-400-STG-4-1-myftp-romanie.de-meyer
** File description:
** main
*/
#include "../include/myftp.h"
static server_t *init_next(server_t *server, char *path)
{
memset(&server->address, 0, server->lenght);
server->address.sin_family = AF_INET;
server->address.sin_port = hto... | 3 |
Aiimeey/alx-low_level_programming | 6fa6aa2 | 0x17-doubly_linked_lists/2-add_dnodeint.c | C | www.github.com/Aiimeey/alx-low_level_programming/tree/main/0x17-doubly_linked_lists/2-add_dnodeint.c | https://raw.githubusercontent.com/Aiimeey/alx-low_level_programming/6fa6aa2/0x17-doubly_linked_lists/2-add_dnodeint.c | Aiimeey/alx-low_level_programming 6fa6aa2 0x17-doubly_linked_lists/2-add_dnodeint.c | true | 200 | 577 | #include "lists.h"
/**
* add_dnodeint - Adds a new node at the beginning of a doubly-linked list
*
* @head: A pointer to a pointer to the head of the doubly-linked list
* @n: The integer value to be stored in the new node
*
* Return: A pointer to the newly created node
*/
dlistint_t *add_dnodeint(dlistint_t **he... | 0 |
MobSlicer152/ftl_clone | 919e6fd | ftl/main.c | C | www.github.com/MobSlicer152/ftl_clone/tree/main/ftl/main.c | https://raw.githubusercontent.com/MobSlicer152/ftl_clone/919e6fd/ftl/main.c | MobSlicer152/ftl_clone 919e6fd ftl/main.c | true | 200 | 1,668 | // Main file
#include "ftl.h"
#include "pack.h"
#include "settings.h"
#include "text.h"
#include "util.h"
int32_t main(int32_t argc, char *argv[])
{
char *ftl_dir;
settings_t *settings;
pkg_file_t *ftl_dat;
char *path;
SDL_Window *wnd;
char *wnd_title;
int32_t wnd_width;
int32_t wnd_height;
... | 6 |
Mvrouvne/SimpleShell | d4abf92 | parsing/check_quotes.c | C | www.github.com/Mvrouvne/SimpleShell/tree/main/parsing/check_quotes.c | https://raw.githubusercontent.com/Mvrouvne/SimpleShell/d4abf92/parsing/check_quotes.c | Mvrouvne/SimpleShell d4abf92 parsing/check_quotes.c | true | 200 | 3,062 | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* check_quotes.c :+: :+: :+: ... | 5 |
jrvalverde/OS-omu | 087da40 | omuRTOS/dev/ramdisk/ramd.h | C | www.github.com/jrvalverde/OS-omu/tree/main/omuRTOS/dev/ramdisk/ramd.h | https://raw.githubusercontent.com/jrvalverde/OS-omu/087da40/omuRTOS/dev/ramdisk/ramd.h | jrvalverde/OS-omu 087da40 omuRTOS/dev/ramdisk/ramd.h | true | 200 | 538 | /******************************************************************************
* Ramdisk settings (Memory area defined in memory.h)
******************************************************************************
*/
/* Number of inode blocks */
# define RD_NINODBK 6 /* 48 inodes */
/* Ramdisk definition s... | 7 |
SwapnilKature25/C-with-DS | f144f47 | Pointer/Adv. Pointers/nullPointer.c | C | www.github.com/SwapnilKature25/C-with-DS/tree/main/Pointer/Adv. Pointers/nullPointer.c | https://raw.githubusercontent.com/SwapnilKature25/C-with-DS/f144f47/Pointer/Adv.%20Pointers/nullPointer.c | SwapnilKature25/C-with-DS f144f47 Pointer/Adv. Pointers/nullPointer.c | true | 200 | 291 | /*
NULL pointer: When a pointer initialized with 0 or NULL
then it is called null pointer. To avoid bad and dangling
pointers we are using null pointer.
*/
#include<stdio.h>
int main()
{
// int *p=NULL;
int *p=0;
printf("p stored addr is %u, value is %d",p, *p); //blank
} | 1 |
anjanaammu/cprogram | 57ac10c | add.c | C | www.github.com/anjanaammu/cprogram/tree/main/add.c | https://raw.githubusercontent.com/anjanaammu/cprogram/57ac10c/add.c | anjanaammu/cprogram 57ac10c add.c | true | 200 | 229 | #include<stdio.h>
int main()
{
float num1=12.34;
float num2=56.78;
float sum;
sum= num1 + num2;
printf("number 1:%.2f\n",num1);
printf("number 2:%.2f\n",num2);
printf("sum:%.2f\n",sum);
return 0;
} | 2 |
ValentinMartino/Informatica2 | a7ee878 | Codigos_parcial_informatica/archivos/archivos1.c | C | www.github.com/ValentinMartino/Informatica2/tree/main/Codigos_parcial_informatica/archivos/archivos1.c | https://raw.githubusercontent.com/ValentinMartino/Informatica2/a7ee878/Codigos_parcial_informatica/archivos/archivos1.c | ValentinMartino/Informatica2 a7ee878 Codigos_parcial_informatica/archivos/archivos1.c | true | 200 | 1,241 | #include<stdio.h>
int main(int argc, char *argv[])
{
FILE *archivo;
char caracter;
long tam;
char nombre[30];
if(argv[1] == NULL)
{
printf("\ningrese el el nombre del archivo: \n");
scanf("%s", nombre);
archivo = fopen(nombre,"w");
if(archivo == NULL)
{
printf("\nno se pudo abrir/crear el archivo \n");
}
}
el... | 4 |
kalema1/alx-low_level_programming | 4d978dd | 0x05-pointers_arrays_strings/8-print_array.c | C | www.github.com/kalema1/alx-low_level_programming/tree/main/0x05-pointers_arrays_strings/8-print_array.c | https://raw.githubusercontent.com/kalema1/alx-low_level_programming/4d978dd/0x05-pointers_arrays_strings/8-print_array.c | kalema1/alx-low_level_programming 4d978dd 0x05-pointers_arrays_strings/8-print_array.c | true | 200 | 308 | #include "main.h"
#include <stdio.h>
/**
* print_array - print elements of array
* @a: pointer
* @n: number of elements
*
* Return: no value
*/
void print_array(int *a, int n)
{
int i;
i = 0;
for (n--; n >= 0; n--, i++)
{
printf("%d", a[i]);
if (n > 0)
{
printf(", ");
}
}
printf("\n");
}
| 6 |
STLarus/WEBTERMO8 | 3662b98 | UserSources/USER/source/WhatsApp.c | C | www.github.com/STLarus/WEBTERMO8/tree/main/UserSources/USER/source/WhatsApp.c | https://raw.githubusercontent.com/STLarus/WEBTERMO8/3662b98/UserSources/USER/source/WhatsApp.c | STLarus/WEBTERMO8 3662b98 UserSources/USER/source/WhatsApp.c | true | 200 | 3,433 | /*
* WhatsApp.c
*
* Created on: 26. velj 2023.
* Author: teovu
*/
#include "http_client.h"
#include "define.h"
static err_t wappHeadresDone(httpc_state_t*, void*, struct pbuf*, u16_t, u32_t);
static void wappResult(void*, httpc_result_t, u32_t, u32_t, err_t);
extern uint8_t wAppStatus, wAppflag;
//--------... | 3 |
randaaz/sorting_algorithms | 85ed181 | deck.h | C | www.github.com/randaaz/sorting_algorithms/tree/main/deck.h | https://raw.githubusercontent.com/randaaz/sorting_algorithms/85ed181/deck.h | randaaz/sorting_algorithms 85ed181 deck.h | true | 200 | 1,128 | #ifndef DECK_H
#define DECK_H
/**
* enum kind_e - Represents the suits of a
* standard deck of playing cards
* @SPADE: Spade suit.
* @HEART: Heart suit.
* @CLUB: Club suit.
* @DIAMOND: Diamond suit.
*/
typedef enum kind_e
{
SPADE = 0,
HEART,
CLUB,
DIAMOND
} kind_t;
/**
* struct card_s - Represents an
* ... | 0 |
Abrsh7/alx-low_level_programming | 4621e08 | 0x17-doubly_linked_lists/2-add_dnodeint.c | C | www.github.com/Abrsh7/alx-low_level_programming/tree/main/0x17-doubly_linked_lists/2-add_dnodeint.c | https://raw.githubusercontent.com/Abrsh7/alx-low_level_programming/4621e08/0x17-doubly_linked_lists/2-add_dnodeint.c | Abrsh7/alx-low_level_programming 4621e08 0x17-doubly_linked_lists/2-add_dnodeint.c | true | 200 | 441 | #include "lists.h"
/**
* add_dnodeint - adds new node at the beginning of list
* @head: double pointer to head of node
* @n: node data
* Return: a new node
*/
dlistint_t *add_dnodeint(dlistint_t **head, const int n)
{
dlistint_t *new;
new = malloc(sizeof(dlistint_t));
if (new == NULL)
return (NULL);
new->... | 5 |
RGBDeehan/LAB-Work-1-5 | b933823 | TJC3.c | C | www.github.com/RGBDeehan/LAB-Work-1-5/tree/main/TJC3.c | https://raw.githubusercontent.com/RGBDeehan/LAB-Work-1-5/b933823/TJC3.c | RGBDeehan/LAB-Work-1-5 b933823 TJC3.c | true | 200 | 493 | // C-03 : Input distance travel in(fractional kilometre) and waiting time (min) in a taxi if fare per kilometre is 25 taka (rounded kilometre) and waiting charge is 5 Taka (per min) then display bill . //
#include <stdio.h>
int main() {
float x,y,z;
int bill ;
printf("Enter Fraction Km: ");
scanf("%f", ... | 1 |
newath2024/temperature-monitoring-system | 306d126 | do_an.c | C | www.github.com/newath2024/temperature-monitoring-system/tree/main/do_an.c | https://raw.githubusercontent.com/newath2024/temperature-monitoring-system/306d126/do_an.c | newath2024/temperature-monitoring-system 306d126 do_an.c | true | 200 | 28,808 | /*******************************************************
This program was created by the
CodeWizardAVR V3.12 Advanced
Automatic Program Generator
� Copyright 1998-2014 Pavel Haiduc, HP InfoTech s.r.l.
http://www.hpinfotech.com
Project :
Version :
Date : 6/7/2022
Author :
Company :
Comments:
Chip type ... | 2 |
Helixcon/C-Programs | 5aeacc7 | 9.2b.c | C | www.github.com/Helixcon/C-Programs/tree/main/9.2b.c | https://raw.githubusercontent.com/Helixcon/C-Programs/5aeacc7/9.2b.c | Helixcon/C-Programs 5aeacc7 9.2b.c | true | 200 | 721 | /*
Heloixcon
CSE 3183-02/ System Programming
Program 9.2: sharing data through FIFOs
*/
#include<stdio.h>
#include<stdlib.h>
#include<unistd.h>
#include<string.h>
#include<time.h>
#include<sys/stat.h>
#include<sys/types.h>
#include<errno.h>
#include<fcntl.h>
//Function to Handle for Errors
int HandleError(int v... | 6 |
Rittik-kumar123/c-and-java-codes | 77c424d | data structure/graph.c/bfs_traversal.c | C | www.github.com/Rittik-kumar123/c-and-java-codes/tree/main/data structure/graph.c/bfs_traversal.c | https://raw.githubusercontent.com/Rittik-kumar123/c-and-java-codes/77c424d/data%20structure/graph.c/bfs_traversal.c | Rittik-kumar123/c-and-java-codes 77c424d data structure/graph.c/bfs_traversal.c | true | 200 | 1,578 | # include<stdio.h>
# include<conio.h>
# define max 4
void bfs(int ver,int adj[ver][ver],int visited[],int start)
{
int queue[ver],front=-1,rear=-1;
for(int k=0;k<ver;k++)
{
visited[k]=0;//making elements of visted array 0.
}
queue[++rear]=start;
++front;
visited[start]=1;
printf(... | 4 |
candrdk/Performance-Aware-Programming | 66121e3 | haversine/haversine/ReferenceHaversine.h | C | www.github.com/candrdk/Performance-Aware-Programming/tree/main/haversine/haversine/ReferenceHaversine.h | https://raw.githubusercontent.com/candrdk/Performance-Aware-Programming/66121e3/haversine/haversine/ReferenceHaversine.h | candrdk/Performance-Aware-Programming 66121e3 haversine/haversine/ReferenceHaversine.h | true | 200 | 1,694 | #pragma once
/* ========================================================================
(C) Copyright 2023 by Molly Rocket, Inc., All Rights Reserved.
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 ... | 3 |
Fss7/dataset | 9d1c820 | AtCoder dataset/arc001/B/4722826.c | C | www.github.com/Fss7/dataset/tree/main/AtCoder dataset/arc001/B/4722826.c | https://raw.githubusercontent.com/Fss7/dataset/9d1c820/AtCoder%20dataset/arc001/B/4722826.c | Fss7/dataset 9d1c820 AtCoder dataset/arc001/B/4722826.c | true | 200 | 746 | #include <stdio.h>
#include <stdlib.h>
int cmp(const void *a,const void *b){
return *(int*)a-*(int*)b;
}
int main(void){
int i,n,*a;
char c[101];
scanf("%d",&n);
scanf("%s",c);
a=(int*) malloc(sizeof(int)*4);
for(i=0;i<4;i++){
a[i]=0;
}
for(i=0;i<n;i++){
a[c[i]-1-0x30... | 7 |
ddouworld/sparrow_vs | 7740905 | sparrow/gc/gc.c | C | www.github.com/ddouworld/sparrow_vs/tree/main/sparrow/gc/gc.c | https://raw.githubusercontent.com/ddouworld/sparrow_vs/7740905/sparrow/gc/gc.c | ddouworld/sparrow_vs 7740905 sparrow/gc/gc.c | true | 200 | 10,799 | #include "gc.h"
#include "compiler.h"
#include "obj_list.h"
#include "obj_range.h"
#if DEBUG
#include "debug.h"
#include <time.h>
#endif
//���obj:����obj�ռ�������vm->grays.grayObjects
void grayObject(VM* vm, ObjHeader* obj) {
//���isDarkΪtrue��ʾΪ��ɫ,˵���Ѿ��ɴ�,ֱ�ӷ���
if (obj == NULL || obj->isDark) return;
... | 1 |
0wen99/alx-low_level_programming | a94134e | 0x12-singly_linked_lists/0-print_list.c | C | www.github.com/0wen99/alx-low_level_programming/tree/main/0x12-singly_linked_lists/0-print_list.c | https://raw.githubusercontent.com/0wen99/alx-low_level_programming/a94134e/0x12-singly_linked_lists/0-print_list.c | 0wen99/alx-low_level_programming a94134e 0x12-singly_linked_lists/0-print_list.c | true | 200 | 381 | #include "lists.h"
/**
* print_list -prints all the elements of a list_t list
*
* @h: pointer
*
* Return: the number of nodes
*
*/
size_t print_list(const list_t *h)
{
size_t nelem;
nelem = 0;
while (h != NULL)
{
if (h->str == NULL)
printf("[%d] %s\n", 0, "(nil)");
else
printf("[%d] %s\n", h->le... | 0 |
nescondo/systems-programming-and-utilities-class | cb02f72 | minilabs/ml15-c/ml15.c | C | www.github.com/nescondo/systems-programming-and-utilities-class/tree/main/minilabs/ml15-c/ml15.c | https://raw.githubusercontent.com/nescondo/systems-programming-and-utilities-class/cb02f72/minilabs/ml15-c/ml15.c | nescondo/systems-programming-and-utilities-class cb02f72 minilabs/ml15-c/ml15.c | true | 200 | 1,064 | #include <stdio.h>
#include <stdlib.h>
int main(void) {
int s_arr[12];
int s_cum[12];
int *arr_ptr = (int *) malloc(sizeof(int)*12);
int *cum_ptr = (int *) malloc(sizeof(int)*12);
printf("numbers in s_arr: ");
for (int i=0;i<12;i++) { //pointer arithmetic notation
*(s_arr+i) = i;
printf("%d ", *(s_arr+i)... | 2 |
Sushmitha-Sateesh-Naik/Naik | 6a9eddd | program15.c | C | www.github.com/Sushmitha-Sateesh-Naik/Naik/tree/main/program15.c | https://raw.githubusercontent.com/Sushmitha-Sateesh-Naik/Naik/6a9eddd/program15.c | Sushmitha-Sateesh-Naik/Naik 6a9eddd program15.c | true | 200 | 306 | #include<stdio.h>
int main()
{
int arr[]={10,20,30,40,50,60,70,90,90,100};
int length = 0;
int n=sizeof(arr) / sizeof(arr[0]);
printf("%d",n);
//while (arr[length] != )
//{
// length++;
//}
//printf("Length of the string is : %d\n\n",length - 1);
return 0;
} | 4 |
Mathmcruz/PP-LAB | 9b65e91 | lab02/ex48.c | C | www.github.com/Mathmcruz/PP-LAB/tree/main/lab02/ex48.c | https://raw.githubusercontent.com/Mathmcruz/PP-LAB/9b65e91/lab02/ex48.c | Mathmcruz/PP-LAB 9b65e91 lab02/ex48.c | true | 200 | 328 | #include <stdio.h>
#include <stdlib.h>
int main()
{
int seg, h, m, s, rest;
printf("Digite um tempo em segundos \n");
scanf("%d", &seg);
h = seg / 3600;
rest = seg % 3600;
m = rest / 60;
s = rest % 60;
printf("O tempo em horas, minutos e segundos eh\n %dh %dm %ds \n", h, m, s);
retu... | 5 |
obedydaka/alx-low_level_programming | 2aeb99c | 0x04-more_functions_nested_loops/101-print_number.c | C | www.github.com/obedydaka/alx-low_level_programming/tree/main/0x04-more_functions_nested_loops/101-print_number.c | https://raw.githubusercontent.com/obedydaka/alx-low_level_programming/2aeb99c/0x04-more_functions_nested_loops/101-print_number.c | obedydaka/alx-low_level_programming 2aeb99c 0x04-more_functions_nested_loops/101-print_number.c | true | 200 | 573 | #include "main.h"
void print_integer(int m);
/**
* print_number - This function prints an integer.
* @n: Input an integer
* Return: Nothing
*/
void print_number(int n)
{
if (n == 0)
_putchar('0');
else if (n < 0)
{
_putchar('-');
print_integer(n * -1);
}
else
{
print_integer(n);
}
}
/**
* print_i... | 1 |
Eirvairdre/HW_OS | f4a7789 | 2/test_utility.c | C | www.github.com/Eirvairdre/HW_OS/tree/main/2/test_utility.c | https://raw.githubusercontent.com/Eirvairdre/HW_OS/f4a7789/2/test_utility.c | Eirvairdre/HW_OS f4a7789 2/test_utility.c | true | 200 | 1,225 | #include "background_launcher.h"
#include <stdio.h>
#include <string.h>
// Основная программа для тестирования библиотеки запуска процессов
int main(int argc, char* argv[]) {
if (argc < 2) {
printf("Usage: %s <program> [args]\n", argv[0]);
return 1;
}
intptr_t process_id;
unsigned int ... | 2 |
obieuan/holbertonschool-low_level_programming | b83960d | 0x02-functions_nested_loops/4-isalpha.c | C | www.github.com/obieuan/holbertonschool-low_level_programming/tree/main/0x02-functions_nested_loops/4-isalpha.c | https://raw.githubusercontent.com/obieuan/holbertonschool-low_level_programming/b83960d/0x02-functions_nested_loops/4-isalpha.c | obieuan/holbertonschool-low_level_programming b83960d 0x02-functions_nested_loops/4-isalpha.c | true | 200 | 230 | #include "main.h"
/**
* _isalpha - Esta revisa si C es minúscula
* @c: variable que recibe
* Return: 1 == if lower 1 == if caps
*/
int _isalpha(int c)
{
if (c > 64 && c < 123)
{
return (1);
}
else
{
return (0);
}
}
| 4 |
RashhGajghate/RashhGajghate | b8a3e86 | Rashmi/pesudo_codes_c/getsputs.c | C | www.github.com/RashhGajghate/RashhGajghate/tree/main/Rashmi/pesudo_codes_c/getsputs.c | https://raw.githubusercontent.com/RashhGajghate/RashhGajghate/b8a3e86/Rashmi/pesudo_codes_c/getsputs.c | RashhGajghate/RashhGajghate b8a3e86 Rashmi/pesudo_codes_c/getsputs.c | true | 200 | 251 | #include<stdio.h>
#include<string.h>
char *gets (char* s);
//int puts(const char *s);
int main()
{
printf("Enter the string \n");
char arr[10];
char *str;
// char *str=arr;
gets(arr);
gets(str);
puts(arr);
puts(str);
return 0;
}
| 5 |
alx-cc/portal3d | 861891c | src/clipping.c | C | www.github.com/alx-cc/portal3d/tree/main/src/clipping.c | https://raw.githubusercontent.com/alx-cc/portal3d/861891c/src/clipping.c | alx-cc/portal3d 861891c src/clipping.c | true | 200 | 7,324 | #include "clipping.h"
#include <math.h>
#define NUM_PLANES 6
plane_t frustum_planes[NUM_PLANES];
///////////////////////////////////////////////////////////////////////////////
// Frustum planes are defined by a point and a normal vector
///////////////////////////////////////////////////////////////////////////////
... | 2 |
lsd-maddrive/Awesome_TAU_Stand | 6ec867c | firmware/src/modbusTCP/modbusGet.c | C | www.github.com/lsd-maddrive/Awesome_TAU_Stand/tree/main/firmware/src/modbusTCP/modbusGet.c | https://raw.githubusercontent.com/lsd-maddrive/Awesome_TAU_Stand/6ec867c/firmware/src/modbusTCP/modbusGet.c | lsd-maddrive/Awesome_TAU_Stand 6ec867c firmware/src/modbusTCP/modbusGet.c | true | 200 | 2,020 | #include "ch.h"
#include "hal.h"
#include "modbusFunc.h"
#include "modbusGet.h"
extern char in_buf[100];
//The Function returns the Transaction ID
int16_t modbustcp_get_tid(uint8_t* data)
{
int16_t tid = data[MB_TCP_TID] << 8U;
tid |= data[MB_TCP_TID + 1];
return tid;
}
//The Function returns the Protocol ID
i... | 4 |
JakubFr4czek/SysOpy | 9e24c63 | lab12/client.c | C | www.github.com/JakubFr4czek/SysOpy/tree/main/lab12/client.c | https://raw.githubusercontent.com/JakubFr4czek/SysOpy/9e24c63/lab12/client.c | JakubFr4czek/SysOpy 9e24c63 lab12/client.c | true | 200 | 6,838 | #include<sys/socket.h>
#include<sys/types.h>
#include<netinet/in.h>
#include<inttypes.h> /* strtoimax */
#include<stdbool.h>
#include<errno.h>
#include<stddef.h>
#include<sys/socket.h>
#include<netinet/in.h>
#include<arpa/inet.h>
#include<stdio.h>
#include<unistd.h>
#include<string.h>
#include<time.h>
#include<stdlib.h... | 1 |
KaushalTarpara/DS_with_C_Lab | e19445d | MA068_Kaushal_L4/stackint.h | C | www.github.com/KaushalTarpara/DS_with_C_Lab/tree/main/MA068_Kaushal_L4/stackint.h | https://raw.githubusercontent.com/KaushalTarpara/DS_with_C_Lab/e19445d/MA068_Kaushal_L4/stackint.h | KaushalTarpara/DS_with_C_Lab e19445d MA068_Kaushal_L4/stackint.h | true | 200 | 477 | #include <stdio.h>
int top=-1;
void push(int *stack, int max, char val)
{
if(top==max-1)
{
printf("Overflow\n");
}else
{ stack[++top] = val;
}
}
int pop(int *stack)
{
if(top==-1)
{
printf("Underflow\n");
return 0;
}
return stack[top--];
//printf("Poped Element : %d \n",stack[top--]);
}
void display(... | 5 |
Kevinagreenhand/NJU-ICS-PA-2024 | e3e314f | navy-apps/libs/libndl/NDL.c | C | www.github.com/Kevinagreenhand/NJU-ICS-PA-2024/tree/main/navy-apps/libs/libndl/NDL.c | https://raw.githubusercontent.com/Kevinagreenhand/NJU-ICS-PA-2024/e3e314f/navy-apps/libs/libndl/NDL.c | Kevinagreenhand/NJU-ICS-PA-2024 e3e314f navy-apps/libs/libndl/NDL.c | true | 200 | 2,283 | #include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <sys/time.h>
static int evtdev = -1;
static int fbdev = -1;
static int screen_w = 0, screen_h = 0;
//新加入的
static int canvas_w = 0, canvas_h = 0;
uint32_t NDL_GetTicks() {
//由于初始化的时间可以很短,因此这里不对时间的修正,也就是没有在init的... | 2 |
AdemolaAsamu/alx-low_level_programming | 46d28ae | 0x02-functions_nested_loops/4-isalpha.c | C | www.github.com/AdemolaAsamu/alx-low_level_programming/tree/main/0x02-functions_nested_loops/4-isalpha.c | https://raw.githubusercontent.com/AdemolaAsamu/alx-low_level_programming/46d28ae/0x02-functions_nested_loops/4-isalpha.c | AdemolaAsamu/alx-low_level_programming 46d28ae 0x02-functions_nested_loops/4-isalpha.c | true | 200 | 321 | #include "main.h"
/**
* _isalpha - checks for alphabetic character
*
* @c: The variable number for ASCII aphabets
*
* Return: (1) if c is a upper/ lower case
* 0 otherwise
*/
int _isalpha(int c)
{
if ((c >= 97 && c <= 122) || (c >= 65 && c <= 90))
{
return (1);
}
else
{
return (0);
}
_putchar('\n');
}... | 1 |
WinnieNgina/alx-low_level_programming | 645efef | 0x04-more_functions_nested_loops/3-print_numbers.c | C | www.github.com/WinnieNgina/alx-low_level_programming/tree/main/0x04-more_functions_nested_loops/3-print_numbers.c | https://raw.githubusercontent.com/WinnieNgina/alx-low_level_programming/645efef/0x04-more_functions_nested_loops/3-print_numbers.c | WinnieNgina/alx-low_level_programming 645efef 0x04-more_functions_nested_loops/3-print_numbers.c | true | 200 | 243 | #include "main.h"
/**
* print_numbers - prints the numbers, from 0 to 9, followed by a new line.
* num: variable name
*/
void print_numbers(void)
{
int num;
for (num = 0; num <= 9; num++)
_putchar((num % 10) + '0');
_putchar('\n');
}
| 4 |
corbera/Punteros_SO | 0d6ad5b | p5.c | C | www.github.com/corbera/Punteros_SO/tree/main/p5.c | https://raw.githubusercontent.com/corbera/Punteros_SO/0d6ad5b/p5.c | corbera/Punteros_SO 0d6ad5b p5.c | true | 200 | 543 | #include <stdio.h>
#include <stdlib.h>
int main(int argc, char *argv[])
{
int i;
printf("\n");
printf("Este programa se ha invocado con %d argumentos\n\n", argc);
printf("El nombre del ejecutable (argumento 0) es %s\n\n", argv[0]);
if (argc == 1)
{
printf("El programa se ha llamado sin... | 5 |
polesskiy-dev/iot-risk-data-logger-nfc-samd21 | 4c14f51 | firmware/src/config/default/device_vectors.h | C | www.github.com/polesskiy-dev/iot-risk-data-logger-nfc-samd21/tree/main/firmware/src/config/default/device_vectors.h | https://raw.githubusercontent.com/polesskiy-dev/iot-risk-data-logger-nfc-samd21/4c14f51/firmware/src/config/default/device_vectors.h | polesskiy-dev/iot-risk-data-logger-nfc-samd21 4c14f51 firmware/src/config/default/device_vectors.h | true | 200 | 5,967 | /*******************************************************************************
Cortex-M device vectors file
Company:
Microchip Technology Inc.
File Name:
device_vectors.h
Summary:
Harmony3 device handler structure for cortex-M devices
Description:
This file contains Harmony3 device handle... | 2 |
Sajida-Ait-si-mhand/Minitalk | b5d23e6 | server_bonus.c | C | www.github.com/Sajida-Ait-si-mhand/Minitalk/tree/main/server_bonus.c | https://raw.githubusercontent.com/Sajida-Ait-si-mhand/Minitalk/b5d23e6/server_bonus.c | Sajida-Ait-si-mhand/Minitalk b5d23e6 server_bonus.c | true | 200 | 1,716 | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* server_bonus.c :+: :+: :+: ... | 1 |
Zai-nab23/alx-low_level_programming | 2675c8d | 0x05-pointers_arrays_strings/0-reset_to_98.c | C | www.github.com/Zai-nab23/alx-low_level_programming/tree/main/0x05-pointers_arrays_strings/0-reset_to_98.c | https://raw.githubusercontent.com/Zai-nab23/alx-low_level_programming/2675c8d/0x05-pointers_arrays_strings/0-reset_to_98.c | Zai-nab23/alx-low_level_programming 2675c8d 0x05-pointers_arrays_strings/0-reset_to_98.c | true | 200 | 205 | #include "main.h"
/**
* reset_to_98 - a function that takes a pointer to an int as parameter
* and uppdate the value it points to 98
* @n: input
* Return: n
*/
void reset_to_98(int *n)
{
*n = 98;
}
| 4 |
iAmSherifCodes/alx-low_level_programming | 870e45f | 0x07-pointers_arrays_strings/8-print_diagsums.c | C | www.github.com/iAmSherifCodes/alx-low_level_programming/tree/main/0x07-pointers_arrays_strings/8-print_diagsums.c | https://raw.githubusercontent.com/iAmSherifCodes/alx-low_level_programming/870e45f/0x07-pointers_arrays_strings/8-print_diagsums.c | iAmSherifCodes/alx-low_level_programming 870e45f 0x07-pointers_arrays_strings/8-print_diagsums.c | true | 200 | 618 | #include <stdio.h>
#include "main.h"
/**
* print_diagsums - print the sum of leading diagonal
* @a: pointer to the array
* @size: size of the array
*
*/
void print_diagsums(int *a, int size)
{
int i, sumDiag = 0, sumTrailDiag = 0;
for (i = 0; i < size * size; i++)
{
if ((i % (size + 1) == 0) && (i % (size ... | 5 |
Priyanto71/W3-Resource-C-Programming | a42effa | Basic-Declarations-and-Expressions/17.c | C | www.github.com/Priyanto71/W3-Resource-C-Programming/tree/main/Basic-Declarations-and-Expressions/17.c | https://raw.githubusercontent.com/Priyanto71/W3-Resource-C-Programming/a42effa/Basic-Declarations-and-Expressions/17.c | Priyanto71/W3-Resource-C-Programming a42effa Basic-Declarations-and-Expressions/17.c | true | 200 | 176 | #include<stdio.h>
int main(){
int h,m,s;
printf("Input seconds: ");
scanf("%d",&s);
h=s/3600;
s=s-(h*3600);
m=s/60;
s=s-(m*60);
printf("There are:\nH:M:S - %d:%d:%d",h,m,s);
}
| 2 |
devaer0147/alx-low_level_programming | b86f7a7 | 0x05-pointers_arrays_strings/5-rev_string.c | C | www.github.com/devaer0147/alx-low_level_programming/tree/main/0x05-pointers_arrays_strings/5-rev_string.c | https://raw.githubusercontent.com/devaer0147/alx-low_level_programming/b86f7a7/0x05-pointers_arrays_strings/5-rev_string.c | devaer0147/alx-low_level_programming b86f7a7 0x05-pointers_arrays_strings/5-rev_string.c | true | 200 | 433 | #include "main.h"
/**
* _strlen - returns the length of a string
* @s: string
*
* Return: length
*/
int _strlen(char *s)
{
int len = 0;
while (*s != '\0')
{
len++;
s++;
}
return (len);
}
/**
* rev_string - reverses a string
* @s: string to reverse
*/
void rev_string(char *s)
{
int i = 0;
int j ... | 4 |
Vishalpawar4912/clang | 46fbe4d | 20240915/Recursions/recursion1.c | C | www.github.com/Vishalpawar4912/clang/tree/main/20240915/Recursions/recursion1.c | https://raw.githubusercontent.com/Vishalpawar4912/clang/46fbe4d/20240915/Recursions/recursion1.c | Vishalpawar4912/clang 46fbe4d 20240915/Recursions/recursion1.c | true | 200 | 529 | //1. Write a C program to print all natural numbers between 1 to n using recursion.
#include<stdio.h>
int main()
{
int lower, upper;
printf("Enter the Lower Limit: ");
scanf("%d", &lower);
printf("Enter the Upper Limit: ");
scanf("%d", &upper);
printf("All Natural NUmber from %d to %d are : ", l... | 5 |
dawsonvoth1/Network_Systems | 19aeaad | proxy/proxy.c | C | www.github.com/dawsonvoth1/Network_Systems/tree/main/proxy/proxy.c | https://raw.githubusercontent.com/dawsonvoth1/Network_Systems/19aeaad/proxy/proxy.c | dawsonvoth1/Network_Systems 19aeaad proxy/proxy.c | true | 200 | 12,425 | #include <sys/stat.h>
#include <dirent.h>
#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
#include <string.h>
#include <netdb.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <errno.h>
#include <time.h>
// #include <curl/curl.h>
#define BUFSIZE 2000... | 1 |
AndresRM777/GleAn_Manualidades1 | a569400 | main.c | C | www.github.com/AndresRM777/GleAn_Manualidades1/tree/main/main.c | https://raw.githubusercontent.com/AndresRM777/GleAn_Manualidades1/a569400/main.c | AndresRM777/GleAn_Manualidades1 a569400 main.c | true | 200 | 2,633 | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include "funciones.h"
#include "lecturas.h"
#define MAX_PRODUCTOS 100
void mostrarMenu();
float calcularPrecioConIVA(float precio);
void registrarEntrada(const char *usuario);
int main() {
char nombres[MAX_PRODUCTOS][11];
int canti... | 2 |
hichamelg110/alx-low_level_programming | 1dbfa30 | 0x05-pointers_arrays_strings/5-rev_string.c | C | www.github.com/hichamelg110/alx-low_level_programming/tree/main/0x05-pointers_arrays_strings/5-rev_string.c | https://raw.githubusercontent.com/hichamelg110/alx-low_level_programming/1dbfa30/0x05-pointers_arrays_strings/5-rev_string.c | hichamelg110/alx-low_level_programming 1dbfa30 0x05-pointers_arrays_strings/5-rev_string.c | true | 200 | 259 | #include "main.h"
/**
* rev_string - a function that reverses a string.
* @s: string
*/
void rev_string(char *s)
{
int i = 0, c = 0;
char tmp;
while (s[i++])
length++;
for (i = 0; i < c / 2; c++)
{
tmp = s[i];
s[i] = s[c - i - 1];
s[c - i - 1] = t;
}
}
| 4 |
VivianDee/sorting_algorithms | 02834e4 | 102-counting_sort.c | C | www.github.com/VivianDee/sorting_algorithms/tree/main/102-counting_sort.c | https://raw.githubusercontent.com/VivianDee/sorting_algorithms/02834e4/102-counting_sort.c | VivianDee/sorting_algorithms 02834e4 102-counting_sort.c | true | 200 | 884 | #include "sort.h"
/**
* counting_sort - Sorts an array using the Counting sort algorithm
* @array: An array of integers
* @size: The size of the array
*
*/
void counting_sort(int *array, size_t size)
{
int max = 0, buffer[1024], output[1024], check = 0, count = 0, k = 0;
size_t i = 0, j = 0;
if (!array || size == ... | 5 |
marugaj/alx-low_level_programming | e546abf | 0x06-pointers_arrays_strings/3-strcmp.c | C | www.github.com/marugaj/alx-low_level_programming/tree/main/0x06-pointers_arrays_strings/3-strcmp.c | https://raw.githubusercontent.com/marugaj/alx-low_level_programming/e546abf/0x06-pointers_arrays_strings/3-strcmp.c | marugaj/alx-low_level_programming e546abf 0x06-pointers_arrays_strings/3-strcmp.c | true | 200 | 502 | #include "main.h"
/**
* _strcmp - This is a function that compares two strings
* @s1: This is the pointer to the first string for comparison
* @s2: This is the pointer to the second string for comparison
* Return: If str1 < str2, negative difference of first unmatched characters.
* If str1 == str2, return 0
* I... | 1 |
azzerttt/mon-projet | a9b404a | devoir5.c | C | www.github.com/azzerttt/mon-projet/tree/main/devoir5.c | https://raw.githubusercontent.com/azzerttt/mon-projet/a9b404a/devoir5.c | azzerttt/mon-projet a9b404a devoir5.c | true | 200 | 1,738 | #include <stdio.h>
#include <stdlib.h>
#include <pthread.h>
#include <semaphore.h>
#include <unistd.h>
#define N 5 // Nombre de threads
sem_t semaphore;
int current_thread = 0; // Indicateur du thread en cours
void* thread_function(void* arg) {
int thread_id = *(int*)arg;
while (1) {
... | 2 |
Bhavani-inamdar/bhavani_dsa | 8b8bf9f | sumofeachcol.c | C | www.github.com/Bhavani-inamdar/bhavani_dsa/tree/main/sumofeachcol.c | https://raw.githubusercontent.com/Bhavani-inamdar/bhavani_dsa/8b8bf9f/sumofeachcol.c | Bhavani-inamdar/bhavani_dsa 8b8bf9f sumofeachcol.c | true | 200 | 979 | #include<stdio.h>
void read(int a[10][10],int m,int n);
void print(int a[10][10],int m,int n);
void sum_col(int a[10][10],int m,int n);
main()
{
int a[10][10],m,n,m1;
printf("Enter the order of the matrix\n");
scanf("%d%d",&m,&n);
if(m!=n)
{
printf("not a square matrix\n");
exit(0);
}
printf("... | 4 |
kasettisiva/T2K-NOvA-JointAnalysis | 3d44ec1 | make_validation_plots/Compare_MaCh3_Ptheta_Aria_t2knova_dm2_07July2022.C | C | www.github.com/kasettisiva/T2K-NOvA-JointAnalysis/tree/main/make_validation_plots/Compare_MaCh3_Ptheta_Aria_t2knova_dm2_07July2022.C | https://raw.githubusercontent.com/kasettisiva/T2K-NOvA-JointAnalysis/3d44ec1/make_validation_plots/Compare_MaCh3_Ptheta_Aria_t2knova_dm2_07July2022.C | kasettisiva/T2K-NOvA-JointAnalysis 3d44ec1 make_validation_plots/Compare_MaCh3_Ptheta_Aria_t2knova_dm2_07July2022.C | true | 200 | 14,397 | //To compare MaCh3 and P-theta sensitivities for t2k-nova joint analysis
#include <iostream>
#include <string.h>
struct Binning {
Int_t nbins;
Double_t bin_min;
Double_t bin_max;
};
const char* oscparname;
Binning dcp_binning = {51,-3.2044245,3.2044245};
Binning dm2_binning = {81,2.25e-3,2.75e-3};
Binning dm2_io_... | 5 |
EBUBECHUKW/alx-low_level_programming | 5db0294 | 0x03-debugging/2-largest_number.c | C | www.github.com/EBUBECHUKW/alx-low_level_programming/tree/main/0x03-debugging/2-largest_number.c | https://raw.githubusercontent.com/EBUBECHUKW/alx-low_level_programming/5db0294/0x03-debugging/2-largest_number.c | EBUBECHUKW/alx-low_level_programming 5db0294 0x03-debugging/2-largest_number.c | true | 200 | 419 | #include "main.h"
/**
* main - Entry point
*
* Description - 'prints the largest of 3 integers'
* @a: first integer
* @b: second integer
* @c: third integer
* Return: largest number
*/
int largest_number(int a, int b, int c)
{
int largest;
if (a > b && a > c)
{
largest = a;
}
else if (a > b && c > a)
{
lar... | 1 |
fl3ur1nestimable/wordlove | 9c70707 | Solveur/src/mot.c | C | www.github.com/fl3ur1nestimable/wordlove/tree/main/Solveur/src/mot.c | https://raw.githubusercontent.com/fl3ur1nestimable/wordlove/9c70707/Solveur/src/mot.c | fl3ur1nestimable/wordlove 9c70707 Solveur/src/mot.c | true | 200 | 3,399 | #include "struct.h"
#include "mot.h"
#include "arbre.h"
#include "pattern.h"
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <stdbool.h>
#include <string.h>
// Crée un mot avec le string str comme valeur et d'entropie nulle
mot *mot_create(char *str){
mot *m = malloc(sizeof(mot));
m->val = s... | 4 |
LucianoMPS/Aeds-I | f9d0dd0 | Atividades Heveraldo/Atividades Mensais/Atividade Mensal I/Exercicio Mensal (questão 2)/main.c | C | www.github.com/LucianoMPS/Aeds-I/tree/main/Atividades Heveraldo/Atividades Mensais/Atividade Mensal I/Exercicio Mensal (questão 2)/main.c | https://raw.githubusercontent.com/LucianoMPS/Aeds-I/f9d0dd0/Atividades%20Heveraldo/Atividades%20Mensais/Atividade%20Mensal%20I/Exercicio%20Mensal%20%28quest%C3%A3o%202%29/main.c | LucianoMPS/Aeds-I f9d0dd0 Atividades Heveraldo/Atividades Mensais/Atividade Mensal I/Exercicio Mensal (questão 2)/main.c | true | 200 | 368 | #include <stdio.h>
#include <stdlib.h>
int main()
{
int cont, sinal;
cont = 0;
sinal = 1;
double S, A, B, AB;
S = 0;
A = 3;
B = 1;
while(cont < 15)
{
AB = A/B;
S = S + AB * sinal;
sinal = sinal * (-1);
A += 3;
B *= 7;
cont = cont + 1;
... | 5 |
instarchies/GB_C | 356e279 | Profi/Pr_7/two.c | C | www.github.com/instarchies/GB_C/tree/main/Profi/Pr_7/two.c | https://raw.githubusercontent.com/instarchies/GB_C/356e279/Profi/Pr_7/two.c | instarchies/GB_C 356e279 Profi/Pr_7/two.c | true | 200 | 1,726 | #include <stdio.h>
#include <stdlib.h>
#include <limits.h>
// Define the structure for a tree node
struct Node {
int data;
struct Node* left;
struct Node* right;
};
// Function to create a new node
struct Node* newNode(int data) {
struct Node* node = (struct Node*)malloc(sizeof(struct Node));
node... | 2 |
Peetah-Ke/alx-low_level_programming | cc50e58 | 0x18-dynamic_libraries/9-strcpy.c | C | www.github.com/Peetah-Ke/alx-low_level_programming/tree/main/0x18-dynamic_libraries/9-strcpy.c | https://raw.githubusercontent.com/Peetah-Ke/alx-low_level_programming/cc50e58/0x18-dynamic_libraries/9-strcpy.c | Peetah-Ke/alx-low_level_programming cc50e58 0x18-dynamic_libraries/9-strcpy.c | true | 200 | 379 | #include "main.h"
/**
* char *_strcpy - a function that copies the string pointed to by src
* @dest: copy to
* @src: copy from
* Return: string
*/
char *_strcpy(char *dest, char *src)
{
int l = 0;
int x = 0;
while (*(src + l) != '\0')
{
l++;
}
for ( ; x < l ; x++)
{
dest[x] =... | 1 |
jteerice/FrazzOS | 3e5492d | kernel/src/gdt/gdt.c | C | www.github.com/jteerice/FrazzOS/tree/main/kernel/src/gdt/gdt.c | https://raw.githubusercontent.com/jteerice/FrazzOS/3e5492d/kernel/src/gdt/gdt.c | jteerice/FrazzOS 3e5492d kernel/src/gdt/gdt.c | true | 200 | 1,125 | #include "gdt.h"
#include "klibc/string.h"
#include "klibc/io.h"
#include "../config.h"
#include "klibc/memory.h"
#include <flanterm.h>
#include <backends/fb.h>
#include "klibc/io.h"
struct gdt gdt[FRAZZOS_TOTAL_SEGMENTS];
struct gdt_structured gdt_structured[FRAZZOS_TOTAL_SEGMENTS] = {
{ .access_byte = 0x00, .fla... | 6 |
sejin8642/C | c8d3cae | exercises/5.13.c | C | www.github.com/sejin8642/C/tree/main/exercises/5.13.c | https://raw.githubusercontent.com/sejin8642/C/c8d3cae/exercises/5.13.c | sejin8642/C c8d3cae exercises/5.13.c | true | 200 | 1,910 | #include <stdio.h>
#include <string.h>
#include <stdlib.h> // for atoi
#define MAXLINES 5000 /* max #lines to be sorted */
#define MAXLEN 1000 /* max length of any input line */
char *lineptr[MAXLINES]; /* pointers to text lines */
int readlines(char *lineptr[], int nlines, char *allocp);
void writelines(char *lineptr... | 3 |
moraamoseti2/alx-low_level_programming | 158405d | 0x09-static_libraries/_putchar.c | C | www.github.com/moraamoseti2/alx-low_level_programming/tree/main/0x09-static_libraries/_putchar.c | https://raw.githubusercontent.com/moraamoseti2/alx-low_level_programming/158405d/0x09-static_libraries/_putchar.c | moraamoseti2/alx-low_level_programming 158405d 0x09-static_libraries/_putchar.c | true | 200 | 241 | #include <unistd.h>
/**
* _putchar - writes the character c to stdout
* @c : the character to print
*
* return : 1 success
* on error -1 is returned, and errno is set appropriately
*/
int _putchar(char c)
{
return (write(1, &c, 1));
}
| 7 |
Cinkut/Cegielnia | 8048d87 | Funkcje/FunkcjeSemafory.c | C | www.github.com/Cinkut/Cegielnia/tree/main/Funkcje/FunkcjeSemafory.c | https://raw.githubusercontent.com/Cinkut/Cegielnia/8048d87/Funkcje/FunkcjeSemafory.c | Cinkut/Cegielnia 8048d87 Funkcje/FunkcjeSemafory.c | true | 200 | 1,481 | #include "FunkcjeSemafory.h"
int create_semafor(const char *path, int identifier, int semafor_amount, int flags)
{
key_t key = ftok(path, identifier);
if ( key == - 1)
{
perror("Ftok failed");
exit(1);
}
int sem_id = semget(key, semafor_amount, flags);
if (sem_id == -1)
{
... | 0 |
AntoineA67/cub3d | 0d9b954 | bonus/src/parsing/l_pts_bonus.c | C | www.github.com/AntoineA67/cub3d/tree/main/bonus/src/parsing/l_pts_bonus.c | https://raw.githubusercontent.com/AntoineA67/cub3d/0d9b954/bonus/src/parsing/l_pts_bonus.c | AntoineA67/cub3d 0d9b954 bonus/src/parsing/l_pts_bonus.c | true | 200 | 1,746 | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* fill_l_pts.c :+: :+: :+: ... | 4 |
djfergus/df_dactyl | 8a45c28 | keymaps/linux_and_mac/macros.c | C | www.github.com/djfergus/df_dactyl/tree/main/keymaps/linux_and_mac/macros.c | https://raw.githubusercontent.com/djfergus/df_dactyl/8a45c28/keymaps/linux_and_mac/macros.c | djfergus/df_dactyl 8a45c28 keymaps/linux_and_mac/macros.c | true | 200 | 6,158 | #include "sharedDefines.h"
bool use_bunnyhop = false;
bool enable_bunnyhop = false;
bool combos_on = true; // use combo feature by default
bool mac_mode = false;
bool colemak_mode = false;
uint32_t rgb_timeout_counter = 0;
uint16_t unlock_password_index = 0;
bool password_bypass = false;
bool dynamic_macro_recordin... | 5 |
Eman288/monty | 24ac11a | is_push.c | C | www.github.com/Eman288/monty/tree/main/is_push.c | https://raw.githubusercontent.com/Eman288/monty/24ac11a/is_push.c | Eman288/monty 24ac11a is_push.c | true | 200 | 829 | #include "monty.h"
/**
*is_push - a function to check if the element is an integer or not and push it
*@head: the header of the stack
*@line_num: the line we are currenlty in
*/
void is_push(stack_t **head, unsigned int line_num)
{
int i, value, j;
j = 0;
if (d.values)
{
i = 0;
if (d.values[0] == '-')
i =... | 2 |
Torycd/alx-low_level_programming | 188d9b6 | 0x0C-more_malloc_free/2-calloc.c | C | www.github.com/Torycd/alx-low_level_programming/tree/main/0x0C-more_malloc_free/2-calloc.c | https://raw.githubusercontent.com/Torycd/alx-low_level_programming/188d9b6/0x0C-more_malloc_free/2-calloc.c | Torycd/alx-low_level_programming 188d9b6 0x0C-more_malloc_free/2-calloc.c | true | 200 | 521 | #include "main.h"
#include <stdlib.h>
/**
* _calloc - A function that allocates memory for an array using malloc
* @nmemb: number of memory spaces
* @size: size of nmemb
* Return: return pointer to alloctaed space, or NULL on failure
*/
void *_calloc(unsigned int nmemb, unsigned int size)
{
unsigned int i = 0;
... | 6 |
LeandroTRibeiro/From_Beginnings_to_C_Exploration | b9b342c | Vetores e Matrizes/ex4.c | C | www.github.com/LeandroTRibeiro/From_Beginnings_to_C_Exploration/tree/main/Vetores e Matrizes/ex4.c | https://raw.githubusercontent.com/LeandroTRibeiro/From_Beginnings_to_C_Exploration/b9b342c/Vetores%20e%20Matrizes/ex4.c | LeandroTRibeiro/From_Beginnings_to_C_Exploration b9b342c Vetores e Matrizes/ex4.c | true | 200 | 635 | /*
4) Escreva um programa que lê um vetor de dimensão n e imprime o índice do
maior elemento daquele vetor.
*/
#include <stdio.h>
int main() {
int array[100];
int arrayLength;
int largerIndex;
printf("\nDigite o tamanho do vetor: ");
scanf(" %d", &arrayLength);
for(int i = 0; i < arrayLength... | 1 |
Ruthyramani/binary_trees | dc77900 | 4-binary_tree_is_leaf.c | C | www.github.com/Ruthyramani/binary_trees/tree/main/4-binary_tree_is_leaf.c | https://raw.githubusercontent.com/Ruthyramani/binary_trees/dc77900/4-binary_tree_is_leaf.c | Ruthyramani/binary_trees dc77900 4-binary_tree_is_leaf.c | true | 200 | 354 | #include "binary_trees.h"
/**
* binary_tree_is_leaf - Checks if a node is a leaf.
*
* @node: A pointer to the node to check.
*
* Return: 1 if the node is a leaf, otherwise 0.
*
*/
int binary_tree_is_leaf(const binary_tree_t *node)
{
if (node == NULL)
return (0);
if (node->left == NULL && node->right == NU... | 7 |
remyCases/CFR_simultaneous | 156ec12 | main.c | C | www.github.com/remyCases/CFR_simultaneous/tree/main/main.c | https://raw.githubusercontent.com/remyCases/CFR_simultaneous/156ec12/main.c | remyCases/CFR_simultaneous 156ec12 main.c | true | 200 | 4,860 | #include <stdlib.h>
#include <stdio.h>
#include <stdint.h>
#include <string.h>
#include "./include/xorshiro256.h"
#include "./include/player.h"
#include "./include/utility.h"
#include "./include/combinatory.h"
typedef enum RPS {
ROCK,
PAPER,
SCISSOR,
NUMBER_CASES,
} RPS;
static uint16_t number_battlef... | 3 |
Mamaropeng/alx-low_level_programming | 4cabd86 | 0x06-pointers_arrays_strings/0-strcat.c | C | www.github.com/Mamaropeng/alx-low_level_programming/tree/main/0x06-pointers_arrays_strings/0-strcat.c | https://raw.githubusercontent.com/Mamaropeng/alx-low_level_programming/4cabd86/0x06-pointers_arrays_strings/0-strcat.c | Mamaropeng/alx-low_level_programming 4cabd86 0x06-pointers_arrays_strings/0-strcat.c | true | 200 | 410 | #include "main.h"
#include <stdio.h>
/**
* _strcat - concatenates two strings
* @dest: The destination string
* @src: The source of string
* Return: A pointer to the resulting string dest.
*
*/
char *_strcat(char *dest, char *src)
{
int a;
int b;
a = 0;
while (dest[a] != '\0')
{
a++;
}
b = 0;
while (s... | 4 |
wnswo8628/42Seoul | 6ab73c7 | minishell/utils2.c | C | www.github.com/wnswo8628/42Seoul/tree/main/minishell/utils2.c | https://raw.githubusercontent.com/wnswo8628/42Seoul/6ab73c7/minishell/utils2.c | wnswo8628/42Seoul 6ab73c7 minishell/utils2.c | true | 200 | 1,787 | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* utils2.c :+: :+: :+: ... | 0 |
mustafaylmz1995/LinkedLists | 4108f66 | CLL_insert2headlast_delete2headlast.c | C | www.github.com/mustafaylmz1995/LinkedLists/tree/main/CLL_insert2headlast_delete2headlast.c | https://raw.githubusercontent.com/mustafaylmz1995/LinkedLists/4108f66/CLL_insert2headlast_delete2headlast.c | mustafaylmz1995/LinkedLists 4108f66 CLL_insert2headlast_delete2headlast.c | true | 200 | 4,155 | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <malloc.h>
typedef struct NODE{
struct NODE *next;
int data;
}node;
node *createCLL(node *head){
// bir tane head üret ve doldur
head = (node *)malloc(sizeof(node));
head->data = 0;
head->next = NULL;
//bir adet geçici ptr üret ve head'e eşitl... | 5 |
LenonGP/aulasC | 14f9238 | matriz/main.c | C | www.github.com/LenonGP/aulasC/tree/main/matriz/main.c | https://raw.githubusercontent.com/LenonGP/aulasC/14f9238/matriz/main.c | LenonGP/aulasC 14f9238 matriz/main.c | true | 200 | 346 | #include <stdio.h>
#include <stdlib.h>
int main()
{
int matriz [3][3] = {{1, 2, 3},
{4, 5, 678},
{8, 9, 0}};
int casas = 5;
for(int i=0; i<3; i++){
for(int j=0; j<3; j++){
printf("%*d",casas, matriz[i][j]);
}
printf("\n");... | 6 |
codeph112/lvgl-test-project | 2b2d27a | src/display/dsi/dsi_layer.c | C | www.github.com/codeph112/lvgl-test-project/tree/main/src/display/dsi/dsi_layer.c | https://raw.githubusercontent.com/codeph112/lvgl-test-project/2b2d27a/src/display/dsi/dsi_layer.c | codeph112/lvgl-test-project 2b2d27a src/display/dsi/dsi_layer.c | true | 200 | 3,918 | #include "thread_disp.h"
#include "r_ioport.h"
#include "r_mipi_dsi_api.h"
#include "hal_data.h"
#include "dsi_layer.h"
void mipi_dsi0_callback(mipi_dsi_callback_args_t * p_args);
static fsp_err_t dsi_layer_set_peripheral_max_return_msg_size(void);
static volatile bool g_message_sent = false;
fsp_err_t dsi_layer_con... | 3 |
karakazeviewview/my_minishell | 7369519 | srcs/terminal/terminal.c | C | www.github.com/karakazeviewview/my_minishell/tree/main/srcs/terminal/terminal.c | https://raw.githubusercontent.com/karakazeviewview/my_minishell/7369519/srcs/terminal/terminal.c | karakazeviewview/my_minishell 7369519 srcs/terminal/terminal.c | true | 200 | 2,273 |
/*
* @file terminal.c
* @brief コマンド入力の待機状態。
* @date 2023-01-01
*/
#include "terminal.h"
#include "constant.h"
#include "parser.h"
#include "expansion.h"
#include "execution.h"
#include <readline/readline.h>
#include <readline/history.h>
/** 最後のコマンドの終了ステータスを保持する */
int g_status = 0;
static void delete_token(void... | 2 |
hpi23/c-projects | dde0868 | json-parser/json.h | C | www.github.com/hpi23/c-projects/tree/main/json-parser/json.h | https://raw.githubusercontent.com/hpi23/c-projects/dde0868/json-parser/json.h | hpi23/c-projects dde0868 json-parser/json.h | true | 200 | 697 | #pragma once
#include "../hashmap/map.h"
#include "../list/list.h"
#include "./lexer.h"
#include "./token.h"
#include <stdint.h>
typedef enum {
JSON_TYPE_OBJECT,
JSON_TYPE_ARRAY,
JSON_TYPE_INT,
JSON_TYPE_FLOAT,
JSON_TYPE_BOOL,
JSON_TYPE_NULL,
JSON_TYPE_STRING,
} JsonType;
typedef struct {
HashMap * fi... | 7 |
Satifi2/nkuics | d386344 | nemu/src/mytest/function_test.c | C | www.github.com/Satifi2/nkuics/tree/main/nemu/src/mytest/function_test.c | https://raw.githubusercontent.com/Satifi2/nkuics/d386344/nemu/src/mytest/function_test.c | Satifi2/nkuics d386344 nemu/src/mytest/function_test.c | true | 200 | 3,223 | #include <stdio.h>
#include <string.h>
union Data {
int i;
float f;
char str[20];
};
void testunion() {
union Data data;
data.i = 10;
printf("data.i: %d\n", data.i);
data.f = 220.5;
printf("data.f:%f\n", data.f);
strcpy(data.str, "Test Union");
printf("data.s:%s\n... | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.