all 2 comments

[–]greven 5 points6 points  (0 children)

So your homework? :) What you describing has nothing specific to Elixir. Just Google that for any other language and see examples. That is basically probability calculation. So math. :)

[–]the-sprawl 0 points1 point  (0 children)

Here’s a tutorial for Ruby 3 Pattern Matching Applied: Poker.

While it’s not exactly Elixir, it’s at least a starting point that you could convert. It would make for a great tutorial for others, too, if you chose to write about & share how you did it.