leo/asg/tests/pass/address/ternary.leo

8 lines
248 B
Plaintext
Raw Normal View History

2021-01-25 18:17:42 +03:00
function main(s: bool, c: address) {
const a = aleo1qnr4dkkvkgfqph0vzc3y6z2eu975wnpz2925ntjccd5cfqxtyu8sta57j8;
const b = aleo18qgam03qe483tdrcc3fkqwpp38ehff4a2xma6lu7hams6lfpgcpq3dq05r;
2021-01-25 18:17:42 +03:00
let r = s ? a: b;
2021-01-25 18:17:42 +03:00
console.assert(r == c);
}