The technical content top engineers rely on to level up.

17 min read
Introduction to the Cairo Language Cairo is a programming language designed for provable, verifiable computation, particularly within the context of zero-knowledge systems like Starknet, a Layer 2...
Last updated on Dec 11, 2025
11 min read
Structure of a Basic Contract This article shows how to build a deployable Cairo contract for Starknet. Starting from a simple sketch, we will gradually add features to build a working contract...
Last updated on Dec 11, 2025
15 min read
Cairo Storage Variable Types In Starknet, Contract Storage is the persistent memory where your smart contract's state lives. Unlike variables declared inside a function which disappear after...
Last updated on Dec 10, 2025
11 min read
Integers in Cairo Cairo doesn’t offer the full range of integer sizes found in Solidity. While Solidity provides integer types for every multiple of 8 bits up to 256, Cairo supports only the...
Last updated on Dec 10, 2025
15 min read
ERC-20 Token on Starknet ERC-20 tokens on Starknet work the same way as on Ethereum. In fact, STRK (Starknet's fee token) is itself an ERC-20 token; there's no special "native" token at the protocol...
Last updated on Dec 10, 2025
17 min read
Cheatcodes in Starknet Foundry A "cheatcode" in Foundry is a mechanism that allows contract tests to control environment variables such as caller address, the current timestamp, and so on. In this...
Last updated on Dec 10, 2025
7 min read
Function Visibility in Cairo Cairo does not have "internal" and "pure" modifiers (or any other modifiers for that matter) like Solidity does. Recall that marking an block with tells Cairo to include...
Last updated on Dec 10, 2025
10 min read
Type Casting Type casting in Cairo is the process of converting values from one data type to another. This becomes necessary when working with Cairo's strict type system, where explicit type matching...
Last updated on Dec 10, 2025
Fixed Point Arithmetic in Solidity (Using Solady, Solmate, and ABDK as Examples) A fixed-point number is an integer that stores only the numerator of a fraction — while the denominator is implied....
Last updated on Dec 5, 2025
3 min read
FFT Friendly Finite Fields In order to carry out the FFT algorithm in a finite field (the Number Theoretic Transform), there needs to be $k$-th roots of unity such that $k$ is a power of 2. Ideally,...
Last updated on Nov 21, 2025
12 min read
Positions in Uniswap v3 Adding liquidity to an AMM means depositing tokens into the AMM pool. Liquidity providers do this in the hope of earning fees from users who swap with that pool. In Uniswap...
Last updated on Nov 13, 2025
9 min read
NTT Algorithm By Hand The NTT (Number Theoretic Transform) algorithm converts a polynomial in a finite field from coefficient form to point form. If a polynomial has degree $d$ then we evaluate it on...
Last updated on Nov 12, 2025