东北大学2007分布式操作系统考博真题

合集下载

2022年东北大学计算机科学与技术专业《操作系统》科目期末试卷A(有答案)

2022年东北大学计算机科学与技术专业《操作系统》科目期末试卷A(有答案)

2022年东北大学计算机科学与技术专业《操作系统》科目期末试卷A(有答案)一、选择题1、某文件系统的簇和磁盘扇区大小分别为1KB和512B。

若一个文件的大小为1026B,则系统分配给该文件的磁盘空间大小是()。

A.1026BB.1536BC.1538BD.2048B2、考虑一个文件存放在100个数据块中。

文件控制块、索引块或索引信息都驻留内存。

那么如果().不需要做任何磁盘I/O操作。

A.采用连续分配策略,将最后一个数据块搬到文件头部,B.采用单级索引分配策略,将最后一个数据块插入文件头部C.采用隐式链接分配策略,将最后一个数据块插入文件头部D.采用隐式链接分配策略,将第一个数据块插入文件尾部,3、下面有关选择进程调度算法的准则,错误的是()A.尽量提高处理器利用率B.尽可能提高系统吞吐量C.适当增长进程在就绪队列中的等待时间D.尽快响应交互式用户的要求4、在使用信号量机制实现互斥时,互斥信号量的初值一般为():而使用信号量机,制实现同步时,同步信号量的初值般为()。

A.0:1B.1:0C.不确定:1D.1:不确定5、若系统S1采用死锁避免方法,S2采用死锁检测方法。

下列叙述中,正确的是()。

I.S1会限制用户申请资源的顺序,而S2不会II.S1需要进程运行所需资源总最信息,而S2不需要III.SI不会给可能导致死锁的进程分配资源,而S2会A.仅I、IIB.仅II、IIIC. 仅I、IID. I、II、III6、下列关于虚拟存储的叙述中,正确的是()A.虚拟存储只能基于连续分配技术B.虚拟存储只能基于非连续分配技术C.虚拟存储容量只受外存容量的限制D.虚拟存储容量只受内存容量的限制7、在请求分页系统中,页面分配策略与页面置换策略不能组合使用的是()。

A.可变分配,全局置换B.可变分配,局部置换C.固定分配,全局置换D.固定分配,局部置换8、在单处理器系统中,可并行的是()I.进程与进程II.处理器与设备III.处理器与通道IV.设备与设备A.I、II和IIIB.I、II和IVC.I、III和IVD.II、III和IV9、 OS通常为用户提供4种使用接口,它们是终端命令、图标菜单、系统调用和()A.计算机高级指令B.宏命令C.类似DOS的批命令文件或UNIX的shell文件D.汇编语言10、下列关于SPOOLing的叙述中,不正确的是()A.SPOOLing系统中必须使用独占设备B.SPOOLing系统加快了作业执行的速度C.SPOOLing系统使独占设备变成了共享设备D.SPOOLing系统利用了处理器与通道并行上作的能力11、通道又称I/O处理器,用于实现()之间的信息传输。

东北大学2007分布式操作系统考博真题

东北大学2007分布式操作系统考博真题

2007年东北大学博士入学考试试题(分布式操作系统)
1 简述分布OS与NET OS的不同
2 解释可伸缩性的含义,举一个限制可伸缩性的实例,提出解决方案。

3 一远程调用,除法:R=FRIBFR(I,J),两实参I,J,返回I/J的结果。

描述RPC中传递值参数进行计算的方法,说明如果第一个参数是I地址,将要面临的问题及解决方法。

4 多线程的几种实现方式
5 K层移动问题
6 时钟滴答问题
7 BULL Y算法的图示,描述,选举冲突时的解决办法。

8 两进程P1、P2,两个整数变量X、Y,初始为0,T为时间印
P1 P2
X=1(T=1) Y=1(T=2)
IF(Y==0)KILL(P2) (T=3) IF(X==0)KILL(P1) (T=4)
8-1 严格一致性模型下,P1,P2能否同时被终止。

