Shell one-liner

From Rosetta Code
Revision as of 16:49, 26 August 2008 by 12.3.123.65 (talk) (added J)
Task
Shell one-liner
You are encouraged to solve this task according to the task description, using any language you may know.

Execute one line of code from the shell.

OCaml

% ocaml <(echo 'print_endline "Hello"')
Hello

Perl

% perl -e 'print "Hello\n"'
Hello

J

% jconsole -js "exit echo 'Hello'"
Hello