Data Structures and Algorithms Course Design big job

 

Nuclear test requirements

Course Code:    400802010        Course Title:     Data Structures and Algorithms Design Course    examination form:    large operations       

1-9 large job to see me download a different version of the report can whisper I upload too much trouble

                                 

First, the design assessment Description :

Students must read "data structures" course design, carefully take the initiative to complete the class-based requirements. There are problems and timely initiative to communicate with teachers.

Students should play a self-learning ability, taking the time to arrange a time to plan the class-based and class-based process of constantly testing their plans to complete, and timely report to the teacher.

Curriculum design need to follow the teaching requirements Yi weeks to complete .

 

Second, the specific requirements:

1 . Students selected topics in the design range of topics, the topics according to a given topic tail number student number, for example, selecting a tail number of the first question, and so on, tail number selected from 0 to 9 and the ninth title.

2 . Students individually designed corresponding software project, to achieve work independently submit complete documentation.

3 . Submit similar documents, and after the first two failed to make treatment.

4 . Requirements in accordance with the design specification system to write design report. The report includes a cover (project title, name, etc.), catalogs, the main part of the design and Postscript. Per person a document.

5 . Requirements contents intact, clear structure, a final submission of electronic documents.

 

Third, the design topic topics list

1, Games scores of statistical issues.

【Problem Description】

Participation in the Games is n, the school No. 1 "" n. Competition is divided into men item m, and w-woman project. Item number men 1 "" m, the woman m + 1 "" m + w. Different projects choose the first five or top three points; points to take the top five were: 7, 5, the top three points are: 5,3,2; which take five or the name of the top three set by the students themselves. (M <= 20, n <= 20).

[Requirements] realization

(1) may enter the top three or top five results of each project;

(2) Statistical schools can score;

(3) may be numbered according to the school, the school scores, men and women's team scores the sort output;

(4) can check on the status school by school code of an item; can query made by item number three or top five schools;

(5) data into the file and can inquire at any time;

(6) the input data in the form and scope: You can enter the name of the school, the name of the Games project.

[Note] realization

  1. Chinese output has prompted schools fraction of plastic;
  2. Each function can be set up menus, user-related functions to achieve the prompts;
  3. Adjacency list storage structure can be taken with reference to FIG their own design.
  4. Design data in the report should be part of the test instructions.

 

2, student achievement management system

【Problem Description】

Existing student achievement information file 1 (1.txt), reads as follows

Name of school mathematics in English language No.    

Zhang Mingming 01,677,882

Licheng You 02,789,188

Zhang Huican 03688256

Wang Lu 04564577

Chen Dongming 05,673,847

….      ..      ..     ..       …

Student achievement information file 2 (2.txt), reads as follows:

Name of school mathematics in English language No.    

Chen Guo 31576882

Fred LI 32889068

Zhangming Dong 33484256

34504587 Mingguo

Chen Daoliang 35475877

….      ..      ..     ..       …

[Requirements] realization

Try to write a management system requirements are as follows:

(1) achieve the two data files are combined to generate a new file 3.txt

(2) extract the three subjects have make-up of students and saved in a new file 4.txt

(3) the data file 3.txt combined in descending order by score (implemented using at least two sorting methods)

(4) Enter a student name, student can find this information and outputs the result (using at least two search methods to achieve)

(5) require the use of other structures, arrays or chains to achieve the above requirements.

 

3, pharmacy drug sales statistics system (ordering application)

【Problem Description】

Design a system, pharmaceutical companies regularly record sales of the drug statistics, according to the number of drugs, price, sales volume or revenue to make rankings.

[Requirements] realization

In this design, the data file is first read out from the information recording each drug is stored in a sequential list. Each of the medicine information includes: number of drugs, drug name, drug price, the number of pins, sales. No drugs were 4, letters and numbers mixing numbers, such as: A125, before a capital letter, as the three figures, which are sorted by number of drugs, radix sorting method may be employed. When sorting unit price, sales, or sales of various drugs, using a variety of sequencing methods, such as direct insertion sort, bubble sort, quick sort, direct selection sorting method. In this design, the use of unit price sort bubble sort, the sort of sales using quick sort, the sort of sales using heap sort.

