Skip to content

Instantly share code, notes, and snippets.

@tropicbliss
tropicbliss / complexity_viz.py
Last active June 21, 2022 06:30
Modelling algorithm complexity using a chart in Python
from pandas import DataFrame
import altair as alt
import timeit
def gcd_brute_force(a, b):
pass
def gcd_dijkstra(a, b):
@tropicbliss
tropicbliss / melody.py
Created January 3, 2022 14:16
Hypixel Skyblock Melody Harp Macro
import sys
import time
import pyautogui
mapping = {"1": (1, 2), "2": (1, 2), "3": (1, 2), "4": (
1, 2), "5": (1, 2), "6": (1, 2), "7": (1, 2)}
pause_delay = 1
with open("sheet.txt", 'r') as file:
text = file.read().rstrip()
@tropicbliss
tropicbliss / fizz.rs
Last active June 21, 2022 06:31
Extremely fast loop unrolled fizz buzz
use std::io::{self, Write};
fn main() {
const BUFFER_CAPACITY: usize = 64 * 1024;
let stdout = io::stdout();
let handle = stdout.lock();
let mut handle = io::BufWriter::with_capacity(BUFFER_CAPACITY, handle);
let mut i: usize = 0;
loop {
i += 1;