Skip to content

Instantly share code, notes, and snippets.

@ar-pa
ar-pa / BigInt.cpp
Last active June 16, 2026 04:52
bignum class for C++
// In the name of Allah.
// We're nothing and you're everything.
// Ya Ali!
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int maxn = 1e2 + 14, lg = 15;
# DSA Question Bank
## Arrays, Hashing, Prefix/Suffix
1. Find the second largest element in one pass without extra space.
2. Find the k largest distinct elements without fully sorting the array.
3. Find the two numbers that appear once when every other number appears twice.
4. Find the majority element that appears more than n / 2 times.
5. Find all elements that appear more than n / 3 times.
6. Count inversions in an array.

LLM Wiki

A pattern for building personal knowledge bases using LLMs.

This is an idea file, it is designed to be copy pasted to your own LLM Agent (e.g. OpenAI Codex, Claude Code, OpenCode / Pi, or etc.). Its goal is to communicate the high level idea, but your agent will build out the specifics in collaboration with you.

The core idea

Most people's experience with LLMs and documents looks like RAG: you upload a collection of files, the LLM retrieves relevant chunks at query time, and generates an answer. This works, but the LLM is rediscovering knowledge from scratch on every question. There's no accumulation. Ask a subtle question that requires synthesizing five documents, and the LLM has to find and piece together the relevant fragments every time. Nothing is built up. NotebookLM, ChatGPT file uploads, and most RAG systems work this way.

@marckohlbrugge
marckohlbrugge / deploy.yml
Created January 9, 2026 07:58
Optimistic Builds™ with Kamal
# Optimistic Builds for Kamal
#
# This workflow speeds up deploys by building the Docker image in parallel with CI.
# Instead of: CI → Build → Deploy (sequential)
# We do: CI ↘
# → Deploy
# Build ↗
#
# The "optimistic" part: we start building before knowing if tests pass.
# Since CI usually passes, this saves ~2 minutes per deploy.
@intenzemotion
intenzemotion / hide-edge-rounded-corners.ps1
Last active June 16, 2026 04:41
Hide Edge v149 forced rounded corners. Additionally hide red dot on profile icon too.
# This script must be run as Administrator to update some shortcut paths. Checking it first...
$IsAdmin = ([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole(
[Security.Principal.WindowsBuiltInRole]::Administrator
)
if (-not $IsAdmin) {
Write-Host "Not running as Administrator. Some shortcuts may fail to update." -ForegroundColor Yellow
Write-Host ""
}
# This is your Edge path, it should be installed here (if you're on Stable channel).
@horaceho
horaceho / 置身钉内.md
Last active June 16, 2026 04:35
置身钉内・滕雅辛

《置身钉内》

作者:滕雅辛(幽素)
发布:2026年6月5日
全文:7.5万字


1696921482553
@basham
basham / css-units-best-practices.md
Last active June 16, 2026 04:30
CSS Units Best Practices

CSS units

Recommendations of unit types per media type:

Media Recommended Occasional use Infrequent use Not recommended
Screen em, rem, % px ch, ex, vw, vh, vmin, vmax cm, mm, in, pt, pc
Print em, rem, % cm, mm, in, pt, pc ch, ex px, vw, vh, vmin, vmax

Relative units

Relative units

@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active June 16, 2026 04:28
Complete Recent Discord Quest

Caution

As of April 7th 2026, Discord has expressed their intent to crack down on automating quest completion.

Some users have received the following system message:

image

There isn't much I can do to make the script undetected, so use it at your own risk, as you most likely WILL get flagged by doing so.

Complete Recent Discord Quest