source
string
code_lang
string
content
string
idx
int64
the-stack-v2-dedup
C
/* * *@Copyright (C) 2010-2020 贵阳高新网用软件有限公司 *@date : 2020-09-03 *@author : 杨文 *@brief : CtImHdmi *@rely : klib.h *@function : 按ETK规范抄写索喜源代码 *@version : 1.0.0 能正常上屏显示图像 * */ #ifndef __CT_IM_HDMI_H__ #define __CT_IM_HDMI_H__ #include <stdlib.h> #include <string.h> // #include "ct_im_hdmi.h" #include "jdsdisp3a.h" #in...
1,330,100
the-stack-v2-dedup
C
#include <stdlib.h> #include <stdio.h> #include <string.h> #include "semantic_support.h" #include "types.h" #include "semantic.h" #include "support.h" // prints a node that is associated with its integer type void printNodeType(TreeNode* node) { char* type; switch(node->kind) { case progNormal: type = "p...
1,330,101
the-stack-v2-dedup
C
/* Copyright (c) 2014, Nils Schneider <nils@nilsschneider.net> 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, ...
1,330,102
the-stack-v2-dedup
C
#ifndef RCC_BITS_H #define RCC_BITS_H /******************** Bit definition for RCC_CR register ********************/ #define RCC_CR_HSION ((uint32_t)0x00000001) /*!< Internal High Speed clock enable */ #define RCC_CR_HSIRDY ((uint32_t)0x00000002) /*!< Inter...
1,330,103
the-stack-v2-dedup
C
/* * Copyright (c) 2005, Daniel C. Newman <dan.newman@mtbaldy.us> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * + Redistributions of source code must retain the above co...
1,330,104
the-stack-v2-dedup
C
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* ft_strsub.c :+: :+: :+: ...
1,330,105
the-stack-v2-dedup
C
#include <ljit/elf/elf-write.h> static void _ljit_write_elf_sections(ljit_elf *elf, int fd) { ljit_elf_section *tmp = elf->section; if (!tmp) return; /* Write data associated with every sections */ while (tmp) { write(fd, tmp->data, tmp->header->sh_size); tmp = tmp->next; ...
1,330,106
the-stack-v2-dedup
C
// https://youtu.be/_Lf1looyJMU // https://www.geeksforgeeks.org/maximum-size-sub-matrix-with-all-1s-in-a-binary-matrix/ /* Given a binary matrix, find out the maximum size square sub-matrix with all 1s. 0, 1, 1, 0, 1}, 1, 1, 0, 1, 0}, {0, 1, 1, 1, 0}, <----- {1, 1, 1, 1, 0}, {1, 1, 1, 1, 1}, <----- {0, 0, 0, 0, 0} ...
1,330,107
the-stack-v2-dedup
C
#pragma once #include <stdint.h> #include <assert.h> #include <exception> #include "codegen/il2cpp-codegen.h" // <PrivateImplementationDetails>/$ArrayType$48 struct U24ArrayTypeU2448_t2396; struct U24ArrayTypeU2448_t2396_marshaled; void U24ArrayTypeU2448_t2396_marshal(const U24ArrayTypeU2448_t2396& unmarshaled, U24A...
1,330,108
the-stack-v2-dedup
C
#ifndef __Encoder_H #define __Encoder_H #include "main.h" void Quad_Encoder_Config(void); void Encoder_Start(void); int32_t GetQuadEncoderDiff(void); #endif
1,330,109
the-stack-v2-dedup
C
#include <msp430.h> #include "my_main.h" void wdtimer_nmi(void){ WDTCTL = WDTPW+WDTHOLD+WDTNMI+WDTNMIES ; IE1 |= NMIIE; } void Smclk_ (char Mhz){ DCOCTL = 0; switch(Mhz){ case 1: BCSCTL1 = CALBC1_1MHZ; DCOCTL = CALDCO_1MHZ; SMCLK_=1000000; case 8: BCSCTL1 = CALBC1_8MHZ; DCOCTL = CALDCO_8MHZ; SMCLK_=8...
1,330,110
the-stack-v2-dedup
C
#include<stdio.h> int main() { int sayi; int i; int rakam; int temp; int top=0; printf("Bir sayi giriniz:"); scanf("%d", &sayi); printf("\n"); for(i=11;i<sayi;i++) { top=0; if(i%7==0 | i%12==0) { printf("%d: \t",i); temp=i; while(temp!=0) { rakam=temp%10; printf("%d",rakam); ...
1,330,111
the-stack-v2-dedup
C
#include <stdio.h> #define numsSize 5 int main() { int x, i, j, a, b = 0; int sqrtArr[numsSize]; int nums[5] = {-4,-1,0,3,10}; //input //fills in sqrtArr for(i=0; i < numsSize; i++){ x = nums[i]; x = (x * x); sqrtArr[i] = x; } //tady uz je pole aqr...
1,330,112
the-stack-v2-dedup
C
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* main.c :+: :+: :+: ...
1,330,113
the-stack-v2-dedup
C
#include<stdio.h> #include<windows.h> #include<conio.h> #include<ctype.h> #include<string.h> #include<stdlib.h> //Function Declaration void WelcomeScreen(void); void Title(void); void Password(void); void ActorMenu(void); void UserMenu(void); void Register(void); void TestReport(void); void BedAdmit(v...
1,330,114
the-stack-v2-dedup
C
#include "phase1Int.h" #include "usloss.h" #include <stdlib.h> #include <assert.h> #include <stdio.h> #include <string.h> extern USLOSS_PTE *P3_AllocatePageTable(int cid); extern void P3_FreePageTable(int cid); // static void illegalMessage(int n,void *arg); typedef struct Context { void ...
1,330,115
the-stack-v2-dedup
C
/***************************************************************************/ /* */ /* ahangles.h */ /* */ /* ...
1,330,116
the-stack-v2-dedup
C
int main() { char c[500]; int len, n, i, j, k, l=0, m, cd[500], ld, max=0; scanf("%d", &n); scanf("%s", c); len = strlen(c); for(i=0; i<500; i++) cd[i] = 1; for(i=0; i<len-n; i++) { for(j=i+1; j<len-n+1; j++) { ld = 0; ...
1,330,117
the-stack-v2-dedup
C
#ifndef _VIEW_GRAPH_H_ #define _VIEW_GRAPH_H_ #include <glib-object.h> #include <gtk/gtk.h> G_BEGIN_DECLS #define VIEW_TYPE_GRAPH (view_graph_get_type()) #define VIEW_GRAPH(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), VIEW_TYPE_GRAPH, ViewGraph)) #define VIEW_GRAPH_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), VIEW_TYPE...
1,330,118
the-stack-v2-dedup
C
// killer.c #include <ansi.h> int update_condition(object me, int duration) { object env; env = environment(me); if( duration < 1) return 0; me->apply_condition("killer", duration - 1); if(duration == 1){ CHANNEL_D->do_channel(find_object(MASTER_OB),"rumor",sprintf("听说官府已经放弃追捕%s了!",me->name())); } else { ...
1,330,119
the-stack-v2-dedup
C
#include <stdio.h> #include "mpi.h" #define N 1024*1024 int main (int argc, char *argv[]) { int rank, size, color, sum=0, localsum=0, i, chunk; int arr[N], recv_arr[N], partialsum[N]; MPI_Status status; int newrank, newsize; MPI_Comm newcomm; MPI_Init (&argc, &argv); MPI_Comm_rank (MPI_COMM_WORLD, &ran...
1,330,120
the-stack-v2-dedup
C
#pragma once #include <stdint.h> #include <assert.h> #include <exception> #include "codegen/il2cpp-codegen.h" struct t224; struct t394; struct t386; struct t385; struct t47; struct t171; struct t7; struct t222; struct t668; struct t669; struct t569; struct t570; struct t225; #include "t219.h" #include "t157.h" #inclu...
1,330,121
the-stack-v2-dedup
C
/* Copyright 1999 American Power Conversion, All Rights Reserved * * Description: * The file defines the interface to the EventLogger. The * EventLogger is reponsible for logging information to the * NT machine's System Event Log. * * * Revision History: * sberard 29Mar1999 initial revis...
1,330,122
the-stack-v2-dedup
C
#ifndef __OS3_ERR_H__ #define __OS3_ERR_H__ #ifdef __cplusplus extern "C" { #endif #ifdef __l4env__ /* l4env includes */ #include <l4/env/errno.h> #endif char const *l4os3_errtostr(long err); #ifdef __cplusplus } #endif #endif
1,330,123
the-stack-v2-dedup
C
#ifndef __CONSTANTES_H #define __CONSTANTES_H #define MAIN 500 #define BEGIN_BLOCK 501 #define END_BLOCK 502 #define SEMICOLON 503 #define COMMA 504 #define LEFT_PARENTHE 505 #define RIGHT_PARENTHE 506 #define ASSIGNMENT 507 #define IF 508 #define ELSE 509 #define WHILE 510 #define SWITCH 511 #define CA...
1,330,124
the-stack-v2-dedup
C
/* Copyright 2014 The ChromiumOS Authors * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ /* NPCX-specific ADC module for Chrome EC */ #include "adc.h" #include "atomic.h" #include "clock.h" #include "clock_chip.h" #include "common.h" #include "console.h" #in...
1,330,125
the-stack-v2-dedup
C
#pragma once // Generated by build script, do not edit! #define UNITY_VERSION "2020.1.0f1" #define UNITY_VERSION_DIGITS "2020.1.0" #define UNITY_VERSION_SUFFIX "f1" #define UNITY_VERSION_VER 2020 #define UNITY_VERSION_MAJ 1 #define UNITY_VERSION_MIN 0 #define UNITY_IS_BETA 0
1,330,126
the-stack-v2-dedup
C
// EMPLOYEE DETAILS USING STRUCTURE #include<stdio.h> struct employee { int id; char name[20]; float salary; int age; }; int main() { struct employee e1; /*declare structure variable*/ int i,n; /*read employee details*/ printf("\nEnter details :\n"); printf("Name ?: "); gets(e1.name); p...
1,330,127
the-stack-v2-dedup
C
#ifndef NVIM_POS_H #define NVIM_POS_H typedef long linenr_T; // line number type /// Column number type typedef int colnr_T; /// Format used to print values which have colnr_T type #define PRIdCOLNR "d" #define MAXLNUM 0x7fffffff // maximum (invalid) line number #define MAXCOL 0x7fffffff // maximum ...
1,330,128
the-stack-v2-dedup
C
/* ** JAM(mbp) - The Joaquim-Andrew-Mats Message Base Proposal ** ** C API ** ** Written by Joaquim Homrighausen. ** ** ---------------------------------------------------------------------- ** ** jamfetch.c (JAMmb) ** ** Fetch messages and texts ** ** Copyright 1993 Joaquim Homrighausen, Andrew Milner, Mats Bir...
1,330,129
the-stack-v2-dedup
C
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* ft_printf_x.c :+: :+: :+: ...
1,330,130
the-stack-v2-dedup
C
// // Created by dtend on 02.04.2019. // #ifndef ASD_L1_UNIFIEDFUNCTIONS_H #define ASD_L1_UNIFIEDFUNCTIONS_H int testSorted( int keys[],int n, int asc); void swap(int *newMin, int *oldFirst); void printArray(int keys[], int n); #endif //ASD_L1_UNIFIEDFUNCTIONS_H
1,330,131
the-stack-v2-dedup
C
/* * Recursive procedures call themselves to work towards a solution to a problem. In simple implementations this balloons the stack as the nesting gets deeper and deeper, reaches the solution, then returns through all of the stack frames. This waste is a common complaint about recursive programming in general.A funct...
1,330,132
the-stack-v2-dedup
C
#include <string.h> #include "ztring.h" const size_t ZTR_HEADER_SIZE = sizeof(struct ztr_header); char *ztr_new(const char *input) { if (!input) { return NULL; } const size_t length = strlen(input); return ztr_new_length(input, length); } char *ztr_new_length(const char *input, size_t leng...
1,330,133
the-stack-v2-dedup
C
/****************************************************************************** * Copyright (c) 2018 Texas Instruments Incorporated - http://www.ti.com * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * ...
1,330,134
the-stack-v2-dedup
C
#pragma once extern void * operator new(size_t size); extern void operator delete(void * p); extern void operator delete[](void * p);
1,330,135
the-stack-v2-dedup
C
/* * Copyright (c) 2008 The Regents of the University of California. * All rights reserved." * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * - Redistributions of source code must retain the above copyrigh...
1,330,136
the-stack-v2-dedup
C
// Ryan O'Halloran - CSE 20311 // Lab 4 // primes.c #include <stdio.h> #include <math.h> int array_ones(int, int array[]); int array_primer(int, int array[]); void array_printer(int, int, int array[]); int main() { // declare number of elements in array, number of columns in array, and array itself int numEl...
1,330,137
the-stack-v2-dedup
C
/* Copyright © 2013, Owen Shepherd * * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice appear in all copies. * * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH *...
1,330,138
the-stack-v2-dedup
C
#ifndef UXDISP_HW_H_ #define UXDISP_HW_H_ #define UXDISP_XTRA_CAPS_PV_VBLANK 0x1 #define UXDISP_XTRA_CAPS_USER_DRAW 0x2 #define UXDISP_XTRA_CTRL_PV_VBLANK_ENABLE 0x1 #define UXDISP_XTRA_CTRL_USER_DRAW_ENABLE 0x2 #define UXDISP_REG_MAGIC 0x00000 #define UXDISP_MAGIC ...
1,330,139
the-stack-v2-dedup
C
#include "TLorentzVector.h" #include "TRandom.h" #include "TF1.h" #include "TH1.h" #include "TH2.h" #include "TFile.h" #include <iostream> #include "charm_decay.h" Double_t powerlaw(Double_t *x, Double_t *par) { double pT = x[0]; double dNdy = par[0]; double meanPt = par[1]; double n = par[2]; double p0 = me...
1,330,140
the-stack-v2-dedup
C
/* Copyright (C) 2020 MIPI Alliance */ /* SPDX-License-Identifier: BSD-3-Clause */ /* Copyright (C) 2019--2020 Intel Corporation */ #ifndef __CCS_DATA_H__ #define __CCS_DATA_H__ #include "ccs-os.h" struct ccs_data_block_version { uint16_t version_major; uint16_t version_minor; uint16_t date_year; uint8_t date_mo...
1,330,141
the-stack-v2-dedup
C
#include <stdio.h> int main() { int price = 0; int money = 0; printf("请输入金额(元)\n"); printf("请输入总额(元)\n"); scanf("%d",&price); scanf("%d",&money); int change = money - price; printf("找您%d\n",change); return 0; }
1,330,142
the-stack-v2-dedup
C
#include <stdio.h> #include <cs50.h> int main(void) { int h; do { printf("height "); h = GetInt(); } while (h < 0 || h > 23); for (int l = 0; l < h; l++) { for (int s = h - l; s > 1; s--) { printf(" "); } for (int hash = 0; h...
1,330,143
the-stack-v2-dedup
C
#include <stdio.h> #include <stdlib.h> #include "binaryTreeLib.h" int** levelOrderBottom(struct TreeNode* root, int** columnSizes, int* returnSize) { return 0; } int main(int argc, char const *argv[]) { struct TreeNode* test = buildSampleBST(1); printTree(test); return 0; }
1,330,144
the-stack-v2-dedup
C
//Bryce Egley and Bruce Garcia //CS 444 //Concurrency exercise 1: Producer-Consumer Problem #include <stdio.h> #include <string.h> #include <pthread.h> #include <time.h> #include <signal.h> #include <stdlib.h> #include <unistd.h> #include "mt19937ar.c" #include <assert.h> #define maxSize 32 //Buffer can hol...
1,330,145
the-stack-v2-dedup
C
//WAP to revarse the Array using fn #include<stdio.h> #include<conio.h> void main() { int x[10] , i ; void reverse(int * , int ); clrscr(); printf("\n enter array x :"); for ( i=0 ; i<10 ; i++ ) scanf( "%d" ,&x[i] ); reverse(x,10); printf("\n reverse array x :"); for (...
1,330,146
the-stack-v2-dedup
C
/*------------------------------------------------------------------------------ KEY_TEST_KEYS.H ------------------------------------------------------------------------------*/ #include "../../main.h" #include "../keyboard.h" #include "../../display/display.h" #include "inc/hw_gpio.h" #include "inc/hw_m...
1,330,147
the-stack-v2-dedup
C
/* ************************************************************************** */ /* LE - / */ /* / */ /* cw_sdl_events.c .:: .:/ . .:: ...
1,330,148
the-stack-v2-dedup
C
// mrp_fsm_application.h typedef enum enumMrpStateAppl{ MRP_STATE_APPL_VO, MRP_STATE_APPL_VP, MRP_STATE_APPL_VN, MRP_STATE_APPL_AN, MRP_STATE_APPL_AA, MRP_STATE_APPL_QA, MRP_STATE_APPL_LA, MRP_STATE_APPL_AO, MRP_STATE_APPL_QO, MRP_STATE_APPL_AP, MRP_STATE_APPL...
1,330,149
the-stack-v2-dedup
C
/* * This source file obviously only exists to provide a spot * for the stb_typetype implementation to exist. */ #define STB_TRUETYPE_IMPLEMENTATION #include "stb_truetype.h"
1,330,150
the-stack-v2-dedup
C
#include<stdio.h> int fac(int i); int main() { int n,f; printf("enter num n:="); scanf("%d",&n); f=fac(n); printf("f=%d",f); return 0; } int fac(int i) { int j=1; if(i==1) return(1); j=i*fac(i-1); return(j); }
1,330,151
the-stack-v2-dedup
C
#include<stdio.h> #include<stdlib.h> #include<string.h> #include<time.h> #include<math.h> #include "pengda.h" int main(int argc, char *argv[]) { if (argc == 1) { printf("Generating random instances...\n"); printf("Enter the circuit board size MAX_X MAX_Y:"); scanf("%d %d"...
1,330,152
the-stack-v2-dedup
C
#include <string.h> #include "my_strlen.h" size_t my_strlen(char const *s) { return strlen(s); }
1,330,153
the-stack-v2-dedup
C
int rpmValue = 0; float vMapRPM = 0; void drill_init (void){ current=0; topCount = 65; //for 120Hz min Nyquist rate for a 60Hz signal OCR2A = topCount; //Top value for this button OCR2B = 0; //Ontime of the 65Hz signal Initialized to zero TCCR2B |= (1<<CS21); //Pre-scale = 8 16M/(8*256) ...
1,330,154
the-stack-v2-dedup
C
#include "mySearch.h" int binarySearch(const int* block, int front, int rear, int value) { //데이터가 정렬 되어있다는 가정 하에 사용되는 검색 알고리즘 if (front > rear || rear < 0) return -1; int mid = (front + rear) >> 1; int cmp = IntegerCmp(block[mid], value); if (cmp == 1) binarySearch(block, mid + 1, rear, value); else if (cmp == ...
1,330,155
the-stack-v2-dedup
C
#include <config.h> #include "mkancesdirs.h" #include <sys/types.h> #include <sys/stat.h> #include <fcntl.h> #include <errno.h> #include <unistd.h> #include "dirname.h" #include "savewd.h"
1,330,156
the-stack-v2-dedup
C
/**************************************************************************** * DroneID main state machine * Copyright (c) 2015, Martin Skriver <MaSkr@mmmi.sdu.dk> & <MaSkr09@gmail.com> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided t...
1,330,157
the-stack-v2-dedup
C
#ifndef HEADER__RESPONSE #define HEADER__RESPONSE #include "request.h" #include "header.h" #include "utils.h" struct http_response_t { int protocol; int status_code; int timestamp; // Headers struct http_header_t headers[MAX_HTTP_HEADER_COUNT]; int header_count; // Body char *body; ...
1,330,158
the-stack-v2-dedup
C
// Based on USB Debug Channel Example from http://www.pjrc.com/teensy/ // All of the avr usb stuff is rather tiresome // I think a better approach would be to use auto code generation for this #include <avr/interrupt.h> #include <avr/io.h> #include "usb_core.h" // Misc functions to wait for ready and send/receive pa...
1,330,159
the-stack-v2-dedup
C
/***************************************************************** * initialise_drivers.c * * Created: 4/27/2019 3:56:25 PM * * Author : Nick Morris * * s44373388 - Team 8 - METR4810 ...
1,330,160
the-stack-v2-dedup
C
/* * main.c * * Created on: 22 нояб. 2018 г. * Author: maxx */ /* * (19)OK (v1.0) Port from W5500_EVB(NXP LPc13xx + W5500) to AtMega1284p+W5500 BLYNK IOT app (look: https://blynk.io/) * TODO: * OK (v1.2) Add DNS resolve before BLYNK app running to <blynk-cloud.com> * OK (v1.1) Add LED_ON/LED_...
1,330,161
the-stack-v2-dedup
C
/* edit:Lilac */ #include<stdio.h> #include<pcap.h> void analysis(const u_char * string){ int Protocol; Protocol = string[23]; if (Protocol == 6) printf("TCP : "); else if(Protocol == 17) printf("UDP : "); else printf("I don't kno...
1,330,162
the-stack-v2-dedup
C
/** * @file zbspac.c * @brief PAC resource file extractor / packager for Baldr Sky & Force EXE. * This is the command line user interface module. * @copyright Covered by 2-clause BSD, please refer to license.txt. * @author CloudiDust * @date 2010.02 * @warning This utility is specially designed for the ...
1,330,163
the-stack-v2-dedup
C
/* * * Panda Theme * * * */ static const char *colorname[] = { "#292a2b", /* base00 */ "#ec2864", /* base08 */ "#35ffdc", /* base0B */ "#ffb86c", /* base0A */ "#7dc1ff", /* base0D */ "#b084eb", /* base0E */ "#ff90d0", /* base0C */ "#ffffff", /* base05 */ "#1e1e1e", /* base03 */ "#df984c", /* base0...
1,330,164
the-stack-v2-dedup
C
// Copyright (c) 1996-1999 Microsoft Corporation #include <windows.h> #include <windowsx.h> #include <stdio.h> #include "misc.h"
1,330,165
the-stack-v2-dedup
C
#include <stdio.h> #include <math.h> /* VIVEK RAJ; 1601CS49 31/01/2017*/ //PROGRAM TO FIND ALL THE PERFECT SQUARES IN A GIVEN RANGE int main() { int no1,no2,i,count,j,phantom=0; //declaration of variables used double sqroot,k=0; //declaration of variables used char inch; ...
1,330,166
the-stack-v2-dedup
C
/* Copyright © 1999 International Securities Exchange LLC ("ISE"). All Rights Reserved. USE OF THIS SOFTWARE IS SUBJECT TO THE TERMS AND CONDITIONS OF THE LICENSE GRANTED TO THE RECIPIENT UNDER THE "DEVELOPERS AGREEMENT". REDISTRIBUTION OF THIS SOFTWARE IS PROHIBITED. THIS SOFTWARE IS PROVIDED "AS IS", WITHOUT A WARR...
1,330,167
the-stack-v2-dedup
C
// This file tests for an specific endless recursion in the filter implementations w.r.t. following store targets // RUN: %c-to-llvm -fno-discard-value-names %s | %opt -O3 -S \ // RUN: | %apply-typeart -typeart-stack -typeart-call-filter -S 2>&1 \ // RUN: | %filecheck %s --check-prefix=CHECK-exp-default-opt // CHECK-e...
1,330,168
the-stack-v2-dedup
C
#include <hre/config.h> #include <float.h> #include <limits.h> #include <math.h> #include <signal.h> #include <stdlib.h> #include <time.h> #include <dm/dm.h> #include <hre/user.h> #include <util-lib/util.h> #include <ltsmin-lib/ltsmin-standard.h> #ifdef DMDEBUG #define DMDBG(x) x #else #define DMDBG(x) #endif void...
1,330,169
the-stack-v2-dedup
C
#define NULL ((void*)0) typedef unsigned long size_t; // Customize by platform. typedef long intptr_t; typedef unsigned long uintptr_t; typedef long scalar_t__; // Either arithmetic or pointer type. /* By default, we understand bool (as a convenience). */ typedef int bool; #define false 0 #define true 1 /* Forward d...
1,330,170
the-stack-v2-dedup
C
#include<stdio.h> #include<string.h> void encrypt(char[],char[]); void decrypt(char[],char[]); int main() { char pt[50],k[50]; int n; printf("\nEnter plain text:"); gets(pt); printf("\nEnter key:"); gets(k); encrypt(pt,k); return 0; } void encrypt(char pt[],char k[]) { int l1=strlen(pt); int l2=strlen(k); ch...
1,330,171
the-stack-v2-dedup
C
#ifndef __LIB_NUMERICS_H__ #define __LIB_NUMERICS_H__ #include <stdint.h> #define LLONG_MAX_LEN 19 #if defined __MINGW32__ #define PRId64 "I64d" #define PRLD "f" #define PRLDType double #define SCLD PRLD #elif defined __GNUC__ #include <inttypes.h> #define PRLD "Lf" #define PRLDType lo...
1,330,172
the-stack-v2-dedup
C
//Based on BWAPI's BW/CBullet.h #pragma once #include "Position.h" #pragma pack(1) struct CSprite; struct CImage { CImage *previous; CImage *next; u16 id; u8 paletteType; //++Drawing function (values are the same as DataEdit) // off...
1,330,173
the-stack-v2-dedup
C
#pragma once #include "MatrixClass.h"
1,330,174
the-stack-v2-dedup
C
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* ft_swap.c :+: :+: :+: ...
1,330,175
the-stack-v2-dedup
C
#include "mpool.h" #include "mstat.h" void mpool_stat_get_nodes(const mpool_t *mpool, size_t *avail, size_t *used) { const blkhead_t *phead; const blknode_t *pnode; size_t i; *avail = 0; *used = 0; for (i = 0; i < mpool->nblocks; i++) { phead = &mpool->blktable[i]; LIST_FOREACH...
1,330,176
the-stack-v2-dedup
C
#include <pebble.h> static Window *window; static TextLayer *bt_callback_layer; static TextLayer *bt_peek_layer; void bluetooth_callback(bool connected) { static char str[] = "CB: false"; if (connected) { snprintf(str, sizeof(str), "CB: true"); } text_layer_set_text(bt_callback_layer, str); } void update_peek...
1,330,177
the-stack-v2-dedup
C
#include <stdio.h> #include <string.h> int main(int argc, char const *argv[]) { char name[10][8], tname[10][8], temp[8]; int i, j, n; printf("Enter the value of n \n"); scanf("%d", &n); printf("Enter %d names n \n", n); for (i = 0; i < n; i++) ...
1,330,178
the-stack-v2-dedup
C
// // float.c // // // Created by Wiktor Korol on 25.07.2015. // // #include <stdio.h> int main(void) { const double CZYNSZ = 2345.67; //stala definiowana za pomoca const printf("*%f*\n", CZYNSZ); printf("*%e*\n", CZYNSZ); printf("*%4.2f*\n", CZYNSZ); printf("*%3.1f*\n", CZYNSZ); printf("*%...
1,330,179
the-stack-v2-dedup
C
#include <stdio.h> int main(int argc, char const *argv[]) { int fak_berapa, penghitung, hasil_faktorial; printf("masukkan angka faktorial yang akan dihitung \n"); scanf("%d", &fak_berapa); printf("\n"); hasil_faktorial = 1; for(penghitung=1; penghitung <= fak_berapa; penghitung++){ hasil_faktorial = hasil...
1,330,180
the-stack-v2-dedup
C
/* * bitmap_ops.h */ #ifndef BITMAP_OPS_H_ #define BITMAP_OPS_H_ /* The quotient represents the integer position(index of array i.e arr[i]) in the given array, * since each integer is represented by 32 bits so the divisor is 32. * The remainder represents the bit position in the referenced integer above. */ #def...
1,330,181
the-stack-v2-dedup
C
#pragma once #include <EASystemEventMessageDispatcher/internal/Config.h> /////////////////////////////////////////////////////////////////////////////// // IEASYSTEM_EVENT_MESSAGE_DISPATCHER_VERSION // #ifndef IEASYSTEM_EVENT_MESSAGE_DISPATCHER_VERSION #define IEASYSTEM_EVENT_MESSAGE_DISPATCHER_VERSION EASEMD_VERSI...
1,330,182
the-stack-v2-dedup
C
#include<stdio.h> #include<conio.h> void Rev_Num(int); int main() { int Num=0; printf("\n Enter The Number=>"); scanf("%d",&Num); Rev_Num(Num); getch(); getch(); printf("\n Thanks..."); return 0; } void Rev_Num(int No) { static int rev=0,rem=0; if(No > 0) { rem...
1,330,183
the-stack-v2-dedup
C
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* rush02.h :+: :+: :+: ...
1,330,184
the-stack-v2-dedup
C
#define NULL ((void*)0) typedef unsigned long size_t; // Customize by platform. typedef long intptr_t; typedef unsigned long uintptr_t; typedef long scalar_t__; // Either arithmetic or pointer type. /* By default, we understand bool (as a convenience). */ typedef int bool; #define false 0 #define true 1 /* Forward d...
1,330,185
the-stack-v2-dedup
C
/* * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * * Change Logs: * Date Author Notes * 2020-04-16 bigmagic first version */ #include <rthw.h> #include <rtthread.h> #include "board.h" #include "drv_uart.h" #include "cp15.h" #include ...
1,330,186
the-stack-v2-dedup
C
#ifndef SOCKET_INCLUDED #define SOCKET_INCLUDED typedef struct SocketStruct * Socket; Socket Socket_Create(void); void Socket_Destroy(Socket *); typedef enum { SOCKET_NULL_POINTER = -2, SOCKET_FAIL = -1, SOCKET_SUCCESS = 0 } SocketReturnCode; int Socket_Open(Socket); void Socket_Close(Socket); int Sock...
1,330,187
the-stack-v2-dedup
C
#include <stdio.h> #include <stdlib.h> #include <string.h> int main(){ char str[20] = "Linguagem C"; char inverted_str[20]; int i, j = 0; for (i = strlen(str) - 1; i >= 0; i--){ printf("%c", str[i]); inverted_str[j] = str[i]; j++; } printf("\n"); inverte...
1,330,188
the-stack-v2-dedup
C
#define _XOPEN_SOURCE #include <unistd.h> #include <cs50.h> #include <stdio.h> #include <string.h> /* * Brute force guesses a password with a given hash by going * through all the possibilities between A - zzzzz, stopping * when it finds a match * * Thomas Komen, 12556963 */ int cracker(char *current_password, char *...
1,330,189
the-stack-v2-dedup
C
#include <stdarg.h> void print_string(const char* s) { for(const char* p = s; *p; ++p) { putchar(*p); } } int puts(const char* s) { print_string(s); putchar('\n'); return 1; } void print_dec(int val) { char buffer[255]; char *p = buffer; if(val < 0) { putchar('-'); print_de...
1,330,190
the-stack-v2-dedup
C
#include <stdlib.h> #include "induction.h" #include "induction/timer.h" #include "induction/timeutil.h" #include "induction/form.h" #include "induction/auth.h" #include "induction/cement.h" #include "induction/entity.h" #include "induction/device.h" #include "induction/container.h" #include "induction/object.h" #inclu...
1,330,191
the-stack-v2-dedup
C
#include <stdio.h> #include <stdlib.h> struct Node { int data; struct Node* next; }; struct Node *head; struct Node* Insert(int data, int loc) { struct Node* temp = (struct Node*)malloc(sizeof(struct Node*)); temp->data = data; temp->next = head; int i; if(loc==1) { temp->next = head; head = temp; re...
1,330,192
the-stack-v2-dedup
C
/************************************************************************************ TerraLib - a library for developing GIS applications. Copyright © 2001-2007 INPE and Tecgraf/PUC-Rio. This code is part of the TerraLib library. This library is free software; you can redistribute it and/or modify it under the ...
1,330,193
the-stack-v2-dedup
C
int main() { for (int i = 0; i < 10000; i++){ void *str0 = malloc(185); void *str1 = malloc(38); void *str2 = malloc(43); free(str1); void *str3 = malloc(49); free(str2); void *str4 = malloc(239); free(str4); void *str5 = malloc(114); free(str5); void *str6 = malloc(5); ...
1,330,194
the-stack-v2-dedup
C
/*------------------------------------------------------------------------ isdecs.h +----------------------------------------------------+ | Worldwide Copyright (c) Byte Designs Ltd (1997) | | | | 20568 -...
1,330,195
the-stack-v2-dedup
C
#pragma once #include"wncurses.h" extern int clearok (WINDOW *window, BOOL n); extern int baudrate (void); extern int wnoutrefresh (WINDOW *window); extern int start_color(void); extern BOOL has_colors(void); extern BOOL can_change_color(void); extern int init_pair (short pair, short f, short b); extern int init_colo...
1,330,196
the-stack-v2-dedup
C
#include <stdio.h> #include <cs50.h> #include "stdnt.h" #define STDNT 3 int main(void) { stdnt student[STDNT]; for (int i = 0; i < STDNT; i++) { printf("Name: "); student[i].name = get_string(); printf("Dorm of %s: ", student[i].name); student[i].dorm = get_string(); ...
1,330,197
the-stack-v2-dedup
C
/* Testing module for MinHeap. * (C) Thomas Lang, 2014 * * This module does some testing on a MinHeap. * * This code is licensed under the BSD3 license. */ #include <stdio.h> #include "min_heap.h" int main( int argc, char *argv[] ) { printf( "*** Initializing new MinHeap ... done.\n" ); printf( "*** Ad...
1,330,198
the-stack-v2-dedup
C
/******************************************************************************/ // Free implementation of Bullfrog's Dungeon Keeper strategy game. /******************************************************************************/ /** @file map_blocks.h * Header file for map_blocks.c. * @par Purpose: * Map blo...
1,330,199