Focus mode
Code from video: https://solidity-by-example.org/mapping/
You can access the video content in Turkish prepared by İTÜ Blockchain here: https://www.youtube.com/watch?v=aZDdyhfesEc&list=PLby2HXktGwN4Cof_6a8YwlMrboX8-hs73&index=7
Mapping in Solidity acts like a hash table or dictionary in any other language. These are used to store data values in key:value pairs. In terms of mapping, the key data is not stored in a mapping, only its keccak256 hash is used to look up the value. The KeyType can be any built-in value type, bytes, string, or any contract or enum type. Other user-defined or complex types, such as mappings, structs or array types are not allowed. ValueType can be any type, including mappings, arrays and structs.
Mappings are mostly used to associate the unique Ethereum address with the associated value type.
Resources:
You can find detailed further information from Solidity Official documentation(in English):
https://docs.soliditylang.org/en/v0.8.15/types.html#mapping-types
Programs to Accelerate Your Progress in a Software Career
Join our 4-8 month intensive Patika+ bootcamps, start with the fundamentals and gain comprehensive knowledge to kickstart your software career!
You need to enroll in the course to be able to comment!