题目内容

药店的药品销售统计系统【问题描述】设计一系统,实现医药公司定期对销售各药品的记录进行统计,可按药品的编号、单价、销售量或销售额做出排名。【实现提示】在本设计中,首先从数据文件中读出各药品的信息记录,存储在顺序表中。各药品的信息包括:药品编号、药名、药品单价、销出数量、销售额。药品编号共4位,采用字母和数字混合编号,如:A125,前一位为大写字母,后三位为数字,按药品编号进行排序时,可采用基数排序法。对各药品的单价、销售量或销售额进行排序时,可采用多种排序方法,如直接插入排序、冒泡排序、快速排序,直接选择排序等方法。在本设计中,对单价的排序采用冒泡排序法,对销售量的排序采用快速排序法,对销售额的排序采用堆排序法。药品信息的元素类型定义:typedef struct node{ char num[4]; /*药品编号*/char name[10]; /*药品名称*/float price; /*药品单价*/int count; /*销售数量*/float sale; /*本药品销售额*/}DataType;存储药品信息的顺序表的定义:typedef struct{ DataType r[MaxSize];int length;}SequenList;

查看答案
更多问题

1. Air freight is used for goods wherethe higher cost of transport by air ____way to otherconsiderations.

A. will give
B. to give
C. giving
D. gives

2. Someproductsmaylookcoolandworkwell—awonderfulcollectionofobjectsthat_____enhanceyourlife.

A. slowly
B. subtly
C. gradually
D. slightly

3. The difference is in the way they’re designed, in the way they look and feel. And it’s industrialdesign _____makes all that difference.

A. which
B. what
C. that
D. who

4.The inside of an industrial designer's sketchbook usually looks like some kind of flattened madScientists’laboratories, ______ with doodles of various types of products.

A. filling
B. to be filled
C. which filled
D. filled

答案查题题库