lambdaclass / erlings Goto Github PK
View Code? Open in Web Editor NEWSmall exercises to get you used to reading and writing Erlang code
License: MIT License
Small exercises to get you used to reading and writing Erlang code
License: MIT License
"Create N process in a ring. Send a message round the ring M times so that a total of N * M messages get sent. Time how long this takes for different values of N and M."
Add excercise that uses message passing with two node and where one node overflows the other. Let's discuss this tomorrow @hernanex3
instead of printing, the processing could consist in pushing a value (for example the priority atom vip/normal) to a list in the state of the loop process. Then you could add a call to the server that returns the current state.
Using this you could have a proper unit test instead of just checking the console output.
In the exercise the result is a list of lists, but it should be a list of tuples.
READMEs:
I've checked out the erlings repository and then run make in the top level as instructed, however I do not see the correct output - I get an error as below:
... erlings (master) $ make
cd otp/shopping_cart && ../../rebar3 as test otp/shopping_cart libraries/shortly sequential/filter_fibonacci_numbers sequential/bank_accounts sequential/hello sequential/calculate_bmi sequential/insert_element_at sequential/filter_numbers sequential/hello_pattern sequential/maps sequential/lists sequential/installing distributed/remote_fun concurrent/ring_benchmark concurrent/priority otp libraries sequential distributed concurrent ct
===> Command 'otp/shopping_cart' not found
make: *** [Makefile:16: otp/shopping_cart] Error 1
Would appreciate any help you can give. Tested with Erlang 18.3 and Erlang 20.1
In readme add list of links to read for learning erlang the language and the system
Make $EXERCISE
fails due to problem related to Common TestI'm trying to run the tests as instructed in the README.md
files, but I'm getting this error related to Common Test Hooks:
bash-3.2$ pwd
/Users/lambda/code/erlings
bash-3.2$ make sequential/filter_numbers
cd sequential/filter_numbers && ../../rebar3 as test ct
===> Verifying dependencies...
===> Compiling filter_numbers
===> Running Common Test suites...
%%% filter_numbers_SUITE:
%%% filter_numbers_SUITE ==> run_eunit: FAILED
%%% filter_numbers_SUITE ==> {fail,"cth_readable_failonly:on_tc_fail/3 CTH call failed"}
%%% undefined ==> end_per_suite: FAILED
%%% undefined ==> {fail,"cth_readable_failonly:on_tc_fail/3 CTH call failed"}
Failed 1 tests. Passed 0 tests.
Results written to "/Users/lambda/code/erlings/sequential/filter_numbers/_build/test/logs/index.html".
===> Failures occurred running tests: 1
make: *** [sequential/filter_numbers] Error 1
I was able to run eunit
from the exercises subdirectories with no problem:
joaquin-lambda:filter_numbers lambda$ pwd
/Users/lambda/code/erlings/sequential/filter_numbers
joaquin-lambda:filter_numbers lambda$ rebar3 eunit
===> Verifying dependencies...
===> Compiling filter_numbers
===> Performing EUnit tests...
...
Finished in 0.047 seconds
3 tests, 0 failures
As @juanbono pointed out, this is related to erlang/rebar3#2063
Things I tried:
eunit
from the rebar3
binary that came with the repo.ct
with the rebar3
binary thar came with the repo.ct
using my installed version of rebar3
Simple bit.ly clone. Receives long urls and returns another but shorter. Should support simple http post/get for that, and also use websocket to show in '/new' the new links shortened.
Check https://people.kth.se/~johanmon/dse.html and see if there are any exercises we can add.
in the main readme, and/or add excercise number in the folder
Create a simple Erlang cluster of two nodes, one should receive and become the function received.
Create an exercise to practice state machines, and logging.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.