8-2 顺序一致性模型下,所有可能的语句交叉模式,判断是否会出现P1,P2两进程之一或全部终止的情况。

8-3 FIFO一致性模型下,两进程能否被同进终止,为什么。

9 将TMR方法推广到2容错度,分别对于FAIL_STOP故障和拜占庭故障给出系统结构图,并解释原因。

东北大学2007级《工程热力学》期末试题(2009年7月8日星期三)

东北大学2007级《工程热力学》期末试题(2009年7月8日星期三)

东北大学《工程热力学》试题A2009年7月8日星期三1.气体常数R g 由气体的种类所决定,其大小与相对分子质量有关,由此我们可以计算诸如氮气、氧气等的气体常数。

通常情况下水不能作为理想气体处理,因为水分子往往借助非常强的氢键结合成为分子链,使得它在常温常压下呈液态而与周围群众格格不入(图一)。

现在的问题是:水的气体常数该如何确定?一种想法是,与其他气体一样,由其单个分子的相对分子质量确定。

另一种想法是,水的气体常数与它所缔合成的分子链大小有关,从而不能称其为常数,如果非要确定一个值的话,可以借助试验等手段给出一个平均值。

请谈谈你的看法,你的理由。

(10分)2.想用一个套管热交换器(Heat exchanger )将140℃的石油制品冷却到40℃。

已知石油制品的比热容约为2.1kJ/(kg ⋅K),套管换热器内管流通截面积是外通道流通截面积的一半。

冷却水进口温度25℃,比热容约为4.2kJ/(kg ⋅K)。

介质流速需控制在8 m/s 以下以避免阻力过大。

假定换热器足够长,两种介质的密度均为1000 kg/m 3,请合理安排两种介质的流程以达到效果最好。

(15分)3.标准状态下,1kmol 的气体压力是多少?温度是多少?体积是多少(取三位有效数字)?高炉热风炉将空气从20℃加热到1100℃,已知20℃到1100℃之间空气的平均体积比热为1.4215kJ/(m 3⋅K)(1.4215千焦耳每标准立方米每开),问100标准立方米的空气完成加热后体积是多少?加热过程吸热量是多少?(15分)4.20世纪末蒸汽参数最高的大功率汽轮机是日本三菱公司和日立公司生产的1000MW-24.5MPa/600℃/600℃超临界一次中间再热汽轮机。

假定再热压力为4.0MPa ,排汽参数为0.005MPa ,试求该机组的理论热效率。

(20分)图一图二5.T–s图上两条定容线可以相交吗?两条定压线呢?为什么?(5分)6.p–v图上两条绝热过程线相交会导致什么结果?请说清楚。

2007东北师范大学英语考博真题

2007东北师范大学英语考博真题

