Learn YUL I


We write “VivaMexicoCabrones” to the memory space with our opcodes and Yul codes.

let greet := "VivaMexicoCabrones"

Store the string offset in mem[0x00]

This is an ABI requirement, 0x20 must be stored at any chosen offset.

 mstore(0x00, 0x20)

Store the length of the string

mstore(0x20, 0x12) // 0x12 = 18, length of "VivaMexicoCabrones".

Store the string in memory

mstore(0x40, greet)

Returns the bytes from memory

return(0x00, 0x60)

What is 566976614d657869636f436162726f6e6573 ?


This is bonus

Associate Professor Engin YILMAZ (VeriDelisi)



Solidity Programming Language

Solidity basics for beginners: Learn the fundamentals of smart contract development and build your first DApp! #Solidity #Foundry #Ethereum #Opcodes #DApps