Hi,
I would like help on creating a function that returns:
a sequence of cards ranked in order
For example,
In a deck of cards there are 13 ranks: A, K, Q, J, T, 9, 8, 7, 6, 5, 4, 3, 2
A can be either high or low, A can be 13 or 1.
Outputs them in two specific strings, "H" and "B".
It's hard to explain, so I'll show by example.
If H = "KQT" and B = "J98"
then with function, it outputs: HHBHBB
which is = KQJT98
If H = "9632" and B = "KJ84"
then with function, it outputs: BBHBHBHH
which is = KJ986432
If H = "53" and B = "AQ"
then with function, it outputs: BBHH AND BHHB (I don't understand how that will be possible but obviously you guys are very good at this)
which is AQ53 and also Q53A
I think those examples explain better what I mean. Could you please help me?
I don't even know where to start to be honest.
Bookmarks