September 2017 Update

This commit is contained in:
Ingy döt Net 2017-09-23 10:01:46 +02:00
parent bba7bfd280
commit ba8067c3b7
14570 changed files with 153136 additions and 63871 deletions

View file

@ -3,5 +3,5 @@ I:=1024;
WHILE I>0 DO
BEGIN
OUTINT(I);
I:=I/2
I:=I DIV 2
END

View file

@ -0,0 +1,8 @@
begin
integer i;
i := 1024;
while i > 0 do begin
write( i );
i := i / 2;
end;
end

View file

@ -0,0 +1,7 @@
scope
local i := 1024;
while i > 0 do
print( i );
i := i \ 2
od
epocs

View file

@ -0,0 +1,5 @@
i = 1024
WHILE i > 0
PRINT i
i = i / 2
WEND

View file

@ -0,0 +1,5 @@
i = 1024
while (i > 0) {
i
i /= 2
}

View file

@ -0,0 +1,10 @@
$ i = 1024
$Loop:
$ IF ( i .LE. 0 ) THEN GOTO LoopEnd
$ WRITE sys$output F$FAO( " i = !4UL", i ) ! formatted ASCII output, fixed-width field
$ ! Output alternatives:
$ ! WRITE sys$output F$STRING( i ) ! explicit integer-to-string conversion
$ ! WRITE sys$output i ! implicit conversion to string/output
$ i = i / 2
$ GOTO Loop
$LoopEnd:

View file

@ -0,0 +1 @@
1024[$][$.10,2/\%]# {Short form}

View file

@ -0,0 +1,6 @@
1024 {push 1024 on stack}
[ ][ ]# {while[condition>0][do]}
$ {DUP}
$. {DUP, print top of stack to STDOUT}
10, {print newline}
2/\% {2 DIV/MOD SWAP POP}

View file

@ -0,0 +1 @@
1024[$][$.10,1»]#

View file

@ -1,9 +1,7 @@
#import system.
#symbol program =
program =
[
#var(type:int)i := 1024.
#loop (i > 0)?
int i := 1024.
while (i > 0)
[
console writeLine:i.

View file

@ -0,0 +1,9 @@
Public Sub Main()
Dim siCount As Short = 1024
While siCount > 0
Print siCount;;
siCount /= 2
Wend
End

View file

@ -0,0 +1,5 @@
U16 i = 1024;
while (i > 0) {
Print("%d\n", i);
i /= 2;
}

View file

@ -0,0 +1,24 @@
DEF X:INT
X=1024
OPENCONSOLE
WHILE X>0
PRINT X
X=X/2
ENDWHILE
'Output starts with 1024 and ends with 1.
'Putting the following in the loop will produce output starting with 512 and ending with 0:
'X=X/2
'PRINT X
'When compiled as a console only program, a press any key to continue message is automatic.
'I presume code is added by the compiler.
CLOSECONSOLE
'Since this is, in fact, an IWBASIC console program, which compiles and runs.
END

View file

@ -0,0 +1,9 @@
// version 1.0.6
fun main(args: Array<String>) {
var value = 1024
while (value > 0) {
println(value)
value /= 2
}
}

View file

@ -1,4 +0,0 @@
var n: int = 1024
while n > 0:
echo(n)
n = n div 2

View file

@ -0,0 +1,5 @@
n := 1024;
while n > 0 loop
print( n );
n := n div 2;
end loop;

View file

@ -0,0 +1,5 @@
n = 1024
>
#.output(n)
n /= 2
< n!<1

View file

@ -0,0 +1,9 @@
begin
integer i;
i:=1024;
while i>0 do
begin
outint(i,5);
i:=i//2-1
end
end

View file

@ -0,0 +1,5 @@
10 LET I=1024
20 IF I=0 THEN GOTO 60
30 PRINT I
40 LET I=INT (I/2)
50 GOTO 20

View file

@ -0,0 +1,5 @@
local n=1024
while `n'>0 {
display `n'
local n=floor(`n'/2)
}

View file

@ -1,6 +0,0 @@
i = 1024
while (i > 0)
{
Print(i)
i = (i / 2).Floor()
}

View file

@ -0,0 +1,6 @@
DECLARE @i INT = 1024;
WHILE @i >0
BEGIN
PRINT @i;
SET @i = @i / 2;
END;

View file

@ -0,0 +1 @@
n:=1024; while(n>0){println(n); n/=2;}