Mapping storage
Write a mapping and inspect the resulting storage change.
Solidity 0.8.36REPL mode
Why use this example
Use this pattern to explore how Solidity represents typed values and how state-changing expressions affect storage. The entry isolates mapping storage so its input, result, and state changes stay easy to compare.
Solidity to run
mapping(address => uint256) public balances
balances[msg.sender] = 25
balances[msg.sender]What to expect
The sender’s mapping entry evaluates to 25 and the run records the corresponding storage write.
Continue the investigation
Change a value, add another expression, or open Inspect after the run. Accepted entries remain available to the next entry, and the clean replay keeps the complete result reproducible.
Read about state and storage Reproducible investigation