leo/compiler/tests/statements/conditional/for_loop.leo

12 lines
126 B
Plaintext

function main(cond: bool) -> u32 {
let mut a = 0u32;
if cond {
for i in 0..4 {
a += i;
}
}
return a
}