mirror of
https://github.com/AleoHQ/leo.git
synced 2024-11-29 22:36:05 +03:00
11 lines
175 B
Plaintext
11 lines
175 B
Plaintext
// Adding the `mut` keyword makes a circuit variable mutable.
|
|
circuit Foo {
|
|
x: u32
|
|
}
|
|
|
|
function main() -> u32 {
|
|
let mut a = Foo { x: 1 };
|
|
a.x = 0;
|
|
|
|
return a.x
|
|
} |