开发者

Is there a way to check for a set of four things in a list and then remove them all in python?

I am trying to write code to simulate something like placing a set of four cards down from the player’s. I want to be able to check for a set of four identical cards in a list and then remove them all from the list and make an external “point” value increase by one. Essentially like playing down a set in a game like go fish.

I can only figure out how to do it with 2 car开发者_JAVA百科ds in the set. And in my deck there are no suits since the game is go fish and the suits dont matter for it. So i only need to figure it out for the rank of the cards

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