Paste: hello world + stdout ?

Author: zimbatm
Mode: factor
Date: Fri, 1 May 2009 21:44:23
Plain Text |
#! ./factor

USING: io accessors ;
IN: hello

: hello-world ( -- )
  "hello one" write ;

MAIN: hello-world

Annotation: output test

Author: zimbatm
Mode: factor
Date: Fri, 1 May 2009 21:45:58
Plain Text |
USING: io io.files io.encodings.utf8 namespaces prettyprint ;
IN: hello2

SYMBOL: output-tmp

: main ( -- )
  output-stream get output-tmp set
  "data.txt" utf8 <file-writer> [ output-tmp get . ] with-output-stream ;

MAIN: main

New Annotation

Summary:
Author:
Mode:
Body: