Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
английский / МО темы / Programming.docx
Скачиваний:
56
Добавлен:
20.04.2015
Размер:
1.74 Mб
Скачать

Vocabulary

6.Complete the sentences (1-6) with the words in the box.

according to ■ behaves ■ devices ■ errors ■ input ■ output

1 ______the bank machine, I have no money in my bank account.

2.Video and digital cameras are other______that use computers.

3 ______is any result a computer displays on a screen or prints from a printer.

4.A computer receives _______ from users when they click on a command.

5.I made too many______in my test so I got a bad grade.

6.Not everyone______logically when things go wrong with a computer.

7.Choose the correct word.

1.Most people can easily learn a ___language and become programmers.

alow-level

b high-level

c binary

2.You can use a mouse or keyboard to ___data into the computer.

aoutput

binput

cprocess

3. Some children ___very badly when they can't have something they want.

aprocess

bsolve

c behave

4.You can draw___for many simple procedures.

aan algorithm

ba code

cdata

5.Computers___programming language into machine language.

ause

bdevelop

c translate

6.A computer can___large amounts of data at very high speeds.

aprocess

bresult

ccomplete

Speaking

8.Work in groups and discuss the questions.

1.What kind of errors do you make with computers?

2.How do you behave when things go wrong with a computer (or any machine)?

3.How do different people you know behave when things go wrong?

Writing

9.Draw a flow chart like the one in Exercise 2. Follow these steps:

•Choose a simple procedure from the ones in the box below (or a similar one of your own).

•Break the procedure down into all the steps that you have to follow. Think about where the process starts and ends, and the input from you and from the outside. When you make a decision, think of when you say 'yes' and when you say 'no', and what happens next.

•Write exactly what happens at each stage.

•Draw the flow chart, putting your text into the different shapes in Exercise 2.

•Show your flow chart to another student. Does he/she agree with your steps?

making a cup of teaor coffee ■ making a telephone call ■ sending a text message ■ answering the door ■ playing a cassette or CD ■ putting on the washing machine

Get real

Make a list of all the devices that use computers in your home, in your school, shops, libraries, banks and offices. During a day, use your list to make a note of every time you use something that contains a computer program. Report back to the class with your list.

PART 2

Task 1.Work in pairs. The stages in programming (1-7) are listed below. Fill in the gaps with the missing stages (a-d).

1. Analysing and defining the problem to be solved

2. _____________________________

3. Coding

4. _________________________________

5. ________________________________

6. ________________________________

7. Obtaining feedback from users

aTraining the users

bTesting

сDesigning the program

dDocumenting

Task 2.Look at stage 1 of the list in Task 1. Discuss how you would analyse and define the problem. Compare your ideas with other students in the class.

Task 3.Programmers sometimes use flowcharts when planning a program. Listen to Part 1 of the recording to identify these symbols used in flowcharts.

Task 5.Listen to Part 2 of the recording which describes this flowchart for calculating sales tax.

Task 6. Work in groups of three. Read one of the texts below and complete this table. When you have finished, exchange information with the others in your group to complete two similar tables.

Type of error

Definition

Example

Ways to avoid or deal

with this kind of error ____________

Text A

System errors affect the computer or its peripherals. For example, you might have written a program which needs access to a printer. If there is no printer present when you run the program the computer will produce a system error message. Sometimes a system error makes the computer stop working altogether and you will have to restart the computer. A sensible way of avoiding system errors is to write code to check that peripherals are present before any data is sent to it.Then the computer would warn you by a simple message on the screen, like 'printer is not ready or available'.

Text В

Syntax errors are mistakes in the programming language (like typingPRNIT instead of PRINT). Syntax errors cause the program to fail. Some translator programs won't accept any line that has syntax errors. Some only report a syntax error when they run the program. Some languages also contain special commands such as debug, which will report structural errors in a program.The programming manual for the particular language you're using will give details of what each error message means.

Text С

Logic errors are much more difficult to detect than syntax errors.

This is because a program containing logic errors will run, but it won't work properly. For example, you might write a program to clear the screen and then print 'hello'. Here is a code for this:

10// Message 30 CLS

20 PRINT'Hello' 40 END.

The code has a logic error in it, but the syntax is right so it will run. You can get rid of logic errors from simple programs by 'hand-testing' them or doing a 'dry run' which means working through each line of the program on paper to make sure it does what you want it to do. You should do this long before you type in the code.

Соседние файлы в папке МО темы