-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
As I pondered creating an Alice/Eve Secret Bounty demo described in #7 , the following Nice to Have occurred to me:
Support the Ring of Unsigned Integers Modulo $64k$ in both PyTeal and Zokrates
For example, in the case $k=16$ this amounts to
Support $\mathbb{Z} / 1024$
- PyTeal supports
uint1024with the following 3 operations:-
modular_add: add two numbers and in the case of overflow, reduce modulo
$2^{1024}$ -
modular_subtract: subtract two numbers and in the case of under, reduce modulo
$2^{1024}$ (obtaining a number in the range$[0, 2^{1024})$ -
modular_multiply: multiply two numbers and in the case of overflow, reduce modulo
$2^{1024}$
-
modular_add: add two numbers and in the case of overflow, reduce modulo
- Create a Zokrates library for type
u<1024>with underlying base typeu64[16]with similar properties to the PyTeal type just described
Links
Metadata
Metadata
Assignees
Labels
No labels