for loops

This commit is contained in:
Jordi Baylina
2019-11-28 15:10:59 +01:00
parent 66291a0efe
commit 93330f065b
24 changed files with 1385 additions and 81 deletions

View File

@@ -0,0 +1,16 @@
template AddConst(c) {
signal input in;
signal output out;
var a = 2;
var b = 3;
a=a+b;
a=a+4;
a=a+c;
out <== 5 + a + in;
}
// It should out <== in + 1+2+3+4+5 = in + 15
component main = AddConst(1);