2018年韩山师范学院本科插班生考试试题《数据结构》A试卷
- 格式:doc
- 大小:60.00 KB
- 文档页数:8
韩山师范学院2019年本科插班生招生考试英语专业基础英语试卷( A卷)nguage knowledge. Choose one word, phrase or statementthat best completes the sentence. (每空1分,共20分)1. Jack ___________ on the project day and night for two months now, and I am beginning to worry about his health.A. has been workingB. would be workingC. had been workingD. was working2. At the end of the road stands a stone house, ________ history dates back to the 18th century.A. whereB. of whoseC. whoseD. which3. Who ________ was coming to see me in my office this afternoon?A. he saidB. did he sayC. did he say thatD. he did say4. Does Sally like sweets?Yes. So much ____ that she eats them almost every day.A. forB. asC. toD. so5. If you explained the situation to your solicitor, he _________ able to advise you much better than I can.A. would beB. will have beenC. wasD. were6.__________, Mr. Cook is scarcely in sympathy with the working class.A. Although he is a socialistB. If he is a socialistC. To be a socialistD. Since he is a socialist7. His remarks were _________ annoy everybody at the meeting.A. so as toB. such as toC. such toD. as much as to8. Jane has just arrived, but I didn’t know she ________ until yesterday. A.will come B. was comingC.had been coming D. came9. Although the bus is ______ to depart at eight o’clock, it is often late.A. programmedB. scheduledC. processedD. organized10. According to the evolutionary theory of Charles Darwin, man is ______ from the apes.A. descendedB. originatedC. derivedD. inherited11. It is impossible to ________ these points of view, they are too different.A. coincideB. compromiseC. reconcileD. negotiate12. In spite of the fact that his discovery bothered him a great deal, he restrained himself from making a move or _______ a word until the next morning.A. unfoldingB. utteringC. reproachingD. weighing13. Do you think it necessary for a wife to ______ her habits and tastes to those of her husband?A. complyB. abideC. conformD. consent14. Although I liked the appearance of the house, what really made me decide to buy it was the beautiful _______ through the window.A. visionB. lookC. pictureD. view15. The publisher considers the novelist’s works to be ________, for it has well developed insights into human nature.A. superficialB. excellentC. superiorD. profound16. When he finally emerged from the cave after thirty days, Jack was ______ pale.A. enormouslyB. startlinglyC. uniquelyD. dramatically17. Thank you for applying for a position with our firm. We do not have any openings at this moment, but we shall keep your application on ______ for two months.A. pileB. segmentC. sequenceD. file18. The manager made a far-seeing decision ________ what she had said.A. in light ofB. at the mercy ofC. in the case ofD. at the cost of19. The _________ of a cultural phenomenon is usually a logical consequence of some physical aspect in the life style of the people.A. implementationB. manifestationC. demonstrationD. expedition20. Ben was about to announce our plan but I ___________ .A. put him throughB. turned him outC. gave him upD. cut him short.II.Derivative. Write down the correct word to complete each sentence. (每题1分,共10分)A.breathe1. It is so hot in this small kitchen that I can hardly ________.2. When I answered the telephone, there was an unknown and _______ voice on the other end, which was really irritating.3. There was a ________ silence during the last world table-tennis championship game.4. You are wasting your ________ trying to persuade him to quit smoking. He’ll only stop when he wants to.5. During our last convention, there were so many items on the agenda that there was hardly any ________ space.B. Help6. Whenever we’re in any difficulty, he’s always willing to give a _____ hand.7. If we need more ________ in the activity, who’ll volunteer to come?8. Can I have another _________ of ice cream?9. Without a car in the country like this, you’l l feel as ________ as a baby.10. Used appropriately, a dictionary will always be _________ to a language learner.III.Match each word in Column A with the phrase in Column B that is similar in meaning. (每题1分,共10分)IV.Fill in each blank with a preposition from the box.(每题1分,共10分)1. Put rice on your shopping list, as we have run ______ it.2. I have never run ______ such a rude man before.3. The camp guards made sure that none of the prisoners of war would run _____.4. She needs a rest. She looks run _____ after walking for the whole afternoon.5. During the lunch hour, my brother ran _____ his notes about the speech.6. He ran _____ the main points in the letter quickly.7. The new clock radio has run _____; we must change the batteries.8. You must be careful of your expenses. Don’t run ____ a large bill at the motel,9. When a friend is in danger, we can’t look _____ with folded arms.10. When he looked _____ on his early struggle as a salesman in a big store, he realized he was a changed man.V.Reading comprehension. Choose the one that you think is the best answer and mark your answers on Answer Sheet.(每题2分,共10分)Passage OneImagine you are a citizen of Athens, enjoying a warm Mediterranean night in the Theater of Heroes Atticus. You are wearing jeans and a T-shirt, listening to a great concert.Now rewind this picture 1,839 years. You are in the same seat, only you are watching classical Greek entertainment and wearing a simple chiton, or tunic.The city of Athens is a fun mix of the old and the new, the classic and the modem. Often a little shop is located next to the rains of a temple,which is only a block from a large, air-conditioned hotel. The great city of 2,500 years ago is still visible today.Ruins are the most obvious sign of ancient Athens, and the most famous of these is the Acropolis. The Acropolis is a large hill that was the center of life in Athens. On its slopes were temples, monuments, and theaters. From the top, you can see how the urban sprawl of Athens stretches out in every direction.On the top of the Acropolis is the Parthenon. This was once a huge temple to Athena, the city's patron. It was first completed in 432 B.C., but has been damaged and destroyed several times. However, visitors can still see the "tricks" used in building the Parthenon. The columns along the outside lean inward, and are slightly fatter in the middle. The temple is also higher in the middle than on the sides. All these effects make the Parthenon look perfectly straight from a distance.Only a block away from the Acropolis is the neighborhood of Plaka. The area, with its little shops and restaurants, is very popular with both tourists and locals, and is an important part of modem Athenian culture.Many great thinkers, writers, and political leaders lived in ancient Athens. The ruins of their homes and favorite spots are scattered throughout the busy port city. The hill where St. Paul addressed early Christian Athenians is located near the Acropolis. Great thinkers such as Pericles and Demosthenes spoke to the civil assemblies held at the Pnyx Hill. Today the Pnyx is an open-air theater for light and sound shows. Greeks still use some ancient sites, such as the Pnyx and the Theater of Heroes Atticus. During Roman times, in 76 A.D., gladiators used the Panathenaic Stadium for contests. The Olympics were held there in 1896, and today people still jog and exercise in the stadium.Tourism is very important to people who live in modem-day Athens. Thousands of people come every year to see these ruins and to tour the many museums that house artifacts from ancient times. This providesmany jobs and brings money into Athens, which helps the city pay for improvements. Athenians take pride in the accomplishments of their ancestors, and people from all around the world come to admire them. By looking around the city today, we can imagine what life was like in ancient Athens.1. Which of the following statements is INCORRECT about the city of Athens?A. The culture of the city is a mixture of the old and modem.B. Traces of the ancient city can still be found.C. Ruins and modem hotels co-exist in the city.D. All the temples are not far away from air-conditioned hotels.2. Which tourist attraction was ancient Athens most famous for?A. Plaka.B. Acropolis.C. Pnyx.D. Parthenon.3. According to the context, "tricks" in Paragraph Five refer to ______.A. mischievous actsB. confusing constructing skillsC. skillful constructing methodsD. constructing materialsPassage TwoWhat we know of prenatal development makes all this attempt made by a mother to mold the character of her unborn child by studying poetry, art, or mathematics during pregnancy seem utterly impossible. How could such extremely complex influences pass from the mother to the child? There is no connection between their nervous systems. Even the blood vessels of mother and child do not join directly. An emotional shock to the mother will affect her child, because it changes the activity of her glands and so the chemistry her blood. Any chemical change in the mother's blood will affect the child for better or worse. But we can not see how a looking for mathematics or poetic genius can be dissolved inblood and produce a similar liking or genius in the child.In our discussion of instincts we saw that there was reason to believe that whatever we inherit must be of some very simple sort rather than any complicated or very definite kind of behavior. It is certain that no one inherits a knowledge of mathematics. It may be, however, that children inherit more or less of a rather general ability that we may call intelligence. If very intelligent children become deeply interested in mathematics, they will probably make a success of that study.As for musical ability, it may be that what is inherited is an especially sensitive ear, a peculiar structure of the hands or the vocal organs connections between nerves and muscles that make it comparatively easy to learn the movements a musician must execute, and particularly vigorous emotions. If these factors are all organized around music, the child may become a musician. The same factors, in other circumstance might be organized about some other center of interest. The rich emotional equipment might find expression in poetry. The capable fingers might develop skill in surgery. It is not the knowledge of music that is inherited, then nor even the love of it, but a certain bodily structure that makes it comparatively easy to acquire musical knowledge and skill. Whether that ability shall be directed toward music or some other undertaking may be decided entirely by forces in the environment in which a child grows up.4. Which of the following statements is not true?A. Some mothers try to influence their unborn children by studying art and other subjects during their pregnancy.B. It is utterly impossible for us to learn anything about prenatal development.C. The blood vessels of mother and child do not join directly.D. There are no connection between mother's nervous systems and her unborn child's.5. A mother will affect her unborn baby on the condition that ____.A. she is emotionally shockedB. she has a good knowledge of inheritanceC. she takes part in all kind of activitiesD. she sticks to studyingVI.Cloze. Decide which of the words given in the box below would best complete the passage if inserted in the corresponding blanks.The words can be used ONCE ONLY. Mark the letter for eachword on Answer Sheet.(每题1分,共10分)The U.S. Department of Education is making efforts to ensure that all students have equal access to quality education. Today it is 1___the launch of the Excellent Educators for All Initiative. The initiative will help states and school districts support great educators for the students who need them most.“All children are 2___ to a high-quality education regardless of their race, zip code or family income. It is 3___ important that we provide teachers and principals the support they need to help students reach their full 4___,” U.S. Secretary of Education Arne Duncan said. “Despite the excellent work and deep 5___ of our nation's teachers and principals, students in high-poverty, high-minority schools are unfairly treated across our country. We have to do better. Local leaders and educators will 6___ their own creative solutions, but we must work together to 7___ our focus on how to better recruit, support and 8___ effective teachers andprincipals for all students, especially the kids who need them most.”Today’s announcement is another important step forward in improving access to quality education, a 9___ of President Obama’s year of action. Later today, Secretary Duncan will lead around table discussion with principals and school teachers from across the country about the 10___of working in high-need schools and how to adapt promising practices for supporting great educators in these schools.e the words given in parentheses to translate the following sentences. Change the forms if necessary.(每题3分,共15分)1. 虽然上课时我们常做听写,但我们还是请老师多给我们一些小段听写文章,好让我们在课后做。
⼭西省2018年专升本选拔考试(C程序设计数据结构)历年真题详解⼭西省2018年专升本选拔考试(C程序设计数据结构)历年真题详解说明:本试题分C程序设计和数据结构(C语⾔版)两部分,各占100分,满分200分,考试时间150分钟。
第⼀部分C程序设计⼀、单项选择题( 本⼤题共10⼩题,共⼩题3分,共计30分,在每⼩题的四个备选答案中,只有⼀个答案是正确的,请将代表正确答案的字母填⼊下列表格内)1.在每个数据声明和语句的最后⼀个必须有⼀个(A)A.分号B.逗号C.顿号D.句号2.合法的字符常量是(D)A.5B."D”C.’\081'D.’\t’3.已知“int b=5".则执⾏“int a=(b= =5);"后,a的值是(C)A5 B.0 C.1 D.24.已知" int a,b,s;",对于语句“scanf ("a=%d,b=%d,c=%d”,&a, &b, &c);” ,能够正确为变量值的输⼊是(B)A.1 3 2B.a=1,b=3,c=2C.a=1 b=3 c=2D.a=1,b=3,c=25.若存在语句”int a; " ,则表达式(a= =1)|| (a!=1)的值是(B)A.0B.1C.2D.不确定6.关于break相continue语有叙述正确的是(A)A. continue语句只结束本次循,但不能够结束整个循环执⾏B. continue语句只结束本次循环,且同时结束整个循环执⾏C break语句⽉结束本次循环,但不能够结束整个循环执⾏D.内循环中的break语句可以结束整个外循环的执⾏7.已知"int a[10]={1,2,3,4};”,则a[4]的值是(C)A.4B.3C.0D.不确定8.设有语句“double a[5],*p=a;",则与数组元素a[3]等价的是(B)A.( *p)[3] B. *(p+3) C. *p[3] D. *p+39.下列语句正确的是(D)A.char s{20};s={”C Language”}B.char s{20};s=”C Language”;C.char *s;s={”C Language”};D.char *s;s=”C Language”;10.下列叙述正确的是(A)A.⼀个⾃定义函数中可以根据不同情况设置多条return语句B.⼀个⾃定义函数中必须有⼀条return语句C.定义为void类型的函数中可以有带返回值的return语句D.没有return语句的⾃定义函数在执⾏结束时不能返回⼆、填空题(本⼤题共8⼩题,每空3分,共计24分。
广州大学2017-2018学年第二学期试卷课程《数据结构》考试形式(闭卷,考试)物理与电子工程学院电子系电子061、062、063 专业学号姓名一、判断题(对打√,错打×。
每题1分,共15分)1、顺序存储结构只能用于存储线性结构。
( )2、在线性表的顺序存储结构中,插入和删除元素时,移动元素的个数与该元素的位置有关。
( )3、在线性表的链式存储结构中,逻辑上相邻的元素在物理位置上不一定相邻( )。
4、二叉树的前序遍历序列中,任意一个结点均处在其子树结点的前面( )。
5、二叉树的前序和后序遍历序列能惟一确定这棵二叉树( )。
6、在无向图中,边的条数是结点度数之和( )。
7、图的邻接矩阵必定是对称矩阵( )。
8、二叉树是度最大为2的有序树( )。
9、结点数固定的二叉树中,完全二叉树具有最小路径长度( )。
10、中序线索树中,右线索若不为空,则一定指向其双亲结点( )。
11、有向图用邻接矩阵表示,容易实现求结点度数的操作( )。
12、按深度优先搜索遍历图时,与始点相邻的结点先于不与始点相邻的结点访问( )13、若有向图的邻接矩阵中对角线以下元素均为零,则该图的拓扑排序序列必定存在( )。
14、若有向图G中包含一个环,则G的结点间不存在拓扑排序( )。
15、图的拓扑排序序列是唯一的( )。
二、选择题(每题2分,共20分)1.数据结构被形式定义为(D,S),其中D是()的有限集合,S是D上的()有限的集合。
A.算法 B.数据元素C.数据操作D.逻辑结构E.操作F.映像G.存储H.关系2.设n为正整数。
下列程序段中前置以记号@的语句的频度为()。
i=1;k=0;while(i<n-1){@ k+=10*i;i++;}A.n B.n-1 C.n-2 D.n-33.线性表若采用链式存储结构时,要求内存可用存储单元的地址()。
A.必须是连续的B.部分地址必须是连续的C.一定是不连续的D.连续不连续都可以4.在解决计算机主机与打印机之间速度不匹配问题时,通常设置一个打印数据缓冲区。
山西省2018年专升本选拔考试(C程序设计数据结构)历年真题详解说明:本试题分C程序设计和数据结构(C语言版)两部分,各占100分,满分200分,考试时间150分钟。
第一部分C程序设计一、单项选择题( 本大题共10小题,共小题3分,共计30分,在每小题的四个备选答案中,只有一个答案是正确的,请将代表正确答案的字母填入下列表格内)1.在每个数据声明和语句的最后一个必须有一个(A)A.分号B.逗号C.顿号D.句号2.合法的字符常量是(D)A.5B."D”C.’\081'D.’\t’3.已知“int b=5".则执行“int a=(b= =5);"后,a的值是(C)A5 B.0 C.1 D.24.已知" int a,b,s;",对于语句“scanf ("a=%d,b=%d,c=%d”,&a, &b, &c);” ,能够正确为变量值的输入是(B)A.1 3 2B.a=1,b=3,c=2C.a=1 b=3 c=2D.a=1,b=3,c=25.若存在语句”int a; " ,则表达式(a= =1)|| (a!=1)的值是(B)A.0B.1C.2D.不确定6.关于break相continue语有叙述正确的是(A)A. continue语句只结束本次循,但不能够结束整个循环执行B. continue语句只结束本次循环,且同时结束整个循环执行C break语句月结束本次循环,但不能够结束整个循环执行D.内循环中的break语句可以结束整个外循环的执行7.已知"int a[10]={1,2,3,4};”,则a[4]的值是(C)A.4B.3C.0D.不确定8.设有语句“double a[5],*p=a;",则与数组元素a[3]等价的是(B)A.( *p)[3] B. *(p+3) C. *p[3] D. *p+39.下列语句正确的是(D)A.char s{20};s={”C Language”}B.char s{20};s=”C Language”;C.char *s;s={”C Language”};D.char *s;s=”C Language”;10.下列叙述正确的是(A)A.一个自定义函数中可以根据不同情况设置多条return语句B.一个自定义函数中必须有一条return语句C.定义为void类型的函数中可以有带返回值的return语句D.没有return语句的自定义函数在执行结束时不能返回二、填空题(本大题共8小题,每空3分,共计24分。
韩山师范学院2017年本科插班生考试试卷计算机科学与技术专业 高级语言程序设计试卷(A 卷)一、填空题(每空2分,共10分)1.C 程序的基本组成单位是 函数 。
2.当a=1,b=35,c=5时,表达式a!=b>c 的值是 _____ 0 __。
3. 一个C 文件是一个__字节流__流或二进制流。
4. 一个字符数据既可以以字符形式输出,也可以以_ 整形 _形式输出。
5. 若a 是int 型变量,且a 的初值为6,则执行表达式a+=a-=a*a 后,a 的值为 -24 。
二、单项选择题(每题2分,共30分)1.下述程序段的输出结果是(D)。
int x=10;int y=x--;printf("%d,%d",(y++,x),y++);A、9,10B、11,10C、10,9D、9,11逗号运算符:表达式用逗号分开,所以最终的值应该是最后一个表达式的值2.下面各选项中,均是C语言标识符的选项组是(C)。
A、for china toB、void union _342C、long_123 short56 _doD、text.txt _075 _3ew 3.若int k=10;则执行下列程序后,变量k的正确结果是(B)。
main( ){ int k=10;switch(k){ case 9: k+=1;case 10: k+=1;break;case 11: k+=1;default: k+=1}printf(″%d\n″,k);}A、12B、11C、10D、94.在位运算中,操作数每右移一位,其结果相当于(A)。
A、操作数除以2B、操作数乘以16C、操作数除以16D、操作数乘以2左移乘二,右移除以2,都是整除5.以下能对二维数组c进行正确的初始化的语句是(B)。
A、int c[][5]={{1},{},{4}};B、int c[][5]={{1},{2},{4}};C、int c[5][]={{2},{8},{4},{5}};D、int c[5][]={{6},{6},{9}};6、以下程序执行后,sum的值是(A)。
韩山师范学院2017年本科插班生考试试卷数学与应用数学 专业 数学分析 试卷(A 卷)一、 填空题(每小题3分,共30分)1. 设函数)(x f 在 [a,b ] 上连续,则21()x d f t dt dx⎰= . 2. 设)(x f 具有连续的导数, 则=+⎰dx x f x f x f )(1)()(2' .3. 设=)(x f sin , 0,, 0, (2, 0,kxx x k x k x x ⎧<⎪⎪=⎨⎪+>⎪⎩为常数), 若()f x 在0x =在右连续,则k =_________ _ ____.4. 设∈+=x x n xn x f n , ||1sin )(2) , (∞+∞-.则=∞→)(lim x f n n . 5. 函数3ln 3)(--=x x x f 全部间断点是 .6.343()41032f x x x ⎡⎤=-+⎢⎥⎣⎦设 ,则其在,上的最小值为 .7. 二重积分23Dx y dxdy ⎰⎰ (其中D :0≤y ≤x 2,0≤x ≤1)的值为 . 8. 设(,)z f x y xy =+,(,)f u v 具有连续偏导数,则偏导数zy∂=∂ . 9. 交换积分dx y x f dyy⎰⎰-101),(的次序成为 .10. 设dy hh x f x f x f y h 36)2()(lim),(0则且=+-=→等于 .二、 计算题(每小题6分,共30分)1. 设⎪⎩⎪⎨⎧=+≠++=0 ,0 0 ,1sin ),(222222y x y x yx y y x f ,考察函数f 在原点(0,0)的偏导数。
2. 求cos 2x 的幂级数展开式.3. 计算极限 2n 11lim(1)nn n→∞++.4.求曲面z y x =+22,4:22=+y x D 及xoy 平面所围成的立体体积.5.求由曲线y 2 = 2x 及直线y = x-4所围成的图形的面积。
2022年韩山师范学院计算机应用技术专业《数据库概论》科目期末试卷A(有答案)一、填空题1、数据库系统是利用存储在外存上其他地方的______来重建被破坏的数据库。
方法主要有两种:______和______。
2、关系代数运算中,基本的运算是______________、______________、______________、______________和______________。
3、事务故障、系统故障的恢复是由______完成的,介质故障是由______完成的。
4、采用关系模型的逻辑结构设计的任务是将E-R图转换成一组______,并进行______处理。
5、在关系数据库的规范化理论中,在执行“分解”时,必须遵守规范化原则:保持原有的依赖关系和______。
6、关系规范化的目的是______。
7、主题在数据仓库中由一系列实现。
一个主题之下表的划分可按______、______数据所属时间段进行划分,主题在数据仓库中可用______方式进行存储,如果主题存储量大,为了提高处理效率可采用______方式进行存储。
8、数据仓库主要是供决策分析用的______,所涉及的数据操作主要是______,一般情况下不进行。
9、在SQL Server 2000中,数据页的大小是8KB。
某数据库表有1000行数据,每行需要5000字节空间,则此数据库表需要占用的数据页数为_____页。
10、使某个事务永远处于等待状态,得不到执行的现象称为______。
有两个或两个以上的事务处于等待状态,每个事务都在等待其中另一个事务解除封锁,它才能继续下去,结果任何一个事务都无法执行,这种现象称为______。
二、判断题11、在关系模式中,主码和候选码可以有多个。
()12、从计算机数据管理的角度看,信息就是数据,数据就是信息。
()13、可以用UNION将两个查询结果合并为一个查询结果。
()14、数据库的数据项之间无联系,记录之间存在联系。
武夷学院期末考试试卷( 09级计算机科学与技术专业2010 ~2011 学年度第 1 学期) 课程名称 数据结构 A 卷 考试形式 闭卷 考核类型 考试 本试卷共 五 大题,卷面满分100分,答题时间120分钟。
一、选择题:(本大题共10小题,每小题2分,共20分)1. 某内排序方法的稳定性是指( )。
A .该排序算法不允许有相同的关键字记录 B .该排序算法允许有相同的关键字记录 C .平均时间为0(n log n )的排序方法 D .以上都不对2.下面程序段的时间复杂度为( )。
for(i=2;i<=n;++I) for(j=2;j<=i-1;++j) {++x;a[i ,j]=x;}A.O (1)B.O (log 2n )C.O (n )D.O (n 2)3.非空的循环单链表head 的尾结点p 满足( )。
A.p->next=head ;B. p->next=NULL ;C.p =NULL ;D. p->next->next =head ;4.设栈s 和队列Q 的初始状态为空, 元素b 1 ,b 2, ,b 3 , b 4 , b 5 和b 6 依次通过栈S ,一个元素出栈后即进队列Q ,若6个元素出队的序列是b 2 ,b 4 ,b 3 ,b 6 ,b 5 ,b 1 ,,则栈S的容量至少应该是()。
A. 3B. 4C. 5D.其它5.表头和表尾均为空表的广义表是()。
A.()B.(())C.((()))D.((),())6.下列二叉排序树中,满足平衡二叉树定义的是()。
A . B. C. D.7.二维数组A的成员是4个字符(每个字符占一个存储单元)组成的串,行下标i的范围从1到8,列下标j的范围从1到10,若A按行优先方式存储,起始地址为SA,那么元素A[8][5]的起始地址为()。
A.SA+292 B.SA+296 C.SA+300 D.SA+3048.当在一个有序的顺序存储表上查找一个数据时,即可用折半查找,也可用顺序查找,但前者比后者的查找速度()。
1 8 韩山师范学院2018年本科插班生考试试卷 计算机科学与技术 专业 数据结构 试卷(A卷)
题号 一 二 三 四 五 六 总分 评卷人 得分
一、单项选择题(每题2分,共30分)
1. 数据的最小单位是( B )。 A. 数据元素 B.数据项 C.数据类型 D. 数据变量 2. 一个栈的输入序列为A B C,则下列序列中不可能是栈的输出序列的是( C )。 A. B C A B.C B A C. C A B D. A B C 3.程序段s=i=0;do {i=i+1; s=s+i;}while(i<=n);的时间复杂度为( A )。 A. O(n) B. O(nlog2n) C.O(n2) D.O(n3/2) 4.一个非空广义表的表头( D )。 A.不可能是子表 B.只能是子表 C.只能是原子 D.可以是子表或原子 5.设顺序循环队列Q[0:M-1]的头指针和尾指针分别为F和R,头指针F总是指向队头元素的前一位置,尾指针R总是指向队尾元素的当前位置,则该循环队列中的元素个数为( D )。 A. R-F B.F-R C. (F-R+M)%M D. (R-F+M)%M 6.设指针变量p指向单链表中结点A,若删除单链表中结点A,则需要修改指针的操作序列为( C )。 A. q=p->next;p->next=q->next;free(q); B. q=p->next;p->data=q->data;free(q); C. q=p->next;p->data=q->data;p->next=q->next;free(q); D. q=p->next;q->data=p->data;p->next=q->next;free(q); 7.设有一个二维数组A[m][n],假设A[0][0]存放位置在644(10),A[2][2]存放位置在676(10),每个元素占一个空间,问A[3][3](10)存放在什么位置?脚注(10)表示用10进制表示( B )。
得分 评卷人 2 8 A. 696 B. 692 C.688 D. 678 //c,对的.676+(676-644)/2
A[2][2]与A[0][0] 相差两排零2个元素 A[3][3]与A[2][2] 相差一排零1个元素 因为元素的地址是连续的 所以A[2][2]与A[0][0] 的地址差是A[3][3]与A[2][2]地址差的2倍 A[2][2]与A[0][0] 的地址差是676-644 A[3][3]与A[2][2]地址差是(676-644)/2 所以A[3][3]的地址是676+(676-644)/2 8.设一组初始关键字记录关键字为(20,15,14,18,21,36,40,10),则以20为基准记录的一趟快速排序结束后的结果为( D )。 A. 15,10,14,18,20,36,40,21 B.10,15,14,18,20,40,36,21 C. 10,15,14,20,18,40,36,2l D. 10,15,14,18,20,36,40,21 9.设某棵二叉树中有2000个结点,则该二叉树的最小高度为( C )。 A.9 B. 10 C.11 D. 12 10.数组的逻辑结构不同于下列( A )的逻辑结构。 A. 树 B. 栈 C. 队列 D. 线性表 11.根据二叉树的定义可知二叉树共有( B )种不同的形态。 A.4 B. 5 C. 6 D. 7 12.设一条单链表的头指针变量为head且该链表没有头结点,则其判空条件是( A )。 A.head==0 B. head->next==0 C. head->next==head D.head!=0 // 注意:不论是带头结点的链表还是不带头结点的链表,头指针head都指向链表中的第一个结点。如果该链表有头结点,则头指针head指向头结点,如果没有头结点,则头指针head指向链表的第一个节点。 1 带头结点的单链表中头指针head指向头结点,头结点的值域不含任何信息,从头结点的后继结点开始存储信息。头指针head始终不等于NULL,head->next等于NULL的时候链表为空。 2 不带头结点的单链表中的头指针head直接指向开始结点,当head等于NULL的时候链表为空。 头结点的存在,使得空链表与非空链表的处理变得一直,也方便了对链表的开始结点插入或删除操作。 3 8 13.设用邻接矩阵A表示有向图G的存储结构,则有向图G中顶点i的入度为( B )。 A.第i行非0元素的个数之和 B. 第i列非0元素的个数之和 C.第i行0元素的个数之和 D. 第i列0元素的个数之和 14.设无向图G中有n个顶点,则该无向图的最小生成树上有(C )条边。 A. 2n B. 2n-1 C. n-1 D. n 15.由权值分别为11,8,6,2,5的叶子结点生成一棵哈夫曼树,它的带权路径长度为( D ) A. 24 B. 48 C. 53 D. 71
二、填空题(每空2分,共20分) 1.数据的物理结构主要包括_顺序储存结构_和___链式存储结构_两种情况。 2.设某棵二叉树中度数为0的结点数为N0,度数为1的结点数为N1,则该二叉树中度数为2的结点数为___N0-1______;若采用二叉链表作为该二叉树的存储结构,则该二叉树中共有_______个空指针域。 3. 设指针p指向单链表中结点A,指针s指向被插入的结点X,则在结点A的前面插入结点X时的操作序列为: 1) s->next=__p->next____;2) p->next=s;3) t=p->data; 4) p->data=____s_______;5) s->data=t;
4. 已知一有向图的邻接表存储结构如下:从顶点1出发,DFS遍历的输出序列是 13452 ,BFS遍历的输出序列是 13245
// 深度优先是从某个顶点出发,访问完后,寻找一个未访问的邻接顶点继
得分 评卷人 4 8 续深度优先,如果此路不同就往回退,所以看邻接表,首先访问V1,完了后顺链寻找没有访问的邻接顶点,自然链表中的第一个结点就是v3,接着转到v3再来深度优先,访问v3后,在其链表中第一个邻接顶点是v4 接着访问v4,下面走不通,回到v3,继续顺链往后,自然是v5,v5的邻接顶点中v2还没有访问 所以序列为v1, v3, v4, v5, v2 再看广度优先,从某个顶点完成后,需要一口气将其邻接未访问的所有顶点都访问,后面类推 于是过程是先v1,再顺链将v3,v2依次访问完,然后再依次访问v3和v2的各个未访问邻接顶点,v3链表中顺链可以访问v4,v5,所以最后访问序列为v1, v3, v2, v4, v5 5. 解决散列表冲突的两种方法是___开放定址法____和__链地址法__。
三、判断题(对的划√,错的划×。每小题1分,共10分)
( × )1.调用一次深度优先遍历可以访问到图中的所有顶点。 ( × )2. 设一棵二叉树的先序序列和后序序列,则能够唯一确定出该二叉树的形状。 //因为不知道左右孩子。所以如果已知中序,只需要一个前序或者后序就可以确定二叉树了 ( √)3.快速排序是排序算法中平均性能最好的一种排序。 ( √ )4.不论是入队列操作还是入栈操作,在顺序存储结构上都需
得分 评卷人 5 8 要考虑“溢出”情况。 ( × )5.线性表中的所有元素都有一个前驱元素和后继元素。 ( √ )6.分块查找的基本思想是首先在索引表中进行查找,以便确定给定的关键字可能存在的块号,然后再在相应的块内进行顺序查找。
//分块查找:即又称索引顺序查找,这是顺序查找的一种改进的方法.在此查找
法中,除表本身以外,尚需建立一个"索引表",其包含两项内容:关键字项(其值为该字表中最大的关键字)和指针项(指示该字表的第一个记录在表中的位置).所谓分块指的是第二个子表中所有的关键字都比第一个表中的关键字大,同理,第三个字表都大于第二个字表中的所有的关键字.. 通常,分块查找的过程需要分两步:先确定待查记录所在的块(字表),然后在块中顺序查找.
( × )7.向二叉排序树中插入一个结点需要比较的次数可能大于该二叉树的高度。 ( √ )8.不论线性表采用顺序存储结构还是链式存储结构,删除值为X的结点的时间复杂度均为O(n)。
( × )9.子串“ABC”在主串“AABCABCD”中的位置为2。 ( × )10.用邻接矩阵作为图的存储结构时,则其所占用的存储空间与图中顶点数无关而与图中边数有关。 四、程序填空题(每个空2分,共10分)
1. 下面程序段的功能是实现冒泡排序算法,请在下划线处填上正确的语句。
void bubble(int r[n]) { for(i=1;i<=n-1; i++) {
得分 评卷人 6 8 for(exchange=0,j=0; j<_____________;j++) if (r[j]>r[j+1]){temp=r[j+1];______________;r[j]=temp;exchange=1;} if (exchange==0) return; } } 2. 如下为二分查找的非递归算法,试将其填写完整。 Int Binsch(ElemType A[ ],int n,KeyType K) { int low=0; int high=n-1; while (low<=high) { int mid=____________________________; if (K==A[mid].key) return mid; //查找成功,返回元素的下标 else if (K<[mid].key) _________________________; //在左子表上继续查找 else __________________; //在右子表上继续查找 } return -1; //查找失败,返回-1 }
五、分析简答题(共20分) 1.(10分)求AOE网的关键路径。
关键路径:v0,v1,v4,v3,v6
得分 评卷人