Skip to content

Instantly share code, notes, and snippets.

View Rudxain's full-sized avatar

Ricardo Fernández Serrata Rudxain

View GitHub Profile
@Rudxain
Rudxain / emoji-guide.md
Last active June 18, 2026 02:42
cheat-sheet/guidelines for emoji-reactions on chat apps
  • ✅/✔️: Correct. Use it when you want to assert something is factual. Use it with care, and be skeptical of yourself. It can also be used to say something is "done".
  • ⬆️/🔼/☝️/👆: ×2/ditto. When you want to repeat whatever someone said, without actually repeating. Useful to emphasize/approve the content of a message, even if you disagree with the person that said it.
  • 👍: Like. To show agreement or subjective approval, or to say that you simply like/support something. Can be used to say "got it", "thanks", and even "you're welcome".
  • 💯: Definitely/definitively. When you absolutely couldn't agree more! Keep in mind this is still subjective. Don't use it for facts, unless paired with "✅".
  • ❤️: Love!. Use it to show your fondness or appreciation for something/someone. I won't go into details about colors, as there's no consensus. Can be used to say "thank you!".
  • 🗿: Based. Use it when someone is a giga-chad or said something [based](https://www.urbandictionary.com/define.php?term=ba
@joboet
joboet / 0000-pattern-types.md
Last active May 12, 2026 12:25
Pattern types RFC

Summary

This RFC introduces pattern types, which are subtypes of matchable types that are statically restricted to a subset of the variants of the original type.

@vi
vi / interesting_crates.md
Last active August 8, 2026 06:35
List of crates that improves or experiments with Rust, but may be hard to find

Let's list here crates that enhance Rust as a language.

It not "batteries" like in stdx, but Rust-specific crates for workarounds for various missing features and experimental ideals from non-accepted/postponed RFCs, or just hacky tricks.

The list is supposed to contain (mostly) crates that are internal to Rust, not ones for making Rust deal with "external world" like other languages bindings, file formats, protocols and so on.

Primary focus should be on crates that are not easy to find by conventional means (e.g. no algorithm name, format or protocol to search for).

Note that quality of the listed crates may vary from proof-of-concept to stable-and-widely-used.

import random
import typing.List
def thanos_sort(a: List[int]) -> List[int]:
'''Removes half of the list until it's perfectly balanced, like all things should be.'''
def _perfectly_balanced(a: List[int]) -> bool:
like_all_things_should_be = True
@rust-play
rust-play / playground.rs
Created September 27, 2018 01:24
Code shared from the Rust Playground
enum RecursionResult<C, R> {
Continue(C),
Return(R),
}
fn tail_recurse<C, R>(mut init: C, mut f: impl FnMut(C) -> RecursionResult<C, R>) -> R {
loop {
match f(init) {
RecursionResult::Continue(c) => init = c,
RecursionResult::Return(r) => return r,
@timvisee
timvisee / falsehoods-programming-time-list.md
Last active November 11, 2026 20:35
Falsehoods programmers believe about time, in a single list

Falsehoods programmers believe about time

This is a compiled list of falsehoods programmers tend to believe about working with time.

Don't re-invent a date time library yourself. If you think you understand everything about time, you're probably doing it wrong.

Falsehoods

  • There are always 24 hours in a day.
  • February is always 28 days long.
  • Any 24-hour period will always begin and end in the same day (or week, or month).
@izabera
izabera / bfsh
Created November 23, 2016 10:23
brainfuck interpreter in posix sh
#!/bin/sh
LANG=C
compile() {
# some preprocessing and basic optimizations
code=$(printf %s "$1" |
(tr -dc '\133\135<>,.+-'; echo) | # ksh's builtin tr doesn't like []<>,.+-
sed -e :a -e 's/<>//g;s/><//g;s/+-//g;s/-+//g
s/\[-]/z/g;s/zzz*/z/g;s/[+-]z/z/g;ta')
print(''.join([chr(x) for x in [int(x,16) for x in \
[str(hex(2 * 2 * 5 * 7 * 37 * 149 * 5417 * 148781 \
* 51939996061871)[i:(i+2)])\
for i in range(25)][2::2]]]))
/* The world's smallest Brainfuck interpreter in C, by Kang Seonghoon
* http://j.mearie.org/post/1181041789/brainfuck-interpreter-in-2-lines-of-c */
s[99],*r=s,*d,c;main(a,b){char*v=1[d=b];for(;c=*v++%93;)for(b=c&2,b=c%7?a&&(c&17
?c&1?(*r+=b-1):(r+=b-1):syscall(4-!b,b,r,1),0):v;b&&c|a**r;v=d)main(!c,&a);d=v;}