...

/

Writing the Game Logic - Part 2

Writing the Game Logic - Part 2

In this lesson, we will continue building the implementation logic for the Rock Paper Scissors game.

Let’s define the result() method, which will implement the core logic of the game.

Accepting the input parameters

We will start by accepting the user choice and computer choice as parameters of the method.

Let’s also initialize the global variables which store the scores.

Press + to interact
def result(user,comp):
global USER_SCORE
global COMP_SCORE

Writing the core logic of

...