diff options
author | Vincent Ambo <tazjin@google.com> | 2019-12-21T00·38+0000 |
---|---|---|
committer | Vincent Ambo <tazjin@google.com> | 2019-12-21T00·38+0000 |
commit | 8c5335a7b5871e6ce78a73103f383a7798442848 (patch) | |
tree | 19800cf7ebc316107cd23bbfba5aa37e9f87dced /presentations/erlang-2016/src/hello_server.erl | |
parent | fcf6ab2d9fc0b2081421885431f6c431087f0ff2 (diff) | |
parent | 8ab71587a7fe532785950ed9dbc2bcfa1acdfcc4 (diff) |
merge(erlang-presentation): Merge at //presentations/erlang-2016 r/258
Diffstat (limited to 'presentations/erlang-2016/src/hello_server.erl')
-rw-r--r-- | presentations/erlang-2016/src/hello_server.erl | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/presentations/erlang-2016/src/hello_server.erl b/presentations/erlang-2016/src/hello_server.erl new file mode 100644 index 000000000000..01df14ac57d5 --- /dev/null +++ b/presentations/erlang-2016/src/hello_server.erl @@ -0,0 +1,12 @@ +-module(hello_server). +-export([start_server/0, server/0]). + +start_server() -> + spawn(fun() -> server() end). + +server() -> + receive + {greet, Name} -> + io:format("Hello ~s!~n", [Name]), + hello_server:server() + end. |