king_pong.py
def main(argv):
        """
        When called `python king_pong.py`
        a CPU is allocated to play against a human
        """
        game_state = GameState(auto_draw = False)

        # 2 game_states of 1 point
        game_state.first_to = [3, 2]
        game_state.top_speed = 5

        while True:
                for event in pygame.event.get():
                    if event.type == pygame.QUIT:
                        exit()

                keys = pygame.key.get_pressed()
                a1 = keys[pygame.K_UP]
                a2 = 0 if a1 else keys[pygame.K_DOWN]
                a0 = 1 if not a1 and not a2 else 0
                image_data, reward = game_state.frame_step([a0, a1, a2])

                game_state.draw_scores()
                game_state.complete_drawing()

                if game_state.game_over():
                    exit(0)

        When called `python king_pong.py`
        a CPU is allocated to play against a human
        
When called `python king_pong.py`
a CPU is allocated to play against a human
When called ` python king_pong . py ` a CPU is allocated to play against a human
def main(argv):
        game_state = GameState(auto_draw = False)
        game_state.first_to = [3, 2]
        game_state.top_speed = 5
        while True:
                for event in pygame.event.get():
                    if event.type == pygame.QUIT:
                        exit()
                keys = pygame.key.get_pressed()
                a1 = keys[pygame.K_UP]
                a2 = 0 if a1 else keys[pygame.K_DOWN]
                a0 = 1 if not a1 and not a2 else 0
                image_data, reward = game_state.frame_step([a0, a1, a2])
                game_state.draw_scores()
                game_state.complete_drawing()
                if game_state.game_over():
                    exit(0)
def main ( argv ) : game_state = GameState ( auto_draw = False ) game_state . first_to = [ 3 , 2 ] game_state . top_speed = 5 while True : for event in pygame . event . get ( ) : if event . type == pygame . QUIT : exit ( ) keys = pygame . key . get_pressed ( ) a1 = keys [ pygame . K_UP ] a2 = 0 if a1 else keys [ pygame . K_DOWN ] a0 = 1 if not a1 and not a2 else 0 image_data , reward = game_state . frame_step ( [ a0 , a1 , a2 ] ) game_state . draw_scores ( ) game_state . complete_drawing ( ) if game_state . game_over ( ) : exit ( 0 )
When called `python king_pong.py`
a CPU is allocated to play against a human
When called ` python king_pong . py ` a CPU is allocated to play against a human
"""
        When called `python king_pong.py`
        a CPU is allocated to play against a human
        """ # 2 game_states of 1 point
argv