This is a simple Rails application where you can play blackJack with the dealer(SYSTEM).
All game’s data is stored in cards table in the database. Only the dealt cards are stored in database.
The class Game handles all the logic in the game. From player’s and dealer’s score to deciding who is the winner.
There are three API end-points:
-
index (to start the game)
-
hit (blackjack move)
-
stand (blackjack move)