Uniswap v4 in five facts
1. One contract, the PoolManager, holds every pool, which makes creating a pool 99% cheaper than before.
2. Flash accounting: balances are tracked as running totals during a call and must net to zero at the end, so the pool is always paid.
3. A hook has 14 possible permissions, stored in the lowest 14 bits of its address. The permissions it declares must match those bits exactly.
4. Dynamic fees are chosen when a pool is created and cannot be switched on later. Fees count in hundredths of a basis point, so 1,000,000 equals 100%.
5.Hooks can take or give tokens during a swap. This is how a hook charges its own fee.