2007一、词汇1. There are as good fish in the sea ________ ever came out of it.(C)A. thanB. likeC. asD. so2. All the President's Men ________ one of the important books for historians who study the Watergate Scandal.(B)A. remainB. remainsC. remainedD. is remaining3. You ________ borrow my notes provided you take care of them,' I told my friend.(A)A. couldB. shouldC. mustD. can4. If only the patient ________ a different treatment instead of using the antibiotics, he might still be alive now.(A)A. had receivedB. receivedC. should receiveD. were receiving5. Linda was ________ to experiment a month ago, but she changed her mind at the last minute.(B)A. to startB. to have startedC. to be startingD. to have been starting6. She ________ fifty or so when I first met her at the conference.(D)A. must beB. had beenC. could beD. must have been7. It is not ________ much the language as the background that makes the book difficult to understand.(C)A. thatB. asC. soD. very8. The committee has anticipated the problems that ________ in the road construction project.(D)A. ariseB. will ariseC. aroseD. have arisen9. The student said there were a few points in the essay he ________ impossible to comprehend.(A)A. had foundB. findsC. has foundD. would find10. He would have finished his college education, but he ________ to quit and find a job to support his family.(C)A. had hadB. hasC. hadD. would have11. The research requires more money than ________.(B)A. have been put inB. has been put inC. being put inD. to be put in12. Overpopulation poses a terrible threat to the human race. Yet it is probably ________ a threat to the human race than enviromental destruction.(B)A. no moreB. not moreC. even moreD. much more13. It is not uncommon for there ________ problems of communication between the old and the young.(D)A. beingB. would beC. beD. to be14.________ at in his way, the situation does not seem so desperate.(B)A. Looking.B. lookedC. Being looked.D. to look15. It is absolutely essential that William ________ his study in spite of some learning difficulties.(C)A. will continueB. continuedC. continueD. continues16. The painting he bought at the street market the other day was a ________ forgery.(D)A. man-madeB. naturalC. crudeD. real17. She's always been kind to me –I can't just turn ________ on her now that she needs my help.(A)A. my backB. my headC. my eyeD. shoulder18. The bar in the club is for the ________ use of its members.(B)A. extensiveB. exclusiveC. inclusiveD. comprehensive19. The tutition fees are ________ to students coming from low-income families.(D)A. approachableB. payableC. reachableD. affordable20. The medical experts warned the authorities of the danger of diseases in the ________ of the earthquake.(A)A. consequenceB. aftermathC. resultsD. effect21. This sort of rude behaviour in public hardly ________ a person in your position.(B)A. becomesB. fitsC. supportsD. improves22. I must leave now.________, if you want that book I'll bring it next time.(B)A. Accidentally.B. Incidentally.C. Eventually.D. Naturally.23. After a long delay, she ________ replying to my e-mail.(D)A. got away withB. got back atC. got backD. got round to24. Personal computers are no longer something beyond the ordinary people; they are ________ available these days.(C)A. promptlyB. instantlyC. readilyD. quickly25. In my first year at the university I learnt the ________ of journalism.(A)A. basicsB. basicC. elementaryD. elements26. According to the new tax law, any money earned over that level is taxed at the ________ of 59 percent ________.(D)A. ratioB. percentageC. proportionD. rate27. Thousands of ________ at the stadium came to their feet to pay tribute to an outstanding performance.(C)A. audienceB. participantsC. spectatorsD. observers28. We stood still, gazing out over the limitless ________ of the dessert.(C)A. spaceB. expanseC. stretchD. land29. Doctor often ________ uneasiness in the people they deal with.(C)A. smellB. hearC. senseD. tough30. Mary sat at the table, looked at the plate and ________ her lips.(A)A. smackedB. openedC. partedD. seperated二、阅读TEXT AIf you like the idea of staying with with a family, living in house might be the answer. Good landladies – those who are superb cooks and launderers, are figures as popular in fiction as the bad ones who terrorize their guest and overcharge them atthe slightest opportunity. The truth is probably somewhere between the two extremes. If you are lucky, the food will be adequate, some of your laundry may be done for you and you will have a reasonable amount of comfort and chompanionship. For the less fortune, house rules may restrict the freedom to invite friends to vistit, and shared cooking and bathroom facilities can be frustrating and row-provoking if tidy and untidy guest are living under the same roof.The same disadvantages can apply to flat sharing, with the added difficulties that arise from deciding who pays for what, and in what proportion. One person may spend hours on the phone, while another rarely makes calls. If you want privacy with guest, how do you persuade the others to go out; how do you persuade them to leave you in peace, especially if you are student and want to study?Conversely, flat sharing can be very cheap, there will always be someone to talk to and go out with, and the chores, in theory, can be shared.1. According to the passage, landladies are ________.(D)A. usually strictB. always meanC. adequately competentD. very popular with their guest2. What is the additional disadvantage of flat sharing?(A)A. Problems of sharing and paying.B. Differences in living habits.C. Shared cooking and bathroom facilities.D. Restriction to invite friends to visit.3. What is NOT mentioned as a benefit of flat sharing?(D)A. Rent is affordable.B. There is companionship.C. Housework.D. There is peace and quiet.TEXT B1. Travelling through the country a couple of weeks ago on business, I was listening to the talk of the late UK writer Douglas Adams' master work "The Hitchhiker's Guide to the Galaxy" on the radio and thought-I know, I'll pick up the next hitchhikers I see and ask them wahat the state of real hitching is today in Britain.2. I drove and drove on main roads and side roads for the next few days and never saw a single one.3. When I was in my teens and 20s, hitchhiking was a main form of long-distance transport. The kindness or curiosity of strangers took me all over Europe, North America, Asiaand southern Africa, Some of the lift-givers became friends, many provided hospitality on the road.4. Not only did you find out much more about a country than when traveling by train or plane, but there was that lelement of excitement about where you would finish up that night.Hitchhiking featured importantly in Western culture. It has books and songs about it. So what has happened to it?5. A few years ago, I was asked the same question about hitching in a column of a newspaper. Hundreds of people from all over the world responded with theirview on the state of hitchhiking.6. Rural Ireland was recommended as a friendly place for hitching, as was Quebec, Canada-"if you don't mind being criticized for not speaking French".7. But while hitchhiking was clearly still alive and well in some places, the general feeling was that throughout much of the west it was doomed.8. With so much news about crime in the media, people assumed that anyone on the open road without the money for even a bus ticket must present a danger. But do we need to be so wary both to hitch and to give a lift?9. In Poland in the 1960s, according to a Polish woman who e-mail me,"the authorities introduced the Hitchhiker's Booklet. The booklet contained coupons for drivers, so each time a driver picked somebody, he or she received a coupon. At the end of the season, drivers who had picked up the most hikers were rewarded with various prizes. Everyone was hitchhiking then".10. Surely this is a good idea for society. Hitchhiking would increase respect by breaking down barriers between strangers. It would help fight global warming by cutting down on fuel consumption as hitchhikers would be using existing fuels. It would also improveeducational standards by delivering instant lessons in geography, history, politics and sociology.11. A century before Douglas Adams wrote his "Hitchhiker's Guide", another adventure story writer, Robert Louis Stevenson, gave us that what should be the hitchhiker's motto:"To travel hopefully is a better thing than to arrive." What better time than putting a holiday weekend into practice. Either put it to the test yourself, or help out someone who is trying to travel hopefully with thumb outstreched.4. In which paragraph (s) does the writer comment on his experience of hitchhiking?(C)A. 大3家B. 大4家C. 大3家and 大4家D. 大4家and 大5家5. What is the current situation of hitchhiking?(A)A. It is popular in some parts of the world.B. It is popular throughout the west.C. It is popular in Poland.6. What is the writer's attitude towards the practice in Poland?(D)A. Critical.B. Unclear.C. Somewhat favourable.D. Strongly favourable.7. The writer has mentioned all the following benefits of hitchhiking EXCEPT(B)A. promoting mutual respect between strangersB. increasing one's confidence in strangersC. protecting enviromentD. enrich one's knowledge8."Either put it to the test yourself…"in Paragraph 大11家means(D)A. to experience the hopefulnessB. to read Adams' bookC. to offer someone a lift TEXT CI am afraid to sleep. I have been afraid to sleep for the last few weeks. I am so tired that, finally, I do sleep, but only for a few minutes. It is not a bad dream that wakes me; it is the realiry I took with me into sleep. I try to think of something else. Immediately the woman in the marketplace comes into my mind.I was on my way to dinner last night when I saw her. She was selling skirts. She moved with the same ease and loveliness I often saw in the women of Laos. Her long black hair was as shiny as the black silk of the skirts she was selling. In her hair, she wore three silk ribbons, blue, green, and white. They meminded me of my childhood and how my girlfriends and I used to spend hours braiding ribbons into our hair.I don't know the word for "ribbons", so I put my hand to my own hair and, with three fingers against my head, I looked at her ribbons and said "Beautiful." She lowered her eyes and said nothing. I wasn't sure if she understood me (I don't speak Laotian very well).I looked back down at the skirts. They ahd designs in them: squares and triangles and circles of pink and green silk. They were very pretty. I decided to buy one of those skirts, and I began to bargain with her over the price. It is the custom to bargain in Asia. In Laos bargaining is done in soft voices and easy moves with the sort of quiet peacefulness.She smiled, more with her eyes than with her lips. She was pleased by the few words I was able to say in her language, although they were mostly numbers, and she saw that I understood something about the soft playfulness of bargaining. We shook our heads in disagreement over the price; then, immediately, we made another offer and then another shake of the head. She was so pleased that unexpectedly, she accepted the last offer I made. But it was too soon. The price was too low. She was being too generous and wouldn't make enough money. I moved quickly and picked up two more skirts and paid for all three at the price set; that way I was able to pay her three times as much before she had a chance to lower the price for the larger purchase. She smiled openly then, and, for the first time in months, my spirit lifted. I almost felt happy.The feeling stayed with me while she wrapped the skirts in a newspaper and handed them to me. When I left, though, the feeling left, too. It was as though it stayed behind in marketplace. I left tears in my throat. I wanted to cry. I didn't, of course.I have learned to defend myself against what is hard; without knowing it, I have also learned to defend myself against what is soft and what should be easy.I get up, light a candle and want to look at the skirts. They are still in the newspaper that the woman wrapped them in. I remove the paper, and raise the skirts up to look at them again before I pack them. Something falls to floor. I reach down and feel something cool in my hand. I move close to the candlelight to see what I have. There are five long silk ribbons in my hand, all different colours. The woman in the maketplace! She has given these ribbons to me!There is no defense against a generous spirit, and this time I cry, and very hard, as if I could make up for all the months that I didn't cry.10. Which of the following in NOT corret?(A)A. The writer was not used to bargaining.B. People in Asia always bargain when buying things.C. Bargaining in Laos was quiet and peaceful.D. The writer was ready to bargain with the woman.11. The writer assumed that the voman accepted the last offer mainly because woman ________.(B)A. thought that the last offer was reasonableB. thought she could still make much moneyC. was glad that the writer knew their way of bargainningD. was tired of bargainning with the writer any more12. Why did the writer finally decide to buy three skirts?(C)A. The skirts were cheap and pretty.B. She liked the patterns on the skirts.C. She wanted to do something as compensation.D. She was fed up with further bargainning with the woman.13. When did the writer left the marketplace, she wanted to cry, but did not because ________.(D)A. she had learned to stay cool and unfeelingB. she was afraid of crying in publicC. she had learned to face difficulties bravelyD. she had to show in public that she was strong14. Why did the writer cry eventually when she looked at the skirts again?(C)A. she suddently felt very sadB. she liked the ribbons so muchC. she was overcome by emotionD. she felt sorry for the womanTEXT DThe kids are hanging out. I pass small bands of students, in my way to work these morings. They have become a familiar part of the summer landscape.These kids are not old enough for jobs. Nor are they rich enough for camp. They are school children without school. The calendar called the school year ran out on them a few weeks ago. Once supervised by teachers and principals, they now appear to be "self care".Passing them is like passing through a time zone. For much of our history, after all, Americans arranged the school year around the needs of work and family. In 19th-century cities, schools were open seven or eight hours a day, 11 months a year. In rural America, the year was arranged around the growing season. Now, only 3 percent of families follow the agricultural model, but nearly all schools are scheduled as if our children went home early to milk the cows and took months off to work the crops. Now, three-quarters of the mothers of school-age children work, but the calendar is written as if they were home waiting for the school bus.The six-hour day, the 180-day school year is regarded as something holy. Butwhen parents work an eight-hour day and a 240-day year, it means something different. It means that many kids go home to empty houses. It means that, in the summer, they hang out."We have a huge mismatch between the school calendar and realisties of family life,"says Dr. Ernest Boyer, head of the Carnegie Foundation for the Advancement of Teaching.Dr. Boyer is one of many who believe that a radical revision of the school calendar is inevitable."School, whether we like it or not, is educational. It always has been."His is not popular idea. School are routinely burdened with the job of solving all our social problems. Can they be asked to meet the needs of our work and family lives?It may be easier to promote a linger school year on its educational merits and, indeed, the educational case is compelling. Despite the complaints and studies about our kids' lack of learning, the United State still has a shorter school year than any industrial nation. In most of Europe, the school year is 220 days. In Japan, it is 240 days long. While classroom time alone doesn't produce a well-educated child, learning takes time and more learning takes more time. The long summers of forgetting take a toll.The opposition to a longer school year comes from families that want to and can provide other experiences for their children. It comes from teachers. It comes from tradition. And surely from kids. But the most important part of the conflict has been over the money.15. Which of the following is an opinion of the auther's?(B)A. "The kids are hanging out."B. "They are school children without school."C. "These kids are not old enough for jobs."D. "The calendar called the school year ran out on them a few weeks ago."16. The current American school calendar was developed in the 19th century according to ________.(A)A. the growing season on nation's formB. the labour demands of the industrial ageC. teachers' demands for more vacation timeD. parents' demands for other experiences for their kids17. The author thinks that the current school calendar ________.(B)A. is still validB. is out of dateC. can not be revisedD. can not be defended18. Why was Dr. Boy's idea unpopular?(D)A. He argues for the role of school in solving social problems.B. He supports the current school calendar.C. He thinks that school year and family life should be donsidered separately.D. He strongly believes in the educational role of school.19."The long summers of forgetting take a toll"in the last paragraph but one means that(C)A. long summer vacation slows down the progress go learningB. long summer vacation has been abandoned in EuropeC. long summers result in less learning timeD. long summers are a result of tradition20. The main purpose of the passage is ________.(C)A. to describe how American children spend their summerB. to explain the needs of the modern working familiesC. to discuss the problems of the current school calendarD. to persuade parents to stay at home to look after their kids。

