1
0
Fork 0
mirror of synced 2025-09-23 12:18:44 +00:00
ZoKrates/examples/simple_ifelse.code
Dennis Kuhnert e3727858ab Finish parser implementation for complete grammar (pow, ifelse, brackets)
Add case to r1cs swap_sub
Add fmt::Debug implementation for absy
Rewrite exampe simple_ifelse.code for new IfElse syntax
Add example brackets.code
2017-02-06 00:39:32 +01:00

6 lines
143 B
Text

// simple ifelse example
// e.g.: x = 5
def qeval(x):
y = if x < 3 then 1 else 5 fi
z = if y < x then x**3 else y**3 fi
return x + y + z