[Note] realization

Drug information element type definition:

typedef struct node

{Char num [4]; / ​​* number of drugs * /

  char name [10]; / * Drug name * /

  float price; / * * Drug Price /

  int count; / * sales * /

  float sale; / * this drug sales * /

 }DataType;

 

Sequential drug information table stored definitions:

typedef struct

{ DataType r[MaxSize];  

  int length;

}SequenList;

 

4, Huffman encoder / decoder issues:

【Problem Description】

Huffman coding information using the communication channel utilization can be greatly improved to shorten the transmission time information, lower transmission costs. However, this requires pre-treatment data-encoded by a coding system on the transmitting side; decoded (restored) at the receiving end of the transmitted data.

[Requirements] realization

The system should have the following features:

(1) Initialization (Initialization). Read from the character set of the terminal size n, and n and m characters weights, the Huffman tree established, and it is stored in the document hfmtree.  

(2) a coding (Coding). Using the Huffman tree has been built (e.g., not in memory, reads from the file hfmtree) tobetrans file encoded in the body, then the result is stored in the file in codefile.   

(3) decoding (Decoding). Code file using the Huffman tree has been built in codefile decoding result is stored in the file textfile.

(4) the actual character set statistics and frequency is given by the following table creating the Huffman tree, and to achieve the encoding and decoding of packets: "THIS PROGRAM IS MY FAVORITE".

character

A

B

C

D

E

F

G

H

I

J

K

L

M

Frequency

64

13

22

32

103

21

15

47

57

1

5

32

20

character

N

THE

P

Q

R

S

T

The

V

W

X

Y

FROM

Frequency

57

63

5

1

48

51

80

23

8

18

1

16

1

 

 

 

 

[Note] realization

According to subject procedure can be classified into the three modules, the menu mode is designed to return to a menu after each execution module. In addition to the initialization process, it has been first read the disk file data in each execution. This is because if the initialization has not been performed (1) after the program execution process, in order to enable subsequent operation smoothly, work may be performed by reading the old data. For example: weight data and the character set procedures if required be fixed, as long as at the time of an initial installation program (1) operation on it. When running the program once again, no matter which action may be needed to read the data into memory.

 

5, the campus tour program

【Problem Description】

Represent your school campus attractions plan, vertices in the graph represents the main attractions, storage number, name, description and other information on attractions, while the figure indicates the road between attractions, the storage path length information undirected network. It requires the ability to answer questions about attractions introduction, tour route and other issues.

【Design requirements】

Design requirements are as follows:

(1) designed to set your sights school campus plan;

(2) other relevant information on the attractions;  

(3) the query graph shortest path between any two spots.

(4) add, delete, update information on attractions and roads.

 

6, analog calculator to solve arithmetic expressions

【Problem Description】

Given an arithmetic expression, the final result is determined by the program.

[Requirements] realization

(1) Value: includes integers and real numbers, values ​​can be positive, negative sign.

(2) Operators: plus, minus, plus, subtraction, multiplication, division, and modulo exponentiation, which may contain parentheses.

[Note] realization

(1) an arithmetic expression input from the keyboard to be solved;

(2) The process of the stack structure to solve arithmetic expressions;

(3) the arithmetic expression can be determined correctly or not;

(4) For error expression prompt;

(5) gives the final results for the correct expression;

 

7, article editing

【Problem Description】

Function: Enter a text, the program can count the number of words, numbers, spaces.

Static storage one article per line up to no more than 80 characters,

【Design requirements】

(1) respectively, the statistics which the number of letters and the number of spaces and the entire article total number of words;

(2) count the number of a string that appears in the article, and outputs the number of times;

(3) delete a substring, and subsequent characters forward.

[Note] realization

Using a linear table storage structure, several sub-functions are implemented by the corresponding function;

The input data in the form and scope: You can enter uppercase, lowercase letters, numbers and punctuation marks any.

Output Type:

(1) each of the output branch lines of characters input by a user;

