added stringdate 2024-11-18 17:54:19 2024-11-19 03:39:31 | created timestamp[s]date 1970-01-01 00:04:39 2023-09-06 04:41:57 | id stringlengths 40 40 | metadata dict | source stringclasses 1
value | text stringlengths 13 8.04M | score float64 2 4.78 | int_score int64 2 5 |
|---|---|---|---|---|---|---|---|
2024-11-18T19:00:42.998658+00:00 | 2019-02-17T01:55:35 | 090802ea9c0c25778ff5c5818edb72e195b990a6 | {
"blob_id": "090802ea9c0c25778ff5c5818edb72e195b990a6",
"branch_name": "refs/heads/master",
"committer_date": "2019-02-17T01:55:35",
"content_id": "c1fe8190b3d3943cadf9fe5ca3d250c507fd9165",
"detected_licenses": [
"MIT"
],
"directory_id": "4e927b82fa163c6197fce9ae7ca53feb8830e6d7",
"extension": "c"... | stackv2 |
#include "object.h"
#define FREE_STRING(ptr) free(*(char**)ptr)
#define FREE_REFERENCE(ptr) corto_release(*(corto_object*)ptr)
#define FREE_OPTIONAL(ptr, action) {\
void *optional_ptr = *(void**)ptr;\
if (optional_ptr) {\
action;\
free(optional_ptr);\
}\
}
#define FREE_UNION(ptr) {\
... | 2.515625 | 3 |
2024-11-18T19:11:15.985998+00:00 | 2019-11-17T09:24:10 | b6ba007a519e88224a614b69ea32bd28bd7b2252 | {
"blob_id": "b6ba007a519e88224a614b69ea32bd28bd7b2252",
"branch_name": "refs/heads/master",
"committer_date": "2019-11-17T09:24:10",
"content_id": "4d6ff5fda76176787fe29c01064f19fa0dfa1fe7",
"detected_licenses": [
"MIT"
],
"directory_id": "9417e92124162f2278400cac181b456b0fc21045",
"extension": "c"... | stackv2 | #include<stdio.h>
const double PI = 3.14159;//c99的做法
#define PI 3.14159//这就是宏,预处理时会进行处理,宏定义;
#define FORMAT "%f\n"
#define PI2 2*PI
#define PRT printf("%f\n",PI);\
printf("%f\n",PI2)
#define DEBUG//没有值得宏,是用来做条件编译的,如果有这个做这个分支,没有这个做另一个分支;
int main(int argc, char const *grgv[])
{
//printf(FORMAT, 2 * PI*3.0);
PRT;
... | 2.546875 | 3 |
2024-11-18T19:11:16.236479+00:00 | 2020-07-03T20:17:54 | e820f936e2031607b9b1c6397d1c7ede53b2e74b | {
"blob_id": "e820f936e2031607b9b1c6397d1c7ede53b2e74b",
"branch_name": "refs/heads/master",
"committer_date": "2020-07-03T20:17:54",
"content_id": "923ab27bd20c8c0b6552e9cf7c121477ae67bdeb",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "2137eb3341f185b45f34bfbdc86b3a60559f61d8",
"extens... | stackv2 | #include <stdbool.h>
#include <stdio.h>
#include <letmecreate/click/fan.h>
#include <letmecreate/core/i2c.h>
/* I2C address of EMC2301 */
#define EMC2301_ADDRESS (0x2F)
/* Register addresses */
#define EMC2301_PRODUCT_ID_REG (0xFD)
#define EMC2301_MANUFACTURER_ID_REG (0xFE)
#define EMC2301_F... | 2.5625 | 3 |
2024-11-18T19:21:45.389321+00:00 | 2023-08-14T10:20:01 | d93785bfadbff40de2edb9704c8ddf114704a8a5 | {
"blob_id": "d93785bfadbff40de2edb9704c8ddf114704a8a5",
"branch_name": "refs/heads/master",
"committer_date": "2023-08-14T10:20:01",
"content_id": "1f86f15249566aba439bd9b6ee66703f82788060",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "887bac7976e84b9a8b785ee8214d033a604b9523",
"extens... | stackv2 | /*
module test-val123-api
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <string.h>
#include <assert.h>
#include <unistd.h>
#include <errno.h>
#include <sys/wait.h>
#include "ncxmod.h"
#include "val123.h"
#include "agt.h"
#include "ses.h"
#include "cfg.h"
#include "getcb... | 2.078125 | 2 |
2024-11-18T19:21:46.581571+00:00 | 2020-02-03T22:53:39 | 3b9d4950b2b402d3151f518c075d6f255ee33338 | {
"blob_id": "3b9d4950b2b402d3151f518c075d6f255ee33338",
"branch_name": "refs/heads/master",
"committer_date": "2020-02-03T22:53:39",
"content_id": "dd713cba1fe92a82b9ab7e2cd869e20c78704b82",
"detected_licenses": [
"MIT"
],
"directory_id": "5ae38340888fc2730e537d64c64762b93ed4dca3",
"extension": "c"... | stackv2 | #include <stdio.h>
#include <graphics/color.h>
#include <geometry/g_maths.h> // for double_equal
#include <util/log.h>
#include <assert.h>
int TST_ColorNewInt()
{
struct color col1 = color_newi(200, 150, 100);
struct color col2 = color_newi(0xff, 0x88, 0x00);
assert(double_equal(col1.r, 0.... | 2.578125 | 3 |
2024-11-18T19:33:39.576569+00:00 | 2015-04-14T20:24:43 | 54426585b7dad63da4e8a707792297cdf4c3d95d | {
"blob_id": "54426585b7dad63da4e8a707792297cdf4c3d95d",
"branch_name": "refs/heads/master",
"committer_date": "2015-04-14T20:24:43",
"content_id": "396f859328cc16f1f35dde91f96db3a48da51677",
"detected_licenses": [
"BSD-2-Clause"
],
"directory_id": "45a175e1a470bf15f4a2aa5b066250d6f8ec5327",
"extens... | stackv2 | /**
* @file
* @brief Print or set the system date and time.
*
* @date 1.06.2012
* @author Alexander Kalmuk
*/
#include <unistd.h>
#include <stdio.h>
#include <string.h>
#include <stdint.h>
#include <hal/clock.h>
#include <kernel/time/ktime.h>
#include <kernel/time/clock_source.h>
#include <time.h>
static void ... | 3.03125 | 3 |
2024-11-18T19:33:39.745523+00:00 | 2021-05-12T23:52:39 | 890a7add56e70ffbde3569954a4ecd707574e0e7 | {
"blob_id": "890a7add56e70ffbde3569954a4ecd707574e0e7",
"branch_name": "refs/heads/master",
"committer_date": "2021-05-12T23:52:39",
"content_id": "dbf86d1260907836722651e340e4629d3db2ce41",
"detected_licenses": [
"Unlicense"
],
"directory_id": "5a1217f2ca5a6c776abcf92aa2416a934a887dad",
"extension... | stackv2 | #ifndef CASINO_STRUCTURES_H
#define CASINO_STRUCTURES_H
typedef struct Card {
unsigned int id: 6;
/*
2 ^ 6 - Достаточно для 52 (36 либо 54 в зависимости от игры)
уникальных карт.
Остальные поля в структурах - аналогично;
*/
} Card;
typedef struct Deck {
unsigned int ... | 2.03125 | 2 |
2024-11-18T19:34:21.849942+00:00 | 2019-10-17T01:59:36 | 02c4236e8e9aaf517f7a15ab7bb85aa42c67a5ad | {
"blob_id": "02c4236e8e9aaf517f7a15ab7bb85aa42c67a5ad",
"branch_name": "refs/heads/master",
"committer_date": "2019-10-17T01:59:36",
"content_id": "fb2802c4af25500a089499f70105642b08f644e5",
"detected_licenses": [
"MIT"
],
"directory_id": "3c5a349169464a0e3884c555f11133b789519610",
"extension": "c"... | stackv2 | // Credits: The foundations of this prototype are from Steve Grubb's public blog post
// http://security-plus-data-science.blogspot.com/2017/04/sending-email-when-audisp-program-sees.html
//
// I just did some minor adjustments to be able to make email and notifications configurable.
// Note the sender is currently ha... | 2.265625 | 2 |
2024-11-18T19:34:22.005772+00:00 | 2021-06-09T20:56:45 | f035123c9911891f9c4c6726f87a8874d3aca729 | {
"blob_id": "f035123c9911891f9c4c6726f87a8874d3aca729",
"branch_name": "refs/heads/main",
"committer_date": "2021-06-09T20:56:45",
"content_id": "40355dca1f99487bb10a8a6f2eb2829aa0f64fcf",
"detected_licenses": [
"MIT"
],
"directory_id": "b7f8bd9646ea5243aa87147ae9d84f696890eae3",
"extension": "c",
... | stackv2 | /*
* Copyright (C) 2021 Biren Patel
* MIT License
* Unit tests for double ended queue
*/
#include <stdint.h>
#include "deque.h"
#include "unity.h"
void test_new_deque_zero_capacity_returns_error(void) {
//arrange
struct deque dq;
uint8_t err;
unsigned char buf[] = {1, 2, 3};
... | 2.8125 | 3 |
2024-11-18T19:34:22.148410+00:00 | 2023-08-30T05:21:33 | f700eb514e5934f205d5891065b6d8fe943ceb4f | {
"blob_id": "f700eb514e5934f205d5891065b6d8fe943ceb4f",
"branch_name": "refs/heads/master",
"committer_date": "2023-08-30T05:21:33",
"content_id": "72d2543ed3f2893eb3f294d8d7c61ac27be4d952",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "3b1223e5259c580cbf107d1f45960d9f08aff27f",
"extens... | stackv2 | #define INCL_DOSMISC /* Miscellaneous values */
#define INCL_DOSERRORS /* DOS Error values */
#include <os2.h>
#include <stdio.h>
int main(VOID) {
typedef struct _MYCPINFO
{ USHORT cCP; /* Number of code pages */
USHORT CP1; /* First code page */
ULONG ... | 2.390625 | 2 |
2024-11-18T19:35:26.408287+00:00 | 2018-01-15T03:10:10 | 9e07205b8cd35a0679a76a9a404bb2a21a1a8402 | {
"blob_id": "9e07205b8cd35a0679a76a9a404bb2a21a1a8402",
"branch_name": "refs/heads/master",
"committer_date": "2018-01-15T03:10:10",
"content_id": "348fb40104d2feac372864ed23e8c499cb6447b4",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "d73ff1d78ffda890c48fc89c674b7f632d319787",
"extens... | stackv2 | #ifndef _PAGE__H
#define _PAGE__H
#include <zjunix/fs/fat.h>
/*
页表结构采用两级页表来实现
页大小为4KB
虚拟地址32位:
0-11:页内偏移
12-21:第二级页表索引
22-31:第一级页表索引
第一级页表大小为1个页大小
第二级页表大小为1个页大小
*/
#define PAGE_SIZE 4096 //4KB
#define PAGE_SHIFT 12
#define PGD_SHIFT 22
#define PTE_SHIFT 12
#define INDEX_MASK 0x3ff //10 bit 1
#define OFFSE... | 2.4375 | 2 |
2024-11-18T19:35:26.908874+00:00 | 2016-10-03T21:35:44 | 6b903c8d407450eedbc6ab8eae58e75fb75b1745 | {
"blob_id": "6b903c8d407450eedbc6ab8eae58e75fb75b1745",
"branch_name": "refs/heads/master",
"committer_date": "2016-10-03T21:49:44",
"content_id": "4293b779ada22b12373d525d2e2a6e9f30279a2d",
"detected_licenses": [
"BSD-2-Clause"
],
"directory_id": "4336e9311c007f203691e157781164118a2f48c1",
"extens... | stackv2 | #include <embox/test.h>
#include <sys/mman.h>
EMBOX_TEST_SUITE("anonymous mmap");
TEST_CASE("allocate one page") {
void *ptr = mmap(NULL, PAGE_SIZE(), PROT_READ | PROT_WRITE, MAP_SHARED | MAP_ANONYMOUS, -1, 0);
test_assert_not_null(ptr);
test_assert_zero(munmap(ptr, PAGE_SIZE()));
}
TEST_CASE("request a non-whole... | 2.71875 | 3 |
2024-11-18T19:35:27.016344+00:00 | 2017-05-24T01:46:45 | 977711d5f79ed48b4fe987b716fbdcf366fe203f | {
"blob_id": "977711d5f79ed48b4fe987b716fbdcf366fe203f",
"branch_name": "refs/heads/master",
"committer_date": "2017-05-24T01:46:45",
"content_id": "9331131bbeaa2dbc5115d18e37fa6deeb200534a",
"detected_licenses": [
"MIT"
],
"directory_id": "75a71f8ec7db121c3c0356f68dde06a88576cd22",
"extension": "c"... | stackv2 | /**
** This file was automatically generated by the Cyclone scheme compiler
** http://justinethier.github.io/cyclone/
**
** (c) 2014-2017 Justin Ethier
** Version 0.5.1
**
**/
#define closcall1(td, clo,a1) \
if (type_is_pair_prim(clo)) { \
Cyc_apply(td, 0, (closure)(a1), clo); \
} else { \
((clo)->fn)(td... | 2.359375 | 2 |
2024-11-18T19:35:27.110405+00:00 | 2019-10-12T18:29:42 | 3c4f5b894a001ffd7bdf0cee7daff7ed0a8bf5ea | {
"blob_id": "3c4f5b894a001ffd7bdf0cee7daff7ed0a8bf5ea",
"branch_name": "refs/heads/master",
"committer_date": "2019-10-12T18:29:42",
"content_id": "699090962766844a135980695ad0adaa4c255483",
"detected_licenses": [
"MIT"
],
"directory_id": "4ce7b314c6c60e762186df5247199c45a8a91504",
"extension": "c"... | stackv2 | // SEE socket-hw-server.c
#include "../os.h"
#define PORT 47000
#define MAX_BUFFER 4096
#define FILENAME "socket-hw-send.txt"
int main(int argc, char *argv[])
{
// get file from user
if (argc < 2)
{
printf("Program usage: %s <filename>", argv[0]);
exit(EXIT_FAILURE);
}
char *file_t... | 2.875 | 3 |
2024-11-18T19:44:30.826955+00:00 | 2023-06-01T08:33:17 | 74cda9349e07955697d2f101c722e404330ad447 | {
"blob_id": "74cda9349e07955697d2f101c722e404330ad447",
"branch_name": "refs/heads/master",
"committer_date": "2023-06-01T08:33:17",
"content_id": "79f201933bc0581d7abb16a2815d6d3eb53b0882",
"detected_licenses": [
"MIT"
],
"directory_id": "8e6b4f182b0b7dedae68b9f6b7b8f0242024687a",
"extension": "c"... | stackv2 | #define _POSIX_C_SOURCE 200809L
#include <string.h>
#include <stdlib.h>
#include "config.h"
#include "mako.h"
#include "surface.h"
void destroy_surface(struct mako_surface *surface) {
if (surface->layer_surface != NULL) {
zwlr_layer_surface_v1_destroy(surface->layer_surface);
}
if (surface->surface != NULL) {
... | 2.125 | 2 |
2024-11-18T19:57:32.895897+00:00 | 2021-07-13T10:41:07 | 34d08022ec49d36d8efb8583e5505f86577a14b7 | {
"blob_id": "34d08022ec49d36d8efb8583e5505f86577a14b7",
"branch_name": "refs/heads/master",
"committer_date": "2021-07-13T10:41:07",
"content_id": "8c098833eabc4a010ddae4c105b5eabeb1c3312c",
"detected_licenses": [
"MIT"
],
"directory_id": "07b73cd7a7a00829a3c234d73f9e14cdd1a774d9",
"extension": "h"... | stackv2 | // !file C++17
/**
==============
Directed Graph
==============
Draw a graph with directed edges using a colormap && different node sizes.
Edges have different colors && alphas (opacity). Drawn using matplotlib.
*/
// Author: Rodrigo Dorantes-Gilardi (rodgdor@gmail.com);
// from __future__ import division
import ma... | 2.375 | 2 |
2024-11-18T19:58:09.176269+00:00 | 2018-03-30T21:06:11 | 067eb59a97271b4030a95dea6dc1403136e27a5b | {
"blob_id": "067eb59a97271b4030a95dea6dc1403136e27a5b",
"branch_name": "refs/heads/master",
"committer_date": "2018-03-30T21:06:11",
"content_id": "24fedcb8670ca6ae52f1098239d3801dbad9ddd3",
"detected_licenses": [
"MIT"
],
"directory_id": "f20581d8186ab4dad446f0adb8b17d5154e83d90",
"extension": "h"... | stackv2 | /**
* @file system_types.h
*
* @brief Type defs for the core openGL functions
*/
#ifndef SYSTEM_TYPES_H
#define SYSTEM_TYPES_H
/**********************************************************************
GENERAL INCLUDES
**********************************************************************/... | 2.234375 | 2 |
2024-11-18T19:58:09.422954+00:00 | 2020-04-16T20:49:34 | 6f5b86fd71fe16f30b64b3a990c3954b5b171ba2 | {
"blob_id": "6f5b86fd71fe16f30b64b3a990c3954b5b171ba2",
"branch_name": "refs/heads/master",
"committer_date": "2020-04-16T20:49:34",
"content_id": "68cdbe2713915839bd82cf1f539286f47bb8727f",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "90dd32f913ef74833946f03a5b43d7cdfed209b8",
"extensio... | stackv2 | /* libpbm1.c - pbm utility library part 1
**
** Copyright (C) 1988 by Jef Poskanzer.
**
** Permission to use, copy, modify, and distribute this software and its
** documentation for any purpose and without fee is hereby granted, provided
** that the above copyright notice appear in all copies and that both that
... | 2.171875 | 2 |
2024-11-18T19:59:55.520410+00:00 | 2021-03-09T13:37:10 | 8ef6b8b411bc26d4d8948c46e1c769795719cf2b | {
"blob_id": "8ef6b8b411bc26d4d8948c46e1c769795719cf2b",
"branch_name": "refs/heads/master",
"committer_date": "2021-03-09T13:37:10",
"content_id": "fc2416daca3ee9939cf63c7942ce755f6d046379",
"detected_licenses": [
"MIT"
],
"directory_id": "4ed45c7e3fc06cf41988570aa0326838387d62e5",
"extension": "c"... | stackv2 | /*
author: Alice Francener
problem: Salary
url: https://www.urionlinejudge.com.br/judge/en/problems/view/1008
*/
#include <stdio.h>
int main()
{
int n, horas;
float valorhora, salario;
scanf("%d %d %f", &n, &horas, &valorhora);
salario = horas * valorhora;
printf("NUMBER = %d\nSALARY = U$ %.2f\n", n, salar... | 3.203125 | 3 |
2024-11-18T19:59:55.642714+00:00 | 2023-08-28T23:30:43 | 863c816a47ccad96108ff083faa46679de1995d9 | {
"blob_id": "863c816a47ccad96108ff083faa46679de1995d9",
"branch_name": "refs/heads/master",
"committer_date": "2023-08-28T23:30:43",
"content_id": "74b3264dc1afd2dd23dd5dec6864505309bae462",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "badb70a0b235c98ac034cfe5b4bfafda36647831",
"extens... | stackv2 | /** @file
Library handling KEXT prelinking.
Copyright (c) 2018, Download-Fritz. All rights reserved.<BR>
This program and the accompanying materials are licensed and made available
under the terms and conditions of the BSD License which accompanies this
distribution. The full text of the license may be found at
ht... | 2.0625 | 2 |
2024-11-18T20:07:42.502651+00:00 | 2018-02-03T13:11:37 | a2fcf7e319aed94b59cf424e41f61c0ee64e6a97 | {
"blob_id": "a2fcf7e319aed94b59cf424e41f61c0ee64e6a97",
"branch_name": "refs/heads/master",
"committer_date": "2018-02-03T13:11:37",
"content_id": "504ff51693376741f2cec40295bba6fd92315943",
"detected_licenses": [
"MIT-Modern-Variant"
],
"directory_id": "9dfb8f15f89a1882febec30b9705ec05e384eb93",
"... | stackv2 | #include "syscall.h"
/*
* In order to execute this test, go to ~/code/userprog
* Then run the following command ./nachos -rs 123 -x ../test/StringThreads
* The output is : 1 for the first thread, 2 for the second thread and 3 for the third .
* The "I am the main thread" stands for the main thread.
* In case of one of ... | 2.984375 | 3 |
2024-11-18T20:07:42.673935+00:00 | 2020-03-06T03:57:46 | 4ce7c0769b0192c9df05ccaf7704cab75c023eaa | {
"blob_id": "4ce7c0769b0192c9df05ccaf7704cab75c023eaa",
"branch_name": "refs/heads/master",
"committer_date": "2020-03-06T03:59:02",
"content_id": "d2437d9dd54eef0d83dd170fe2145d4cdc891707",
"detected_licenses": [
"MIT"
],
"directory_id": "df92ea7d37f16c18d17b2ccc6a42fb26ab819ca9",
"extension": "c"... | stackv2 | // TODO: handle file size larger than uint32_t under 32bit process
int fsize(FILE *fp, size_t *out)
{
off_t curr = ftello(fp);
if(fseeko(fp, 0, SEEK_END) != 0) return O_FAILED;
*out = ftello(fp);
// it will be a fatal error if we can't restore file pointer
assert(fseeko(fp, curr, SEEK_SET) == 0);
return O_SUCCESS... | 2.75 | 3 |
2024-11-18T20:07:42.773648+00:00 | 2021-01-12T22:37:03 | 18efdaf102a14b44b60000a5397be20f050b3754 | {
"blob_id": "18efdaf102a14b44b60000a5397be20f050b3754",
"branch_name": "refs/heads/master",
"committer_date": "2021-01-12T22:37:03",
"content_id": "d7df3b6dcb230600f2679a6ae81e1bb4cd95e748",
"detected_licenses": [
"MIT"
],
"directory_id": "baa705a17da6e212b9620ac927ef85ff1345b68d",
"extension": "c"... | stackv2 | #include "mouse.h"
#include <std/math.h>
#include <std/std.h>
#include <kernel/util/vfs/fs.h>
#include <kernel/util/adi/adi.h>
#include <kernel/drivers/ps2/ps2.h>
#include <kernel/interrupts/idt.h>
#include <kernel/interrupts/interrupts.h>
#define PS2_MOUSE_CMD_SET_DEFAULT_SETTINGS 0xF6
#define PS2_MOUSE_CMD_ENABLE_DA... | 2.0625 | 2 |
2024-11-18T20:07:42.933904+00:00 | 2023-08-14T19:47:16 | 1a5d36fc08444f4ec10cb9ace1c4d62db549c81b | {
"blob_id": "1a5d36fc08444f4ec10cb9ace1c4d62db549c81b",
"branch_name": "refs/heads/master",
"committer_date": "2023-08-14T19:47:16",
"content_id": "99a08aed8dbf0e4f7659cf3242f6742cf407b96d",
"detected_licenses": [
"BSD-2-Clause"
],
"directory_id": "0827979a9e3bfca5900726f1cef428f8a8c819ba",
"extens... | stackv2 | // Thorn : NRPyEOS
// File : NRPyEOS_Tabulated_general_interpolators.cc
// Author(s) : Leo Werneck (wernecklr@gmail.com)
// Description: In this file we provide a general function to retrieve
// table quantities from (rho,Ye,T). We also provide a
// general function which is able t... | 2.484375 | 2 |
2024-11-18T20:19:16.019781+00:00 | 2018-03-30T02:04:55 | 1282c5a218165b1a89ce286024cb10a7342d69ee | {
"blob_id": "1282c5a218165b1a89ce286024cb10a7342d69ee",
"branch_name": "refs/heads/master",
"committer_date": "2018-03-30T02:04:55",
"content_id": "380bd223e6ea41df6cf3c9df14a29bf3c14b3872",
"detected_licenses": [
"BSD-2-Clause-Views",
"BSD-2-Clause"
],
"directory_id": "eafa4aa8dc585b2c6ee1bd5f2a... | stackv2 | // Test qfunction evaluation
#include <ceed.h>
static int setup(void *ctx, void *qdata, CeedInt Q, const CeedScalar *const *u,
CeedScalar *const *v) {
CeedScalar *w = qdata;
for (CeedInt i=0; i<Q; i++) {
w[i] = u[0][i];
}
return 0;
}
static int mass(void *ctx, void *qdata, CeedInt Q, cons... | 2.796875 | 3 |
2024-11-18T20:19:16.415596+00:00 | 2019-02-27T15:03:16 | aa8a2d65e2747402f11f1759012e4076d0957325 | {
"blob_id": "aa8a2d65e2747402f11f1759012e4076d0957325",
"branch_name": "refs/heads/master",
"committer_date": "2019-02-27T15:03:16",
"content_id": "235b16f9f9c9da1d78b05860b8c7bce5f432dd37",
"detected_licenses": [
"MIT"
],
"directory_id": "645d21c5c313168c7c38fc8ecce8b4eaadffb343",
"extension": "c"... | stackv2 | #include <texture.h>
#include <string.h>
#include <utils.h>
#include <stdlib.h>
#include <stb_image.h>
#include <SDL.h>
#include <gfx.h>
extern ctx_t* ctx;
texture_t* texture_new(const char* file_path)
{
texture_t* texture = malloc(sizeof(texture_t));
CHECK_RET(texture, NULL, "could not allocate space for t... | 2.546875 | 3 |
2024-11-18T20:40:50.708351+00:00 | 2021-05-07T21:19:07 | 33c30f8314c91ca4ecbbe83d455f98a30c5e89fd | {
"blob_id": "33c30f8314c91ca4ecbbe83d455f98a30c5e89fd",
"branch_name": "refs/heads/main",
"committer_date": "2021-05-07T21:19:07",
"content_id": "7e69aca1eef460f812a70226067074b582e3ee96",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "7436db955219a85e3aa38e0710135303de4a4202",
"extension"... | stackv2 | #include "pid_lib.h"
volatile double Kp;
volatile double Ki;
volatile double Kd;
volatile double stepSize;
double K;
double zeta;
double wn;
void PID_Config(PID sample_pid){
Kp = sample_pid.pid_kp;
Kd = sample_pid.pid_kd;
Ki = sample_pid.pid_ki;
stepSize = sample_pid.stepsize;
}
/*
void Simulation_Config(Syste... | 2.640625 | 3 |
2024-11-18T20:40:51.189206+00:00 | 2012-09-16T18:27:30 | 9178ef3f81e7f5faa48493dceb46d76170f82461 | {
"blob_id": "9178ef3f81e7f5faa48493dceb46d76170f82461",
"branch_name": "refs/heads/master",
"committer_date": "2012-09-16T18:27:30",
"content_id": "831566cefc97dd9ffec0d6cff52a9a44516df1d6",
"detected_licenses": [
"MIT"
],
"directory_id": "32cd9ea355e134826a890b9cc28bbd709cf59a6d",
"extension": "c"... | stackv2 | /*
* winstore.c: Windows-specific implementation of the interface
* defined in storage.h.
*/
#include <stdio.h>
#include <stdlib.h>
#include <limits.h>
#include "putty.h"
#include "storage.h"
#include <shlobj.h>
#ifndef CSIDL_APPDATA
#define CSIDL_APPDATA 0x001a
#endif
#ifndef CSIDL_LOCAL_APPDATA
#define CSIDL_LOCAL_... | 2.3125 | 2 |
2024-11-18T20:40:53.728296+00:00 | 2023-01-30T10:00:49 | f18747d8fd6d2ffc39820fcf13e8741d94f4b8fe | {
"blob_id": "f18747d8fd6d2ffc39820fcf13e8741d94f4b8fe",
"branch_name": "refs/heads/master",
"committer_date": "2023-01-30T10:00:49",
"content_id": "ddc70901401bd0e35ca7e758af43c5970c3b996e",
"detected_licenses": [
"MIT"
],
"directory_id": "d10090b0c23c789baaac67f40cccb61f39554e07",
"extension": "c"... | stackv2 | /**
* MIT License
*
* Copyright (c) 2019 Brian Amos
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modi... | 2.546875 | 3 |
2024-11-18T20:40:53.878255+00:00 | 2019-05-07T21:01:24 | 4bf077ce904dac17ca70aa452df46caf4fa2bfe3 | {
"blob_id": "4bf077ce904dac17ca70aa452df46caf4fa2bfe3",
"branch_name": "refs/heads/master",
"committer_date": "2019-05-07T21:01:24",
"content_id": "7a50f08404a555a50edd216acdfdcb9d0fb3b9c3",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "8b0231925099f101f21b12df18d1b3c42097343f",
"extens... | stackv2 | #include <jni.h>
#include <stdlib.h>
#include <string.h>
#include <vulkan/vulkan.h>
jlong jniPointerToLong(const void* p);
void* jniLongToPointer(jlong l);
jlong jniFunctionPointerToLong(PFN_vkVoidFunction p);
PFN_vkVoidFunction jniLongToFunctionPointer(jlong l);
void jniThrowException(JNIEnv* env, const char* message... | 2.171875 | 2 |
2024-11-18T18:36:19.709358+00:00 | 2020-04-14T17:00:06 | df5fe587c307752c47f9900d34445f3095a92683 | {
"blob_id": "df5fe587c307752c47f9900d34445f3095a92683",
"branch_name": "refs/heads/master",
"committer_date": "2020-04-14T17:00:06",
"content_id": "834e06c4e2f879deab1caae1791790a98d991030",
"detected_licenses": [
"MIT"
],
"directory_id": "61f2ca19601c4c51912c2fee2d5c82c035b1619e",
"extension": "c"... | stackv2 | /**
* Author: Rory Ryan [K00218864]
* Date: 2020/03/09
*
* This is the Source file for the Client side of the TCP version of the
* Networked Hangman game.
*
*/
#include "../hdr/hangserver_tcp_fork.h"
/**
* A Function Designed to create a thread that does
* not become a Zombie for testing purposes
*/
... | 2.609375 | 3 |
2024-11-18T18:36:21.704660+00:00 | 2023-08-07T19:18:32 | 9b8ee2dc29f0e688e59208e4795e1bf10acda983 | {
"blob_id": "9b8ee2dc29f0e688e59208e4795e1bf10acda983",
"branch_name": "refs/heads/master",
"committer_date": "2023-08-07T19:18:32",
"content_id": "a445aca9dac798a2265f7329a4ce90fd33e9eb54",
"detected_licenses": [
"Apache-2.0",
"curl"
],
"directory_id": "e1d9c54e9925e30e388a255b53a93cccad0b94cb",... | stackv2 | #include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include "v1_service_account_list.h"
v1_service_account_list_t *v1_service_account_list_create(
char *api_version,
list_t *items,
char *kind,
v1_list_meta_t *metadata
) {
v1_service_account_list_t *v1_service_account_list_local_var = ... | 2.171875 | 2 |
2024-11-18T18:37:43.080349+00:00 | 2021-03-01T02:47:19 | 26ed900bfbe48c5a2c9b74b28ce9b5f4c7142d54 | {
"blob_id": "26ed900bfbe48c5a2c9b74b28ce9b5f4c7142d54",
"branch_name": "refs/heads/main",
"committer_date": "2021-03-01T02:47:19",
"content_id": "0ebdb7d9e31621e07dc09666fd6463377c0d9e75",
"detected_licenses": [
"MIT"
],
"directory_id": "40be2ce3b39877203e9b3357ad2f47903483e654",
"extension": "c",
... | stackv2 | #include <stdio.h>
#include <stdlib.h>
main(){
float consumo, distancia;
char tipo;
printf("TIPO DO CARRO: [A, B E C]\n\n");
printf("qual eh o tipo do carro? ");
scanf("%c", &tipo);
printf("qual eh a distancia percorrida em km/h? ");
scanf("%f", &distancia);
if (tipo == 'A')
consumo = distancia / 8;
else ... | 3.09375 | 3 |
2024-11-18T18:37:43.335098+00:00 | 2021-04-26T23:16:39 | 3df41e1e17ac7b88b7fe37e225f2f2d84ebd9c4c | {
"blob_id": "3df41e1e17ac7b88b7fe37e225f2f2d84ebd9c4c",
"branch_name": "refs/heads/master",
"committer_date": "2021-04-26T23:16:39",
"content_id": "108f3b99db6dc84fe57947e7a3a43766a0a38d3c",
"detected_licenses": [
"MIT"
],
"directory_id": "e30a212fcd8a02111cb984c67f424256b16a29d6",
"extension": "c"... | stackv2 | #include <stdlib.h>
#include <stdio.h>
#include <stdbool.h>
// Checking if array is sorted, inserting element in a sorted array
struct Array
{
int A[10];
int length;
int size;
};
void insert(struct Array *arr, int key)
{
if (arr->length == arr->size) // There needs to be at least one vacant space
... | 3.921875 | 4 |
2024-11-18T18:37:43.430223+00:00 | 2018-01-21T18:37:37 | 0ff44776f0c21d39dc82b438fd822388d021a9e7 | {
"blob_id": "0ff44776f0c21d39dc82b438fd822388d021a9e7",
"branch_name": "refs/heads/master",
"committer_date": "2018-01-21T18:37:37",
"content_id": "3740efd522d5130bc50e5e3fe30fda621984a7df",
"detected_licenses": [
"MIT"
],
"directory_id": "4814a35513a883627b50e12be4fca6caa8dcf284",
"extension": "c"... | stackv2 | #include <stdio.h>
#include <stdlib.h>
#include <limits.h>
#include <string.h>
#define FILE_FRECCE "frecce2.txt"
#define inf INT_MAX
int comb(int*, int, int, int*, int*);
int din(int*, int, int, int, int*, int*);
int getCosto(int*, int*, int);
int isBalanced(int, int*, int);
void equalizza(int*, int, int);
void print... | 2.984375 | 3 |
2024-11-18T18:38:24.201279+00:00 | 2020-04-30T19:59:55 | 126671c5f14d00783495e157b3f73a4bd9467511 | {
"blob_id": "126671c5f14d00783495e157b3f73a4bd9467511",
"branch_name": "refs/heads/master",
"committer_date": "2020-04-30T19:59:55",
"content_id": "f4ea6b581d1520340b248b3f2f826b5f627169ff",
"detected_licenses": [
"MIT"
],
"directory_id": "7bdab7c84f7d6f4fe2c2e10fdda9f377e2de5c2e",
"extension": "c"... | stackv2 | /*
* MIT License
*
* Copyright (c) 2020 dead-end
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify,... | 2.109375 | 2 |
2024-11-18T18:38:27.896078+00:00 | 2016-12-15T23:11:04 | ecbefc8405cd0fdc7eb5a53e7dac64f8ebc44e18 | {
"blob_id": "ecbefc8405cd0fdc7eb5a53e7dac64f8ebc44e18",
"branch_name": "refs/heads/master",
"committer_date": "2016-12-15T23:11:04",
"content_id": "4ec48b581f2377d156f61783d3162f9e05a52ef2",
"detected_licenses": [
"MIT"
],
"directory_id": "66cf530b7abbc7ca0b617d92098cd78e7332d589",
"extension": "c"... | stackv2 | #include "../labstreaminglayer/LSL/liblsl/include/lsl_c.h"
#include "ads1299.h"
#include <stdio.h>
#include <sys/time.h>
#include <time.h>
#include <bcm2835.h>
int InputCheck(int seconds)
{
fd_set set;
struct timeval timeout = {seconds, 0};
FD_ZERO(&set);
FD_SET(0, &set);
return select(1, &set, NU... | 2.53125 | 3 |
2024-11-18T19:14:08.100157+00:00 | 2020-09-23T16:20:59 | b542297b0f5846f6d8d1637c1448e00e7d072b66 | {
"blob_id": "b542297b0f5846f6d8d1637c1448e00e7d072b66",
"branch_name": "refs/heads/master",
"committer_date": "2020-09-23T16:20:59",
"content_id": "bbe26dcab0d470f2f69cd4ad8f493e35afe2076e",
"detected_licenses": [
"MIT"
],
"directory_id": "10287b76cd674e40be1cc4dde8749ae2adf8e7ee",
"extension": "c"... | stackv2 | /* Author: Dishank Goel
* Date written: 21st August 2020
*
* chmod.c implements the `chmod` command in UNIX without any options
* chmod is used to change permissions of a file
* Usage: chmod MODE FILE...
*/
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <string.h>
#include <sys/stat.h>
... | 3.4375 | 3 |
2024-11-18T19:14:08.211893+00:00 | 2018-03-20T11:12:08 | 401538384e3b7963be6a97b1859a10d1e46f978c | {
"blob_id": "401538384e3b7963be6a97b1859a10d1e46f978c",
"branch_name": "refs/heads/master",
"committer_date": "2018-03-20T11:12:08",
"content_id": "ef9c104dd2dda1dcaa0cd258c198cad4ddd3b5ff",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "ed675ee1295b12773b2cc4562df3b16e296ef2c6",
"extens... | stackv2 | #include "instruction.h"
#include "util.h"
void
inst_apply_actions(struct apply_actions *aa, struct action_list al)
{
aa->hdr.type = INSTRUCTION_APPLY_ACTIONS;
aa->actions = al;
}
void
inst_clear_actions(struct clear_actions *ca)
{
ca->hdr.type = INSTRUCTION_CLEAR_ACTIONS;
}
void
inst_write_actions(struc... | 2.296875 | 2 |
2024-11-18T19:38:42.143863+00:00 | 2023-08-09T13:42:00 | 06fa7b12cd3e5cc015539b931d244a98d5c3416d | {
"blob_id": "06fa7b12cd3e5cc015539b931d244a98d5c3416d",
"branch_name": "refs/heads/master",
"committer_date": "2023-08-09T13:55:42",
"content_id": "e4feedb0bbe257e6cffb9aec97674efbfe11af05",
"detected_licenses": [
"BSD-3-Clause",
"MIT",
"Apache-2.0"
],
"directory_id": "0ac5b8a6550769be58720d0... | stackv2 | /*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... | 2.015625 | 2 |
2024-11-18T19:38:42.293749+00:00 | 2023-09-01T08:20:15 | a3ac49105782fc4a21f327192a9a21cb1e7a504b | {
"blob_id": "a3ac49105782fc4a21f327192a9a21cb1e7a504b",
"branch_name": "refs/heads/master",
"committer_date": "2023-09-01T08:21:05",
"content_id": "2749a7fa6779279ff62c39eb7ffce9e942feb85d",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "820b6af9fd43b270749224bb278e5f714f655ac9",
"extens... | stackv2 | /*
* Copyright(C) 1999-2020 National Technology & Engineering Solutions
* of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with
* NTESS, the U.S. Government retains certain rights in this software.
*
* See packages/seacas/LICENSE for details
*/
#include "exodusII.h" // for ex_err, etc
#inclu... | 2.4375 | 2 |
2024-11-18T19:38:42.389111+00:00 | 2016-05-29T09:16:42 | 79dba5e208c3059d6da0a26ec4626a7b498e709b | {
"blob_id": "79dba5e208c3059d6da0a26ec4626a7b498e709b",
"branch_name": "refs/heads/master",
"committer_date": "2016-05-29T09:16:42",
"content_id": "a986bed57052acc3da961d908fa14a0b6c1397d3",
"detected_licenses": [
"NCSA"
],
"directory_id": "3d80d68564da1f1d650988a1fafe221d749cdc31",
"extension": "c... | stackv2 | // RUN: gcc -O2 -I../../../include -o %t1 %s
// RUN: ./%t1
//
#define __KLEE_H__
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include "../../runtime/mmu/shadow.h"
#define klee_assert(x) assert(x)
#define klee_min_value(x) x
#define klee_max_value(x) x
#define klee_assume_eq(x,y) asse... | 2.578125 | 3 |
2024-11-18T19:38:58.536287+00:00 | 2014-05-26T02:35:00 | a83469a9cec961e95148eb66965226eadef475fc | {
"blob_id": "a83469a9cec961e95148eb66965226eadef475fc",
"branch_name": "refs/heads/master",
"committer_date": "2014-05-26T02:35:00",
"content_id": "3814158d2df32e17abe200d5a2f65df7667ef2a3",
"detected_licenses": [
"MIT"
],
"directory_id": "ef8d2610613464d24e0ee2384bd82223180496f3",
"extension": "c"... | stackv2 | /* squelette.c */
/********************************************************************/
/* S Q U E L E T T E . C */
/* jean.fruitet@univ-mlv */
/*------------------------------------------------------------------*/
/* Squelettisat... | 2.90625 | 3 |
2024-11-18T19:39:53.599139+00:00 | 2021-03-15T12:05:44 | b372be8c662487e1ef346897a5917b331b990a4c | {
"blob_id": "b372be8c662487e1ef346897a5917b331b990a4c",
"branch_name": "refs/heads/main",
"committer_date": "2021-03-15T12:05:44",
"content_id": "fef6a475af0c712dd7f6343ec976eac289108739",
"detected_licenses": [
"BSD-2-Clause"
],
"directory_id": "6280c36ab5e3d3bf0dea7bcda6c0d46eea5e23f3",
"extensio... | stackv2 | #include <ngx_config.h>
#include <ngx_core.h>
#include <ngx_http.h>
#include "test_print.h"
typedef struct
{
ngx_int_t bidirection_switch;
} ngx_http_bidirection_loc_conf_t;
static ngx_int_t ngx_http_bidirection_filter_init(ngx_conf_t *cf);
// static ngx_int_t ngx_http_bidirection_filter(ngx_http_request_t *r);
s... | 2.3125 | 2 |
2024-11-18T19:51:59.007879+00:00 | 2018-01-26T21:42:19 | 86ecb6a5832057b6987097c82bcea58c75cf3ea2 | {
"blob_id": "86ecb6a5832057b6987097c82bcea58c75cf3ea2",
"branch_name": "refs/heads/master",
"committer_date": "2018-01-26T21:42:19",
"content_id": "932ca5fcc85e96b3136db31a0b2216e5b25f1f17",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "68435e25286e78615994480145000f44de540692",
"extens... | stackv2 | #include <stdio.h>
#include <math.h>
#include <freetype2/ft2build.h>
#include <freetype.h>
void mViewer_labeledCurve (char *face_path, int fontsize, int showLine,
double *xcurve, double *ycurve, int npt,
char *text, double offset,
... | 2.390625 | 2 |
2024-11-18T19:51:59.170150+00:00 | 2017-06-23T04:54:39 | dd654aa837396e7d8d6f6c3b48c02d40304dc74a | {
"blob_id": "dd654aa837396e7d8d6f6c3b48c02d40304dc74a",
"branch_name": "refs/heads/master",
"committer_date": "2017-06-23T04:54:39",
"content_id": "ef75e682f8bf3ef8a2760bcf10700dcc86356294",
"detected_licenses": [
"MIT"
],
"directory_id": "cd99dd1737e891aeee76902a38f293b2cebb397d",
"extension": "h"... | stackv2 | #ifndef _STACK_H_
#define _STACK_H_
#include <common.h>
typedef _DATA STACK_DATA;
typedef struct stack_node {
STACK_DATA data;
struct stack_node *next;
} STACK_NODE;
typedef struct stack {
STACK_NODE *head;
STACK_NODE *tail;
unsigned int size;
} STACK;
STACK *stack_create();
unsigned int stack... | 2.265625 | 2 |
2024-11-18T19:51:59.405957+00:00 | 2020-03-20T14:58:38 | 8151fc423279e4670f034a82074a05b5b176710a | {
"blob_id": "8151fc423279e4670f034a82074a05b5b176710a",
"branch_name": "refs/heads/master",
"committer_date": "2020-03-20T14:58:38",
"content_id": "9840f73e2e22106c5ad39cbbeba7a16a60b3ccad",
"detected_licenses": [
"MIT"
],
"directory_id": "5708eb23e3aead3420c0296bdcc7d9ecb62f4758",
"extension": "c"... | stackv2 | #include <stdio.h>
#include <assert.h>
#include <stdlib.h>
#include "testBmp.h"
#include "bmp.h"
static void testCreateBitMap ();
static void testAccessFunctions ();
static void testCompareChannels ();
static void testChannelAccessFunctions ();
static void testInitializeBmpDFLT ();
static void testMiscOps ();
static ... | 2.34375 | 2 |
2024-11-18T19:51:59.549047+00:00 | 2020-05-30T00:09:36 | 23f05271ecc659335381023abbbce636759cc182 | {
"blob_id": "23f05271ecc659335381023abbbce636759cc182",
"branch_name": "refs/heads/master",
"committer_date": "2020-05-30T00:09:36",
"content_id": "9e540ac03183652dae0f3903844f9cc8c6908b63",
"detected_licenses": [
"MIT"
],
"directory_id": "a86fff5ea47604837a8065978fadfdbe0e4769fc",
"extension": "h"... | stackv2 | #ifndef SYMBOL_TABLE_H
#define SYMBOL_TABLE_H
#include "structures.h"
//STRING ELEMENTS
typedef struct _sel{
char *string;
int tamanho;
int pos;
int printed;
struct _sel *next;
} string_element;
//VARIAVEIS DO METODO
typedef struct _tel{
char *name;
char *type;
int is_declared;
int is_param;
struct _tel *n... | 2.375 | 2 |
2024-11-18T20:13:48.588563+00:00 | 2023-05-31T23:22:47 | 02890c9969612fa50bd24889f5184c25406763c9 | {
"blob_id": "02890c9969612fa50bd24889f5184c25406763c9",
"branch_name": "refs/heads/main",
"committer_date": "2023-05-31T23:22:47",
"content_id": "a05594800c26bcfd56b64e9e033e8b8f8bf4bbf7",
"detected_licenses": [
"MIT"
],
"directory_id": "4a727ce379e9d21826895699d09164cdac4836d5",
"extension": "c",
... | stackv2 | #include <stdio.h>
#include <stdlib.h>
#include <pthread.h>
#include <unistd.h>
#define NUM_OXYGEN_THREADS 3
#define NUM_HYDROGEN_THREADS 6
void*
oxy_thread(void *arg)
{
printf("Oxygen thread arrived\n");
printf("Oxygen bonding...\n");
sleep(3);
return NULL;
}
void*
hydro_thread(void *arg)
{
pr... | 3.140625 | 3 |
2024-11-18T20:13:48.671263+00:00 | 2021-05-12T07:00:39 | 106e73e3b8d16add28ae34ad28c138bf19d8d06d | {
"blob_id": "106e73e3b8d16add28ae34ad28c138bf19d8d06d",
"branch_name": "refs/heads/master",
"committer_date": "2021-05-12T07:00:39",
"content_id": "16c4877d97f4811bc50535b6508e6affb61c812c",
"detected_licenses": [
"CC0-1.0"
],
"directory_id": "0741eeed19eda37d52f2abfe820ced26b1a1a67d",
"extension":... | stackv2 | /*
ID: ulysses4
LANG: C
PROG: template
*/
#include <stdio.h>
#include <string.h>
char PROG[] = "template";
void actualMain() {
// write programs here
}
int main() {
int size = sizeof(PROG);
char in[size + 3], out[size + 4];
freopen(strcat(strcpy(in, PROG), ".in"), "r", stdin);
freopen(strcat(strcpy(out, PROG), "... | 2.609375 | 3 |
2024-11-18T20:13:48.930467+00:00 | 2020-02-02T23:23:14 | 0f776d08085dc12cd347e6e819ce562062f4ab93 | {
"blob_id": "0f776d08085dc12cd347e6e819ce562062f4ab93",
"branch_name": "refs/heads/master",
"committer_date": "2020-02-02T23:23:14",
"content_id": "89f45a44eca38c2f1f6b5ce20ed163fb7788b6b7",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "00f7db8768c0fc6b52413aa588465a992f129aa9",
"extensio... | stackv2 | // SPDX-License-Identifier: Apache-2.0
// Copyright 2019 Charles University
#ifndef _MM_HEAP_H
#define _MM_HEAP_H
#include <types.h>
typedef struct mem_chunk {
size_t mem_amount;
size_t address;
} mem_chunk;
#define ARR_LENGTH 1800
#define UINT_MAX 1000000
typedef struct my_heap {
mem_chunk arr[ARR_LEN... | 2.375 | 2 |
2024-11-18T20:25:45.048686+00:00 | 2019-01-06T15:42:44 | a3de2bcfb2b34792874619cc6ebc36ce4886e8ec | {
"blob_id": "a3de2bcfb2b34792874619cc6ebc36ce4886e8ec",
"branch_name": "refs/heads/master",
"committer_date": "2019-01-06T15:42:44",
"content_id": "8b2cbd9f2f1e54e35fe7592fb0da3533b504f756",
"detected_licenses": [
"MIT"
],
"directory_id": "bd611f37f75fc61387e962d842d38afd16fe152c",
"extension": "c"... | stackv2 | /***********************************************************************************************************************************
IO Functions
***********************************************************************************************************************************/
#include "common/assert.h"
#include "comm... | 2.359375 | 2 |
2024-11-18T20:25:45.335195+00:00 | 2020-06-10T10:12:06 | 4ab221397d319ad0f92e60dd4dff3a85a54369fe | {
"blob_id": "4ab221397d319ad0f92e60dd4dff3a85a54369fe",
"branch_name": "refs/heads/master",
"committer_date": "2020-06-10T10:12:06",
"content_id": "f42fd4234058e3716fd603c94404fade7263dc9d",
"detected_licenses": [
"MIT"
],
"directory_id": "9a533526e3b65ab6b996900a56129b3e519cbcba",
"extension": "c"... | stackv2 | #include "min_heap.h"
#include <stdio.h>
void min_heapify(P_Queue* q, Node i) {
Node l = left_child(*q, i);
Node r = right_child(*q, i);
Node smallest = i;
if (l < q->size && q->keys[l].priority < q->keys[i].priority)
smallest = l;
if (r < q->size && q->keys[r].priority < q->keys[smallest]... | 3.515625 | 4 |
2024-11-18T20:25:45.412189+00:00 | 2023-04-04T03:02:47 | a8d6cac22e9dc4313940819ecb8d7f7f2016f9c4 | {
"blob_id": "a8d6cac22e9dc4313940819ecb8d7f7f2016f9c4",
"branch_name": "refs/heads/master",
"committer_date": "2023-04-04T03:02:47",
"content_id": "3c1285ac9a7fb391a885c3ea492823a8940708f8",
"detected_licenses": [
"MIT"
],
"directory_id": "fe8942af9cb004c7d91c12845fc7c08c9087aee6",
"extension": "c"... | stackv2 | #include "IO.h"
#include <stdlib.h>
#include <string.h>
#include <stdarg.h>
void io_print_none(struct IO *const io, const char *const format, va_list args)
{
(void)io;
(void)format;
(void)args;
}
void io_print_file(struct IO *const io, const char *const format, va_list args)
{
vfprintf(io->file, format, args);
}... | 2.59375 | 3 |
2024-11-18T20:26:15.537920+00:00 | 2020-08-02T20:23:15 | d452ba0584630f6cab466e604821a84689cd6bd3 | {
"blob_id": "d452ba0584630f6cab466e604821a84689cd6bd3",
"branch_name": "refs/heads/master",
"committer_date": "2020-08-02T20:23:15",
"content_id": "03ea6629a6684644183fc55ea92084a78840b394",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "971e9cb164ca5ca8bcc1b1da4d758b5e958d3c0f",
"extens... | stackv2 | /*
functions common to all hash table instantiations
*/
#include <assert.h>
#include <limits.h>
#include <math.h>
#include <setjmp.h>
#include <stdarg.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "scheme.h"
struct htable *htable_new(struct htable *h, size_t size)
{
... | 2.6875 | 3 |
2024-11-18T20:37:13.989658+00:00 | 2021-01-04T16:27:58 | c8766f8df72c10fd85a2b2fd25d9a1dd0d27a82d | {
"blob_id": "c8766f8df72c10fd85a2b2fd25d9a1dd0d27a82d",
"branch_name": "refs/heads/master",
"committer_date": "2021-01-04T16:27:58",
"content_id": "77d2ca4ca0ecb45382268f5414e69108ffb58b14",
"detected_licenses": [
"MIT"
],
"directory_id": "0d7caef3f04c62d53ebd51902ecfd16c3fe8d17b",
"extension": "h"... | stackv2 | #ifndef _SPRITE_H_
#define _SPRITE_H_
#include <lcom/lcf.h>
#include <stdbool.h>
#include <stdint.h>
#include "graphics.h"
#include "queue.h"
/** A Sprite is an "object" that contains all needed information to
* create, animate, and destroy a pixmap. The functions assume that
* the background is BLACK and they t... | 2.484375 | 2 |
2024-11-18T20:37:14.126294+00:00 | 2019-01-16T02:40:27 | 1e96b06c548430758b7742c0a803b854a08c4cbe | {
"blob_id": "1e96b06c548430758b7742c0a803b854a08c4cbe",
"branch_name": "refs/heads/master",
"committer_date": "2019-01-16T02:40:27",
"content_id": "7ca42dbed9417b5a66bffa78cc83657ae5d0bd54",
"detected_licenses": [
"MIT"
],
"directory_id": "92ed4ee02cc093f80cd60b0a46e07f83f3d2d97e",
"extension": "c"... | stackv2 | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* draw.c :+: :+: :+: ... | 2.9375 | 3 |
2024-11-18T20:37:14.320863+00:00 | 2021-10-01T15:13:25 | eea96d89f01156541012cbd53ba0bc5a4bc48f56 | {
"blob_id": "eea96d89f01156541012cbd53ba0bc5a4bc48f56",
"branch_name": "refs/heads/main",
"committer_date": "2021-10-01T15:13:25",
"content_id": "14bff185cc902bff94e3b1f5892fb53f4b0f78d6",
"detected_licenses": [
"MIT"
],
"directory_id": "ead9e57130b285d2071b5d606de28f34510134a2",
"extension": "c",
... | stackv2 | #include <stdio.h>
#include <stdlib.h>
typedef struct node Node;
struct node {
int data;
Node *prev;
Node *next;
};
int dequeue(Node **head, Node **tail) {
int val = (*tail)->data;
if (*head == *tail) {
free(*tail);
*head = NULL;
*tail = NULL;
} else {
Node *pr... | 3.640625 | 4 |
2024-11-18T20:46:44.086388+00:00 | 2014-09-15T17:20:46 | 42c3852a7da01feda0aa002246287df53ee66631 | {
"blob_id": "42c3852a7da01feda0aa002246287df53ee66631",
"branch_name": "refs/heads/master",
"committer_date": "2014-09-15T17:20:46",
"content_id": "32aee992d0bf86e98607bdadde6dbc36078a3630",
"detected_licenses": [
"MIT"
],
"directory_id": "fb256e7dbe62b40196c1150350ee3f8b21eda35b",
"extension": "c"... | stackv2 | #include "gc_timer.h"
// TODO: This struct should probably have a better API for distiguishing major/
// minor GC phases for a real implementation.
typedef struct {
int started;
int total_time;
int count;
} gc_timer_t;
VALUE rb_cGCTimer;
VALUE timers_array;
#ifdef RUBY_INTERNAL_EVENT_GC_START
#include "r... | 2.28125 | 2 |
2024-11-18T20:46:45.650989+00:00 | 2020-12-30T09:40:30 | a17c9512648e9c9b3976efbb1c65d8916133f567 | {
"blob_id": "a17c9512648e9c9b3976efbb1c65d8916133f567",
"branch_name": "refs/heads/main",
"committer_date": "2020-12-30T09:40:30",
"content_id": "188c92b6bcf209f8e8cda15c1d248b68562e5df0",
"detected_licenses": [
"MIT"
],
"directory_id": "6eced55e71fdfc1ab75b74ec41db2a11f4b8ecce",
"extension": "c",
... | stackv2 | //
// Created by silvi on 29/12/2020.
//
#include "unidirectionalLinkedList.h"
#include <stdio.h>
#include <stdlib.h>
void init(struct unidirectionalLinkedList **ptr) {
ptr = NULL;
}
void preInsert(struct unidirectionalLinkedList **ptr, float value) {
struct unidirectionalLinkedList *tmp;
tmp = *ptr... | 3.3125 | 3 |
2024-11-18T18:48:21.908947+00:00 | 2018-07-09T17:59:30 | e099064b2d2b18f6acb3980c70f4c62c2f9a058d | {
"blob_id": "e099064b2d2b18f6acb3980c70f4c62c2f9a058d",
"branch_name": "refs/heads/master",
"committer_date": "2018-07-09T17:59:30",
"content_id": "ef18046edffd719275703c4e300005d65fb4690c",
"detected_licenses": [
"Unlicense"
],
"directory_id": "a6abc214f9e4567145aa828500a8869a826a45b8",
"extension... | stackv2 | /* ************************************************************************** */
/* */
/* ::: :::::::: */
/* tester.c :+: :+: :+: ... | 2.921875 | 3 |
2024-11-18T18:58:31.243784+00:00 | 2020-12-12T22:25:57 | 64b7899c32b93062b55f70898774f31940010152 | {
"blob_id": "64b7899c32b93062b55f70898774f31940010152",
"branch_name": "refs/heads/master",
"committer_date": "2020-12-12T22:25:57",
"content_id": "9af0272391f021e306b3f0a57c841de6796fea0d",
"detected_licenses": [
"MIT"
],
"directory_id": "6a26a6a254d667ca10bb4633b45f005e52b29325",
"extension": "c"... | stackv2 | /* SPDX-License-Identifier: MIT */
#include "efika/core.h"
#include "efika/core/blas.h"
/*----------------------------------------------------------------------------*/
/*! Dot product of a sparse vector x in compressed-vector storage mode and a
* sparse vector y in full-vector storage mode. */
/*------------------... | 2.421875 | 2 |
2024-11-18T19:25:16.218727+00:00 | 2023-08-24T07:58:02 | 4447c7d71b175a0dd33a7d2656c7ea649db2b50e | {
"blob_id": "4447c7d71b175a0dd33a7d2656c7ea649db2b50e",
"branch_name": "refs/heads/master",
"committer_date": "2023-08-24T07:58:02",
"content_id": "8d41f00438d787c8df279d91f7fe286a7878ee01",
"detected_licenses": [
"MIT"
],
"directory_id": "cb9ffece95cef31e363b55d9e07e21cc22a446eb",
"extension": "c"... | stackv2 | /* -*- coding: utf-8; tab-width: 8; indent-tabs-mode: t; -*- */
/*
* Suika 2
* Copyright (C) 2001-2023, TABATA Keiichi. All rights reserved.
*/
/*
* [Changes]
* - 2021/06/12 作成
* - 2023/01/06 日本語の指定に対応
*/
#include "suika.h"
#define INVALID_MOVE_TYPE (0)
#define PI (3.1415926f)
enum shake_move_type {
SHA... | 2.5625 | 3 |
2024-11-18T19:25:16.416241+00:00 | 2019-12-04T19:29:09 | f02e3c65b6323f1acaed34766b8f907da2b4ff2d | {
"blob_id": "f02e3c65b6323f1acaed34766b8f907da2b4ff2d",
"branch_name": "refs/heads/master",
"committer_date": "2019-12-04T19:29:09",
"content_id": "aa46e0888eaa1e46bec525325b041870cff04862",
"detected_licenses": [
"MIT"
],
"directory_id": "200011f21a47553a2104c441fbada6857ed1239c",
"extension": "h"... | stackv2 | /*
* Base64 Encoder/Decoder C Routines
* <https://github.com/mattbucknall/json>
*
* Copyright (c) 2019 Matthew T. Bucknall
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without re... | 2.03125 | 2 |
2024-11-18T19:25:16.559513+00:00 | 2019-11-18T15:09:21 | 225afd91266035f48b0983b2c6126bcc51ee9145 | {
"blob_id": "225afd91266035f48b0983b2c6126bcc51ee9145",
"branch_name": "refs/heads/master",
"committer_date": "2019-11-18T15:09:21",
"content_id": "f6d3308f6987230cf7489f1143657347b305e4ea",
"detected_licenses": [
"MIT"
],
"directory_id": "84ef5d7b0a3b55225689e021bd9f27440f252ac4",
"extension": "c"... | stackv2 | #include "person.h"
static struct person htc = {
.name = "hongtaoC",
.id = "123456123456781234",
};
struct person * get_person_info(){
return &htc;
}
| 2.03125 | 2 |
2024-11-18T19:25:42.908779+00:00 | 2014-10-15T14:44:43 | 23c60afe38c22e145d7b994b989d29c54f553a36 | {
"blob_id": "23c60afe38c22e145d7b994b989d29c54f553a36",
"branch_name": "refs/heads/master",
"committer_date": "2014-10-15T14:44:43",
"content_id": "2bd2a52639509e9b6a8987584a1da62420a45d75",
"detected_licenses": [
"MIT"
],
"directory_id": "b0806bdd1b32be5d5bd7a91b5e2eb81e5fafc539",
"extension": "c"... | stackv2 |
// http://en.wikipedia.org/wiki/Rabin%E2%80%93Karp_algorithm
#include <assert.h>
#include <fcntl.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <sys/stat.h>
#include <sys/time.h>
#include <sys/types.h>
#include <sys/uio.h>
#include <time.h>
#include <unistd.h>
static uint64_t chunks;
stat... | 3.0625 | 3 |
2024-11-18T19:25:43.542296+00:00 | 2016-05-12T04:16:32 | afcfcc8703b5575163fb8528aa85af53bb233e23 | {
"blob_id": "afcfcc8703b5575163fb8528aa85af53bb233e23",
"branch_name": "refs/heads/master",
"committer_date": "2016-05-12T04:16:32",
"content_id": "1de7d862ed5e9e5e3ce51155af5a81035f70cb69",
"detected_licenses": [
"MIT"
],
"directory_id": "e0815a8a894680859a8783a10080a1c76fce1911",
"extension": "c"... | stackv2 | #pragma config(I2C_Usage, I2C1, i2cSensors)
#pragma config(Sensor, I2C_1, rightIEM, sensorQuadEncoderOnI2CPort, , AutoAssign )
#pragma config(Sensor, I2C_2, leftIEM, sensorQuadEncoderOnI2CPort, , AutoAssign )
#pragma config(Motor, port1, rightMotor, tmotorVex393_HBridge, openLoop, enc... | 2.65625 | 3 |
2024-11-18T19:25:43.599844+00:00 | 2017-01-29T10:57:04 | df3bc017f0de0c1df1f5bb26df752f5d290e2f90 | {
"blob_id": "df3bc017f0de0c1df1f5bb26df752f5d290e2f90",
"branch_name": "refs/heads/master",
"committer_date": "2017-01-29T10:57:04",
"content_id": "415fd5e404f8406c9e6918be584a200ba40c70ad",
"detected_licenses": [
"MIT"
],
"directory_id": "ca47a0ab65680aea00e53c3ef541dd0cdb2e304c",
"extension": "h"... | stackv2 | /* Define function's */
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
// #define MAXBUFF (3200*2400*4) /* 30 MB, covers 3200x2400x4 (32bits) : Matrox HD cards (single headed) */
/* Helper macros to make the code lighter, more readable and more maintainable */
/*
#define EXDL_POP_DATA(t) ((... | 2.140625 | 2 |
2024-11-18T19:25:43.687900+00:00 | 2021-03-11T19:16:36 | 1fce50b1c49feeba3a2746944407f26b10a1fbc1 | {
"blob_id": "1fce50b1c49feeba3a2746944407f26b10a1fbc1",
"branch_name": "refs/heads/master",
"committer_date": "2021-03-11T19:16:36",
"content_id": "fcaa6d01a8c4b8238e57b60301b12d2cc6f764c7",
"detected_licenses": [
"MIT"
],
"directory_id": "5e9045a24fda7cdfeb83f9234c2ab1579dd6dd95",
"extension": "c"... | stackv2 | #include "GERazerUtils.h"
CFStringRef GERazerStringCreateFromInt(SInt32 value)
{
return CFStringCreateWithFormat(kCFAllocatorDefault, NULL, CFSTR("%d"), value);
}
void GERazerDictionaryRecursivelyMergeDictionary(CFMutableDictionaryRef mutableDictionary, CFDictionaryRef dictionary2)
{
CFTypeID dictionaryTypeId = CFD... | 2.640625 | 3 |
2024-11-18T19:26:33.536733+00:00 | 2017-06-20T04:09:36 | 6d0b20403ff15c448b55b9b6fea584459690790c | {
"blob_id": "6d0b20403ff15c448b55b9b6fea584459690790c",
"branch_name": "refs/heads/master",
"committer_date": "2017-06-20T04:09:36",
"content_id": "cb5fc257407e8d1877913c2d34e9ba1e43eb12fb",
"detected_licenses": [
"MIT"
],
"directory_id": "854abadcd9dd731607aa130d15add6d3e6cf5cf5",
"extension": "c"... | stackv2 | /*
* Timer setup and run functions
*
* Author: Tyler Holmes (tyler@holmesengineering.com)
* Date: 1/21/2016
*/
#include <stdint.h>
#include "MKL03Z4.h"
#include "hardware.h"
#include "fsl_lptmr.h"
#include "fsl_gpio.h"
#include "fsl_common.h" // has USEC_TO_COUNT macro
//#include "pin_mux.h"
#include "clock... | 2.578125 | 3 |
2024-11-18T19:26:33.628498+00:00 | 2019-03-01T05:16:46 | 398b1876f5a2b87a573b93db611ee9198fcee1e0 | {
"blob_id": "398b1876f5a2b87a573b93db611ee9198fcee1e0",
"branch_name": "refs/heads/master",
"committer_date": "2019-03-01T05:16:46",
"content_id": "42ec7f72cb54917bec7595894dfe08acb4819d6a",
"detected_licenses": [
"MIT"
],
"directory_id": "5a17a3d150c4773318d397a46878d2fd74c0671f",
"extension": "c"... | stackv2 | // 書房 shufang.c
#include <ansi.h>
inherit ROOM;
void create()
{
set("short", "書房");
set("long", @LONG
這裏是胡青牛的書房,靠牆邊有個大書櫃,一排一排的書架上分
門別類地擺放着各種各樣的醫學書籍,連失傳已久的《黃帝蝦嫫經》、
《西方子明堂灸經》、《太平聖惠方》、《灸甲乙經》、《千金方》、
《此事難知》也在其中,書櫃正對着一個書桌,上面擺放着一個筆筒,
筆筒旁邊擱着一本打開的書。
LONG );
set("exits", ([
"west" : __DI... | 2 | 2 |
2024-11-18T19:26:33.818609+00:00 | 2015-12-02T21:42:30 | da71a0ece01baed863f72a4e1e5bcfc6728613fc | {
"blob_id": "da71a0ece01baed863f72a4e1e5bcfc6728613fc",
"branch_name": "refs/heads/master",
"committer_date": "2015-12-02T21:42:30",
"content_id": "9be180b723f1bb7e53589c9a53d562a2c9ac8050",
"detected_licenses": [
"MIT"
],
"directory_id": "97b470b259e889609194b3274c1fbdc6d1905703",
"extension": "c"... | stackv2 | /*
* Find the sums of all ordered N-digit six-tuples of polygonals (triangle to octagon) that are 2-digit cyclical
*/
#include <stdio.h>
#include <stdlib.h>
#include "math_utils.h"
#include "linked_list.h"
#define POLY_COUNT 6
typedef long (* poly_func_t) (void);
static poly_func_t polygonal_functions[] = {
next... | 3.328125 | 3 |
2024-11-18T19:27:14.962871+00:00 | 2018-06-19T22:41:46 | 35cd9cc070333ffebad76882ce841f034ac31cb1 | {
"blob_id": "35cd9cc070333ffebad76882ce841f034ac31cb1",
"branch_name": "refs/heads/master",
"committer_date": "2018-06-19T22:41:46",
"content_id": "0e339de54c992a6ef3b4eead6d9a7b51f1f542f6",
"detected_licenses": [
"ISC"
],
"directory_id": "ecf43a659126ec6d1a2bfaa30138fe557cbaaa8b",
"extension": "c"... | stackv2 | #include "handling.h"
int open_uart(void)
{
int file = 0;
file = open(pathes.hardware_Path,O_RDWR);
printf("open Uart fd:\t%d\n",file);
return file;
}
void close_uart(int fd)
{
close(fd);
}
int send_byte(int file ,char buffer)
{
int bytes = 0;
//printf("write\t%c\n",buffer);
bytes = w... | 2.328125 | 2 |
2024-11-18T19:27:15.027636+00:00 | 2018-06-25T19:42:42 | 124a748cb348cf14793ff742db1cf140ef03b454 | {
"blob_id": "124a748cb348cf14793ff742db1cf140ef03b454",
"branch_name": "refs/heads/master",
"committer_date": "2018-06-25T19:42:42",
"content_id": "552cc933271d0654d4911db5240561f27974910e",
"detected_licenses": [
"MIT"
],
"directory_id": "b3a620e4e30a715a1eb40a8bb89f58035fda4161",
"extension": "h"... | stackv2 | #ifndef T
#error You must define T before include macro_array.h
#endif
#include <stdlib.h>
#include <assert.h>
#define _CAT2(x,y) x##y
#define CAT2(x,y) _CAT2(x,y)
#define TArray CAT2(T,Array)
#define TArray_ CAT2(T,Array_)
typedef struct TArray_ TArray;
struct TArray_ {
int capacity;
int size;
T* values;
};
#... | 2.65625 | 3 |
2024-11-18T19:27:15.082921+00:00 | 2017-11-24T01:18:18 | e36d9c50310678a69e6bf5884ff00fa9e8020097 | {
"blob_id": "e36d9c50310678a69e6bf5884ff00fa9e8020097",
"branch_name": "refs/heads/master",
"committer_date": "2017-11-24T01:18:18",
"content_id": "694e282d6ca0ff1ddfe17849d216ceb12296182b",
"detected_licenses": [
"MIT"
],
"directory_id": "db2406659c2df9f8b411e0ea8afa9efb85c73cc7",
"extension": "c"... | stackv2 | #include "pathfinder.h"
#define I2CTIMEOUT 50 // 50 ticks of 50Hz is 1 second
uint8_t timeout = 0;
void init(void){
/* pins
* PB0 ASLP
* PB1 OC1A Servo1
* PB2 OC1B Servo2
* PB3 OC2A AIN1
* PD3 OC2B AIN2
* PD5 OC0B BIN2
* PD6 OC0A BIN1
* PD7 BSLP
*
* PC4 SDA
* PC5 SCL
*
* PC0 PC1 PC2 PC3 are misc GPIO pins defined... | 2.390625 | 2 |
2024-11-18T19:49:02.603222+00:00 | 2019-05-07T15:08:27 | 6d13e2501c4b36d55ff6c96ea6777d2338cda2ab | {
"blob_id": "6d13e2501c4b36d55ff6c96ea6777d2338cda2ab",
"branch_name": "refs/heads/master",
"committer_date": "2019-05-07T15:08:27",
"content_id": "b4ea8079c1c9fc421fb66cea4fe6710b79fa196e",
"detected_licenses": [
"MIT"
],
"directory_id": "25e76410612348be2a25dd172003f3fb6ec41ab1",
"extension": "c"... | stackv2 | /*
** BillyScene, 2018
** textfield_set_focus
** File description:
** bs_textfield_set_focus
*/
#include "bs_components.h"
#include "bs_prototypes.h"
#include <stdbool.h>
/**
* @brief Set Focus to textfield
*
* @param textfield
* @param is_focus
*/
bool bs_textfield_set_focus(bs_textfield_t *textfield, bool is_... | 2.46875 | 2 |
2024-11-18T19:49:02.762243+00:00 | 2020-06-30T23:57:45 | ecafebf6c650db8ddd507544835088ce6bccbb62 | {
"blob_id": "ecafebf6c650db8ddd507544835088ce6bccbb62",
"branch_name": "refs/heads/master",
"committer_date": "2020-06-30T23:57:45",
"content_id": "42d7099b8313705c314d5b922b7f62a39b2dd5c4",
"detected_licenses": [
"MIT"
],
"directory_id": "ed5212f4fade616f067f499794892f6fb0e29f5c",
"extension": "c"... | stackv2 | #include "module/heap.h"
#include "module/user.h"
#include "module/tasking.h"
#include "api/message.h"
#include "kernel/modloader.h"
#include "kernel/logging.h"
#include "kernel/io.h"
int message_push(message_buffer_t *buf, message_t *msg){
buf->buffer[buf->tail] = msg;
buf->tail++;
if(buf->tail >= MSG_M... | 2.265625 | 2 |
2024-11-18T19:49:02.873027+00:00 | 2014-11-20T13:40:21 | a2d687361904383127185492a36cc3b0b5df72fa | {
"blob_id": "a2d687361904383127185492a36cc3b0b5df72fa",
"branch_name": "refs/heads/master",
"committer_date": "2014-11-20T13:40:21",
"content_id": "397b7ba8edb9622b866fa6c94ec22c15394604f8",
"detected_licenses": [
"MIT"
],
"directory_id": "f6d698b626f5e4f439a596384b8c677265385b33",
"extension": "h"... | stackv2 | #ifndef _LENVIEW_H_
#define _LENVIEW_H_
#ifdef __APPLE__
#include <GLUT/glut.h>
#else
#include <GL/glut.h>
#endif
//#pragma comment( lib, "opengl32.lib" )
//#pragma comment( lib, "glu32.lib" )
#pragma comment( lib, "glut32.lib" )
#define BGR 1.0f
#define BGG 1.0f
#define BGB 1.0f
#define LVW 770
#define LVH 480
#def... | 2.203125 | 2 |
2024-11-18T19:49:22.576131+00:00 | 2019-05-12T17:52:25 | eba31c3dd550dfe23ccac52f061c9f44aab9345d | {
"blob_id": "eba31c3dd550dfe23ccac52f061c9f44aab9345d",
"branch_name": "refs/heads/master",
"committer_date": "2019-05-12T17:52:25",
"content_id": "1bf4babac1d7231ccbdf369599f3720e6f7fb475",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "0e51646082f3703363b843d79c1d960c2ab13ed1",
"extensio... | stackv2 | /*
read a line of text and display in reverse*/
#include <stdio.h>
#include <string.h>
int main() {
char str[30];
int size;
printf("Enter a text: ");
scanf("%[^\n]", str);
size = strlen(str);
while (size--) {
printf("%c", str[size]);
}
} | 3.046875 | 3 |
2024-11-18T19:49:22.794108+00:00 | 2015-06-30T20:23:05 | 3baf853d410cf410ea2de02e506f8d20628407ad | {
"blob_id": "3baf853d410cf410ea2de02e506f8d20628407ad",
"branch_name": "refs/heads/master",
"committer_date": "2015-06-30T20:23:05",
"content_id": "311d4142d06173add39f3be8f5bc4f60977d6720",
"detected_licenses": [
"Intel"
],
"directory_id": "73b5d880fa06943c20ff0a9aee9d0c1d1eeebe10",
"extension": "... | stackv2 | #include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <netdb.h>
#include <unistd.h>
#include <errno.h>
#include <stdlib.h>
#include <string.h>
#include "sfsource.h"
uint32_t platform;
int saferead(int fd, void *buffer, int count)
{
int actual = 0;
while (count > 0)
{
int n = ... | 2.796875 | 3 |
2024-11-18T19:49:22.960018+00:00 | 2023-08-30T08:51:45 | b407fb50b1768013b32bfa36d111a9fa83ca9c32 | {
"blob_id": "b407fb50b1768013b32bfa36d111a9fa83ca9c32",
"branch_name": "refs/heads/master",
"committer_date": "2023-08-30T09:26:56",
"content_id": "e4adc1a8fb0ff7f98e607225356eee56691820ca",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "f5324faf087a512f15fe7ccefc1e61f609a5e9fa",
"extensio... | stackv2 | /*
* Copyright (c) 2021 SK Telecom Co., Ltd. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless requir... | 2.265625 | 2 |
2024-11-18T19:49:40.109831+00:00 | 2023-07-11T23:06:35 | 948b3b10429a6788f2c75352795581b5bfeba213 | {
"blob_id": "948b3b10429a6788f2c75352795581b5bfeba213",
"branch_name": "refs/heads/master",
"committer_date": "2023-07-11T23:06:35",
"content_id": "959d065e28badc924b77bc9931711f011a0da0a6",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "26bc498c752e59b3954113ca856e5807364c135e",
"extensio... | stackv2 | /*
-------------------------------------------------------------------------
OBJECT NAME: func.c
FULL NAME:
DESCRIPTION: Template for AMLIB std & user directories.
COPYRIGHT: University Corporation for Atmospheric Research, 1995, 1998
-------------------------------------------------------------------------
*/
... | 2.1875 | 2 |
2024-11-18T19:49:41.838922+00:00 | 2014-03-09T20:42:03 | e9e99db82cef14644eb39c7c30e20b1d988a7855 | {
"blob_id": "e9e99db82cef14644eb39c7c30e20b1d988a7855",
"branch_name": "refs/heads/master",
"committer_date": "2014-03-09T20:42:03",
"content_id": "b8473374ae84b5286d0c4eff2e75c36fc9ee3ba9",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "eb2bd105c22b3fc4e9abd1813ff1c25a5c153eac",
"extens... | stackv2 | /* ========================================================================= */
/* ------------------------------------------------------------------------- */
/*!
\file utils_version.h
\date September 2013
\author TNick
*//*
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Ple... | 2.3125 | 2 |
2024-11-18T19:49:41.913763+00:00 | 2017-11-06T03:29:53 | 81521e73d85c5eeedecb15d40023f10d7dcbc8a2 | {
"blob_id": "81521e73d85c5eeedecb15d40023f10d7dcbc8a2",
"branch_name": "refs/heads/master",
"committer_date": "2017-11-06T03:31:11",
"content_id": "f3b64526f8f89239d27178f6ee22d41e370863f8",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "e8fae11d39451210d80ef43edd73bb3acb421e4a",
"extensio... | stackv2 | #define NETMAP_WITH_LIBS
#include <net/netmap_user.h>
#include <poll.h>
#include <stdio.h>
#include <string.h>
#include <netinet/ether.h>
#include <arpa/inet.h>
#include <sys/time.h>
#include "test.h"
void sender(void)
{
struct nm_desc *d;
char data[1024];
struct pollfd pfd;
memset(data, 'a', 1024);
/**
* O... | 2.59375 | 3 |
2024-11-18T19:49:42.144242+00:00 | 2019-07-03T06:22:28 | 4ba124dd17d3adb85b84082a18fe418f9109189b | {
"blob_id": "4ba124dd17d3adb85b84082a18fe418f9109189b",
"branch_name": "refs/heads/master",
"committer_date": "2019-07-03T06:22:28",
"content_id": "a3d9b5a89ecbaeeecac8b8f78bd91f53aaa4dd8e",
"detected_licenses": [
"MIT"
],
"directory_id": "3db2607e15d6c4aff743a1bc428d875c2f7f8452",
"extension": "c"... | stackv2 | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <semaphore.h>
#include <fcntl.h>
#include <time.h>
#include <unistd.h>
#include <sys/stat.h>
#include <sys/mman.h>
#define SHARED_MEMORY_SIZE 536870912
#define BUFFER_SIZE 16384
int main(int argc, char* argv[]){
clock_t Begin=cl... | 2.578125 | 3 |
2024-11-18T20:01:21.397085+00:00 | 2019-10-06T06:30:41 | e28d350cc94273f99759c34c246048716edf47b1 | {
"blob_id": "e28d350cc94273f99759c34c246048716edf47b1",
"branch_name": "refs/heads/master",
"committer_date": "2019-10-06T06:30:41",
"content_id": "ef650e4eb958f1ddc22a9fb192dc23d8e0ea1cd1",
"detected_licenses": [
"MIT"
],
"directory_id": "180c1a81f28a0d633faf478d374c78bc2366bbb8",
"extension": "h"... | stackv2 | #ifndef __LCD_H
#define __LCD_H
#ifdef __cplusplus
extern "C"{
#endif
#include "stdint.h"
#include "stdbool.h"
typedef enum{
LCD_ERROR_NONE = 0,
LCD_ERROR_RESOURCE_BUSY = 1,
LCD_ERROR_INVALID_PARAMETER = 2
}LCD_Error_t;
// ================================================================... | 2.328125 | 2 |
2024-11-18T20:01:21.584156+00:00 | 2014-04-09T17:50:37 | 97f8be95c87ac30b39c1f58e979e54bfc9cff731 | {
"blob_id": "97f8be95c87ac30b39c1f58e979e54bfc9cff731",
"branch_name": "refs/heads/master",
"committer_date": "2014-04-09T17:50:37",
"content_id": "998772ec7f365ea2d031473ca508f45c25f5f58b",
"detected_licenses": [
"Artistic-2.0"
],
"directory_id": "5b88fee4c71fc518ed65437ecab407da268bb87b",
"extens... | stackv2 | #ifndef ELM_WIDGET_BOX_H
#define ELM_WIDGET_BOX_H
#include "Elementary.h"
/**
* @addtogroup Widget
* @{
*
* @section elm-box-class The Elementary Box Class
*
* Elementary, besides having the @ref Box widget, exposes its
* foundation -- the Elementary Box Class -- in order to create
* other widgets which are a... | 2.109375 | 2 |
2024-11-18T20:01:21.691937+00:00 | 2020-05-13T14:47:52 | 3dc728fd1f628305e515593e60b3d6019d491cd6 | {
"blob_id": "3dc728fd1f628305e515593e60b3d6019d491cd6",
"branch_name": "refs/heads/master",
"committer_date": "2020-05-13T14:47:52",
"content_id": "38d08d606d1a35fd1e89f4fb7a817c19de885c88",
"detected_licenses": [
"BSD-3-Clause"
],
"directory_id": "e8efe55ccc28c7d50b02f377ea43518b0197a1eb",
"extens... | stackv2 |
#include "MyTimer.h"
#include "CodeurIncremental.h"
#include "stm32f103xb.h"
#include "stm32f1xx_ll_tim.h"
#include "stm32f1xx_ll_gpio.h"
#include "RFtelecommande.h"
#include "stm32f1xx_ll_bus.h"
void GPIOB_pb6_pb7_Config (void) {
LL_APB2_GRP1_EnableClock(LL_APB2_GRP1_PERIPH_GPIOB);
LL_GPIO_SetPinPull(GPIOB, LL_GP... | 2.296875 | 2 |
2024-11-18T20:01:21.762396+00:00 | 2014-01-23T15:47:46 | d29cc53409ae930bc8ac649e7edb1a82ee5a2843 | {
"blob_id": "d29cc53409ae930bc8ac649e7edb1a82ee5a2843",
"branch_name": "refs/heads/master",
"committer_date": "2014-01-23T15:47:46",
"content_id": "98136e6c804429930e50a1a982689d70a92bdd7f",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "0bd83c7ba5abeb2d6d5195a9ce030699ba8f5925",
"extensio... | stackv2 | /* embedded_coms_boost.c
*
* Author: Skeleton code by Steve Gunn & Klaus-Peter Zauner. Modified by jgn1g13
* Licence: This work is licensed under the Creative Commons Attribution License.
* View this license at http://creativecommons.org/about/licenses/
* Notes:
* - Use with boost_converte... | 2.5625 | 3 |
2024-11-18T20:12:32.145496+00:00 | 2016-09-16T22:10:34 | f7b18cef98720b621b4086f4a6a8c6e903232011 | {
"blob_id": "f7b18cef98720b621b4086f4a6a8c6e903232011",
"branch_name": "refs/heads/master",
"committer_date": "2016-09-16T22:10:34",
"content_id": "21cbb184000303809f96b311a83033104749917f",
"detected_licenses": [
"MIT"
],
"directory_id": "23289bf207465cd9d203f62b2dba06d00a5929b2",
"extension": "h"... | stackv2 | #include "HardwareSerial.h"
// Arduino core code limits serial buffer size to 64. Increasing it requires more than changing the define.
#define BUFFER_SIZE 64
#define NaN 0x7FFFFFFF
#define MSG_NONE 0
#define MSG_DRIVE 1
#define MSG_SENSOR 2
#define MSG_GOAL 3
#define MSG_SEG 4
// The following list outlines the data... | 2.21875 | 2 |
2024-11-18T20:12:32.400559+00:00 | 2015-09-10T12:21:47 | c96f507d0d01b359d80c61e5d22bf8c97a82cd1b | {
"blob_id": "c96f507d0d01b359d80c61e5d22bf8c97a82cd1b",
"branch_name": "refs/heads/master",
"committer_date": "2015-09-10T12:21:47",
"content_id": "d3a99ed51f70b66d165702f04d251bc09f20379e",
"detected_licenses": [
"MIT"
],
"directory_id": "520bf7676a04d8a2d379bb11292c864a631dd59d",
"extension": "c"... | stackv2 | #include <ic_stdc.h>
/* MS uses here a linear congruential scheme. The function is multiplying and
adding to a number, which is taken module 2^32, and returning the upper
16 bit as "random" number.
Because it is multiplying and adding numbers, which are coprime to the
modulus, this creates a sort of unifor... | 2.390625 | 2 |
2024-11-18T20:25:27.360849+00:00 | 2020-12-21T07:20:00 | 26950b58e2b6148f6fa041cdda6809d7da16ec87 | {
"blob_id": "26950b58e2b6148f6fa041cdda6809d7da16ec87",
"branch_name": "refs/heads/master",
"committer_date": "2020-12-21T07:20:00",
"content_id": "da7f19a8cbae455e5c96e6078a48bce5f536e3df",
"detected_licenses": [
"MIT"
],
"directory_id": "6e513076c3fece69e2ed5339a5ad17681763dddb",
"extension": "c"... | stackv2 |
#include<stdio.h>
#define SIZE 10
int binary_search(int a[],int key)
{
int mid=0;
int low=0;
int high=SIZE -1;
while(low <= high)
{
mid=(low+high)/2;
if(key == a[mid])
return mid+1;
else if(key < a[mid])
{
high = mid-1;
}
else
{
low =mid+1;
}
}
return 0;
}
int main()
{
int arr[1... | 3.390625 | 3 |
2024-11-18T20:25:27.432875+00:00 | 2021-06-04T14:08:26 | 79ea261184e3a01b746d8cf1f13b9c4336b73eaf | {
"blob_id": "79ea261184e3a01b746d8cf1f13b9c4336b73eaf",
"branch_name": "refs/heads/main",
"committer_date": "2021-06-04T14:28:40",
"content_id": "ce7934b30aaf1032a07905a8c3400bfbb67110b4",
"detected_licenses": [
"MIT"
],
"directory_id": "98687d92b72a5c81099ad80b36ae24d9dbd966b8",
"extension": "c",
... | stackv2 | /* SPDX-License-Identifier: MIT */
/*
* tests/test_explicit_behviour.c
* Copyright (C) 2020 Ferdinand Blomqvist
*
* $autogen_notice$
*/
#include <check.h>
#include <signal.h>
#include <stdio.h>
#include <stdlib.h>
#include "$prefix$contract/contract.h"
#include "test_helper.h"
/* Handler that continues on MAYBE... | 2.234375 | 2 |
2024-11-18T20:39:06.890190+00:00 | 2018-04-29T13:10:25 | ba69d4a2b8fa019e9fabca91c26cd85931a6359d | {
"blob_id": "ba69d4a2b8fa019e9fabca91c26cd85931a6359d",
"branch_name": "refs/heads/master",
"committer_date": "2018-04-29T13:10:25",
"content_id": "690a46a91324ca1f45fbea236c168a694bc5d193",
"detected_licenses": [
"MIT"
],
"directory_id": "429f750a0738bbbf4b3a38023b9e03192e271491",
"extension": "c"... | stackv2 | #include <stdio.h>
#include <time.h>
char* getDate(char * buffer)
{
//Creating the time and date for the log files
time_t datatime;
struct tm * gettime;
time (&datatime);
gettime = localtime(&datatime);
strftime(buffer, 80, "%d_%m_%Y_%H_%M_%S",gettime);
printf("\nTime:%s",buffer);
return buffer;
}
| 2.640625 | 3 |
2024-11-18T20:39:07.032175+00:00 | 2020-07-24T12:00:48 | adf471556dfb524bc9de6d3c83c3ef27eced1272 | {
"blob_id": "adf471556dfb524bc9de6d3c83c3ef27eced1272",
"branch_name": "refs/heads/master",
"committer_date": "2020-07-24T12:00:48",
"content_id": "f4561a439fc133a614d4981ab00a74c2aacebbf0",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "cd52ac9fe97112f4623ab3adcc4b85447a4d970e",
"extensio... | stackv2 | #define INDEX_VERSION_MAGIC ("sgrep-index v0")
#define max_term_len 256
#define INTERNAL_INDEX_BLOCK_SIZE 12
#define NEGATIVE_NUMBER_TAG ((unsigned char)255)
#define END_OF_POSTINGS_TAG ((unsigned char)127)
#define DOT_REGIONS (1<<17) /* 65536*2 */
#define MAX_MEMORY_LOADS 256
#define INDEX_BUFFER_ARRAY_SIZE 1024
#defi... | 2.03125 | 2 |
2024-11-18T20:50:00.094926+00:00 | 2023-05-30T15:14:32 | c953670e6c6e424f2034753f205c5fa46b37a6ed | {
"blob_id": "c953670e6c6e424f2034753f205c5fa46b37a6ed",
"branch_name": "refs/heads/master",
"committer_date": "2023-05-30T15:14:32",
"content_id": "00a6e1d2b3fe6b83608438a0b891a0311c56f919",
"detected_licenses": [
"MIT"
],
"directory_id": "b4e19f4e05577cce0bec993c33e80c0ff7cffe3c",
"extension": "c"... | stackv2 | /* SYSIFCOPT(*IFSIO) TERASPACE(*YES *TSIFC) STGMDL(*INHERIT) */
//#define TESTMAIN
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <errno.h>
#include <limits.h>
#include <qwcrsval.h>
#include <qlgrtvdc.h>
#include <ctype.h>
#include "ostypes.h"
#include "apierr.h"
#include "xlate.h"
#include "rtvsys... | 2.359375 | 2 |
2024-11-18T18:39:42.807297+00:00 | 2016-10-18T03:57:10 | a016afbad5f79c56ad3fad0a5610bab36c8b5797 | {
"blob_id": "a016afbad5f79c56ad3fad0a5610bab36c8b5797",
"branch_name": "refs/heads/master",
"committer_date": "2016-10-18T03:57:10",
"content_id": "dcaf0288d3ab97f95c952f7017c9a906fb1ba0c7",
"detected_licenses": [
"MIT"
],
"directory_id": "2feb8b34d47cf1e420f88ab2ee857d1f6182a5e6",
"extension": "c"... | stackv2 | /*
vga.c
===============================================================================
MIT License
Copyright (c) 2007-2016 Michael Lazear
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without ... | 2.6875 | 3 |
2024-11-18T18:39:43.219892+00:00 | 2020-07-10T01:50:15 | aff483900c15ad6f08eda0348d10d3304639edd1 | {
"blob_id": "aff483900c15ad6f08eda0348d10d3304639edd1",
"branch_name": "refs/heads/master",
"committer_date": "2020-07-10T01:50:15",
"content_id": "6c3a730387ba6aaed4aeba0a5a0608ed1db28916",
"detected_licenses": [
"MIT"
],
"directory_id": "ae90a314d912f9c40a5ef6545c4e1e6f21ceb682",
"extension": "c"... | stackv2 | #include <stdio.h>
// function decalration 函数原型/函数声明
char converter(char);
int main()
{
char lowercase, uppercase;
printf("Please input a lowercase letter character : ");
lowercase = getchar();
if (lowercase < 'a' || lowercase > 'z')
{
// 如果不是英文小写字母,直接输出
printf("The character is not ... | 3.9375 | 4 |
2024-11-18T18:39:43.374873+00:00 | 2018-07-14T23:13:49 | e274bf3058dafa0bc2989c3c9a2f3b5b6ad3a4b0 | {
"blob_id": "e274bf3058dafa0bc2989c3c9a2f3b5b6ad3a4b0",
"branch_name": "refs/heads/master",
"committer_date": "2018-07-14T23:13:49",
"content_id": "f14bae5299b86bc2a8615b7301cf0ea84413ea35",
"detected_licenses": [
"Apache-2.0"
],
"directory_id": "14eb0596fe1d8abf629def9759000fbc21779dc6",
"extensio... | stackv2 | // graphics middleware (c) 2018. All rights reserved.
#include <stdio.h>
#include <SDL2/SDL.h>
#include <SDL2/SDL_ttf.h>
#include "textbox.h"
text_box_t header = {
.colour = { .r = 0, .g = 0, .b = 0, .a = 0 },
.draw_rect = { .x = 32, .y = 15, .w = 200, .h = 20 },
};
void CreateTextBox(SDL_Renderer *renderer, t... | 2.546875 | 3 |
2024-11-18T18:39:43.643759+00:00 | 2023-03-26T16:22:39 | aa99b657fab2eb6b62905175f2f9c9643fa37f4b | {
"blob_id": "aa99b657fab2eb6b62905175f2f9c9643fa37f4b",
"branch_name": "refs/heads/main",
"committer_date": "2023-03-26T16:22:39",
"content_id": "3990e3eb00ee361719fa5b5cdd6757b51a77af85",
"detected_licenses": [
"MIT"
],
"directory_id": "d8c16011fa2cae9cfb3ba274ac931b6051b251da",
"extension": "c",
... | stackv2 | #include <stdlib.h>
#include "lua.h"
#include "lauxlib.h"
#include "lualib.h"
#define LIST_T "List"
/* compatibility with older Lua versions, which did not define this in the
* header. */
#ifndef LUA_LOADED_TABLE
/* key, in the registry, for table of loaded modules */
#define LUA_LOADED_TABLE "_LOADED"
#endif
/*
**... | 2.4375 | 2 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.