Data update

This commit is contained in:
Ingy döt Net 2026-02-01 16:33:20 -08:00
parent 5150844a7d
commit 4bb20c9b71
7735 changed files with 38060 additions and 199180 deletions

View file

@ -1,63 +0,0 @@
with Loopers;
use Loopers;
procedure For_Main is
begin
Looper_1;
Looper_2;
Looper_3;
end For_Main;
package Loopers is
procedure Looper_1;
procedure Looper_2;
procedure Looper_3;
end Loopers;
with Ada.Text_IO, Ada.Integer_Text_IO;
use Ada.Text_IO, Ada.Integer_Text_IO;
package body Loopers is
procedure Looper_1 is
Values : array(1..5) of Integer := (2,4,6,8,10);
begin
for I in Values'Range loop
Put(Values(I),0);
if I = Values'Last then
Put_Line(".");
else
Put(",");
end if;
end loop;
end Looper_1;
procedure Looper_2 is
E : Integer := 5;
begin
for I in 1..E loop
Put(I*2,0);
if I = E then
Put_Line(".");
else
Put(",");
end if;
end loop;
end Looper_2;
procedure Looper_3 is
Values : array(1..10) of Integer := (1,2,3,4,5,6,7,8,9,10);
Indices : array(1..5) of Integer := (2,4,6,8,10);
begin
for I in Indices'Range loop
Put(Values(Indices(I)),0);
if I = Indices'Last then
Put_Line(".");
else
Put(",");
end if;
end loop;
end Looper_3;
end Loopers;

View file

@ -1,14 +0,0 @@
IDENTIFICATION DIVISION.
PROGRAM-ID. Display-Odd-Nums.
DATA DIVISION.
WORKING-STORAGE SECTION.
01 I PIC 99.
PROCEDURE DIVISION.
PERFORM VARYING I FROM 1 BY 2 UNTIL 10 < I
DISPLAY I
END-PERFORM
GOBACK
.

View file

@ -1,6 +0,0 @@
// Can be set on commandline via --N=x
config const N = 3;
for i in 1 .. 10 by N {
writeln(i);
}

View file

@ -1,7 +1,7 @@
public program()
public Program()
{
for(int i := 2; i <= 8; i += 2 )
{
console.writeLine(i)
Console.writeLine(i)
}
}

View file

@ -1,3 +0,0 @@
for i = 1 to 10 by 2 do
? i
end for

View file

@ -1,2 +0,0 @@
print(1, something)
puts(1, "\n")

View file

@ -1,23 +0,0 @@
class Step {
var end:Int;
var step:Int;
var index:Int;
public inline function new(start:Int, end:Int, step:Int) {
this.index = start;
this.end = end;
this.step = step;
}
public inline function hasNext() return step > 0 ? end >= index : index >= end;
public inline function next() return (index += step) - step;
}
class Main {
static function main() {
for (i in new Step(2, 8, 2)) {
Sys.print('$i ');
}
Sys.println('WHOM do we appreciate? GRAMMAR! GRAMMAR! GRAMMAR!');
}
}

View file

@ -1,14 +0,0 @@
MODULE LoopForStep;
IMPORT
Out;
VAR
i: INTEGER;
BEGIN
FOR i := 0 TO 10 BY 3 DO
Out.LongInt(i,0);Out.Ln
END;
FOR i := 10 TO 0 BY -3 DO
Out.LongInt(i,0);Out.Ln
END
END LoopForStep.

View file

@ -1,3 +0,0 @@
for ($i = 0; $i -lt 10; $i += 2) {
$i
}

View file

@ -1,2 +0,0 @@
for i 2 8 2 [prin join i ", "]
print "who do we appreciate?"

View file

@ -1,5 +0,0 @@
buffer = ""
For i = 2 To 8 Step 2
buffer = buffer & i & " "
Next
WScript.Echo buffer