(2) output lines 4 minutes "the total number of letters", "number of digits", "the number of spaces", "total number of words the article"

(3) delete the article output after a string;

 

8, car park management

【Problem Description】  

It features a park cars n the narrow parking lot, it is only one door can be used for vehicle access. Vehicle parking lot for morning and evening arrival time in order to park (the first to arrive first car in the parking lot innermost) from the parking lot at the entrance to the innermost. N If the parking lot is filled with vehicles, the vehicles can only later on the sidewalk outside the gate of the parking lot to wait, once drove away in the car park, then came in the first car on the sidewalk to enter the parking lot. If the parking lot of a car to drive away, the car after it entered the car park must first leave the parking lot to make way for it, wait until after opening the parking lot, according to these vehicles re-entering the original order. Each vehicle when leaving the parking lot, should be based on the time it stays in the parking lot of the length of payment. If you stay on the sidewalk of the car into the parking lot is not going away, allowing it to leave, do not charge parking fees, and still maintain order on the sidewalk waiting for the vehicle. The preparation of a program to simulate the management of the parking lot.

[Requirements] realization 

Requirements Program outputs per vehicle reaches the parking position (parking lot or sidewalk), as well as the cost of a car leaving the parking lot should be paid and the time it stays in the parking lot.

[Note] realization

Car analog input format can be :( Arrival / departure, car license number, departure time arrival /). For example, ( 'A', 1,5) denotes a license plate No. 5 at this time reaches the car, and ( 'D', 5,20) represents a leaving car license plate No. 5 at 20 this time. The entire program may input information ( 'E', 0,0) the end. The problem can be implemented stacks and queues. Design and implementation of a traffic advisory system.

 

9, design and implementation of hash table

【Problem Description】

Design a hash table to achieve telephone number lookup system.

【basic requirements】

(1) Each record has provided the following data items: phone number, user name, address;

(2) from each record keyboard input, respectively, phone number and user name keyword up the hash table;

(3) the use of certain methods to resolve the conflict;

(4) find and display records the telephone number given;

(5) to find and display the record the user's given name.

[Further] complete content

(1) improve the system functions;

Different (2) design a hash function, the collision rate comparison;

(3) under the premise of the hash function determined by various methods to try different types of conflict, to find the average change in length of the investigation.

 

PS: hand over relevant content requirements

Contents turned over the results must consist of the following four parts, indispensable

1. Turned over to the source: the source of all students in accordance with the specific requirements of the curriculum design developed (it should be placed in a folder);

2. Turned over to the program's documentation :( saved in .txt) in the documentation should specify the directory where the program is turned over, turned over to the main program file name, if necessary, the installation instructions have procedures;

3. Curriculum design :( saved as a Word 97-2003 format file, the file name in accordance with the requirements "study - Name - curriculum design" to take the name of the file extension ".doc" , such as a file named " 162 203 301 112 - Li Bin - curriculum design .doc " )  function blocks established in accordance with the specific requirements of curriculum design, each module is completed in accordance with the requirements of several carefully reads as follows;

These include:

(1) needs analysis:

Described in this section, the function of each module of claim

(2) Summary of design :

In this description the algorithm description of each part (which may be described with a flowchart of the algorithm), description storage structure used in each program (as defined in the storage structure if the specified storage structure Please write.

(3) Detailed design :

Each algorithm of the source, have the appropriate source (the source may be a set, each functional module implemented using a different function) for each topic .

To write source code in accordance with the rules of procedure to write. To clear structure, focusing on variable focus function key functional part to add a clear program comments.

(4) debug analysis

Test data, test results output, the time complexity analysis, and thinking problems when each module design and debugging (what is the problem? How to solve the problem?), Improved algorithm vision.

4. The class-based summary:

Paul saved as Word 97-2003 format. Summary may include: Harvesting the course of the design process, encountered problems, to think and solve problems thinking process, program debugging capabilities encountered, Reflection on the data structure of this course, the curriculum design process of this door awareness program and other content .

Published 100 original articles · won praise 18 · views 30000 +

Guess you like

Origin blog.csdn.net/sereasuesue/article/details/104153835