about summary refs log tree commit diff stats
path: root/html/factorial.mu.html
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2015-11-13 10:08:57 -0800
committerKartik K. Agaram <vc@akkartik.com>2015-11-13 10:08:57 -0800
commitc603cd6cef43100aa83a62e15f96fd54c9fb987e (patch)
treed8631b1964a0200d170a996314f6e023686ff8de /html/factorial.mu.html
parent05d3592047a76db4cc8d77102508c21ca1b86e7b (diff)
downloadmu-c603cd6cef43100aa83a62e15f96fd54c9fb987e.tar.gz
2430 - make room for more transforms
Diffstat (limited to 'html/factorial.mu.html')
-rw-r--r--html/factorial.mu.html7
1 files changed, 3 insertions, 4 deletions
diff --git a/html/factorial.mu.html b/html/factorial.mu.html
index 31ac9c26..db6840b9 100644
--- a/html/factorial.mu.html
+++ b/html/factorial.mu.html
@@ -40,9 +40,9 @@ body { font-family: monospace; color: #eeeeee; background-color: #080808; }
 <span class="Constant">]</span>
 ]
 
-<span class="muRecipe">recipe</span> factorial [
+<span class="muRecipe">recipe</span> factorial n:number<span class="muRecipe"> -&gt; </span>result:number [
   <span class="Constant">local-scope</span>
-  n:number<span class="Special"> &lt;- </span><span class="Constant">next-ingredient</span>
+  <span class="Constant">load-ingredients</span>
   <span class="Delimiter">{</span>
     <span class="Comment"># if n=0 return 1</span>
     zero?:boolean<span class="Special"> &lt;- </span>equal n, <span class="Constant">0</span>
@@ -52,8 +52,7 @@ body { font-family: monospace; color: #eeeeee; background-color: #080808; }
   <span class="Comment"># return n * factorial(n-1)</span>
   x:number<span class="Special"> &lt;- </span>subtract n, <span class="Constant">1</span>
   subresult:number<span class="Special"> &lt;- </span>factorial x
-  result:number<span class="Special"> &lt;- </span>multiply subresult, n
-  <span class="muControl">reply</span> result
+  result<span class="Special"> &lt;- </span>multiply subresult, n
 ]
 
 <span class="Comment"># unit test</span>