东北大学考博专业课分布式系统课件第一章

东北大学考博专业课分布式系统课件第一章
第一章 分布式系统概述
25
(3)总线型多计算机
Local Memory Local Memory Local Memory
CPU
CPU
CPU
• 本地内存 • 局域网络(10M ~ 100M~1G) •Share-nothing结构 •缺点:有限伸缩性(25-100节点)
2006-3-7
东北大学软件所 于戈
第1章 分布式系统 章
东北大学信息学院 于戈 2006年3月
主要内容
1.1 分布式系统概念 1.2 分布式系统的特点 1.3 硬件概念 1.4 软件概念 1.5 客户/服务器模型 1.6 分布式系统设计问题
2006-3-7
东北大学软件所 于戈
第一章 分布式系统概述
2
1.1 分布式系统概念
“一个分布式系统是若干个独立的计算机的集合, 一个分布式系统是若干个独立的计算机的集合, 一个分布式系统是若干个独立的计算机的集合 但是对该系统的用户来说, 但是对该系统的用户来说,感觉该系统就像一台计算 机一样。 机一样。” • 硬件方面:每台计算机都是独立、自主的计算机 • 软件方面:用户感觉在独占系统
排名 1 2 3 4 5 6 7 8 9 10 26 42 93 地点 美国DOE/NNSA/LLNL 美国IBM Thomas J. Watson Research Center 美国DOE/NNSA/LLNL 美国NASA/Ames Research Center/NAS 美国Sandia National Laboratories 美国Sandia National Laboratories 日本The Earth Simulator Center 西班牙Barcelona Supercomputer Center 荷兰ASTRON/University Groningen 美国Oak Ridge National Laboratory 中国Meteorological Administration 中国Shanghai Supercomputer Center 中国Chinese Academy of Science 计算机 BlueGene/L - eServer Blue Gene Solution,IBM BGW - eServer Blue Gene Solution, IBM ASC Purple - eServer pSeries p5 575 1.9 GHz, IBM Columbia - SGI Altix 1.5 GHz, Voltaire Infiniband, SGI Thunderbird - PowerEdge 1850, 3.6 GHz, Infiniband, Dell Red Storm Cray XT3, 2.0 GHz, Cray Inc. Earth-Simulator, NEC MareNostrum - JS20 Cluster, PPC 970, 2.2 GHz, Myrinet, IBM Stella - eServer Blue Gene Solution, IBM Jaguar - Cray XT3, 2.4 GHz, Cray Inc. eServer pSeries 655 (1.7 GHz Power4+), IBM Dawning 4000A, Opteron 2.2 GHz, Myrinet,曙 光 DeepComp 6800, Itanium2 1.3 GHz, QsNet,联想 处理机# 处理机 131072 40960 10240 10160 8000 10880 5120 4800 12288 5200 3200 2560 1024 年份 2005 2005 2005 2004 2005 2005 2002 2005 2005 2005 2005 2004 2003 Rmax 280600 91290 63390 51870 38270 36190 35860 27910 27450 20527 10310 8061 4193 Rpeak 367000 114688 77824 60960 64512 43520 40960 42144 34406.4 24960 21760 11264 5324.8

