Skip to content

vlmaier/indigo-card-game

Repository files navigation

Indigo Card Game

Repository for learning Kotlin w/ JetBrains Academy Indigo Card Game Project.

Learning outcomes

Create a fun game that you can play afterward. Refine your skills in using lists and Object-oriented programming. Test yourself to create an algorithm that provides competition to the players of the game.

Game

Indigo Card Game
Play first?
yes
Initial cards on the table: Q♥ 10♣ A♠ J♠

4 cards on the table, and the top card is J♠
Cards in hand: 1)7♠ 2)5♣ 3)3♠ 4)K♦ 5)6♣ 6)2♣
Choose a card to play (1-6):
1
Player wins cards
Score: Player 4 - Computer 0
Cards: Player 5 - Computer 0

No cards on the table
A♣ 2♥ 7♦ 8♠ 8♦ 4♥
Computer plays 2♥

1 cards on the table, and the top card is 2♥
Cards in hand: 1)5♣ 2)3♠ 3)K♦ 4)6♣ 5)2♣
Choose a card to play (1-5):
5
Player wins cards
Score: Player 4 - Computer 0
Cards: Player 7 - Computer 0

No cards on the table
A♣ 7♦ 8♠ 8♦ 4♥
Computer plays 7♦

1 cards on the table, and the top card is 7♦
Cards in hand: 1)5♣ 2)3♠ 3)K♦ 4)6♣
Choose a card to play (1-4):
...