# Lab — Bytecode and opcodes

## Prerequisites
- Foundry (forge/cast/anvil)
- Không cần ví mainnet hoặc token thật

## Steps
1. `cd solution`
2. `forge build`
3. `forge test -vvv`
4. `forge test --gas-report`
5. Run `forge inspect src/Lab.sol:OpcodeLab deployedBytecode` and `forge inspect src/Lab.sol:OpcodeLab opcodes`; identify PUSH, ADD, GT, RETURN and explain optimizer differences.

## Expected output
- `forge build` thành công
- Các test functions trong `test/Lab.t.sol` đều PASS
- Không có transaction mainnet

## Troubleshooting
- `forge: command not found`: cài Foundry theo tài liệu chính thức
- `solc` download fails: kiểm tra kết nối, compiler 0.8.24
- Assertion fails: dùng `forge test -vvvv` để đọc call trace
