summaryrefslogtreecommitdiff
path: root/docs/2026_REBASE/demos/control.smp
diff options
context:
space:
mode:
Diffstat (limited to 'docs/2026_REBASE/demos/control.smp')
-rw-r--r--docs/2026_REBASE/demos/control.smp9
1 files changed, 9 insertions, 0 deletions
diff --git a/docs/2026_REBASE/demos/control.smp b/docs/2026_REBASE/demos/control.smp
new file mode 100644
index 00000000..6b7b1b17
--- /dev/null
+++ b/docs/2026_REBASE/demos/control.smp
@@ -0,0 +1,9 @@
+int n = arg;
+if( n < 0 ) n = -n;
+int sum = 0;
+int i = 0;
+while( i < n ) {
+ i = i + 1;
+ sum = sum + i;
+}
+return sum;