People : What is the real advantage of "ππ₯π¨ππ€ππ‘ππ’π§"
Me : The real breakthrough of blockchain is not crypto but the ability to record truth in a way that is hard to fake.....
Almost everyone says your "wallet holds your crypto"...
But that is technically incorrect....
Your wallet never stores any cryptocurrency
"Everything you own has always remained on the blockchain".
Here's how it actually works π§΅ β
@stfu_aayushiii I agree in some sense that in certain job positions dsa should not be skipped but it should not be the only factor to reject someone....
"storage" , "memory" and "calldata" in Solidity don't just change the location of data but they change how much a user pays to use your smart contract
Check this post to understand the difference between storage vs memory vs calldata
Most Solidity beginner get confused between "storage" , "memory" and "calldata" and it cost them more gas.. Here is the simple way to understand it ...
1. Storage :
Storage is where the smart contract's state variable lives permanently on blockchain .
The variables stored in storage can be read and modified by the contractβs functions, depending on their visibility and also the access control.
Storage is actually the most expensive data location in solidity in terms of gas
2. memory :
memory is a temporary data location in Solidity used during function execution .
The variable stored in memory can be read and modified but only inside same function execution.
Once the function finishes, the data is gone.
memory is actually cheaper than storage in terms of gas as it is temporary memory.
3. calldata :
calldata is a temporary, read-only data location in Solidity used as function input, especially for "external calls".
You can read it, but you cannot modify it directly.
Gas cost is less compared to storage and memory for read-only input.
If I have to explain in one sentence then "storage saves data permanently, calldata receives input, and memory is temporary working space".