# Gr11 IT Practical LB HiRes

> Grade 11 Information Technology textbook, 252 pages. Read online or get the free PDF download.

- Page: https://www.hlayiso.com/library/gr11-it-practical-lb-hires/214cc7ab-f437-4c6b-aa84-5f4aae12ca37
- Updated: 2026-10-10
- Subject: Information Technology
- Grade: Grade 11
- Document type: Textbook
- Publisher: Study Guides
- Curriculum: CAPS
- Pages: 252

Breadcrumbs: [Home](https://www.hlayiso.com/) › [Library](https://www.hlayiso.com/library) › [Grade 11](https://www.hlayiso.com/library/grade-11) › [Information Technology](https://www.hlayiso.com/library/grade-11/information-technology) › [Gr11 IT Practical LB HiRes](https://www.hlayiso.com/library/gr11-it-practical-lb-hires/214cc7ab-f437-4c6b-aa84-5f4aae12ca37)

## About this document

Information Technology · Grade 11. Textbook, 252 pages. Read online or download the PDF.

Read it free online on the page above; download the PDF from there.

## Document text

Text extracted from the PDF. Layout, diagrams and tables may not survive extraction.

### Page 1

Practical Book

                              INFORMATION
                              TECHNOLOGY

                                         CAPS

IT-Practical-LB-Gr11.indb 1                     2019/10/02 10:13

### Page 2

MTN South Africa, through MTN SA Foundation, is a proud supporter of the CAT and IT digital books.

                        As an organisation rooted in technology, we believe in providing a new bold digital world to communities we
                         operate in. This unique digital book provides the fundamental knowledge necessary for a sound grounding
                            from which to make practical use of the complete and indispensable application-oriented information
                          regarding Computer Applications Technology (CAT) and Information Technology (IT). It is a foundational
                       reference for today’s secondary school learners and teachers alike - as well as for the next generation of CAT
                                                                       and IT students.

                                                    Information Technology Practical Book Grade 11
                                                                ISBN 978-1-928388-53-1
                                    First published in 2019 © 2019. Copyright in the text remains with the contributors.

                                                  Quality Assurance team for Information Technology
                                   Allison Philander, Carina Labuscagne, David Peens, Denise van Wyk, Edward Gentle,
                                        Jugdeshchand Sewnanen, Julian Carstens, Magdalena Brits, Shamiel Dramat,
                                                            Shani Nunkumar and Zainab Karriem

                                                                      Restrictions
                       You may not make copies of this book in part or in full – in printed or electronic or audio or video form – for a
                                                                profit seeking purpose.

                                                             Rights of other copyright holders
                       All reasonable efforts have been made to ensure that materials included are not already copyrighted to other
                       entities, or in a small number of cases, to seek permission from and acknowledge copyright holders. In some
                         cases, this may not have been possible. The publishers welcome the opportunity to redress this with any
                                                             unacknowledged copyright holders.

IT-Practical-LB-Gr11.indb 2                                                                                                                2019/10/02 10:13

### Page 3

Contents

                       Term 1                                                                                                                                           Chapter 6                       User-defined methods
                                                                                                                                                                        Introduction............................................................................................................................. 129
                        Chapter 1                         Grade 10 Revision and Mathematical
                                                          Functions                                                                                                     Unit 6.1 Introduction to user-defined methods................................. 130

                        Introduction.............................................................................................................................   1   Unit 6.2 Procedures.................................................................................................. 132

                        Unit 1.1 Errors, debugging and mathematical methods...........                                                                              2   Unit 6.3 Functions ...................................................................................................... 144

                        Unit 1.2 Mathematical methods .....................................................................                                         6   Unit 6.4 Basic input validation techniques ............................................ 148

                        Consolidation activity.................................................................................................... 13                   Consolidation activity.................................................................................................... 152

                        Chapter 2                         Nested loops
                                                                                                                                                                        Term 4
                        Introduction............................................................................................................................. 19
                        Unit 2.1 Nested Loops ........................................................................................... 20                            Chapter 7                       User interfaces

                        Unit 2.2 Using nested loops .............................................................................. 26                                   Introduction............................................................................................................................. 155

                        Unit 2.3 Creating shapes using nested loops .................................... 34                                                             Unit 7.1 Multi-form user interfaces ............................................................. 156

                        Consolidation activity.................................................................................................... 37                   Unit 7.2 Dynamic Instantiation of objects .............................................. 162

                                                                                                                                                                        Chapter 8                       Databases
                       Term 2                                                                                                                                           Introduction............................................................................................................................. 167

                        Chapter 3                         Arrays                                                                                                        Unit 8.1 Creating a database ............................................................................ 168

                        Introduction............................................................................................................................. 41    Unit 8.2 Connecting to a database ............................................................. 172

                        Unit 3.1 Arrays ............................................................................................................... 42              Unit 8.3 Reading data from a database.................................................. 178

                        Unit 3.2 Searching and sorting arrays ...................................................... 55                                                 Unit 8.4 Writing data to a database............................................................ 182

                        Unit 3.3 Parallel arrays ............................................................................................ 64                        Unit 8.5 Manipulating data .................................................................................. 188

                        Consolidation activity.................................................................................................... 67                   Consolidation activity.................................................................................................... 198

                        Chapter 4                         String and date manipulation
                                                                                                                                                                        Annexure A – Grade 10 Revision                                                                                                     201
                        Introduction............................................................................................................................. 69
                        Unit 4.1 Built-in string methods ..................................................................... 70
                                                                                                                                                                        Annexure B – Naming convention of components 238
                        Unit 4.2 Delimited strings..................................................................................... 86
                        Unit 4.3 Built-in Date-Time methods......................................................... 90
                                                                                                                                                                        Annexure C – Programming and visible characters 240
                        Consolidation activity.................................................................................................... 97

                                                                                                                                                                        Glossary                                                                                                                           243
                       Term 3

                        Chapter 5                         Text files                                                                                                    QR Code list                                                                                                                       245
                        Introduction............................................................................................................................. 101
                        Unit 5.1 Introduction to text files.................................................................... 102
                        Unit 5.2 Reading from a text file ................................................................... 106
                        Unit 5.3 Writing to a text file.............................................................................. 112
                        Unit 5.4 Creating reports ...................................................................................... 121
                        Consolidation activity.................................................................................................... 124

IT-Practical-LB-Gr11.indb 3                                                                                                                                                                                                                                                                                             2019/10/02 10:13

### Page 4

Dear Learner
                      Welcome to the IT Practical Grade 11 textbook, and welcome to programming.

                      If this is your first time learning how to program, don’t worry. This textbook has been designed to teach anyone –
                      regardless of experience – how to program. If you follow along with all the examples then you will be an
                      experienced programmer who has written more than 50 programs by the end of this book.

                      Programming and programming languages, much like real languages, can only be learned through practice.
                      You cannot sit at home and learn to speak French from a textbook. In the same way, you cannot read this book
                      and hope to be a programmer at the end of it. Instead, you will need to write every bit of code and create every
                      program shown in this book. Even if all you do is follow the steps of the examples on your own computer, you
                      will learn how to write code. Once you have mastered the code, you will be able to comfortably use it in your
                      own programs.

                      For you to master programming, try to work through as many of the programs given to you. Each program has
                      been designed to both teach you new concepts and reinforce existing concepts. The book will start by teaching
                      you how to create simple programs. However, by the end of the book you will be creating useful programs and
                      fun games to play.

                      Programming is not only about knowing and using the programming language. There are also important
                      theoretical concepts that you will need to understand, and planning and problem-solving tools that you will need
                      to master. The best-coded program in the world will not be useful if it solves the wrong problem. This book has
                      therefore been divided into the following chapters:
                      ●  Chapter 1: Errors, debugging and mathematical methods
                      ●  Chapter 2: Nested loops                                                             WHAT MOST SCHOOLS
                      ●  Chapter 3: Arrays                                                                        DON’T TEACH
                      ●  Chapter 4: String and date manipulation
                      ●  Chapter 5: Text files
                      ●  Chapter 6: User-defined methods
                      ●  Chapter 7: User interfaces
                      ●  Chapter 8: Databases

                      Before getting started with algorithms, watch the video in the QR code.
                                                                                                              https://www.youtube.com/
                                                                                                                watch?v=nKIu9yen5nc

IT-Practical-LB-Gr11.indb 4                                                                                                                2019/10/02 10:13

### Page 5

To give you the most opportunities to learn, this book will give three types of programming activities:
                             UNIT

                      Examples2.3 Creating shapes using nested loops
                      Examples will guide you through the creation of a program from start to finish. All you need to do with examples
                      is to follow the step-by-step   guidance provided to you.
                                            You can create simple geometrical shapes using special characters such as ‘*’
                                                           or digits.

                                                                 Example 2.1          Create the shape below using the special character ‘*’

                                                             We know that there are six rows and each row has 6 *s. The code to draw this shape:
                                                             ******
                                                             ******
                                                             ******
                                                             ******
                                                             ******
                                                             ******

                                                                 Line 1:             for i := 1 to 6 do
                                                                 Line 2:             begin
                                                                 Line 3:             sLine := ’’;
                                                                 Line 4:                for j := 1 to 6 do
                                                                 Line 5:                sLine := sLine +’*’;
                                                                 Line 6:                memDisplay.Lines.Add(sLine);
                                                                 Line 7:             end;

                                                             Note:
                                                             ●     Line 1: The outer i-loop will run six times because there are six rows.
                                                             ●     Line 3: String sLine is set to null for each row.
                      Guided activities                      ●     Line 4-5: In each row, 6 *’s must be joined together.
                                                             ●     Line 6: Display the string sLine before Guided
                                                                                                             moving activity
                                                                                                                     to the next
                                                                                                                              2.1row.
                      Guided activities have a program
                                                                            You need to develop a multiplication table for a primary school learner as shown below:
                      that you need to create     on your Creating a shape
                                              Example 2.2
                                                                            1×1=1                2×1=2
                      own. Your teacher will provide
                                            We know that there are six rows 1and
                                                                               × 2each
                                                                                   = 2row has 6 2*s.×The
                                                                                                      2 =code
                                                                                                          4 to draw this shape:
                      you with the solution.*
                                                    These
                                                                            1×3=3                2×3=6
                      solutions should be **used as an                      You are required to create the 1 times and 2 times multiplication table. In the 1 times multiplication table, you only need
                      opportunity to compare***        your                 to find the product of 1 multiplied by a multiplier from 1 to 3. This is also true for the 2 times multiplication table.
                                            ****                            Let’s create an algorithm and flowchart for the problem.
                      program, and to see *****
                                              where you
                      may have made errors  The codeor    leftthis shape: ALGORITHM
                                                     to create                                                                               FLOWCHART
                                                                              for I = 1 to 2
                      something out.          Line 1:         for i := 1 to 5 do
                                                                               begin
                                                                                                                                                                Start

                                              Line 2:         begin
                                         IMPLEMENTATION
                                              Line 3:
                                                               OF   INPUT VALIDATION
                                                                sLine := ’’;
                                                                                      for J = 1 to 3                                                                         1
                                                                                                                                                                                    I←1
                                          Input validation                            begin different ways:
                                                Line 4: can be for  implemented
                                                                          j := 1 intoseveral
                                                                                        i do
                                             One   way 5:
                                                        to implement   input:=validation     Answer
                                                                                                 inform=the I*user
                                                                                                                J of the problem
                                          ●     Line                 sLine       sLine is to
                                                                                          +’*’;                                                          2
                                                                                             Display I,’*’, J, ‘=’, answer                        I <= 2           Stop
                                             before
                                                Linethey6: try to process the data. This     could be in the form of an error
                                                                     memDisplay.Lines.Add(sLine);                                                        False
                                                                                      end
                                                Line    7:       end;
                                             message or a disabled button with an error message.                                                         3
                                                                                end
                                          ●  A second way of implementing input validation is to check the data before it                         J←1
                      Activities                                               The I-loop isyou
                                             is processed. With this implementation,          the build
                                                                                                  outer loop.
                                                                                                         certain checks or
                                                                                                                                                                                                                          8
                      Activities are programs     that your
                                             conditional           teacher
                                                          statements            can
                                                                        into your
                                                                               The      give
                                                                                  program
                                                                                   J-loop      theto
                                                                                            is to      you
                                                                                                  ensure
                                                                                                   inner   thatas
                                                                                                         loop.     classroom
                                                                                                                you do not process activities or homework.
                                                                                                                                                  J <= 3
                                                                                                                                                         4
                                                                                                                                                              With these
                                                                                                                                                                    I←J+1
                                             incorrect data. When these statements        identify   incorrect  data, you send a                         False
                      programs, you will only be assessed on how well your program works, so use your creativity to 5
                                                                               The I-loop will  run twice.                                               come up with
                                             message informing the user of the problem.
                                                                                                     The J-loop will run three times.
                      a solution!                                                                                                                                             Answer ← I * J
                                                                                                     The statements within the J-loop will be executed
                      34      INFORMATION TECHNOLOGY I GRADE 11 I Practical Book
                                                                                                                                                                                                      6
                                                                                                     six times.
                                                                                                                                                                                     Display
                                                                      Activity 1.1                                                                                           I, '*', J, '=', Answer

                                                                                                                                                                                                      7
                                                       1.7.1 What is the difference between syntax, runtime and logic errors?
                                                                                                                                                                                  J←J+1
                                                       1.7.2 Give two examples of each of the following errors:
                                                                  a. Syntax errors
                                                                  b. Runtime errors              The nested loop executes in the following manner:
                                                                  c. Logic errors                ●     When the outer loop is executed for the first time, it triggers the execution of the inner loop. Control is transferred
                                                                                                       from the outer loop to the inner loop. The inner loop executes from its initial value to its end value and control is
                                                                                                       transferred back to the outer loop.
                                                                                                 ●     For each change of value of the outer loop value, the inner loop is triggered. This process continues until the outer
                                                                                                       loop reaches its end value.
                                                                                                 ●     Therefore in the example above, the inner loop will be triggered twice and for each trigger, the inner loop is executed
                                                                                                       three times.

IT-Practical-LB-Gr11.indb 5                                                                                                                                                                                                      2019/10/02 10:13

### Page 6

….
                                                                                                                                                                                                  Else
                                                                                                                                                                                                         rAm
                                                                                                                                                                                                        ….

                                                                                                                                                                                            ●   Range valid
                                                                                                                                                                                                range. For
                                                                                                                                                               Activity 1.9                     validation to

                                                                                                                                                                                                          iAge
                                                                                                                                                1.9.1 Open the SquareCubeRoot_p project and create
                                                                                                                                                                                                    if (iAg
                                                                                                                                                        [Calculate] button to do the following:
                                                                                                                                                        ●   Generate a random number in the range 10 ….      to
                                   ‘Take note’ and ‘Did you know’ boxes                                                                                                                             Else
                                                                                                                                                        ●   Display the random number in the EditBox.
                                   The boxes provide extra, interesting content                                                                             For each number from 1 to the random genera    Sho
                                                                                                                 Take note                              ●
                                                                                                                                                                                                          ….
                                   that might caution you to ‘take note’ of                                                                              Didsquare,
                                                                                                                                                              you know cube and square root of the number.    T
                                   something important; or give you additional                         If you cannot see all the                            number,     its square,cube  and  square root with
                                                                                                                                                   In general, it is better to
                                   information. Note that the content in the                           lines that you have                                                                    ●   Patternplace
                                                                                                                                                                                                           ma
                                                                                                                                                   prevent avalues
                                                                                                                                                             user frommustmaking
                                                                                                                                                                             be formatted to two decimal
                                                                                                       generated in the Memo                                Save                                  specific pat
                                   ‘Did you know’ boxes will not be part of                                                                        a mistake
                                                                                                                                                        ●
                                                                                                                                                              thanand     run the project.
                                                                                                                                                                     to inform
                                                                                                       component, then you need                                                                 that they co
                                   your exams.                                                                                                     the user that they have
                                                                                                       to set the ScrollBars                                                                    followed by
                                                                                                                                                   made a mistake afterwards.
                                                                                                       property to ssVertical.                                                                  stop with le
les continued

bsite Users Folder.
are stored in a text file Users.txt.
would put the system at risk.
by inserting dummy data                                                                                                                 UNIT 1.9.2 Open  the CircleAreaCircum_p project and create
                                                                                                                                                   Calculate button to read the radius of a circle and
                                                   New words                   New words                                                4area and
                                                                                                                                              INFORMATION        of theI GRADE
                                                                                                                                                          TECHNOLOGY
                                                                                                                                                  circumference                  TheI Practical
                                                                                                                                                                         circle. 11   formulaeB
he provided text. For                      obfuscated – the                    These are difficult words that you may not have1.1
                                                                                                                               encountered before.
                                                                                                                                         ●   Area
                                                                                                                                                    Errors, debugging and valida
                                                                                                                                                               :         π r2
n                                          deliberate act of creating          A brief explanation for these words are given.
                                           source or machine code
                                                                                                                                         ●   Circumference :             2π r
    o          K      n      U
                                           that is difficult for humans                                                                      Save and run your program.
    8          9     10      11
                                           to understand                                                                                                           Programming errors can generally b
                                                                                                                                                                   errors, runtime errors and logic errors.
                                                                                                                               WHAT’S AN
                                                                                                                              ALGORITHM?                           Syntax refers to the rules of the progra
                                                                                                                                                                   this includes the rules that all statemen
                                                                                                                                                                   the colon-equals operator (:=) is used t
e code to:                                                                                                                                                         you break the rules of the programmin
e does not exist, display an error message and terminate the                                                                     1.9.3 Open the LearnerAlphabet_p file from your disk.
                                         QR Codes, Videos and Screen captures                                                                  Common syntax errors include:
                                                                                                                                       allocated  in the following manner to each learner:
                                         These will link you to online content. When you                                                       ●    Leaving out a semicolon at the end
 ne from the file each time the loop runs.are in the eBook, you can easily access the links.                                           Learner●1: ZAdding a semicolon
                                                                                                                                                                 Learner 2: Xat the end of a
haracters at even positions in the extracted line.                                                         https://www.youtube.com/    Learner 3: V(for example, Learner
                                                                                                                                                                     in an4: T
                                                                                                                                                                            IF-THEN-ELSE ….
                                                                                                   Take note watch?v=6hfOvs8pY1k
edOut RichEditBox.                                                                                                                                  Leaving out the command “var” wh
                                                                                                                                       Do the following:
                                                                                                                                               ●
                                                                                         If you cannot see all the                                  Assigning
                                                                                                                                                       OnCreatea event
                                                                                                                                                                   variable   using the     equa
                                                                                                                                               ●
                                                                                         lines that you have
                                                                                                                                       ●   Create an                     to initialise  variables
                                                                                         generated in the Memo                             of the alphabet that will be assigned to thenam
                                                                                                                                               ●    Making     a typing mistake      in the  firs
                                                                                                                                           the first
                                                                                                                                               ●    Not   surrounding strings with the sin
                                                                                                                                                     learner.
                                Consolidation activities                                 component, then you need
                                                                                                                                       ●   Create
                                                                                                                                               ●    Supplying
                                                                                                                                                    an            variables
                                                                                                                                                       OnClick event         to a
                                                                                                                                                                       for the      function
                                                                                                                                                                                Generate       in
                                                                                                                                                                                            butto
                                                                                         to set in
                                This is a revision activity based on what you have covered      thethe
                                                                                                    ScrollBars
                                                                                                        chapter. Take time to answer the questions on
                                                                                                                                           next     incorrect
                                                                                                                                                 line of the     number of variables to a f
                                                                                                                                                              sequence.
                                your own. You teacher may also use these to assess property        to ssVertical. during class.
                                                                                          your performance
                                                                                                                                                                   With Delphi, RAD Studio will provide
                                                                                                                                                                   Structure panel at the top left Code sc
                                                  CONSOLIDATION ACTIVITY          Chapter 1: Grade 10 Revision and Mathematical Functions                          try to run the program. Double clicking
                                                                                                                                                                   jump to the line with the problem.
                                                  QUESTION 1 GENERAL PROGRAMMING SKILLS

                                                  INSTRUCTIONS
                                                  Open the incomplete program in the Question1_1 folder found in the Question 1 folder.
                                                  Add your name and surname as a comment in the first line of the Question1_1_u.pas file.
                                                  Compile and execute the program. The program currently has no functionality.
                                                                                                            12     INFORMATION TECHNOLOGY I GRADE 11 I Practical Book

                                                    SCENARIO
ogin Folder.                                  Congratulations! You have been selected to take part in your schools Cricket tour in New Zealand in the
 when they interact with a work computer. Details   on users
                                              upcoming         have holidays. Unfortunately, there are some costs involved and your parents have stated that
                                                          December
ext file contains delimited data formatted as you
                                              follows:
                                                   will have to come up with some of the money yourself. Fortunately, you are an IT student and are able to
                                              use the skills you have learnt in IT to raise some funds.

             IT-Practical-LB-Gr11.indb 6
                                                    You have decided to create two applications that will help you to keep track of the money you will make.                         2019/10/02 10:13

### Page 7

TERM 1

                      ERRORS, DEBUGGING AND                                                                                     CHAPTER

                      MATHEMATICAL METHODS                                                                                          1
                        CHAPTER UNITS
                        Unit 1.1:   Errors, debugging and validation
                        Unit 1.2:   Mathematical methods

                         Learning outcomes
                        At the end of this chapter you should be able to:
                        ●   consolidate your knowledge of the work done in Grade 10
                        ●   use the different mathematical methods: Random(), RandomRange(), Round(),
                            Trunc(), Frac(), Ceil(), Floor(), Sqr(), Sqrt(), Inc(), Dec(), Pi and Power()
                        ●   use the mathematical methods to solve programs.

                      INTRODUCTION
                      This chapter serves to consolidate all the knowledge you acquired in your
                      Grade 10 studies (also see Annexure A for more Grade 10 revision). It also
                      focuses on new content that includes work on mathematical methods. You will
                      use these mathematical methods to solve problems during this year.

                                                                                TERM 1 I CHAPTER 1 ERRORS, DEBUGGING AND MATHEMATICAL METHODS   1

IT-Practical-LB-Gr11.indb 1                                                                                                                         2019/10/02 10:13

### Page 8

UNIT

                                   1.1        Errors, debugging and validation

                                                           Programming errors can generally be grouped into three categories: syntax
                                                           errors, runtime errors and logic errors.
                        WHAT’S AN
                       ALGORITHM?                          Syntax refers to the rules of the programming language. For example, in Delphi,
                                                           this includes the rules that all statements have to end with a semicolon and that
                                                           the colon-equals operator (:=) is used to assign values. Syntax errors occur when
                                                           you break the rules of the programming language.

                                                           Common syntax errors include:
                                                           ● Leaving out a semicolon at the end of a statement.
                                                           ● Adding a semicolon at the end of a line which is not the end of a statement
                 https://www.youtube.com/                    (for example, in an IF-THEN-ELSE statement).
                   watch?v=6hfOvs8pY1k                     ● Leaving out the command “var” when declaring variables.
                                                           ● Assigning a variable using the equals sign.
                                                           ● Making a typing mistake in the name of a variable.
                                                           ● Not surrounding strings with the single quotation marks.
                                                           ● Supplying variables to a function in the incorrect order or supplying an
                                                             incorrect number of variables to a function.

                                                           With Delphi, RAD Studio will provide you with information on the error in the
                                                           Structure panel at the top left Code screen, as well as in the compiler when you
                                                           try to run the program. Double clicking on the mistake in the Structure panel will
                                                           jump to the line with the problem.

                                                           Figure 1.1: The Structure panel will inform you of most syntax mistakes

                                                           Runtime errors occur when you ask your program to do a task that is either
                                                           impossible or is impossible under certain circumstances. In most instances,
                                                           runtime errors will cause your program to crash. Runtime errors can occur in
                                                           almost any program, but some examples include:
                                                           ●  Doing mathematical calculations on strings.
                                                           ●  Performing illegal mathematical operations (such as dividing numbers by 0)
                                                           ●  Reading and using values from empty textboxes.
                                                           ●  Reading a list value that has not been created.
                                                           ●  Activating a ListBox’s OnClick event when nothing is selected.
                                                           ●  Combining strings and numbers without changing their data types.

                       2      INFORMATION TECHNOLOGY I GRADE 11 I Practical Book

IT-Practical-LB-Gr11.indb 2                                                                                                                     2019/10/02 10:13

### Page 9

One way to solve a runtime error is to step through your program. You can also search for the error code
                      online to see if it helps you to identify the cause of the error.

                      Figure 1.2: Error 102 is caused by a file assignment problem

                      The final, and most difficult errors to solve are logic errors. These errors occur when there is a logical error
                      or design problem in your program. While logic errors can cause applications to crash or give error
                      messages, the program can also work without issue but give incorrect answers.

                      One way to identify a logic error is to use RAD Studio to track the value of the variable with the incorrect
                      result. By seeing how the value changes with each step of the application, you can usually identify the
                      point at which the mistake occurs. You will learn more about this technique in a later chapter.

                      VALIDATING DATA
                      Data validation is a technique used by programmers to check (or validate) the information that users enter
                      before processing it. This allows programmers to prevent common errors from occurring by making sure
                      that the information entered is correct before it is used. The goal of input validation is to prevent users from
                      accidentally or purposefully entering incorrect data into your program.

                      If your program automatically generates the data it will use, you can test
                      the data before using it. You can also improve the algorithm generating the                         New words
                      data to ensure that only the correct types of data are generated for your
                                                                                                                  step through – to step
                      program.
                                                                                                                  through means that you are
                                                                                                                  working through a program
                      In contrast, when a user is asked to supply data for your program, many                     line by line
                      unpredictable things can happen. The user may have:
                                                                                                                  validate – to try and lessen
                      ●   misunderstood what data is expected
                                                                                                                  the number of errors during
                      ●   clicked the next button without entering data                                           the process of data input in
                      ●   entered the correct data in an incorrect format                                         programming
                      ●   entered the correct type of data, but an incorrect value.

                      This incorrect data can cause your application to crash, or even worse, provide incorrect output.

                                          TERM 1 I CHAPTER 1 ERRORS, DEBUGGING AND MATHEMATICAL METHODS I UNIT 1.1 Errors, debugging and validation   3

IT-Practical-LB-Gr11.indb 3                                                                                                                               2019/10/02 10:13

Text truncated here. Open the document page to read the rest.

## Related documents

- [IT P1 QP GR11 NOV 2022 English](https://www.hlayiso.com/library/it-p1-qp-gr11-nov-2022-english/3db564bd-1d04-48ab-aedd-fae2d9f9939f) — Information Technology · QP · 2022 · Eng
- [IT P2 GR11 QP NOV2022 Afrikaans](https://www.hlayiso.com/library/it-p2-gr11-qp-nov2022-afrikaans/00d1cb8c-b0d9-41ea-9060-a94b73039d3a) — Information Technology · QP · 2022 · Afr
- [IT P2 GR11 QP NOV2022 English](https://www.hlayiso.com/library/it-p2-gr11-qp-nov2022-english/1c12dccc-2a5b-4b41-a80c-5bd8b30f6151) — Information Technology · QP · 2022 · Eng
- [IT P1 MEMO GR11 NOV 2022 AFR](https://www.hlayiso.com/library/grade-11-information-technology-2022-exemplar-november-exam-memorandum-paper-1-afrikaans/02cbecc3-c4be-49dd-986d-125a0173594d) — Information Technology · Memo · 2022 · Afr
- [IT P1 QP GR11 NOV 2022 AFR](https://www.hlayiso.com/library/grade-11-information-technology-2022-exemplar-november-exam-question-paper-paper-1-afrikaans/a17870ba-8fac-4013-9eda-0831f367fbca) — Information Technology · QP · 2022 · Afr
- [IT P1 QP GR11 NOV 2022 English](https://www.hlayiso.com/library/grade-11-information-technology-2022-exemplar-november-exam-question-paper-paper-1-english/c2d16637-c6bc-43d6-b469-cb62712d9eb0) — Information Technology · QP · 2022 · Eng

## More from Grade 11 Information Technology

- [IT P2 GR11 QP NOV2022 Afrikaans](https://www.hlayiso.com/library/grade-11-information-technology-2022-exemplar-november-exam-question-paper-paper-2-afrikaans/be8f522c-a9ab-4a0d-bbce-f1b478d57356) — QP · 2022 · Afr
- [IT P2 GR11 QP NOV2022 English](https://www.hlayiso.com/library/grade-11-information-technology-2022-exemplar-november-exam-question-paper-paper-2-english/b3f6c643-27fc-4fd5-baa3-b8c49c4b6f61) — QP · 2022 · Eng
- [GEO-Sept-QP & Memo-2015-Gr11](https://www.hlayiso.com/library/geo-sept-qp-memo-2015-gr11/cfa849fa-4151-4938-b293-d0122c3a72c6) — QP + Memo · 2021
- [IT P1 MEMO GR11 NOV 2020 Afrikaans](https://www.hlayiso.com/library/it-p1-memo-gr11-nov-2020-afrikaans/b58d463e-025c-4716-9255-6eeeebfafbc3) — Memo · 2020 · Afr
- [IT P1 MEMO GR11 NOV 2020 Afrikaans D](https://www.hlayiso.com/library/it-p1-memo-gr11-nov-2020-afrikaans-d/25d21533-ac81-4ade-a4b8-c56f655e7a81) — Memo · 2020 · Afr
- [IT P1 QP MEMO GR11 NOV2020 Afrikaans D](https://www.hlayiso.com/library/it-p1-qp-memo-gr11-nov2020-afrikaans-d/09d5bea3-08be-4b20-9a72-e526738e9d32) — Memo · 2020 · Afr

## Collection

- [Grade 11 Study guides](https://www.hlayiso.com/study-guides/grade-11/information-technology)

---

Hlayiso: free CAPS and IEB past papers, memos, notes and study guides for South African learners. When citing, link the page URL above, not a PDF or /api/ URL.
