Zero to the zero power: Difference between revisions

Content added Content deleted
imported>Tromp
Line 260: Line 260:
In lambda calculus, <code>\n. n n</code> is a function mapping a Church numeral n to the Church numeral n^n. The following BLC program computes this for n=0 by using its empty input as a Church numeral (since nil coincides with Church numeral 0), and outputting in unary (i.e as a string of 0^0 1s), as generated from https://github.com/tromp/AIT/blob/master/rosetta/exp00.lam :
In lambda calculus, <code>\n. n n</code> is a function mapping a Church numeral n to the Church numeral n^n. The following BLC program computes this for n=0 by using its empty input as a Church numeral (since nil coincides with Church numeral 0), and outputting in unary (i.e as a string of 0^0 1s), as generated from https://github.com/tromp/AIT/blob/master/rosetta/exp00.lam :


<syntaxhighlight>0001010110100000010110111011010</syntaxhighlight>
<pre>0001010110100000010110111011010</pre>


Output:
Output:


<pre>1</pre>
<syntaxhighlight>1</syntaxhighlight>


=={{header|BQN}}==
=={{header|BQN}}==