This project demonstrates the fundamentals of blockchain architecture by implementing a simple blockchain in Python from scratch — no frameworks, just logic.
- 🧱 Custom Blockchain with block structure, hashes, and chaining logic.
- ⛏️ Proof-of-Work algorithm to simulate mining difficulty and validation.
- 🔒 Transaction System with support for sender, receiver, and balances.
- 🧠 Smart State Logic that maintains user balances and prevents double-spending.
- 📏 Chain Validation and block integrity check on each new addition.
- 📜 Simple CLI Interface to simulate block creation and network behavior.
python3 blockchain.py🛠️ Tech Stack
- Language: Python 3
- Hashing: SHA-256 (hashlib)
- Logic: Pure OOP and Functional Design
- Blockchain fundamentals
- Hashing with SHA-256
- Proof-of-Work difficulty
- Merkle chain and block linking
- Transaction verification
- Final state & ledger maintenance
New Block Received; Checking... Block accepted. Chain length: 8 Final State: {'Alice': 76, 'Bob': 24}