Skip to content

FriendlyLifeguard/cairo_zero_example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Cairo Zero example that uses output builtin.

Cairo Zero is a low level language for Cairo, a smart contract language for Starknet Blockchain.

To compile and run Cairo Zero programs, you would need to setup a python environment.

I had success using Conda.

Then, follow instructions from Cairo Zero documentation. I tried to use Python 3.11 but it didn't work. Use Python 3.9!

Once you are in the virtual python environment, compile the contract.

cairo-compile test_with_builtin.cairo --output test_compiled_builtin.json 

And with the output json file, run the following command to visualize the memory layout.

cairo-run \                                                                  
  --program=test_compiled_builtin.json --print_output \
  --print_info --print_segments --print_memory --layout=small

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages