Hello world/Standard error: Difference between revisions
Line 902: | Line 902: | ||
=={{header|XLISP}}== |
=={{header|XLISP}}== |
||
<lang xlisp>(DISPLAY "Goodbye, |
<lang xlisp>(DISPLAY "Goodbye, World!" *ERROR-OUTPUT*)</lang> |
||
=={{header|XPL0}}== |
=={{header|XPL0}}== |
Revision as of 15:16, 10 April 2016
You are encouraged to solve this task according to the task description, using any language you may know.
A common practice in computing is to send error messages to a different output stream than normal text console messages.
The normal messages print to what is called "standard output" or "standard out". The error messages print to "standard error".
This separation can be used to redirect error messages to a different place than normal messages.
Show how to print a message to standard error by printing "Goodbye, World!" on that stream.
4DOS Batch
<lang 4dos>echoerr Goodbye, World!</lang>
Ada
<lang ada>with Ada.Text_IO; use Ada.Text_IO;
procedure Goodbye_World is begin
Put_Line (Standard_Error, "Goodbye, World!");
end Goodbye_World;</lang>
Aime
<lang aime>v_text("Goodbye, World!\n");</lang>
ALGOL 68
The procedures print and printf output to stand out, whereas put and putf can output to any open file, including stand error.
<lang algol68>main:(
put(stand error, ("Goodbye, World!", new line))
)</lang>
- Output:
Goodbye, World!
Argile
<lang Argile>use std eprint "Goodbye, World!"</lang> or <lang Argile>use std eprintf "Goodbye, World!\n"</lang> or <lang Argile>use std fprintf stderr "Goodbye, World!\n"</lang>
ATS
<lang ATS>implement main0 () = fprint (stderr_ref, "Goodbye, World!\n")</lang>
AutoHotkey
requires AutoHotkey_N implementation. <lang autohotkey>; c:\> autohotkey.exe stderr.ahk 2> error.txt FileAppend, Goodbye`, World!, stderr ; requires AutoHotkey_N</lang>
Or with the current AutoHotkey_L:
(documentation on this behavior: http://www.autohotkey.net/~Lexikos/AutoHotkey_L/docs/commands/FileAppend.htm) <lang AutoHotkey>FileAppend, Goodbye`, World!, *</lang>
AutoIt
<lang AutoIt>ConsoleWriteError("Goodbye, World!" & @CRLF)</lang>
AWK
To print a message to standard error, pipe it through a shell command:
<lang awk>BEGIN {
print "Goodbye, World!"| "cat 1>&2"
}</lang>
Or write to /dev/stderr:
<lang awk>BEGIN {
print "Goodbye, World!" > "/dev/stderr"
}</lang>
With gawk, mawk and nawk: a special feature associates "/dev/stderr" with standard error. The manuals of gawk and mawk describe this feature; nawk also has this feature.
Other implementations might try to open /dev/stderr as a file. Some Unix clones, like BSD, have a /dev/stderr device node that duplicates standard error, so this code would still work. Some systems have no such device node, so this code would fail. We recommend "cat 1>&2", which is more portable, and works with any Unix clone.
BASIC
ZX Spectrum Basic
On the ZX Spectrum, standard error is on stream 1:
<lang zxbasic> 10 PRINT #1;"Goodbye, World!" 20 PAUSE 5: REM allow time for the user to see the error message </lang>
Batch File
<lang dos>1>&2 echo Goodbye, World!</lang>
The redirection operator 1>&2
causes all output on stream 1 (standard out) to be redirected to stream 2 (standard error).
The redirection can be moved to the end of the line, too.
BBC BASIC
The program must be compiled as a console application for this to work. <lang bbcbasic> STD_ERROR_HANDLE = -12
SYS "GetStdHandle", STD_ERROR_HANDLE TO @hfile%(1) PRINT #13, "Goodbye, World!" QUIT</lang>
C
Unlike puts(), fputs() does not append a terminal newline. <lang c>#include <stdio.h>
int main() { fprintf(stderr, "Goodbye, "); fputs("World!\n", stderr);
return 0; }</lang>
C#
<lang csharp>static class StdErr {
static void Main(string[] args) { Console.Error.WriteLine("Goodbye, World!"); }
}</lang>
C++
<lang cpp>#include <iostream>
int main () {
std::cerr << "Goodbye, World!" << std::endl;
}</lang>
Clojure
<lang lisp>(binding [*out* *err*]
(println "Goodbye, world!"))</lang>
CMake
Most messages go to standard error.
<lang cmake>message("Goodbye, World!")</lang>
The message cannot be a keyword; message("STATUS")
never prints "STATUS", but message("" "STATUS")
does work.
COBOL
Using fixed format.
<lang cobol> program-id. ehello. procedure division. display "Goodbye, world!" upon syserr. stop run.</lang>
CoffeeScript
<lang coffeescript>console.warn "Goodbye, World!"</lang>
Common Lisp
<lang lisp>(format *error-output* "Goodbye, world!~%")</lang>
D
<lang d>import std.stdio;
void main () {
stderr.writeln("Goodbye, World!");
}</lang>
Alternative Version
<lang d>import tango.io.Stdout;
void main () {
Stderr("Goodbye, World!").newline;
}</lang>
Déjà Vu
<lang dejavu>!write-fragment!stderr !encode!utf-8 "Goodbye, World!\n"</lang>
Delphi
<lang Delphi>program Project1;
{$APPTYPE CONSOLE}
begin
WriteLn(ErrOutput, 'Goodbye, World!');
end.</lang>
Dylan.NET
One Line version: <lang Dylan.NET>Console::get_Error()::WriteLine("Goodbye World!")</lang> Goodbye World Program: <lang Dylan.NET> //compile using the new dylan.NET v, 11.5.1.2 or later //use mono to run the compiler
- refstdasm mscorlib.dll
import System
assembly stderrex exe ver 1.1.0.0
class public Program
method public static void main() Console::get_Error()::WriteLine("Goodbye World!") end method
end class </lang>
E
<lang e>stderr.println("Goodbye, World!")</lang>
Elixir
<lang elixir>IO.puts :stderr, "Goodbye, World!"</lang>
Emacs Lisp
<lang Emacs Lisp> (error "Goodbye, World!")
</lang>
Output:
Goodbye, World!
Erlang
<lang erlang>io:put_chars(standard_error, "Goodbye, World!\n").</lang>
Euphoria
<lang Euphoria>puts(2,"Goodbye, world!\n") -- 2 means output to 'standard error'</lang>
F#
<lang fsharp>eprintfn "%s" "Goodbye, World!"</lang> or you can use the .Net classes <lang fsharp>System.Console.Error.WriteLine("Goodbye, World!");</lang>
Factor
Start Factor in a terminal for this: <lang factor>error-stream get [ "Goodbye, World! bbl, crashing" print flush ] with-output-stream*</lang>
Fantom
<lang fantom> class Main {
public static Void main () { Env.cur.err.printLine ("Goodbye, World!") }
} </lang>
Forth
<lang forth>outfile-id
stderr to outfile-id ." Goodbye, World!" cr
to outfile-id</lang>
Fortran
Normally standard error is associated with the unit 0 but this could be different for different vendors. Therefore since Fortran 2003 there's an intrinsic module which defines the parameter ERROR_UNIT.
<lang fortran>program StdErr
! Fortran 2003 use iso_fortran_env
! in case there's no module iso_fortran_env ... !integer, parameter :: ERROR_UNIT = 0 write (ERROR_UNIT, *) "Goodbye, World!"
end program StdErr</lang>
Frink
<lang frink> staticJava["java.lang.System","err"].println["Goodbye, World!"] </lang>
Go
Built in println now goes to stderr. <lang go>package main func main() { println("Goodbye, World!") }</lang> but the builtin print() and println() functions are not guaranteed to stay in the language. So you should probably use <lang go>package main import ("fmt"; "os") func main() { fmt.Fprintln(os.Stderr, "Goodbye, World!") }</lang>
Groovy
<lang groovy>System.err.println("Goodbye, World!")</lang>
Haskell
<lang haskell>import System.IO main = hPutStrLn stderr "Goodbye, World!"</lang>
Icon and Unicon
<lang icon>procedure main()
write(&errout, "Goodbye World" )
end</lang>
J
<lang j>stderr =: 1!:2&4 stderr 'Goodbye, World!'</lang>
Java
<lang java>public class Err{
public static void main(String[] args){ System.err.println("Goodbye, World!"); }
}</lang>
JavaScript
and only with cscript.exe
<lang javascript>WScript.StdErr.WriteLine("Goodbye, World!");</lang>
<lang javascript>console.warn("Goodbye, World!")</lang>
<lang javascript>console.error("Goodbye, World!")//only works if console object exists</lang> OR <lang javascript>throw new Error("Goodbye, World!")//Should work in any browser</lang>
jq
<lang jq>error("Goodbye, World!")</lang>
Note that although this satisfies the task requirement, error/1 also raises an error condition.
Julia
<lang julia>println(STDERR, "Goodbye, World!")</lang>
Lasso
<lang Lasso>define stderr(s::string) => {
file_stderr->writeBytes(#s->asBytes)
}
stderr('Goodbye, World!')</lang>
Logtalk
The stream alias "user_error" can be used to print to the "standard error" stream. <lang logtalk>
- - object(error_message).
% the initialization/1 directive argument is automatically executed % when the object is compiled and loaded into memory: :- initialization(write(user_error, 'Goodbye, World!\n')).
- - end_object.
</lang>
Lua
<lang lua>io.stderr:write("Goodbye, World!\n")</lang>
m4
<lang m4>errprint(`Goodbye, World! ')dnl</lang>
Mathematica / Wolfram Language
<lang Mathematica>Write[Streams["stderr"], "Goodbye, World!"]</lang>
MATLAB / Octave
This prints to standard error, and continues execution <lang MATLAB>fprintf(2,'Goodbye, World!')</lang> This will not stop further execution, if called from within a script or function. <lang MATLAB>error 'Goodbye, World!'</lang>
Mercury
<lang>
- - module hello_error.
- - interface.
- - import_module io.
- - pred main(io::di, io::uo) is det.
- - implementation.
main(!IO) :-
io.stderr_stream(Stderr, !IO), io.write_string(Stderr, "Goodbye, World!\n", !IO).
</lang>
Metafont
Metafont has no a real way to send a text to the standard output/error nor to a file. Anyway it exists the errmessage
command which will output an error message and prompt the user for action (suspending the interpretation of the source).
<lang metafont>errmessage "Error"; message "...going on..."; % if the user decides to go on and not to stop
% the program because of the error.</lang>
ML/I
<lang ML/I>MCSET S4=1 MCNOTE Goodbye, World!</lang>
Modula-2
<lang modula2>MODULE HelloErr; IMPORT StdError;
BEGIN
StdError.WriteString('Goodbye, World!'); StdError.WriteLn
END HelloErr.</lang>
Modula-3
<lang modula3>MODULE Stderr EXPORTS Main;
IMPORT Wr, Stdio;
BEGIN
Wr.PutText(Stdio.stderr, "Goodbye, World!\n");
END Stderr.</lang>
Nemerle
<lang Nemerle>System.Console.Error.WriteLine("Goodbye, World!");</lang>
NetRexx
<lang NetRexx>/* NetRexx */
options replace format comments java crossref savelog symbols binary
System.err.println("Goodbye, World!") </lang>
Nim
<lang nim>stderr.writeln "Hello World"</lang>
Oberon-2
Oxford Oberon-2 <lang oberon2> MODULE HelloErr; IMPORT Err; BEGIN Err.String("Goodbye, World!");Err.Ln END HelloErr. </lang>
- Output:
Goodbye, World!
Objective-C
In Objective-C one can use the standard C library and the stderr as in the C language; nonetheless a common way to output to stderr for logging purpose and/or error notification is the NSLog function, that works almost like fprintf(stderr, "..."), save for the fact that the format string is an NSString object, and it also prepends a timestamp.
<lang objc>#import <Foundation/Foundation.h>
int main() {
fprintf(stderr, "Goodbye, World!\n"); fputs("Goodbye, World!\n", stderr); NSLog(@"Goodbye, World!"); return 0;
}</lang>
OCaml
<lang ocaml>prerr_endline "Goodbye, World!"; (* this is how you print a string with newline to stderr *) Printf.eprintf "Goodbye, World!\n"; (* this is how you would use printf with stderr *)</lang>
we can also use the out_channel stderr:
<lang ocaml>output_string stderr "Goodbye, World!\n"; Printf.fprintf stderr "Goodbye, World!\n";</lang>
finally the Unix module also provides unbuffered write functions:
<lang ocaml>let msg = "Goodbye, World!\n" in ignore(Unix.write Unix.stderr msg 0 (String.length msg)) ;;</lang>
Octave
<lang octave>fprintf(stderr, "Goodbye, World!\n");</lang>
Oforth
<lang Oforth>System.Err "Goodbye, World!" << cr</lang>
ooRexx
ooRexx provides a .error object that writes output to the standard error stream. <lang ooRexx>.error~lineout("Goodbye, World!")</lang> The .error object is a proxy that delegates to a backing stream, so this might be redirected. By default, this delegates to the .stderr object, which can also be used directly. <lang ooRexx>.stderr~lineout("Goodbye, World!")</lang> or in 'Classic REXX style' <lang ooRexx>/* REXX ---------------------------------------------------------------
- 07.07.2014 Walter Pachl
- 12.07.2014 WP see Discussion where redirection from within the program is shown
- --------------------------------------------------------------------*/
Say 'rexx serr 2>err.txt directs the stderr output to the file err.txt' Call lineout 'stderr','Good bye, world!' Call lineout ,'Hello, world!' Say 'and this is the error output:' 'type err.txt' </lang>
Oz
<lang oz>functor import Application System define
{System.showError "Goodbye, World!"} {Application.exit 0}
end</lang>
PARI/GP
<lang parigp>error("Goodbye, World!")</lang>
Pascal
<lang pascal>program byeworld;
begin
writeln(StdErr, 'Goodbye, World!');
end.</lang>
Perl
<lang perl>warn "Goodbye, World!\n";</lang>
Or:
<lang perl>print STDERR "Goodbye, World!\n";</lang>
Perl 6
<lang perl6>note "Goodbye, World!";</lang>
Phix
<lang Phix>puts(2,"Goodbye, World!\n")</lang>
PHP
<lang php>fprintf(STDERR, "Goodbye, World!\n");</lang> or <lang php>file_put_contents("php://stderr","Hello World!\n");</lang>
PicoLisp
<lang PicoLisp>(out 2 (prinl "Goodbye, World!"))</lang>
PL/I
<lang PL/I>display ('Goodbye, World');</lang>
PostScript
<lang postscript>(%stderr) (w) file dup (Goodbye, World! ) writestring closefile</lang>
PowerBASIC
<lang powerbasic>STDERR "Goodbye, World!"</lang>
PowerShell
Since PowerShell has a slightly different system of pipes and streams (to facilitate easy usage from a host application) the standard Write-Error cmdlet is mainly for sending annotated error messages to the host: <lang powershell>Write-Error "Goodbye, World!"</lang> Note that this outputs more than just the message, because behind the scenes it is an uncaught exception:
Write-Error "Goodbye, World!" : Goodbye, World! + CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException
To accurately reproduce the behavior of other languages one has to resort to .NET in this case: <lang powershell>[Console]::Error.WriteLine("Goodbye, World!")</lang>
PureBasic
ConsoleError() writes the message string (plus a newline) to the standard error output of current program.
Standard error output can be used in conjunction with ReadProgramError() to reads a line from an other programs error output (stderr).
<lang PureBasic>ConsoleError("Goodbye, World!")</lang>
Python
<lang python>import sys
print >> sys.stderr, "Goodbye, World!"</lang>
<lang python>import sys
print("Goodbye, World!", file=sys.stderr)</lang>
Works with either: <lang python>import sys
sys.stderr.write("Goodbye, World!\n")</lang>
R
<lang R>cat("Goodbye, World!", file=stderr())</lang>
Ra
<lang Ra> class HelloWorld **Prints "Goodbye, World!" to standard error**
on start
print to Console.error made !, "Goodbye, World!" </lang>
Racket
<lang Racket> (eprintf "Goodbye, World!\n") </lang>
Retro
<lang Retro>with files' "Goodbye, World!" tempString dup getLength "/dev/stderr" spew</lang>
REXX
version 1
This version will work with those operating systems (hosts)
that support stream output and a STDERR output
stream (by name).
If the stderr name is supported and enabled, the output is written to the terminal.
If not supported or disabled, the output is written to a (disk) file named STDERR.
<lang rexx>call lineout 'STDERR', "Goodbye, World!"</lang>
version 2
Same as above, but uses a different style and also invokes charout instead of lineout. <lang rexx>msgText = 'Goodbye, World!' call charout 'STDERR', msgText</lang>
version 3
this works on Windows 7 and ooRexx and REGINA <lang rexx>/* REXX ---------------------------------------------------------------
- 07.07.2014 Walter Pachl
- enter the appropriate command shown in a command prompt.
- "rexx serr.rex 2>err.txt"
- or "regina serr.rex 2>err.txt"
- 2>file will redirect the stderr stream to the specified file.
- I don't know any other way to catch this stream
- --------------------------------------------------------------------*/
Parse Version v Say v Call lineout 'stderr','Good bye, world!' Call lineout ,'Hello, world!' Say 'and this is the error output:' 'type err.txt'</lang>
Ring
<lang ring>fputs(stderr,"Goodbye, World!")</lang>
Ruby
<lang ruby>$stderr.puts "Goodbye, World!"</lang>
The following also works, unless you have disabled warnings (ruby command line option "-W0" or set $VERBOSE=nil
)
<lang ruby>warn "Goodbye, World!"</lang>
Run BASIC
<lang runbasic>html "<script> window.open(,'error_msg',); document.write('Goodbye, World!'); </script>""</lang> Run Basic runs in a browser. This opens a new browser window, or a tab in the case of Chrome and some others.
Rust
<lang rust> use std::io::{self,Write};
fn main() {
writeln!(&mut io::stderr(), "Goodbye, world!").expect("Could not write to stderr"); // writeln! supports formatted strings so the following works as well let goodbye = "Goodbye"; let world = "world"; writeln!(&mut io::stderr(), "{}, {}!", goodbye, world).expect("Could not write to stderr");
} </lang>
or <lang rust> use std::io::{self, Write}; fn main() {
io::stderr().write(b"Goodbye, world!").expect("Could not write to stderr"); // With some finagling, you can do a formatted string here as well let goodbye = "Goodbye"; let world = "world"; io::stderr().write(&*format!("{}, {}!", goodbye, world).as_bytes()).expect("Could not write to stderr"); // Clearly, if you want formatted strings there's no reason not to just use writeln!
}</lang>
Salmon
<lang Salmon> standard_error.print("Goodbye, World!\n"); </lang>
or
<lang Salmon> include "short.salm"; stderr.print("Goodbye, World!\n"); </lang>
or
<lang Salmon> include "shorter.salm"; err.print("Goodbye, World!\n"); </lang> or
<lang Salmon> include "shorter.salm"; se.print("Goodbye, World!\n"); </lang>
Sather
<lang sather>class MAIN is
main is #ERR + "Hello World!\n"; end;
end;</lang>
Scala
Ad hoc REPL solution
Ad hoc solution as REPL script: <lang Scala>Console.err.println("Goodbye, World!")</lang>
Via Java runtime
This is a call to the Java run-time library. Not recommendated. <lang Scala>System.err.println("Goodbye, World!")</lang>
Via Scala Console API
This is a call to the Scala API. Recommendated. <lang Scala>Console.err.println("Goodbye, World!")</lang>
Short term deviation to err
<lang Scala>Console.withOut(Console.err) { println("This goes to default _err_") }</lang>
Long term deviation to err
<lang Scala> println ("Out not deviated")
Console.setOut(Console.err) println ("Out deviated") Console.setOut(Console.out) // Reset to normal</lang>
Scheme
<lang scheme>(error "Goodbye, World!")</lang>
sed
Requires /dev/stderr
<lang sed>#n 1 { s/.*/Goodbye, World!/w /dev/stderr }</lang>
This program requires at least 1 line of input. It changes the first line to "Goodbye, World!" and then prints the first line to standard error. It reads and ignores the remaining lines.
- Test output:
<lang bash>$ echo a | sed -f error.sed >/dev/null Goodbye, World!</lang>
Seed7
<lang seed7>$ include "seed7_05.s7i";
const proc: main is func
begin writeln(STD_ERR, "Goodbye, World!"); end func;</lang>
Sidef
<lang ruby>STDERR.println("Goodbye, World!");</lang>
Slate
<lang slate>inform: 'Goodbye, World!' &target: DebugConsole.</lang>
Smalltalk
The details on to which name stderr is bound may vary between Smalltalk dialects. If different, a "Smalltalk at:#Stderr put:<name your stream here>" should provide compatibility.
<lang smalltalk>Stderr nextPutAll: 'Goodbye, World!'</lang>
However, all smalltalks provide a console named "Transcript", where diagnostics is usually sent to. Thus:
<lang smalltalk>Transcript show: 'Goodbye, World!'</lang>
will work on all, and is the preferred way to do this. And yes, when operating UI-less, the global "Transcript" is usually bound to the stderr stream.
SNOBOL4
<lang snobol4> terminal = "Error"
output = "Normal text"
end</lang>
Standard ML
<lang sml>TextIO.output (TextIO.stdErr, "Goodbye, World!\n")</lang>
Swift
<lang Swift>import Foundation
let out = NSOutputStream(toFileAtPath: "/dev/stderr", append: true) let err = "Goodbye, World!".dataUsingEncoding(NSUTF8StringEncoding, allowLossyConversion: false) out?.open() let success = out?.write(UnsafePointer<UInt8>(err!.bytes), maxLength: err!.length) out?.close()
if let bytes = success {
println("\nWrote \(bytes) bytes")
}</lang>
- Output:
Goodbye, World! Wrote 15 bytes
Tcl
<lang tcl>puts stderr "Goodbye, World!"</lang>
Transact-SQL
<lang Transact-SQL> RAISERROR 'Goodbye, World!', 16, 1 </lang>
TUSCRIPT
<lang tuscript> $$ MODE TUSCRIPT PRINT/ERROR "hello world" text="goodbye world" PRINT/ERROR text </lang>
- Output:
@@@@@@@@ hello world @@@@@@@@ @@@@@@@@ goodbye world @@@@@@@@
UNIX Shell
<lang bash>echo "Goodbye, World!" >&2</lang>
C Shell
<lang csh>echo "Goodbye, World!" >/dev/stderr</lang>
This requires /dev/stderr
, a device node from BSD
and some other Unix clones.
This command works with both Bourne Shell and C Shell.
X86 Assembly
This is known to work on Linux, it may or may not work on other Unix-like systems
Note that it is only 2 characters different from the Assembly example on User Output - text
Prints "Goodbye, World!" to stderr (and there is probably an even simpler version): <lang asm>section .data msg db 'Goodbye, World!', 0AH len equ $-msg
section .text global _start _start: mov edx, len
mov ecx, msg mov ebx, 2 mov eax, 4 int 80h
mov ebx, 1 mov eax, 1 int 80h</lang>
XLISP
<lang xlisp>(DISPLAY "Goodbye, World!" *ERROR-OUTPUT*)</lang>
XPL0
The terms "standard output" and "standard error" are not used, but it's trivial to send messages to a variety of devices by specifying their numbers. Normally messages are displayed on the text console, which is device 0. Instead, this example sends the message to the (first) printer, which is device 2.
<lang XPL0>code Text=12; Text(2, "Goodbye, World!")</lang>
zkl
<lang zkl>File.stderr.writeln("Goodbye, World!")</lang>
- Programming Tasks
- Basic language learning
- Selection/Short Circuit/Console Program Basics
- Streams
- Applesoft BASIC/Omit
- Bc/Omit
- Brainf***/Omit
- Dc/Omit
- GUISS/Omit
- Integer BASIC/Omit
- Jack/Omit
- TI-83 BASIC/Omit
- TI-89 BASIC/Omit
- Unlambda/Omit
- 4DOS Batch
- Ada
- Aime
- ALGOL 68
- Argile
- ATS
- AutoHotkey
- AutoIt
- AWK
- BASIC
- ZX Spectrum Basic
- Batch File
- BBC BASIC
- C
- C sharp
- C++
- Clojure
- CMake
- COBOL
- CoffeeScript
- Common Lisp
- D
- Tango
- Déjà Vu
- Delphi
- Dylan.NET
- E
- Elixir
- Emacs Lisp
- Erlang
- Euphoria
- F Sharp
- Factor
- Fantom
- Forth
- Fortran
- Frink
- Go
- Groovy
- Haskell
- Icon
- Unicon
- J
- Java
- JavaScript
- Jq
- Julia
- Lasso
- Logtalk
- Lua
- M4
- Mathematica
- Wolfram Language
- MATLAB
- Octave
- Mercury
- Metafont
- ML/I
- Modula-2
- Modula-3
- Nemerle
- NetRexx
- Nim
- Oberon-2
- Objective-C
- OCaml
- Oforth
- OoRexx
- Oz
- PARI/GP
- Pascal
- Perl
- Perl 6
- Phix
- PHP
- PicoLisp
- PL/I
- PostScript
- PowerBASIC
- PowerShell
- PureBasic
- Python
- R
- Ra
- Racket
- Retro
- REXX
- Ring
- Ruby
- Run BASIC
- Rust
- Salmon
- Sather
- Scala
- Console
- Scheme
- Sed
- Seed7
- Sidef
- Slate
- Smalltalk
- SNOBOL4
- Standard ML
- Swift
- Tcl
- Transact-SQL
- TUSCRIPT
- UNIX Shell
- C Shell
- X86 Assembly
- XLISP
- XPL0
- Zkl