Skip to content

Instantly share code, notes, and snippets.

View angelcaru's full-sized avatar

angelcaru

View GitHub Profile
@angelcaru
angelcaru / printimg.c
Created May 3, 2024 14:47
Simple ANSI terminal image viewer in C
// NOTE: you will need stb_image in order to compile this
// Currently only works on POSIX-compliant systems because of the use of ioctl()
#define STB_IMAGE_IMPLEMENTATION
#include "stb_image.h"
#include <sys/ioctl.h>
void usage(const char *program_name) {
printf("Usage: %s <filename>\n", program_name);
}
@angelcaru
angelcaru / index.html
Created March 17, 2024 19:43
"""Cookie clicker""" in 11 lines of code
<canvas id="canvas" width="800" height="800"></canvas>
<script src="main.js"></script>
@angelcaru
angelcaru / bf.c
Created February 28, 2024 19:37
Brainf**k transpiler in C
#include <stdio.h>
#include <stddef.h>
#include <string.h>
#include <errno.h>
#include <unistd.h>
void usage(const char *program_name) {
printf("Usage: %s <input-file>\n", program_name);
}