aboutsummaryrefslogtreecommitdiffstats
path: root/research
diff options
context:
space:
mode:
Diffstat (limited to 'research')
-rw-r--r--research/experiments/041-batches/costs/recur.aup11
1 files changed, 11 insertions, 0 deletions
diff --git a/research/experiments/041-batches/costs/recur.aup b/research/experiments/041-batches/costs/recur.aup
new file mode 100644
index 0000000..fb56004
--- /dev/null
+++ b/research/experiments/041-batches/costs/recur.aup
@@ -0,0 +1,11 @@
+state out = 0
+input go = message {
+ n: u32
+}
+on go {
+ let x = 1
+ for i in 0 .. go.n * 1000 {
+ x = x * 48271 - floor(x * 48271 / 2147483647) * 2147483647
+ }
+ out = x
+}