代写辅导接单-Python Reversi Game Challenge

欢迎使用51辅导,51作业君孵化低价透明的学长辅导平台,服务保持优质,平均费用压低50%以上! 51fudao.top

Python Reversi Game Challenge

Building an Agent to Outsmart Opponents

 

This assignment presents a challenge to students in the realm of Python programming and Reversi game development. Youwill be required to build an agent capable of outsmarting the other opponents in the game. Students will need to create a function that enables the agent to analyze the game state, strategize its moves, and potentially devise clever tactics to gain an advantage over other players.

 

All the agents developed by the students will participate in a tournament scheduled during the final week of the lecture. This tournament will serve as a platform to evaluate and compare the performance of the different agents against each other. It will provide an opportunity for students to showcase the effectiveness of their agent implementations and determine which one excels in playing the Reversi game. The tournament will likely involve multiple rounds of gameplay, allowing each agent to face various opponents and test their strategic capabilities. Through this tournament, students will have the chance to observe the diverse strategies employed by different agents and gain insights into the strengths and weaknesses of their own implementations.

 

 

 

 

 

 

 

 

 

Rule:

The game initiation and game play demo code is in the Jupyter Notebook.

 

No extra packages can be used.

 

In each game, the board size will be randomly assigned. You will have a maximum of 8 seconds to generate the next move using your function. If the time limit is exceeded, a random agent will be utilized instead.

 

IMPORTANT: If any error or invalid move is occur, random agent will be used in your next move.

 

Grading (10 pts):

Your agent will be tested in the following sequences:

1. Your agent will engage in a series of 5 Reversi games against a random agent, aiming to achieve 3 wins. If your agent wins, you got 6 pts. If your agent is failed to win the random agent, you got 0 pts.

2. Your agent will engage in another series of 5 Reversi games against a naïve agent, aiming to achieve 3 wins. If your agent wins again, you got another 2 pts. (which means you got 9 pts in total) NOTE: the naïve agent is a little bit intelligence than random agent, but the code will not be disclosed.

3. In the tournament, top 3 agents in the class will get another 2 pts. Agents that ranks from 4 – 8 will get another 1 pts.

 

Submission:

1. Give a name of your group

2. Filename: your_group_name.py

3. Your function name is your group name

4. One file submission per group

 

Functions:

possible_moves() – returns a list of all the possible moves

 

board_analysis() – returns the current board, you may use this to analyze

 

make_move() – make the move

 

print_board() – print the current board

 

Your move should be in string: e.g. ‘C2’ represents your move is at (row 2, col C)

 

Your function should have exactly 1 inputlike the random agent.

 

You can use the list memory which is declared in the beginning of the code for whatever you need in your function. (declare as global variable)

 

51作业君

Email:51zuoyejun

@gmail.com

添加客服微信: abby12468