Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
18
Task/Babbage-problem/Befunge/babbage-problem.bf
Normal file
18
Task/Babbage-problem/Befunge/babbage-problem.bf
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
1+ ::* "d"::** % "V8":** -! #v_ > > > > >
|
||||
v
|
||||
increment n n*n modulo 1000000 equal to 269696? v if false, loop to right
|
||||
v
|
||||
v"Smallest number whose square ends in 269696 is "0 < else output n below
|
||||
>:#,_$ . 55+, @
|
||||
|
||||
ouput message then n newline exit
|
||||
|
||||
numeric constants explained:
|
||||
|
||||
"d" ascii value of 'd', i.e. 100
|
||||
:: duplicate twice: 100,100,100
|
||||
** multiply twice: 100*100*100 = 1000000
|
||||
|
||||
"V8" ascii values of 'V' and '8', i.e. 86 and 56
|
||||
: duplicate the '8' (56): 86,56,56
|
||||
** multiply twice: 86*56*56 = 269696
|
||||
Loading…
Add table
Add a link
Reference in a new issue