问题 填空题

已知序列{17,18,60,40,7,32,73,65,85},采用冒泡排序法对该序列做降序排序时,第4趟的结果是 【1】

答案

参考答案:60,40,73,65,85,32,18,17,7

解析: 冒泡排序法的算法基本思想是:通过无序区中相邻记录关键字间的比较和位置交换,使关键字最小的记录如气泡一般逐渐往上漂浮直至水面。整个算法是从最下面的记录开始,对每两个相邻的关键字进行比较,且使关键字较小的记录换至关键字较大的记录之前,使得经过 1趟冒泡排序后,关键字最小的记录达到最上端,接着,再在剩下的记录中找关键字最小的记录,并把它换在第2个位置上。依此类推,一直到所有记录都有序为止。根据这种思想,每趟的排序结果如下。 初 始 17,18,60,40,7,32,73,65,85 第一趟 18,60,40,17,32,73,65,85,7 第二趟 60,40,18,32,73,65,85,17,7 第三趟 60,40,32,73,65,85,18,17,7 第四趟 60,40,73,65,85,32,18,17,7 第五趟 60,73,65,85,40,32,18,17,7 第六趟 73,65,85,60,40,32,18,17,7 第七趟 73,85,65,60,40,32,18,17,7 第八趟 85,73,65,60,40,32,18,17,7

填空题
阅读理解

阅读理解。

     If you don't keep yourself warm enough, winter can be a time of illness.

     During the winter months, people easily get colds and flu (流感). Many think they are the same, but

these two illnesses are different.

     Colds can stay with you for up to a week. You will have a running nose, sore throat, headache, cough

and a fever.

     Flu is more serious. You will feel sick very quickly. You will have a fever and a headache. Your body

will hurt and become weak. This could last for up to four weeks. 

     Is there any way to keep yourself away from colds and flu? Staying clear of people with colds or flu

may work.

     Try not to touch (触摸) your nose or eyes if you have been close to someone who has a cold. Wash

your hands, especially after cleaning your nose.

     Going out with wet hair can also give you a cold!

     If you catch a cold or flu, go to bed and rest. Doing this will help you get better. Drink lots of water.

Stay in a warm, well-aired room. If you have a headache, or your muscles hurt, take some medicine.

1. 阅读上面的短文,根据短文内容帮助Mary完成下面的一封信。

Dear Mom and Dad, 

     How's everything going?

     I'm having great fun at winter camp. But for the past two days, I'm not feeling very well. I don't know

what's wrong. Maybe I have ____ a cold. I have a ____ nose and ____ throat. Last night I couldn't sleep

because I had a _____, ____ and a slight ____. But don't worry. I've been to the doctor's. The doctor told

me that it was not ____, which would otherwise be more ____. He advised me to ____ lots of water, lie

down and ____ for a few days. He said I would get well in a week. Okay, so much for now.  

     Take good care of yourselves, too.

                                                                                                                                             Love,

                                                                                                                                             Mary

2. 假设你是Mary的朋友Tina. 得知她生病的消息后,你很着急,立刻发一封e-mail,给她提一些建议

(三至五条,可参考短文,字数100字左右)。