---
title: "Discussion on \"Storing Mappings in Solidity's Storage\" | Hashnode"
description: "Discussion on \"Storing Mappings in Solidity's Storage\". Okay let’s first look at the code\ncontract Demo {\n    uint256 a = 0x1a01; // Slot 0\n    uint256 b = 0x2a01; // Slot 1\n    mapping(uint => uint) c; // Slot 2\n    uint256 d = 0x5a01; // Sot 3\n\n    constructor(){\n        c[10] = 0xfe3f;\n        c[100] =..."
url: "https://hashnode.com/posts/storing-mappings-in-soliditys-storage/6741c163fb2918e75bf37954"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Storing Mappings in Solidity's Storage](https://mansoor-eth.hashnode.dev/storing-mappings-in-soliditys-storage?utm_source=hashnode&utm_medium=feed)

Okay let’s first look at the code contract Demo { uint256 a = 0x1a01; // Slot 0 uint256 b = 0x2a01; // Slot 1 mapping(uint => uint) c; // Slot 2 uint256 d = 0x5a01; // Sot 3 constructor(){ c\[10\] = 0xfe3f; c\[100\] =...

Nov 23, 2024 · 2 min read · mansoor-eth.hashnode.dev  
Read the article

-   [#solidity](https://hashnode.com/tag/solidity)
-   [#evm](https://hashnode.com/tag/evm)
-   [#evm-storage](https://hashnode.com/tag/evm-storage)
-   [#web3](https://hashnode.com/tag/web3)
-   [#web30](https://hashnode.com/tag/web30)
-   [#smart-contracts](https://hashnode.com/tag/smart-contracts)

## Written by

[Mansoor Butt](https://hashnode.com/@MansoorEth)

@MansoorEth · Karachi,Pakistan

  
[View profile](https://hashnode.com/@MansoorEth)

Software Engineer building Smart Contracts

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
