Last active
August 29, 2019 05:57
-
-
Save BMuscle/9f0c6ee292d10b9c70dccf0cf25c294e to your computer and use it in GitHub Desktop.
じゃんけんソース③
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //main関数内 | |
| if(player1 == player2){ | |
| judge = 3;//あいこの場合 | |
| }else{ | |
| player1 = player % 3;//相手との差を求める | |
| if(player1 + 1 == player2){ | |
| judge = 1;//P1が勝ち | |
| }else{ | |
| judge = 2;//あいこは条件から外れているのでP2の勝ち | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment