Skip to content

Instantly share code, notes, and snippets.

View alajpie's full-sized avatar

Alicja alajpie

View GitHub Profile
global _start
section .data
fizz: db "fizz", 10
buzz: db "buzz", 10
fizzbuzz: db "fizzbuzz", 10
section .text
_start:
xor rcx, rcx
sub rsp, 3
#include <stdbool.h>
#include <stdio.h>
// only on ints cause lol no generics in C
typedef struct optional {
bool exists;
int value;
} optional;
optional functor(int (*f)(int), optional x) {
@alajpie
alajpie / bumper.js
Last active April 8, 2019 00:16
Stupid simple Disboard bumping bot
// CHANGE HERE
const serverId = "12345678987654321";
const channelId = "12345678987654321";
const userToken = "NTY0NTM0NTk0NzY0NjQ0MzYx.XcTNkw.IyU7orE_XbkVeKgWs_gpoLLxl9s";
// ---
const Discord = require("discord.js");
const moment = require("moment");
@alajpie
alajpie / queue-ll.c
Last active February 25, 2019 15:26
#include <stdio.h>
#include <stdlib.h>
#include <limits.h>
struct node {
int value;
struct node* next;
};
struct queue {
@alajpie
alajpie / fangtab.py
Created February 24, 2019 16:56
Parse tab_state from Chrome on Android
import sys
data = sys.stdin.buffer.read()
i = 26
while i < len(data):
while i < len(data) and data[i] != 0:
sys.stdout.write(chr(data[i]))
i += 1
sys.stdout.write("\n")