当前位置:网站首页>Using C language to compile student achievement management system (C language student achievement management system deleted)
Using C language to compile student achievement management system (C language student achievement management system deleted)
2022-07-28 11:24:00 【Full stack programmer webmaster】
Hello everyone , I meet you again , I'm your friend, Quan Jun .
One 、 Course design topic
① Basic requirements topic : Matrix multiplication .
② Comprehensive training : Student achievement management system
Two 、 The design requirements
Matrix multiplication : Write a function implementation matrix A(2 That's ok 3 Column ) And matrix B
Multiply (3 That's ok 2 Column ), Product on C Array . Enter two arrays multiplied in the main function , And output the result .
Student achievement management :( Array of structs 、 function 、 The pointer 、 Algorithm 、 Comprehensive application of process structure and documents )
Program description : Yes N A student , The data of each student contains the student number ( No repetition )、 full name 、 The grades and average grades of the three courses , Try to design a student achievement management system , It can provide the following functions :
Student achievement management system
1、 Score entry
2、 Score inquiry
3、 Score statistics
4、 refund Out
(1) The main menu
(2) Functions of each menu item
① Score entry : Enter the student number 、 Name and grades of three courses ;
② Score inquiry :( At least one query method ).
v Query student records by student number .
v Check the records of failed students .
③ Score statistics :
v Calculate the average score of students ;
v According to the average score of students , Sort the students' data and output ;
v Sort the students' grades in a single subject , Output the student's name and the grade of the subject ;
④ Exit the system : Exit the whole system ( Main menu ).
(3) Array of structs :
#define N 30
struct student
{int
num;
char
name[20];
float score[3];
float
average;
};struct student stu[N];
3、 ... and 、 Data structure design description
System function description
1 Be able to input the student number 、 full name 、 Three grades and calculate the average score .
2 Be able to output student records in the form of tables
3 Be able to sort according to the average scores of students in three subjects
4 Be able to sort according to students' single subject scores
5 Be able to query student records according to student number
6 Insert student records into the table
7 Delete student records from the table
8 Store records in files
9 Read records from files
10 sign out
The data dictionary
1 data flow
Data stream name : All records
Alias : nothing
sketch : All the records about students' grades after the latest update
source : database
Whereabouts : machining “ Record screening ”
Data traffic : There is no limit
form : Student number + full name +SC1+SC2+SC3+ Average score
Data storage bar
Data store name : Student record
Alias : nothing
sketch : Store all information available to students
form : Student number + full name +SC1+SC2+SC3+ Average score
Organization : Index file , Take the student number as the keyword
Query requirements : It is required to inquire immediately
2 Data item entry
Data item name : Student number
Alias : nothing
sketch : Student numbers of all school students
type : character string
3 Processing items
Processing name : Changed records
Excitation conditions : The student record has been changed
priority : Ordinary
Input : New record
Output : Update data 、 Data unchanged
Processing logic : According to the existing student record
if New record <> Old record
then Update data
else Data unchanged
endif
Design test process
1、 Enter interface
2、 Input options 0, enter ;
Enter data as prompted
3、 Back to the main menu ;
Input options 8, enter ;
Input file name :data, enter ;
A success message appears , Then the read file operation succeeds .
4、 Back to the main menu , Input 1, enter
Every time 10 Pause display data
5、 Back to the main menu , Input 2, enter
The sorting success message appears .
6、 Back to the main menu , Input 3, enter
The sorting success message appears .
7、 Back to the main menu , Input 5, enter
Insert a set of data as prompted
8、 Back to the main menu , Input 6, enter
Press the prompt to enter a name , Delete data
The message of successful deletion appears
9、 Back to the main menu , Input 4, enter
Enter the student number to query
10、 Back to the main menu , Input 1, enter
Statistics appear
11、 Back to the main menu , Input 7, enter
Input result, enter
The message that the file was successfully written appears
12、 Back to the main menu , Input 9, Press enter to exit the system
Four 、 Definition and function of each variable
#define N 3 Defining constants
typedef struct z1 Define the data structure
{ char no[11];
char name[15];
int score[N];
float sum;
float average;
int order;
struct z1 *next;
}STUDENT;
char *menu[] Define the menu string array
Enter list Input record
Print list Display all records in the single linked list
Sort to make new file Sort according to the total score
sort to Single course result Sort according to the scores of single subjects
Search record on ID Search the record according to the student number
Insert record to list Insert record into table
Delete a record from list Delete a record from a table
Save the file Save the records in the single linked list to a file
Load the file Read records from files */
Quit sign out
STUDENT *init() Initialize linked list
STUDENT *create() Create a linked list , Complete the data entry function
inputs(char *prompt, char *s, int count) Custom input control function inputs
Publisher : Full stack programmer stack length , Reprint please indicate the source :https://javaforall.cn/128282.html Link to the original text :https://javaforall.cn
边栏推荐
- Related concepts of several databases
- DHCP experiment demonstration (Huawei switch device configuration)
- Eslint, Eslint中文文档
- 做数据分析,你还不懂RFM分析方法(模型)?
- 2021-03-24
- C language uses double pointer to realize simple factory mode (polymorphism)
- Installation points and precautions of split angle probe
- postgres概述
- C语言使用二重指针实现简单工厂模式(多态)
- 万字详解 Google Play 上架应用标准包格式 AAB
猜你喜欢

用手机对电脑进行远程关机

What kind of knowledge payment system functions are more conducive to the development of the platform and lecturers?

LiteSpeed Web服务器中安装SSL证书

mysql还有哪些自带的函数呢?别到处找了,看这个就够了。

做数据分析,你还不懂RFM分析方法(模型)?

outlook突然变得很慢很卡怎么解决

CTF skill tree - file upload
JWT login authentication + token automatic renewal scheme, well written!

Machine learning strong foundation plan 0-5: why is the essence of learning generalization ability?

CVPR2021 行人重识别/Person Re-identification 论文+开源代码汇总
随机推荐
b2子主题/博客b2child子主题/开源源码
vim命令下显示行号[通俗易懂]
18张图,直观理解神经网络、流形和拓扑
Make a virtual human with zego avatar | virtual anchor live broadcast solution
栈和队列
mysql的左连接和右连接(内连接和自然连接的区别)
ripro9.0修正升级版+WP两款美化包+稀有插件
为什么传输前要进行编码与调制
【cesium】entity属性和时许绑定:SampledProperty方法简单使用
[MySQL from introduction to proficiency] [advanced chapter] (IX) precautions for InnoDB's b+ tree index
Machine learning strong foundation plan 0-5: why is the essence of learning generalization ability?
Question of hanging the interviewer
PHP发送移动MAS短信乱码的解决方法
Under the platform driven platform, the "dev- > dev.of_node" of the formal parameter dev in the probe function Understanding of
Analysis of boot process of cortex-m4 and cortex-a7 kernel
EC20/EC25 4G模块AT指令开发总结
Remote shutdown of computer with mobile phone
2021-03-24
Eslint, Eslint中文文档
苹果手机iCloud钥匙串的加密缺陷