东北大学计算机网络B卷(附答案)

东北大学计算机网络B卷(附答案)


(
)7.If a package is to be broadcasted to the local network, then the destination
A. 1~1023
B. 1024 and above
C. 1~256
D. 1~65534

IP address of the package should be:

( F ) 3.The hubs can interconnect a token-ring network and an Ethernet.

( F ) 4.8 broadcast domains are created when you segment a network with an 8-port

(
)3. Which device extends the LAN on data link layer?

A. Repeater B. Hub C. Switch
D. Router


(
)4.The communication method which can transmit data bi-directionally(双向)

4. _65534_ (how many) usable subnets are created by applying the subnet mask

255.255.255.0 to a Class A network.
Hubs
Routers
Switches

5. FF-FF-FF-FF-FF-FF is a Layer-2 broadcast address.

计算机考博试题及答案

计算机考博试题及答案

计算机考博试题及答案1. 数据结构与算法1.1 平衡二叉树平衡二叉树,也称为AVL树,是一种特殊的二叉搜索树,它的左右子树的高度差不超过1。

请说明如何插入和删除节点以保持平衡。

答案:当向平衡二叉树中插入一个节点时,需要按照二叉搜索树的规则找到对应的位置。

插入节点后,如果破坏了平衡二叉树的平衡性,则需要进行相应的调整。

