···58585959Find the rank of every hand in your set. *What are the total winnings?*
60606161-To begin, [get your puzzle input](7/input).
6161+Your puzzle answer was `251136060`.
6262+6363+The first half of this puzzle is complete! It provides one gold star: \*
6464+6565+\--- Part Two ---
6666+----------
6767+6868+To make things a little more interesting, the Elf introduces one additional rule. Now, `J` cards are [jokers](https://en.wikipedia.org/wiki/Joker_(playing_card)) - wildcards that can act like whatever card would make the hand the strongest type possible.
6969+7070+To balance this, *`J` cards are now the weakest* individual cards, weaker even than `2`. The other cards stay in the same order: `A`, `K`, `Q`, `T`, `9`, `8`, `7`, `6`, `5`, `4`, `3`, `2`, `J`.
7171+7272+`J` cards can pretend to be whatever card is best for the purpose of determining hand type; for example, `QJJQ2` is now considered *four of a kind*. However, for the purpose of breaking ties between two hands of the same type, `J` is always treated as `J`, not the card it's pretending to be: `JKKK2` is weaker than `QQQQ2` because `J` is weaker than `Q`.
7373+7474+Now, the above example goes very differently:
7575+7676+```
7777+32T3K 765
7878+T55J5 684
7979+KK677 28
8080+KTJJT 220
8181+QQQJA 483
8282+8383+```
8484+8585+* `32T3K` is still the only *one pair*; it doesn't contain any jokers, so its strength doesn't increase.
8686+* `KK677` is now the only *two pair*, making it the second-weakest hand.
8787+* `T55J5`, `KTJJT`, and `QQQJA` are now all *four of a kind*! `T55J5` gets rank 3, `QQQJA` gets rank 4, and `KTJJT` gets rank 5.
8888+8989+With the new joker rule, the total winnings in this example are `*5905*`.
9090+9191+Using the new joker rule, find the rank of every hand in your set. *What are the new total winnings?*
62926393Answer:
64946565-You can also [Shareon [Twitter](https://twitter.com/intent/tweet?text=%22Camel+Cards%22+%2D+Day+7+%2D+Advent+of+Code+2023&url=https%3A%2F%2Fadventofcode%2Ecom%2F2023%2Fday%2F7&related=ericwastl&hashtags=AdventOfCode) [Mastodon](javascript:void(0);)] this puzzle.9595+Although it hasn't changed, you can still [get your puzzle input](7/input).
9696+9797+You can also [Shareon [Twitter](https://twitter.com/intent/tweet?text=I%27ve+completed+Part+One+of+%22Camel+Cards%22+%2D+Day+7+%2D+Advent+of+Code+2023&url=https%3A%2F%2Fadventofcode%2Ecom%2F2023%2Fday%2F7&related=ericwastl&hashtags=AdventOfCode) [Mastodon](javascript:void(0);)] this puzzle.