Data update
This commit is contained in:
parent
5150844a7d
commit
4bb20c9b71
7735 changed files with 38060 additions and 199180 deletions
|
|
@ -1,13 +0,0 @@
|
|||
with Ada.Text_IO; use Ada.Text_IO;
|
||||
|
||||
procedure Test_Recursion_Depth is
|
||||
function Recursion (Depth : Positive) return Positive is
|
||||
begin
|
||||
return Recursion (Depth + 1);
|
||||
exception
|
||||
when Storage_Error =>
|
||||
return Depth;
|
||||
end Recursion;
|
||||
begin
|
||||
Put_Line ("Recursion depth on this system is" & Integer'Image (Recursion (1)));
|
||||
end Test_Recursion_Depth;
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
;AutoIt Version: 3.2.10.0
|
||||
$depth=0
|
||||
recurse($depth)
|
||||
Func recurse($depth)
|
||||
ConsoleWrite($depth&@CRLF)
|
||||
Return recurse($depth+1)
|
||||
EndFunc
|
||||
|
|
@ -1,50 +0,0 @@
|
|||
identification division.
|
||||
program-id. recurse.
|
||||
data division.
|
||||
working-storage section.
|
||||
01 depth-counter pic 9(3).
|
||||
01 install-address usage is procedure-pointer.
|
||||
01 install-flag pic x comp-x value 0.
|
||||
01 status-code pic x(2) comp-5.
|
||||
01 ind pic s9(9) comp-5.
|
||||
|
||||
|
||||
linkage section.
|
||||
01 err-msg pic x(325).
|
||||
|
||||
procedure division.
|
||||
100-main.
|
||||
|
||||
set install-address to entry "300-err".
|
||||
|
||||
call "CBL_ERROR_PROC" using install-flag
|
||||
install-address
|
||||
returning status-code.
|
||||
|
||||
if status-code not = 0
|
||||
display "ERROR INSTALLING ERROR PROC"
|
||||
stop run
|
||||
end-if
|
||||
|
||||
move 0 to depth-counter.
|
||||
display 'Mung until no good.'.
|
||||
perform 200-mung.
|
||||
display 'No good.'.
|
||||
stop run.
|
||||
|
||||
200-mung.
|
||||
add 1 to depth-counter.
|
||||
display depth-counter.
|
||||
perform 200-mung.
|
||||
300-err.
|
||||
entry "300-err" using err-msg.
|
||||
perform varying ind from 1 by 1
|
||||
until (err-msg(ind:1) = x"00") or (ind = length of err-msg)
|
||||
continue
|
||||
end-perform
|
||||
|
||||
display err-msg(1:ind).
|
||||
|
||||
*> room for a better-than-abrupt death here.
|
||||
|
||||
exit program.
|
||||
|
|
@ -1,25 +0,0 @@
|
|||
IDENTIFICATION DIVISION.
|
||||
PROGRAM-ID. recurse RECURSIVE.
|
||||
DATA DIVISION.
|
||||
WORKING-STORAGE SECTION.
|
||||
01 Starter PIC S9(8) VALUE 1.
|
||||
PROCEDURE DIVISION.
|
||||
Program-Recurse.
|
||||
CALL "recurse-sub" USING Starter
|
||||
STOP RUN.
|
||||
|
||||
IDENTIFICATION DIVISION.
|
||||
PROGRAM-ID. recurse-sub.
|
||||
DATA DIVISION.
|
||||
WORKING-STORAGE SECTION.
|
||||
LINKAGE SECTION.
|
||||
01 Countr PIC S9(8).
|
||||
PROCEDURE DIVISION USING Countr.
|
||||
Program-Recursive.
|
||||
DISPLAY Countr
|
||||
ADD 1 TO Countr
|
||||
CALL "recurse-sub" USING Countr
|
||||
|
||||
EXIT PROGRAM.
|
||||
END PROGRAM recurse-sub.
|
||||
END PROGRAM recurse.
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
(defun my-recurse (n)
|
||||
(my-recurse (1+ n)))
|
||||
(my-recurse 1)
|
||||
=>
|
||||
enters debugger at (my-recurse 595),
|
||||
per the default max-lisp-eval-depth 600 in Emacs 24.1
|
||||
|
|
@ -1,19 +1,18 @@
|
|||
-->
|
||||
<span style="color: #004080;">atom</span> <span style="color: #000000;">t1</span> <span style="color: #0000FF;">=</span> <span style="color: #7060A8;">time<span style="color: #0000FF;">(<span style="color: #0000FF;">)<span style="color: #0000FF;">+<span style="color: #000000;">1</span>
|
||||
with javascript_semantics
|
||||
atom t1 = time()+1
|
||||
|
||||
<span style="color: #004080;">integer</span> <span style="color: #000000;">depth</span> <span style="color: #0000FF;">=</span> <span style="color: #000000;">0</span>
|
||||
integer depth = 0
|
||||
|
||||
<span style="color: #008080;">procedure</span> <span style="color: #000000;">recurse<span style="color: #0000FF;">(<span style="color: #0000FF;">)</span>
|
||||
<span style="color: #008080;">if</span> <span style="color: #7060A8;">time<span style="color: #0000FF;">(<span style="color: #0000FF;">)<span style="color: #0000FF;">><span style="color: #000000;">t1</span> <span style="color: #008080;">then</span>
|
||||
<span style="color: #0000FF;">?<span style="color: #000000;">depth</span>
|
||||
<span style="color: #000000;">t1</span> <span style="color: #0000FF;">=</span> <span style="color: #7060A8;">time<span style="color: #0000FF;">(<span style="color: #0000FF;">)<span style="color: #0000FF;">+<span style="color: #000000;">1</span>
|
||||
<span style="color: #008080;">end</span> <span style="color: #008080;">if</span>
|
||||
<span style="color: #000000;">depth</span> <span style="color: #0000FF;">+=</span> <span style="color: #000000;">1</span>
|
||||
<span style="color: #000080;font-style:italic;">-- only 1 of these will ever get called, of course...</span>
|
||||
<span style="color: #000000;">recurse<span style="color: #0000FF;">(<span style="color: #0000FF;">)</span>
|
||||
<span style="color: #000000;">recurse<span style="color: #0000FF;">(<span style="color: #0000FF;">)</span>
|
||||
<span style="color: #000000;">recurse<span style="color: #0000FF;">(<span style="color: #0000FF;">)</span>
|
||||
<span style="color: #008080;">end</span> <span style="color: #008080;">procedure</span>
|
||||
procedure recurse()
|
||||
if time()>t1 then
|
||||
?depth
|
||||
t1 = time()+1
|
||||
end if
|
||||
depth += 1
|
||||
-- only 1 of these will ever get called, of course...
|
||||
recurse()
|
||||
recurse()
|
||||
recurse()
|
||||
end procedure
|
||||
|
||||
<span style="color: #000000;">recurse<span style="color: #0000FF;">(<span style="color: #0000FF;">)
|
||||
<!--
|
||||
recurse()
|
||||
|
|
|
|||
|
|
@ -1,26 +1,26 @@
|
|||
-->
|
||||
<span style="color: #004080;">atom</span> <span style="color: #000000;">t1</span> <span style="color: #0000FF;">=</span> <span style="color: #7060A8;">time<span style="color: #0000FF;">(<span style="color: #0000FF;">)<span style="color: #0000FF;">+<span style="color: #000000;">1</span>
|
||||
with javascript_semantics
|
||||
atom t1 = time()+1
|
||||
|
||||
<span style="color: #004080;">integer</span> <span style="color: #000000;">depth</span> <span style="color: #0000FF;">=</span> <span style="color: #000000;">0<span style="color: #0000FF;">,</span> <span style="color: #000000;">depth_blown</span> <span style="color: #0000FF;">=</span> <span style="color: #004600;">false</span>
|
||||
<span style="color: #004080;">string</span> <span style="color: #000000;">btd</span> <span style="color: #0000FF;">=</span> <span style="color: #008000;">"building"</span>
|
||||
integer depth = 0, depth_blown = false,
|
||||
limit = iff(platform()=JS?8e3:2e7)
|
||||
string btd = "building"
|
||||
|
||||
<span style="color: #008080;">procedure</span> <span style="color: #000000;">recurse<span style="color: #0000FF;">(<span style="color: #0000FF;">)</span>
|
||||
<span style="color: #008080;">if</span> <span style="color: #7060A8;">time<span style="color: #0000FF;">(<span style="color: #0000FF;">)<span style="color: #0000FF;">><span style="color: #000000;">t1</span> <span style="color: #008080;">then</span>
|
||||
<span style="color: #7060A8;">printf<span style="color: #0000FF;">(<span style="color: #000000;">1<span style="color: #0000FF;">,<span style="color: #008000;">"depth: %d (%s)\n"<span style="color: #0000FF;">,<span style="color: #0000FF;">{<span style="color: #000000;">depth<span style="color: #0000FF;">,<span style="color: #000000;">btd<span style="color: #0000FF;">}<span style="color: #0000FF;">)</span>
|
||||
<span style="color: #008080;">if</span> <span style="color: #000000;">depth<span style="color: #0000FF;">><span style="color: #000000;">20<span style="color: #000000;">_000_000</span> <span style="color: #008080;">then</span>
|
||||
<span style="color: #000000;">depth_blown</span> <span style="color: #0000FF;">=</span> <span style="color: #004600;">true</span>
|
||||
<span style="color: #000000;">btd</span> <span style="color: #0000FF;">=</span> <span style="color: #008000;">"tearing down"</span>
|
||||
<span style="color: #008080;">end</span> <span style="color: #008080;">if</span>
|
||||
<span style="color: #000000;">t1</span> <span style="color: #0000FF;">=</span> <span style="color: #7060A8;">time<span style="color: #0000FF;">(<span style="color: #0000FF;">)<span style="color: #0000FF;">+<span style="color: #000000;">1</span>
|
||||
<span style="color: #008080;">end</span> <span style="color: #008080;">if</span>
|
||||
<span style="color: #008080;">if</span> <span style="color: #000000;">depth_blown</span> <span style="color: #008080;">then</span>
|
||||
<span style="color: #000000;">depth</span> <span style="color: #0000FF;">-=</span> <span style="color: #000000;">1</span>
|
||||
<span style="color: #008080;">else</span>
|
||||
<span style="color: #000000;">depth</span> <span style="color: #0000FF;">+=</span> <span style="color: #000000;">1</span>
|
||||
<span style="color: #000000;">recurse<span style="color: #0000FF;">(<span style="color: #0000FF;">)</span> <span style="color: #000080;font-style:italic;">-- (build, aka +1 with progress)</span>
|
||||
<span style="color: #000000;">recurse<span style="color: #0000FF;">(<span style="color: #0000FF;">)</span> <span style="color: #000080;font-style:italic;">-- (tear down, -1 with progress)</span>
|
||||
<span style="color: #008080;">end</span> <span style="color: #008080;">if</span>
|
||||
<span style="color: #008080;">end</span> <span style="color: #008080;">procedure</span>
|
||||
procedure recurse()
|
||||
if time()>t1 or depth>limit then
|
||||
printf(1,"depth: %d (%s)\n",{depth,btd})
|
||||
if depth>limit then
|
||||
depth_blown = true
|
||||
btd = "tearing down"
|
||||
end if
|
||||
t1 = time()+1
|
||||
end if
|
||||
if depth_blown then
|
||||
depth -= 1
|
||||
else
|
||||
depth += 1
|
||||
recurse() -- (build, aka +1 with progress)
|
||||
recurse() -- (tear down, -1 with progress)
|
||||
end if
|
||||
end procedure
|
||||
|
||||
<span style="color: #000000;">recurse<span style="color: #0000FF;">(<span style="color: #0000FF;">)
|
||||
<!--
|
||||
recurse()
|
||||
|
|
|
|||
|
|
@ -1,15 +0,0 @@
|
|||
function TestDepth ( $N )
|
||||
{
|
||||
$N
|
||||
TestDepth ( $N + 1 )
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
TestDepth 1 | ForEach { $Depth = $_ }
|
||||
}
|
||||
catch
|
||||
{
|
||||
"Exception message: " + $_.Exception.Message
|
||||
}
|
||||
"Last level before error: " + $Depth
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
-- 7 Aug 2025
|
||||
-- 23 Aug 2025
|
||||
parse version version
|
||||
say 'FIND LIMIT OF RECURSION'
|
||||
say version
|
||||
|
|
|
|||
|
|
@ -1,13 +0,0 @@
|
|||
'mung.vbs
|
||||
option explicit
|
||||
|
||||
dim c
|
||||
if wscript.arguments.count = 1 then
|
||||
c = wscript.arguments(0)
|
||||
c = c + 1
|
||||
else
|
||||
c = 0
|
||||
end if
|
||||
wscript.echo "[Depth",c & "] Mung until no good."
|
||||
CreateObject("WScript.Shell").Run "cscript Mung.vbs " & c, 1, true
|
||||
wscript.echo "[Depth",c & "] no good."
|
||||
|
|
@ -1,14 +0,0 @@
|
|||
'mung.vbs
|
||||
option explicit
|
||||
|
||||
sub mung(c)
|
||||
dim n
|
||||
n=c+1
|
||||
wscript.echo "[Level",n & "] Mung until no good"
|
||||
on error resume next
|
||||
mung n
|
||||
on error goto 0
|
||||
wscript.echo "[Level",n & "] no good"
|
||||
end sub
|
||||
|
||||
mung 0
|
||||
Loading…
Add table
Add a link
Reference in a new issue