Gobang Experimental Report

Source: Internet
Author: User

Software

Topic Gobang Game Programming

First, the content

Gobang's game rules are very clear to all of us. As long as a piece of a party in a straight line, the number of pieces first reached five or more, then the party is the winner.

My Gobang small Game program to achieve two people to fight the simple steps and some simple rules, can judge the winning and losing of both sides. When the number of pieces of a party first reaches five or more, it is possible to judge this side as the winner. And can judge, when the Board of a certain position there is a pawn, can determine that the position can no longer lazi. When a party wins, you can choose whether to play the game again. You can also exit the game when the game has not yet been decided. Enter the game side can use "W","S","A","D","Z"separately to control the direction and Lazi of the upper and lower sides, the other side uses"O","L","I","P"and the empty Glyd respectively control the direction of the upper and lower left and Lazi.

Second, GitHub links

Https://github.com/wangyanlinsun/test/new/master

Description of each function:

  1. Main() primary function
  2. void Drawqipan() Draw Board
  3. void Move GB () move cursor
  4. void Luozi () Lower Pawn
  5. void Judgewin () Judging winning or losing
  6. void System () systems Functions

Iv. operation of the program

1. Initial interface

2. Game Interface

3, can be dropped in the middle

Five, experience

This program makes me feel how limited my knowledge is. So I want to study the knowledge of programming more diligently. But this programming process also let me gain a lot, first strengthened my knowledge point, also exercised my debugging ability. Actually this time also let me feel C language also quite interesting, let me to C language of interest more thick. and C Language Coding

Gobang Experimental Report

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.