当前位置:网站首页>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
边栏推荐
- 什么样的知识付费系统功能,更有利于平台与讲师发展?
- BOM part attributes and understanding
- Combination of const and pointer
- RHEL 6.4 安装svn和apache
- Nodejs: detect and install the NPM module. If it is already installed, skip
- 接口测试的作用
- Reading these six books makes learning MySQL easier
- 2021-03-24
- [FPGA tutorial case 41] image case 1 - reading pictures through Verilog
- No swagger, what do I use?
猜你喜欢

CTF skill tree - file upload

不用Swagger,那我用啥?

五面阿里技术专家岗,已拿offer,这些面试题你能答出多少
![[MySQL from introduction to proficiency] [advanced chapter] (x) MyISAM's indexing scheme & advantages and disadvantages of indexing](/img/f4/e04bf0f8f0866ea9db0615f0e5e1c4.png)
[MySQL from introduction to proficiency] [advanced chapter] (x) MyISAM's indexing scheme & advantages and disadvantages of indexing

Encryption defect of icloud Keychain in Apple mobile phone

好用到爆!IDEA 版 Postman 面世了,功能真心强大

【MySQL从入门到精通】【高级篇】(十)MyISAM的索引方案&&索引的优缺点

Two dimensional prefix and

重新刷新你对Redis集群的理解

mysql还有哪些自带的函数呢?别到处找了,看这个就够了。
随机推荐
Learn how to do e-commerce data analysis (with operation analysis index framework)
offsetof宏与container_of宏分析详解
Analysis of boot process of cortex-m4 and cortex-a7 kernel
Technology sharing | quick intercom integrated dispatching system
Table data processing software, what else besides excel?
[MySQL] MySQL error "error 2006 (HY000): MySQL server has gone away"
mysql的左连接和右连接(内连接和自然连接的区别)
Generation and use of Lib library files in keil and IAR
[FPGA tutorial case 41] image case 1 - reading pictures through Verilog
【cesium】entity属性和时许绑定:SampledProperty方法简单使用
ZBrush 2022软件安装包下载及安装教程
go status.go 状态码定义
Tree shaking and DCE
技术分享| 快对讲综合调度系统
Ec20/ec25 4G module at instruction development summary
A solution to the problem that ThinkPad fingerprint verification cannot be used in win7
用c语言编写学生成绩管理系统(c语言学生成绩管理系统删除)
keil和IAR中lib库文件的生成和使用
Sword finger offer 06. print linked list from end to end
const与指针的组合使用