After a few months with his new phone, Mirko decided to find a new hobby. That is how he ran into a card game called bridge.
Bridge is played by four players with a deck of 52 cards. There are four suits (clubs, hearts, diamonds, spades) and thirteen values (A, K, Q, J, 10, 9, 8, 7, 6, 5, 4, 3, 2). Every player gets 13 cards at the start of a game.
Before the game starts, each player counts the honor points in their hand like this:
- each ace (A) is worth 4 points
- each king (K) is worth 3 points
- each queen (Q) is worth 2 points
- each jack (J) is worth 1 point
- every other card is worth 0 points, and this task writes it as X
Mirko took up bridge only recently, so he decided to practice counting. He dealt himself a hand N times, counted his honor points each time, and added everything up at the end.
He wants to know whether he got it right. Check it for him.