Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Computer Basics.docx
Скачиваний:
7
Добавлен:
24.11.2019
Размер:
3.92 Mб
Скачать

Input: Data Accuracy

A famous slogan in computing sums up the importance of accurate data:

GIGO = Garbage In, Garbage Out

Conclusions are no better than the data they are based on.

Checking for Accuracy

A major task for any program that accepts data is to try to guarantee the accuracy of the input. Some kinds of errors cannot be caught but many of the most common kinds of mistakes can be spotted by a well-designed program.   A program should attempt to do the following:

1.

test data type and format

ex.

2/a/96 is not a date

ex.

If a phone number should have exactly 10 digits with the area code, then 555-123 is not acceptable.

2.

test data reasonableness

ex.

231 should not be a person's age, at least not since the time of Noah and the Flood

ex.

A sale of $50,000 worth of chewing gum at the corner market is probably missing a decimal point somewhere!

3.

test data consistency

ex.

A man's death date should be later than his birth date!

ex.

The sum of the monthly paychecks should be the same as the total paid for the year.

4.

test for transcription and transposition errors

ex.

Typing 7754 instead of 7154 is a transcription error, typing the wrong character.

ex.

Typing 7754 instead of 7745 is a transposition error, interchanging two correct characters.

Both are very hard to check for!

Input: Summary

The data that a computer receives is input, the first part of the machine processing cycle. Input can be raw data, user responses like mouse clicks, commands, and programs.

The keyboard is an input device that comes is several different shapes, sizes, and key arrangements. The QWERTY layout is still the most popular, though it is not the most efficient layout.

A variety of pointing devices let you control the computer - mouse, trackball, game controller, glide pad, pen or stylus, touchscreen.

Modern terminals like point-of-sale terminals make it easy to input sales, calculate totals with tax, and monitor inventory.

Multimedia input devices send photos, sounds, and videos to your computer. You can even use your voice to control the computer or input data, if you have voice recognition software.

Automating input helps avoid errors. Scan instead of type! Special inks, special shapes to characters, bar codes of several types, and RFID tags all make it easy to input accurately. But some errors can still occur. Transcription errors record an incorrect character. Transposition errors reverse the order of characters. Input must be checked for correct type of values, reasonableness, and consistency.

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]