问题 填空题

以下是一个竞赛评分程序。8位评委,去掉一个最高分和一个最低分,计算平均分(设满分为10分),请填空补充完整。Private Sub Form_Click() Dim Max as Integer,Min as Integer Dim i as Integer, X as Integer,s as Integer Dim p as Single Max=0 Min=10For i=1 To 8 x=Val(InputBox("请输入分数:")) If 【13】 Then Max=x lf 【14】 Then Min=x s=s +x Next i s= 【15】 p=s/6 MsgBox"最后得分:"& pEnd Sub

答案

参考答案:X>Max 或 x>=Max 或 Max<x 或 Max<=x X<Min 或 x<=Min 或 Min>x 或 Min>=Xs-Max-Min 或 s-Min-Max

解析: 本题考查考生设计简单算法的能力。根据题意,首先要找出最大值与最小值,所给程序用循环读入数据并找出最大值与最小值,并对读入的数据进行求和操作。此时用总和减去最大值和最小值再求出平均分,就可完成题目要求。位置语句的作用是记录最高分,因此,在当前输入的分数x大于(也可以是大于或等于)以前的最高分数Max时,就应该使Max取当前的x值。因此,该位置应该填x>Max、或 x>=Max、或Max<x、或Max<=x。位置语句的作用是记录最低分,因此,在当前输入的分数x小于(也可以是小于或等于)以前的最低分数Min时,就应该使Min取当前的 x值。因此,该位置应该填x<Min、或x<=Min、或Min>x、或Min>=x。本题中For循环结束后,变量s的值为所有8个分数值的总和,而题目要求计算平均分的前提是去掉一个最高分和一个最低分,因为最高分储存在变量Max中,最低分储存在变量Min中,应该在总分s中将 Max和Min减掉。 位置应该填s-Max-Min或s-Min-Max。

单项选择题
完形填空
It was my birthday last Thursday. I decided to  36  by inviting a few friends out to supper. I chose a restaurant in a  37  part of town. It is one of my favorite restaurants because the food is good and the waiters are friendly. It is  38  ever crowded, because not many people know about it, so it is not usually  39  to book(预定) a table. In any case, Thursday is not a busy evening  40 .
When we entered the restaurant, we were surprised to find it completely  41 . I looked around but no  42  was free. One of the waiters recognized me. He came across and explained the situation. “A party of tourists(旅游团) came in about half an hour ago,” he said. “It was like an invasion (侵略).  43  the place was full! We can hardly manage (对付,应付).”
The waiter then pointed to a table in the corner. “The people there are about to  44 ,” he said. “Just hold on and you’ll  45  a place there.” He was right. Fifteen minutes later, the people  46  the corner table paid their  47 , got up and left. I led my friends across and we all sat down.
 48 , our table was almost out of sight. We tried to call the attention of the waiter who sent us there,   49  he, like all the other waiters, was  50  with the party of tourists. They ordered lots of food. At last, an hour later, the tourists were finishing their meal and looking very  51  with life. The waiter, now very tired, appeared at our table. I advised my friends about the best dishes and finally the waiter went off with our  52 .
A few moments later he returned to our table. We could tell from his face that he had  53  news for us.  54  a little sorry he told us that there was no meat or fish. “All we can  55  you,” he said, “is an omelet (煎蛋卷) !”
小题1:
A.rememberB.congratulateC.memorizeD.celebrate
小题2:
A.calmB.quietC.busyD.faraway
小题3:
A.hardlyB.oftenC.hardD.always
小题4:
A.importantB.possibleC.necessaryD.certain
小题5:
A.as usualB.in factC.as beforeD.in all
小题6:
A.fullB.emptyC.freeD.quiet
小题7:
A.personB.tableC.waiterD.friend
小题8:
A.HappilyB.LuckilyC.SuddenlyD.Hopefully
小题9:
A.startB.endC.leaveD.pay
小题10:
A.findB.takeC.waitD.see
小题11:
A.byB.atC.besideD.near
小题12:
A.moneyB.drinkC.foodD.bill
小题13:
A.LuckilyB.NormallyC.UnluckilyD.Angrily
小题14:
A.butB.soC.yetD.and
小题15:
A.easyB.busyC.strictD.satisfied
小题16:
A.excitedB.tiredC.disappointedD.pleased
小题17:
A.orderB.foodsC.dishesD.money
小题18:
A.goodB.badC.valuableD.pleasant
小题19:
A.RemainingB.SeeingC.LookingD.Finding
小题20:
A.findB.sellC.offerD.bring