1
0
Fork 0
mirror of synced 2025-09-23 12:18:44 +00:00
ZoKrates/zokrates_cli/examples/book/struct_assign.zok
2022-06-28 19:23:45 +02:00

11 lines
157 B
Text

struct Point {
field x;
field y;
}
def main(field a) -> Point {
Point mut p = Point { x: 1, y: 0 };
p.x = a;
p.y = p.x;
return p;
}