插入节点后,从插入节点到根节点的路径上的所有节点的平衡因子需要更新,并沿着路径向上检查,如果某个节点的平衡因子超过了1或小于-1,则需要进行旋转操作来恢复平衡。

当删除一个节点时,同样需要按照二叉搜索树的规则找到对应的位置,并将该节点删除。

删除节点后,同样需要从删除节点到根节点的路径上的所有节点的平衡因子进行更新,并进行相应的旋转操作来恢复平衡。

1.2 Dijkstra算法Dijkstra算法是一种用于求解加权有向图中单源最短路径问题的算法。

请简要介绍Dijkstra算法的原理及步骤。

答案:Dijkstra算法的原理是,通过不断找出当前距离源点最近的顶点,并更新其他顶点的距离和路径,最终得到源点到其他所有顶点的最短路径。

步骤如下:1) 初始化:将源点设置为当前顶点,将源点到其他顶点的距离初始化为无穷大,将源点到自身的距离初始化为0。

2) 循环:在未遍历的顶点中,选择当前距离源点最近的顶点作为当前顶点。

3) 更新:计算当前顶点的邻居顶点经过当前顶点到达源点的距离,若经过当前顶点到达邻居顶点的距离比已知的距离更短,则更新邻居顶点的距离和路径。

4) 标记:将当前顶点标记为已遍历。

