当前位置:网站首页>C language guessing numbers game
C language guessing numbers game
2022-06-09 01:38:00 【_ Programming_】
C Language Guessing Number Game
Title Two guessing numbers game
1. The design requirements :
The game can be randomly generated by the program - individual N Digit number , Or by the
The user enters a N Digit number , As a number to be guessed ( Ladies and gentlemen
Don't repeat ). After the player begins to guess , There can be M Secondary machine
Will enter a number to match the above number to be guessed . Every time the user enters a
Time , The system gives the guess result :A Indicates that the position is correct and the number
correct ,B Indicates that the number is correct and the position is incorrect . such as : 2A1B,
Express 2 The bit position is correct and the number is correct ,1 The digit number is correct but the position
Incorrect .
After a guess , Game over . if M I'll run out of opportunities , game
It's over . The menu format is shown in the figure .
2. Basic function
1) Generate data to be guessed , Random generation , Or entered by the user .
Need to judge legitimacy : N Digit numbers do not appear repeatedly .
2) Provide the most M One chance to guess , Each feedback guess result . become
The function immediately ends guessing and returns to the main menu .
3) Enter the user name before the game starts , First use for user notes
book . Whether the game is successful or not can return to the main menu .
4) View results : View the historical guess results of a user
Minimum number of guesses , The success rate ;
5) Parameters M,N You can set it up freely
Source download
link :https://pan.baidu.com/s/1JJs9vbZahUCB6cQvXLgAVg?pwd=1111
Extraction code :1111
边栏推荐
- Lambda8 quickly realize list to map, grouping, filtering and other operations - personal notes
- C语言学生籍贯信息记录簿
- shell 大写转小写
- shell 天气预报
- Shell subtraction
- GCD Locks Dead cycle SpinLock synchronized
- Shell command output
- Dom----- event flow
- flush tables with read lock & information_ schema. processlist
- Shell simple interaction
猜你喜欢

flush tables with read lock & information_ schema. processlist

Former Disney executive says Depp will return to pirates of the Caribbean to continue playing Captain

Jenkins can view the forgotten credential password based on the credential ID and how to reset the admin password

How to use superset to seamlessly connect with MRS for self-service analysis

Cobalt strike certificate modification bypasses traffic review

Laravel implements nearby people, shops and houses based on mongodb (LBS)

Shell loop for while (IV)

A sharp tool to expose data inconsistency -- a real-time verification system

php安装CI框架解决

Shell weather forecast
随机推荐
Assembly language integrated development environment learning notes
iscc-2022
Daily weekly report
A collection of commonly used SQL scripts is recommended!
How to improve code standardization -- embedded C programming specification.
CAD entry level exercises
C语言成绩记录簿
Explication détaillée du nombre de points flottants (une étude approfondie du nombre de points flottants)
不容错过|额度管理与应用-银行信用卡行为评分篇(实操见)
Notes on supporting geo data mining live broadcast of Shengxin skill tree
Predicate pushdown of Presto RBO
jenkins根据凭证ID查看忘记的凭证密码以及重置admin密码的操作方法
在centOS中requires SQLite 3.8.3 or higher报错
[JS] array de duplication
Cobalt strike certificate modification bypasses traffic review
《C 语言程序设计实践》任务书
Shell display system information menu
Openeuler notebook networking
浮点数详解(一篇彻底学通浮点数)
Shell get IP location