September Morn Update

This commit is contained in:
Ingy döt Net 2019-09-12 10:33:56 -07:00
parent 4e2d22a71d
commit aac6731f2c
6856 changed files with 141342 additions and 21127 deletions

View file

@ -0,0 +1,15 @@
100 PROGRAM "Type.bas"
110 TEXT 80
120 INPUT PROMPT "File name: ":F$
130 WHEN EXCEPTION USE IOERROR
140 OPEN #1:F$ ACCESS INPUT
150 DO
160 LINE INPUT #1,IF MISSING EXIT DO:F$
170 PRINT F$
180 LOOP
190 CLOSE #1
200 END WHEN
210 HANDLER IOERROR
220 PRINT EXSTRING$(EXTYPE)
230 END
240 END HANDLER

View file

@ -0,0 +1,11 @@
100 PROGRAM "Type.bas"
110 INPUT PROMPT "File name: ":F$
120 WHEN EXCEPTION USE IOERROR
130 OPEN #1:F$
140 COPY FROM #1 TO #0
150 CLOSE #1
160 END WHEN
170 HANDLER IOERROR
180 PRINT EXSTRING$(EXTYPE)
190 CLOSE #1
200 END HANDLER

View file

@ -1,8 +1,8 @@
import system'routines.
import system'io.
import extensions'routines.
import system'routines;
import system'io;
import extensions'routines;
program =
[
ReaderEnumerator new(File new:"file.txt"); forEach:printingLn.
].
public program()
{
ReaderEnumerator.new(File.assign:"file.txt").forEach(printingLn)
}

View file

@ -1,10 +1,10 @@
import system'io.
import system'io;
program =
[
var reader := File new:"file.txt"; textreader.
while (reader available)
[
console writeLine(reader readLiteral).
].
].
public program()
{
var reader := File.assign:"file.txt".textreader();
while (reader.Available)
{
console.writeLine(reader.readLine())
}
}

View file

@ -0,0 +1,7 @@
let rec input_caller () =
let input = read_line() in
your_function input ;
input_caller() ;
;;
let () = input_caller()

View file

@ -1,6 +1,4 @@
/*REXX program reads from the (console) default input stream until null*/
do until _==''
parse pull _
end /*until ...*/
exit /*stick a fork in it, we're done.*/
end /*until*/ /*stick a fork in it, we're done.*/

View file

@ -1,6 +1,4 @@
/*REXX program reads from the (console) default input stream until null*/
do until _==''
_=linein()
end /*until ...*/
exit /*stick a fork in it, we're done.*/
_= linein()
end /*until*/ /*stick a fork in it, we're done.*/

View file

@ -0,0 +1,10 @@
Public Sub test()
Dim filesystem As Object, stream As Object, line As String
Set filesystem = CreateObject("Scripting.FileSystemObject")
Set stream = filesystem.OpenTextFile("D:\test.txt")
Do While stream.AtEndOfStream <> True
line = stream.ReadLine
Debug.Print line
Loop
stream.Close
End Sub