Iterated Prisoner's Dilemma in myriad languages
jacquesfuentes.comI think I will try my hand at an Elixir version, based off the (very functionally well written!) Ruby version.
Also, you should have test suites for these. :)
Elixir's pretty cool if you haven't played with it yet- http://elixir-lang.org
It's like Ruby, but 100% functional, immutable, concurrent, and faster. :)
Thanks for the compliment and please do submit an Elixir version. I'm played around a bit with Erlang/Elixir but not substantially. I try to follow the Elixir community a bit and have done extensive reading of the OTP/actor system in Erlang :) Also, one of the reviewers of the article, Daniel Farrell, does Elixir for fun: https://github.com/danielfarrell/sass.ex.
Regarding test suites: yeah, I agree but it's a first pass and right now the "test" is "does running the program produce the correct output?" and that's sufficient for now:)
that "test" is literally 1 step away from a "proper" test :) Slap an "assert_equal" in there and boom, tested! Or heck even "raise unless expected == actual"
Good point! I'll add an issue for it. Where's that Elixir version? :))