5) 终止条件:当所有顶点都被标记为已遍历时,算法终止。

2. 操作系统2.1 进程和线程的区别进程和线程是操作系统中的两个重要概念,请简要说明它们的区别。

答案:进程是操作系统资源分配的基本单位,每个进程都拥有独立的内存空间和系统资源,进程之间通过进程间通信(IPC)来进行数据交换。

而线程是进程中的执行单元,每个进程可以包含多个线程,线程共享进程的内存空间和系统资源,线程之间可以直接访问共享的内存数据。

DS-2007级参考答案

DS-2007级参考答案

2006级(嵌入式软件与系统、计算机应用方向)《数据结构》期终考试试卷答案一、单项选择题 (每题1分,共15分)答案:C, A, B, B, C, D, D, C, D, A, B, B, A, C, A二、已知一个无向图的顶点集为{ a , b , c , d , e , f },其邻接矩阵如下所示(0-无边,1-有边)。

⎥⎥⎥⎥⎥⎥⎥⎥⎦⎤⎢⎢⎢⎢⎢⎢⎢⎢⎣⎡00110001101110110111010001101010010fe d c b af e d c b a(1). 画出该图的图形;(2). 根据邻接矩阵从顶点a 出发进行广度优先遍历,画出相应的广度优先遍历树。

