The Wayback Machine - http://web.archive.org/web/20201127014853/http://21%E5%A4%A9%E5%AD%A6%E9%80%9Aerlang.github.io/

21天学通Erlang

2015年10月18日

如何同步代码片段


21Erlang便

snip.pymy-first-snippet% SNIP BEGIN % SNIP END
% SNIP BEGIN my-first-snippet
hello() ->
    world.
% SNIP END

snip.py build
hello() ->
    world.

Erlangclause;clause.%- SNIP ENDbuild;.clause
% SNIP BEGIN my-second-snippet
hello(1) ->
    world
%- SNIP END
.

snip.py build
hello(1) ->
    world.

clause
% SNIP BEGIN my-second-snippet
hello(1) ->
    world
%- SNIP END
;
hello(2) ->
    big_world.

snip.py build
hello(1) ->
    world;
hello(2) ->
    big_world.

LaTeXErlang%LaTeXPDF使% SNIP REFERENCE
% SNIP REFERENCE hello.erl my-first-snippet
\begin{SourceCode}
% SNIP BEGIN my-first-snippet
hello(1) ->
    world.
% SNIP END
\end{SourceCode}

snip.py statussnip.py sync
2015年10月11日

核对Erlang Shell会话的记录


21ErlangShellPDF

便ErlangShellSessionenvironmentLaTeXErlang Shell
\newcounter{erlangshellsession}[section]
\newoutputstream{erlangshellsession}
\newenvironment{ErlangShellSession}{
\stepcounter{erlangshellsession}
\openoutputfile{\currfiledir\theerlangshellsession.session}{erlangshellsession}
\writeverbatim{erlangshellsession}
}{
\endwriteverbatim
\closeoutputstream{erlangshellsession}
\begin{SingleSpacing}
\lstinputlisting[title={Erlang Shell}]{\currfiledir\theerlangshellsession.session}
\end{SingleSpacing}}

OTPPythondoctestErlangJoe ArmstrongErlang Questions[1]

Erlang ShellREPLShellprocessgroup leaderI/O protocolShellget_untilShellput_charsShelleofShell退
[1]Programmatic interface to the shell
2015年10月04日

为什么21天能学通Erlang


21Peter Norvig广21

2121Erlang1Erlang21Perl 6[1]


[1]

When Perl 6 arrives, every day will be like Christmas!

Pugs, an implementation of Perl 6

1 / 1