-module(helloworld). -export([start/0]). start() -> io:fwrite("~p~n",[registered()]).
-module(helloworld). -export([start/0, call/2]). call(Arg1, Arg2) -> io:format("~p ~p~n", [Arg1, Arg2]). start() -> Pid = spawn(?MODULE, call, ["hello", "process"]), io:fwrite("~p~n",[pid_to_list(Pid)]).
-module(helloworld). -export([start/0, call/2]). call(Arg1, Arg2) -> io:format("~p ~p~n", [Arg1, Arg2]). start() -> Pid = spawn(?MODULE, call, ["hello", "process"]), io:fwrite("~p~n",[is_process_alive(Pid)]).
-module(helloworld). -export([start/0, call/2]). call(Arg1, Arg2) -> io:format("~p ~p~n", [Arg1, Arg2]). start() -> Pid = spawn(?MODULE, call, ["hello", "process"]), io:fwrite("~p",[is_pid(Pid)]).
-module(helloworld). -export([start/0, call/2]). call(Arg1, Arg2) -> io:format("~p ~p~n", [Arg1, Arg2]). start() -> Pid = spawn(?MODULE, call, ["hello", "process"]), io:fwrite("~p",[Pid]).
-module(helloworld). -export([start/0]). start() -> Adder = fun(X) -> fun(Y) -> io:fwrite("~p~n",[X + Y]) end end, A = Adder(6), A(10).
-module(helloworld). -export([start/0]). start() -> B = 6, A = fun(X) -> io:fwrite("~p~n",[X]), io:fwrite("~p~n",[B]) end, A(5).
-module(helloworld). -export([start/0]). start() -> A = fun(X) -> io:fwrite("~p~n",[X]) end, A(5).
-module(helloworld). -export([start/0]). start() -> A = fun() -> io:fwrite("Hello") end, A().
-module(helloworld). -export([start/0]). start() -> io:fwrite("~p~n",[binary_to_atom(<<"Erlang">>, latin1)]).
We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy. Accept Learn more