(15分) 解:(1). 该邻接矩阵所对应的的图2.1所示(2). 从顶点a 出发进行广度优先遍历的遍历树如图2.2所示三、已知一个散列表如下图所示:其散列函数为h (key ) = key % 13,处理冲突的方法为双重散列法,探查序列为:h i = (h (key ) + i * 3) % 13, i = 1, 2, …问:对表中关键字61进行查找时,所需进行的比较次数为多少?依次写出每次的计算公式和值。

(10分)解:在表中查找关键字61时,所需进行的计算公式如下:h (61) = 61 % 13 = 9h 1 = (9 + 1 * 3) % 13 = 12图2.1 图2.2 a b e d f ch 2 = (9 + 2 * 3) % 13 = 15 % 13 = 2由上过程可知:在表中查找关键字61时,需要进行3次比较。

四、阅读下面程序,回答问题 (10分)void function(Link **Head) {Link *pt1, *pt2, *tmp; pt1 = *Head;if (pt1 == NULL) return;pt2 = pt1->next; pt1->next = NULL;// 语句行S 1while (pt2 != NULL) { tmp = pt2->next;pt2->next = pt1; pt1 = pt2; pt2 = tmp; }*Head = pt1;// 语句行S 2}回答下列问题:(1). 说明语句行S 1和S 2的作用(指对单向链表中所起的作用);(2). 简洁地给出函数function 的功能描述(非每条语句的语义说明);(3). 若链表Head 的线性表形式为(a 1, a 2, …, a n ),写出函数执行后链表Head 的线性表形式。

  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

2007年东北大学博士入学考试试题(分布式操作系统)
1 简述分布OS与NET OS的不同
2 解释可伸缩性的含义,举一个限制可伸缩性的实例,提出解决方案。

3 一远程调用,除法:R=FRIBFR(I,J),两实参I,J,返回I/J的结果。

描述RPC中传递值参数进行计算的方法,说明如果第一个参数是I地址,将要面临的问题及解决方法。

4 多线程的几种实现方式
5 K层移动问题
6 时钟滴答问题
7 BULL Y算法的图示,描述,选举冲突时的解决办法。

8 两进程P1、P2,两个整数变量X、Y,初始为0,T为时间印
P1 P2
X=1(T=1) Y=1(T=2)
IF(Y==0)KILL(P2) (T=3) IF(X==0)KILL(P1) (T=4)
8-1 严格一致性模型下,P1,P2能否同时被终止。

8-2 顺序一致性模型下,所有可能的语句交叉模式,判断是否会出现P1,P2两进程之一或全部终止的情况。

8-3 FIFO一致性模型下,两进程能否被同进终止,为什么。

9 将TMR方法推广到2容错度,分别对于FAIL_STOP故障和拜占庭故障给出系统结构图,并解释原因。

相关文档
最新文档