Babbage problem: Difference between revisions
Content deleted Content added
Added PicoLisp |
Wrote a babbage number code in R lang |
||
Line 689: | Line 689: | ||
print(n) # prints n |
print(n) # prints n |
||
</lang> |
|||
{{out}} |
|||
<pre>25264</pre> |
|||
=={{header|R}}== |
|||
<lang R> |
|||
babbage_function=function(){ |
|||
n=0 |
|||
while (n**2%%1000000!=269696) { |
|||
n=n+1 |
|||
} |
|||
return(n) |
|||
} |
|||
babbage_function()[length(babbage_function())] |
|||
</lang> |
</lang> |
||
{{out}} |
{{out}} |