今日已更新 185 条资讯 | 累计 40041 条内容
关于我们

标签:#ha

找到 15368 篇相关文章

AI 资讯

$100 to a Debian Developer who can get Fresh Editor into Trixie

I use Debian 13 in a regulated industry and I'm teaching people how to code in the context of large projects and TUI. I want to use Fresh Editor (https://getfresh.dev/). This is because Fresh is easier to learn quickly than vim & emacs, and more of an IDE than micro & nano, and more favorable for compliance auditing because of its core-and-plugins architecture and open source code using Rust. I would like to donate toward this goal. I can afford to offer $100 to any Debian Developer who has the

2026-06-01 原文 →
AI 资讯

Show HN: Ouijit, an open-source task and terminal manager for coding agents

Hi HN, I’m working on Ouijit. It’s a project and task-based terminal session manager that provides a few basic but useful tools for agent workflows: - Terminal sessions in Ouijit have access to the ouijit CLI, and supported agents (Claude, Codex, Pi) can work with it out of the box to manage tasks and customize a personal development workflow - Tasks live on a kanban board that supports hooks for task lifecycle events (eg. ‘Run this script when a task moves to ‘in progress’) I’ve found this simp

2026-06-01 原文 →
AI 资讯

A .NET Dinosaur in Web3. Day 18 - Automated Market Maker

🏦 Day 6 of 7: Building a Mini Uniswap in 80 Lines of Solidity Imagine a vending machine. It has 1,000 coffee beans and 1,000 coins. No menu, no cashier — just one iron rule: the product of the two numbers inside must never decrease. That's it! This is how Uniswap works — and this is what I built on Day 6, coming from .NET. Here's how, why it's elegant, and where you can step on a rake. Why an Order Book Doesn't Work on a Blockchain Traditional exchanges — Binance, NYSE, any CEX — run on an order book . Market makers post bids and asks. A matching engine pairs them. Millions of updates per second, all in a centralised database. In a blockchain, this is impossible. Transactions take 12 seconds. Every state change costs gas. Storing millions of constantly changing orders would eat all the profit before a single trade completes. Uniswap's solution: replace the order book with a liquidity pool — a smart contract holding two tokens — and replace the matching engine with pure math. Just a formula — below. x · y = k — The Formula That Broke Finance The Constant Product Invariant : x · y = k Where x is the reserve of Token0, y is the reserve of Token1, and k is a constant that must never decrease during swaps. When a trader sells Token0 into the pool, x increases. To keep k constant, y must decrease — the contract sends out Token1. The price is determined automatically by the ratio of reserves. Live example with numbers: Pool: 1,000 Token0, 1,000 Token1. k = 1,000,000. Trader sells 100 Token0: amountOut = (reserveOut × amountIn) / (reserveIn + amountIn) amountOut = (1000 × 100) / (1000 + 100) amountOut = 100,000 / 1,100 amountOut ≈ 90.9 Token1 The trader gets ~90.9, not 100. That gap is slippage — and it's not a bug. It's the formula protecting the pool. The more you buy relative to pool size, the worse your price gets. Naturally. Mathematically. After the swap: pool has 1,100 Token0 and ~909.1 Token1. k ≈ 1,000,000. Invariant holds. The Contract: SimpleAMM Three functions.

2026-05-31 原文 →