Skip to content

Instantly share code, notes, and snippets.

View yazaldefilimone's full-sized avatar
🪶
I like simple and fast things

Yazalde Filimone yazaldefilimone

🪶
I like simple and fast things
View GitHub Profile
@yazaldefilimone
yazaldefilimone / ytb.css
Created September 11, 2025 10:20 — forked from noghartt/ytb.css
A simple CSS style injection to turn youtube a bit more usable (and also removing Shorts related stuff)
/* ==UserStyle==
@name www.youtube.com
@namespace github.com/openstyles/stylus
@version 1.0.0
@description A new userstyle
@author noghartt
==/UserStyle== */
@-moz-document url-prefix("https://www.youtube.com/") {
/* Remove all references to Shorts. */
@yazaldefilimone
yazaldefilimone / pr.md
Created October 16, 2024 13:10 — forked from piscisaureus/pr.md
Checkout github pull requests locally

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = git@github.com:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

ast.exe: ast.c
gcc -Werror -Wswitch -Wimplicit-fallthrough ast.c -o ast.exe
clean:
rm -f *.o *.exe *.s a.out
test.s: ast.exe
./ast.exe > test.s
impl<V: Value> core::str::FromStr for NonNormalizingDec<V> {
type Err = &'static str;
#[inline(never)]
#[rustfmt::skip]
fn from_str(s: &str) -> Result<Self, Self::Err> {
/// Converts an ASCII decimal digit to an int.
///
/// In release builds, no range checks are performed and passing a
/// non-digit character will result is undefined (yet safe) behavior.
@yazaldefilimone
yazaldefilimone / cc.md
Created April 27, 2024 23:55 — forked from noghartt/cc.md
Resources to learn more about Computer Science and related stuffs
@yazaldefilimone
yazaldefilimone / UntypedLambda.agda
Created March 10, 2024 19:54 — forked from gallais/UntypedLambda.agda
Interpreting the untyped lambda calculus in Agda
{-# OPTIONS --copatterns #-}
module UntypedLambda where
open import Size
open import Function
mutual
data Delay (A : Set) (i : Size) : Set where
@yazaldefilimone
yazaldefilimone / phoas.md
Created March 10, 2024 19:28 — forked from VictorTaelin/phoas.md
PHOAS in JS / HVM
@yazaldefilimone
yazaldefilimone / simple_fast_functional_sieve.md
Created February 20, 2024 15:02 — forked from VictorTaelin/simple_fast_functional_sieve.md
Can a simple functional sieve be fast? Optimizing Tromp's algorithm on HVM.

Can a simple functional sieve be fast? Optimizing Tromp's algorithm on HVM.

Today, John Tromp - creator of the Binary λ-Calculus, and one of the smartest functional wizards alive - ported his famous prime number generator (first published 12 years ago!) to HVM:

@yazaldefilimone
yazaldefilimone / sat.md
Created February 20, 2024 15:02 — forked from VictorTaelin/sat.md
Simple SAT Solver via superpositions

Solving SAT via interaction net superpositions

I've recently been amazed, if not mind-blown, by how a very simple, "one-line" SAT solver on Interaction Nets can outperform brute-force by orders of magnitude by exploiting "superposed booleans" and optimal evaluation of λ-expressions. In this brief note, I'll provide some background for you to understand how this works, and then I'll present a simple code you can run in your own computer to observe and replicate this effect. Note this is a new observation, so I know little about how this algorithm behaves asymptotically, but I find it quite