# Information Technology Grade 12 P1 2022 Memo (Afr)

> Grade 12 Information Technology Paper 1 memorandum from the Eastern Cape Mock Exam 2022 (Afrikaans), 16 pages. Read online or download the free PDF.

- Page: https://www.hlayiso.com/library/it-p1-gr12-memo-sept-2022-afrikaans/43cd69be-f0ac-46f4-9d4c-b2503fe09125
- Updated: 2026-09-27
- Subject: Information Technology
- Grade: Grade 12
- Language: Afrikaans
- Document type: Memorandum
- Year: 2022
- Exam period: Eastern Cape Mock Exam
- Paper: 1
- Curriculum: CAPS
- Pages: 16

Breadcrumbs: [Home](https://www.hlayiso.com/) › [Library](https://www.hlayiso.com/library) › [Grade 12](https://www.hlayiso.com/library/grade-12) › [Information Technology](https://www.hlayiso.com/library/grade-12/information-technology) › [Information Technology Grade 12 P1 2022 Memo (Afr)](https://www.hlayiso.com/library/it-p1-gr12-memo-sept-2022-afrikaans/43cd69be-f0ac-46f4-9d4c-b2503fe09125)

## About this document

Information Technology · Grade 12 · Eastern Cape Mock Exam · 2022 · Afrikaans. Memorandum, 16 pages. Read online or download the PDF.

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

## Matching paper and memo

- [IT P1 GR12 QP SEPT 2022 Afrikaans](https://www.hlayiso.com/library/it-p1-gr12-qp-sept-2022-afrikaans/f864e03f-add3-41d0-9b55-3110e7180172) — QP · 2022 · Afr

## Document text

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

### Page 1

Downloaded from hlayiso.com

                         NASIONALE
                     SENIOR SERTIFIKAAT

                              GRAAD 12

                      SEPTEMBER 2022

                INLIGTINGSTEGNOLOGIE V1
                      NASIENRIGLYN

PUNTE:   150

                   Hierdie nasienriglyn bestaan uit 16 bladsye.

### Page 2

Downloaded from hlayiso.com
2                                   INLIGTINGSTEGNOLOGIE V1                            (EC/SEPTEMBER 2022)

 NAAM VAN LEERDER:
     TOTAAL               TOTAAL                  TOTAAL                 TOTAAL
                                                                                            TOTAAL
    VRAAG 1:             VRAAG 2:                VRAAG 3:               VRAAG 4:

            /40                   /40                   /40                     /30              /150
                                                                                      MAKS. PUNTE
 VRAAG 1: ALGEMENE PROGRAMMERINGSVAARDIGHEDE
                                                                                      PUNTE BEHAAL

 1.1     Knoppie [1.1 Vorm]
         shpToets.Shape := stcircle; ✓
         shpToets.Brush.Color := clgreen; ✓                                            4
         gbxVraag12.Visible := true; ✓
         gbxVraag13.Enabled := true; ✓

 1.2     Knoppie [1.2 Ontsyfer]

         Kry toevoer van edtToevoer ✓
         Inisialiseer 'n leë string ✓

         Lus totdat toevoer string leeg is ✓
                                                                                       8
           Kry ordinale getal en verwerk na integer ✓
           Verwyder ordinale getal van toevoer string ✓
           Verwerk ordinale getal na karakter deur CHR te gebruik ✓
           Voeg karakter by nuwe string ✓

         Vertoon nuwe string in edtAfvoer ✓

 1.3     Knoppie [1.3 Toets]

         Maak die list box skoon ✓
         Kry toevoer van spinedit ✓
         Inisialiseer die teller vir skikking ✓

         Kry die aantal priemfaktore van die toevoer en stoor in skikking – 7
         punte:

         Buitenste Lus van 1 tot toevoer ✓
          Stel getal priemfaktore na 0 ✓
             Binneste Lus van 1 na buitenste lus telle (geneste lus) ✓
                As binneste lus teler ŉ priemfaktor is ✓
                    Vermeerder dan die aantal priemfaktore met 1 ✓
            As getal priemfaktore = 2 ✓
                Voeg dan die buitenste lus teller by skikking ✓

Kopiereg voorbehou                                                                     Blaai om asseblief

### Page 3

Downloaded from hlayiso.com
(EC/SEPTEMBER 2022)                    INLIGTINGSTEGNOLOGIE V1                                   3

         Bereken en vertoon die pare van priemfaktore wat se som gelyk is aan
         die toevoer – 9 punte:

         Stel boolse vlag na vals ✓
         Buitenste lus van 1 na skikking teller – 1 ✓
           Stel veranderlike 1 na skikking[buitenste lus teller] ✓
             Binneste lus van buitenste loop +1 na skikking teller ✓            21
               Stel veranderlike 2 na skikking[binneste lus teller] ✓
                  As veranderlike 1 + veranderlike 2 = toevoer ✓
                    Vertoon dan albei getalle in listbox✓
                                                Omgeskakel na string ✓
                      Stel Boolse vlag na waar ✓

         As Boolse vlag = vals is ✓
          Vertoon gepaste boodskap in ShowMessage komponent ✓

 1.4     Knoppie [1.4 Area]

         Bereken area van vierkant ✓
         Bereken area van sirkel:
           Pi * (0.9/(2 * Pi)) * (0.9/(2 * Pi)) ✓ gebruik Pi of 3.1415 ✓
                                                                                7
         Trek area van vierkant af van area van sirkel ✓
                                  Vermenigvuldig met 100 ✓
         Voeg antwoord by huidige 'caption' van lblAfvoer ✓
         Rond af na 3 desimale plekke ✓

                                                        TOTAAL VRAAG 1          40

Kopiereg voorbehou                                                              Blaai om asseblief

### Page 4

Downloaded from hlayiso.com
4                                  INLIGTINGSTEGNOLOGIE V1                        (EC/SEPTEMBER 2022)

                                                                            MAKS.         PUNTE
 VRAAG 2: DATABASISPROGRAMMERING
                                                                            PUNTE        BEHAAL
 2.1.1   Knoppie: [V 2.1.1]
         ‘select Afleweringsadres, AfleweringDatum from tblBestellings
         order by AfleweringDatum Desc’

         Konsepte:                                                            3
         SELECT twee korrekte velde ✓
         FROM korrekte tabel ✓
         ORDER BY korrekte veld DESC ✓

 2.1.2   Knoppie: [V 2.1.2]
         'select count(BestellingID) as Items20ofMeer from tblBestellings
         where items >= 20'

         Konsepte:
         SELECT count(enige veld van tblBestellings-tabel) ✓                  4
          as Items20ofMeer ✓
         FROM korrekte tabel ✓
         WHERE items >=20 ✓

 2.1.3   Knoppie: [V 2.1.3]
         'select * from TblBestellings where Afleweringsadres like ' +
         quotedstr('%' + sline + '%')

         Konsepte:                                                            4
         SELECT * (alle velde) ✓
         FROM korrekte tabel ✓
         WHERE Afleweringsadres LIKE ✓
         quotedstr('%' + sline + '%') ✓

 2.1.4   Knoppie: [V 2.1.4]
         'update tblBestellings set Kollekteer = true where
         AfleweringDatum is null'

         Konsepte:                                                            3
         Update tblBestellings ✓
         Set Kollekteer = true ✓
         Where AfleweringDatum is null ✓

 2.1.5   Knoppie: [V 2.1.5]
         'select Afleweringsadres, AfleweringDatum - BestellingDatum as
         AflewerDae from TblBestellings where Kollekteer = false'

         Konsepte:                                                            4
         Select DeliveryAdress ✓
               AfleweringDatum – BestellingDatum ✓
           From TblBestellings ✓
           Where Kollekteer = false ✓

Kopiereg voorbehou                                                                Blaai om asseblief

### Page 5

Downloaded from hlayiso.com
(EC/SEPTEMBER 2022)                    INLIGTINGSTEGNOLOGIE V1                                   5

 2.1.6    Knoppie: [V 2.1.6]
          'select WinkelNaam, format(sum(BestellingBedrag,"currency") as
          TOTALEVerkope from tblBestellings, tblWinkels where
          tblWinkels.Winkelsid = tblBestellings.Winkelsid group by
          WinkelNaam

          Concepts:
          Select WinkelNaam, ✓                                             7
             format(sum(BestellingBedrag ✓, “currency”) ✓
            as TOTALEVerkope ✓
          from TblBestellings, Winkels ✓
          where TblWinkels.TblWinkelsID =
          TblBestellings.WinkelsID ✓
          group by WinkelNaam ✓
                                                   2.1 Subtotaal: SQL      25

 2.2.1    Knoppie: [V 2.2.1]

          tblWinkels.First ✓
          while not tblWinkels.eof do ✓                                    5
          if tblWinkels['Aanlyn'] = true then ✓
             redOutput.Lines.Add(tblWinkels['WinkelNaam']) ✓
          tblWinkels.Next ✓

 2.2.2    Knoppie: [V 2.2.2]

          Gaan na eerste ry in tblWinkels en lus ✓
          as WinkelNaam = combobox item ✓
           stel dan integer veranderlike na tblWinkelsID ✓
           Gaan na volgende ry in tblWinkels
          Stel reële som veranderlike na = 0 ✓

          Gaan na eerste ry in tblBestellings en lus
                                                                           10
          as TblWinkelsID = integer veranderlike van eerste lus ✓
            Vertoon dan in redAfvoer:
                     BestellingDatum omgeskakel na string ✓
                       en BestellingBedrag in geldeenheid ✓
               Voeg BestellingBedrag by reële som veranderlike ✓
            Gaan na volgende ry in TblBestellings ✓

          Na die lus vertoon die reële som veranderlike in
          redAfvoer in geldeenheid ✓
                                    2.2 Subtotaal: Kode Konstrukte         15

                                                   TOTAAL VRAAG 2          40

Kopiereg voorbehou                                                              Blaai om asseblief

### Page 6

Downloaded from hlayiso.com
6                             INLIGTINGSTEGNOLOGIE V1                    (EC/SEPTEMBER 2022)

                                                                         MAKS.       PUNTE
VRAAG 3: OBJEK-GEÖRIENTEERDE PROGRAMMERING
                                                                         PUNTE      BEHAAL
3.1.1   Konstruktor Create:
         Korrekte naam ✓ met een string parameter en een
         integer parameter ✓                                                4
         Ken korrekte parameter waardes toe aan korrekte attribute ✓
         Stel fKoste = 70 * fUre ✓
3.1.2   prosedure setTotaleKoste
        Korrekte metode – procedure ✓
        Een integer parameter ✓                                             4
        Stel korrekte attribuut (fTotaleKoste) ✓
           = 70 * parameter ✓
3.1.3   Funksie BerekenDae(ure : integer) : integer
        Korrekte metode – integer funksie ✓
        een integer parameter ✓
        As ure > 8 ✓                                                        6
          bereken en stuur korrekte dae terug (Ceil of ander metode) ✓
        else ✓
           Stuur 1 dag terug ✓
3.1.4   funksie toString : string;
        korrekte string metode ✓
        korrekte attribute teruggestuur as result ✓                         4
        gebruik #13, ✓
        skakel ure en koste om na string ✓
                                            2.1 Subtotaal: Objekklas       18
3.2.1   Knoppie [V 3.2.1 Voeg by kwotasie]
        Kry toevoere van spinedit ✓ en list box ✓
        Instansieer die objek
        Objeknaam = ✓ tHerstel.create ✓
          een string, een integer parameter✓ In korrekte volgorde ✓        11
        Gebruik metode van klas ✓ en objeknaam om te vertoon ✓
        Vertoon leë reël in redV3 ✓
        Gebruik metode van klas en objeknaam ✓ om by totale ure
        globale veranderlike te voeg ✓
3.2.2   Knoppie [V 3.2.2 Finaliseer Kwotasie]
        Gebruik objeknaam en metode van die klas ✓
           setTotaleKoste met globale totale ure as parameter ✓
        Gebruik objeknaam en metode van die klas ✓
             getTotaleKoste en ken aan lokale veranderlike toe ✓           11
        As cbxParte geselekteer is, ✓ voeg 150 by totale koste ✓
        Vertoon dae in richedit deur objeknaam ✓ en korrekte metode
        BerekenDae met iTotaleUre as parameter ✓ as ŉ string ✓
        Vertoon totale koste in richedit ✓ omgeskakel na geldeenheid ✓
                                             2.2 Subtotaal: Vormklas       22

                                                   TOTAAL VRAAG 3          40

Kopiereg voorbehou                                                       Blaai om asseblief

### Page 7

Downloaded from hlayiso.com
(EC/SEPTEMBER 2022)                 INLIGTINGSTEGNOLOGIE V1                            7

                                                              MAKS.        PUNTE
 VRAAG 4: PROBLEEMOPLOSSING
                                                              PUNTE       BEHAAL
 4.1    Assignfile stelling ✓
        Reset tekslêer vir lees ✓
        Stel kolomteller na 0 ✓
        Lus deur tekslêer ✓
          Lees ŉ reël✓
          Inkrementeer kolom ✓                                 12
          Stel ry = 1 ✓
          Voeg reël na skikking, ✓ verander na integer ✓
          Lees ŉ reël ✓
          Stel ry = 2 ✓
          Voeg reël na skikking, verander na integer ✓

 4.2      Stel tellers van A en B na 0 ✓
          Stel kolomteller na 0 ✓

        Lus deur skikking ✓
        Stel ry = 1 ✓
        Voeg 1 by kolom teller ✓
         Stel eerste syfer na skikking gebruik ry en kolom
         tellers [ry,kolom] ✓
        Stel ry = 2 ✓
         Stel tweede syfer na skikking gebruik ry en kolom-
         tellers [ry,kolom] ✓
        as eerste syfer > tweede syfer ✓
                                                               18
           vertoon in richedit
              korrekte bewoording – distriknommer en A ✓
              inkrementeer A teller ✓
        else ✓
          vertoon in richedit
              korrekte bewoording – distriknommer en B ✓
              inkrementeer B teller ✓

        as A teller > B teller ✓
         dan vertoon wenner A ✓
        else ✓
         vertoon wenner B ✓

                                           TOTAAL VRAAG 4      30

Kopiereg voorbehou                                                    Blaai om asseblief

### Page 8

Downloaded from hlayiso.com
8                                  INLIGTINGSTEGNOLOGIE V1               (EC/SEPTEMBER 2022)

VOORBEELDE VAN OPLOSSINGS

VRAAG 1

procedure TfrmQuestion1.btnQ1_3Click(Sender: TObject);
var inum, i1,i2, k, x, m, ifactors : integer;
arrprime : array[1..100] of integer;
icount: integer;
bprime : boolean;
begin
lstoutput.clear;

icount := 0;
inum := sednumber.Value;

for k := 1 to inum do
  begin
  ifactors := 0;
  for m := 1 to k do
    begin
    if k mod m = 0 then
    inc(ifactors);
    end;
  if ifactors = 2 then
   begin
   inc(icount);
   arrprime[icount] := k;
   end;
  end;

bprime := false;
for k := 1 to icount - 1 do
    begin
    i1 := arrprime[k];
    for x := k + 1 to icount do
      begin
       i2 := arrprime[x];
       if i1 + i2 = inum then
        begin
         lstoutput.Items.Add(inttostr(i1) + ' + ' + inttostr(i2));
         bprime := true;
        end;
      end;
    end;

if bprime = false then
    showmessage(inttostr(inum) + ' cannot be calculated using the sum of two prime
numbers')
end;

Kopiereg voorbehou                                                       Blaai om asseblief

### Page 9

Downloaded from hlayiso.com
(EC/SEPTEMBER 2022)                    INLIGTINGSTEGNOLOGIE V1                                   9

procedure TfrmQuestion1.btnQ1_4Click(Sender: TObject);
var rsq, rc : real;
rr : real;
begin
rsq := 0.2 * 0.2;
rc := Pi * (0.9/(2 * Pi)) * (0.9/(2 * Pi));
rr := (rc - rsq) * 100;
lbloutput.Caption := lbloutput.Caption + floattostrf(rr,fffixed,8,3) + ' square cm';
end;

procedure TfrmQuestion1.btnQ1_1Click(Sender: TObject);
begin
shpToets.Shape := stcircle;
shpToets.Brush.Color := clgreen;
gbquestion1_2.Visible := true;
gbquestion1_3.Enabled := true;
end;

procedure TfrmQuestion1.btnQ1_2Click(Sender: TObject);
var sline : string;
snew , sword : string;
k, inum : integer;
begin
// If text in edtinput is erased use the following as input:
//           '73 84 32 105 115 32 101 97 115 121 33'

sline := edtinput.Text;
snew := '';
 while length(sline) <> 0 do
    begin
       sword := copy(sline,1, pos(' ',sline) - 1);
       delete(sline,1, pos(' ',sline));
       inum := strtoint(sword);
       snew := snew + chr(inum);
     end;
    edtoutput.text := snew;
end;

end.

Kopiereg voorbehou                                                              Blaai om asseblief

### Page 10

Downloaded from hlayiso.com
10                             INLIGTINGSTEGNOLOGIE V1                     (EC/SEPTEMBER 2022)

VRAAG 2
procedure TQuestion_2.btnQuestion2_1_1Click(Sender: TObject);
// Provided code - do not change
var
  sSQL1: String;
begin
/// enter your code below//
  sSQL1 := 'select Afleweringsadres, AfleweringDatum from tblBestellings order by
AfleweringDatum desc';

 // Provided code - do not change
  dbCONN.runSQL(sSQL1);
    if length(ssql1) <> 0 then
    dbconn.setgridforsql1(dbgsql);
end;
procedure TQuestion_2.btnQuestion2_1_2Click(Sender: TObject);
// Provided code - do not change
var
   sSQL2: String;
begin
/// enter your code below//
    sSQL2 := 'select count(BestellingID) as TblBestellings20orMore from tblBestellings
where items >= 20';

 // Provided code - do not change
  dbCONN.runSQL(sSQL2);
end;

procedure TQuestion_2.btnQuestion2_1_3Click(Sender: TObject);
// Provided code - do not change
var
 sline : string;
  sSQL3: String;
begin
   sline := inputbox('Enter a street name','','Nxolo Street');
/// enter your code below//
   sSQL3 := 'select * from TblBestellings where Afleweringsadres like ' + quotedstr('%' +
sline + '%');
 // Provided code - do not change
 dbCONN.runSQL(sSQL3);
 if length(ssql3) <> 0 then
    dbconn.setgridforsql3(dbgsql);
end;
procedure TQuestion_2.btnQuestion2_1_4Click(Sender: TObject);
// Provided code - do not change
var
  sSQL4: String;
begin
/// enter your code below//
  sSQL4 := 'update tblBestellings set Kollekteer = true where AfleweringDatum is null';
Kopiereg voorbehou                                                          Blaai om asseblief

### Page 11

Downloaded from hlayiso.com
(EC/SEPTEMBER 2022)                   INLIGTINGSTEGNOLOGIE V1                              11

 // Provided code - do not change
 dbCONN.executeSQL(sSQL4,dbgtblWinkels,dbgorder,dbgsql);
   if length(ssql4) <> 0 then
    dbconn.setgridforsql3(dbgsql);
end;

procedure TQuestion_2.btnQuestion2_1_5Click(Sender: TObject);
// Provided code - do not change
var
  sSQL5: String;
begin
/// enter your code below//
  sSQL5 := 'select Afleweringsadres, AfleweringDatum - BestellingDatum as AflewerDae
from TblBestellings where Kollekteer = false';

 // Provided code - do not change
 dbCONN.runSQL(sSQL5);
 if length(ssql5) <> 0 then
     dbconn.setgridforsql5(dbgsql);
end;

procedure TQuestion_2.btnQuestion2_1_6Click(Sender: TObject);
// Provided code - do not change
var
  sSQL6: String;
begin
/// enter your code below//
  sSQL6 := 'select WinkelNaam, format(sum(BestellingBedrag),"currency") as
TOTALEVerkope from tblBestellings, tblWinkels where tblWinkels.tblWinkelsid =
tblBestellings.tblWinkelsid group by WinkelNaam';

 // Provided code - do not change
 dbCONN.runSQL(sSQL6);
   if length(ssql6) <> 0 then
    dbconn.setgridforsql6(dbgsql);
end;

procedure TQuestion_2.btnQuestion2_2_1Click(Sender: TObject);
begin
// Provided code - do not change
redoutput.Clear;
redoutput.Lines.Add('TblWinkelss that are available for Aanlyn tblWinkelsping');
redoutput.Lines.Add('-----------------------------------------------------');
/// enter your code below//
   tblWinkels.First;
   while not tblWinkels.eof do
      begin
        if tblWinkels['Aanlyn'] = true then
             redoutput.Lines.Add(tblWinkels['WinkelNaam']) ;
      tblWinkels.Next;
      end;
end;

Kopiereg voorbehou                                                         Blaai om asseblief

### Page 12

Downloaded from hlayiso.com
12                             INLIGTINGSTEGNOLOGIE V1                      (EC/SEPTEMBER 2022)

procedure TQuestion_2.btnQuestion2_2_2Click(Sender: TObject);
var stblWinkels : string; // Provided code - do not change
bfound : boolean;
inum : integer;
rsum : real;
begin
// Provided code - do not change
redoutput.Clear;
redoutput.Lines.Add('Order Date' + #9 + 'Amount of order');
redoutput.Lines.Add('--------------------------------------------') ;
stblWinkels := cmbtblWinkels.Text;
/// enter your code below//
bfound := false;
tblWinkels.First;
while (not tblWinkels.Eof) and (bfound = false) do
    begin
     if tblWinkels['WinkelNaam'] = stblWinkels then
         begin
          inum := tblWinkels['tblWinkelsid'];
          bfound := true;
         end;
    tblWinkels.Next;
    end;
rsum := 0;
tblBestellings.first;
while not tblBestellings.eof do
   begin
    if tblBestellings['tblWinkelsid'] = inum then
      begin
      redoutput.Lines.Add(datetostr(tblBestellings['BestellingDatum']) + #9 +
floattostrf(tblBestellings['BestellingBedrag'],ffcurrency,8,2));
      rsum := rsum + tblBestellings['BestellingBedrag'];
      end;
   tblBestellings.Next;
   end;
   redoutput.Lines.Add('');
 redoutput.Lines.Add('Total amount ordered: '+ floattostrf(rsum,ffcurrency,8,2));
end;

Kopiereg voorbehou                                                          Blaai om asseblief

### Page 13

Downloaded from hlayiso.com
(EC/SEPTEMBER 2022)                    INLIGTINGSTEGNOLOGIE V1                   13

VRAAG 3

Klaseenheid:
unit Question3ClassDefinition;

interface
uses sysutils, math, dialogs;

type
TRepair = class
  private
    frepairname : string;
    fhours : integer;
    fcost : real;
    ftotalcost : real;

 public
   constructor create(sname : string; ihrs : integer);
   function calculatedays(ihrs : integer) : integer;
   function gethours : integer;
   function tostring : string;
   procedure settotalcost(ihrs : integer);
   function gettotalcost : real;
end;

implementation
{ TRepair }

constructor TRepair.create(sname: string; ihrs: integer);
begin
  frepairname := sname;
  fhours := ihrs;
  fcost := 70 * fhours;
end;

// provided code do not delete//
function TRepair.gethours: integer;
begin
result := fhours;
end;

// provided code do not delete//
function TRepair.gettotalcost: real;
begin
result := ftotalcost;
end;

procedure TRepair.settotalcost(ihrs: integer);
begin
ftotalcost := ihrs * 70;
end;

Kopiereg voorbehou                                               Blaai om asseblief

### Page 14

Downloaded from hlayiso.com
14                                INLIGTINGSTEGNOLOGIE V1                      (EC/SEPTEMBER 2022)

function TRepair.calculatedays(ihrs: integer) : integer;
var idays : integer;
begin
  if ihrs > 8 then
      begin
        idays := ceil(ihrs/8);
      end
      else
      idays := 1;
result := idays;
end;

function TRepair.tostring: string;
begin
 result := frepairname +
  #13 + 'Hours to complete: ' + inttostr(fhours) +
  #13 + 'Labour Cost: ' + floattostrf(fcost,ffcurrency,8,2)
end;

end.

Hoofeenheid:
procedure TForm1.btnQ3_2_1Click(Sender: TObject);
begin
 objrepair := trepair.create(lstrepairs.Items[lstrepairs.ItemIndex],sedhours.value);
 redq3.Lines.Add(objrepair.tostring);
 redq3.Lines.Add('');
 itotalhours := itotalhours + objrepair.gethours;
end;

procedure TForm1.cbxBuyPartsClick(Sender: TObject);
var rcost : real;
begin
objrepair.settotalcost(itotalhours);
rcost := objrepair.gettotalcost;

if cbxparts.checked = true then
   rcost := rcost + 150;

redq3.Lines.Add('');
redq3.Lines.Add('Total days to complete all jobs = ' +
inttostr(objrepair.calculatedays(itotalhours)));
redq3.Lines.Add('Total labour cost = ' + floattostrf(rcost,ffcurrency,8,2));
end;

Kopiereg voorbehou                                                             Blaai om asseblief

### Page 15

Downloaded from hlayiso.com
(EC/SEPTEMBER 2022)                INLIGTINGSTEGNOLOGIE V1                              15

VRAAG 4

unit Question4_u;
interface
uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls, Grids, ComCtrls;

type
  TForm1 = class(TForm)
   pgc: TPageControl;
   tbsvoting: TTabSheet;
   btnQ4_1: TButton;
   btnQ4_2: TButton;
   redQ4: TRichEdit;
   procedure btnQ4_1Click(Sender: TObject);
   procedure btnQ4_2Click(Sender: TObject);

 private
  { Private declarations }
 public
  { Public declarations }
 end;

var
 Form1: TForm1;
 ar2Stemme : array[1..2,1..10] of integer;

implementation
{$R *.dfm}

 procedure TForm1.btnQ4_1Click(Sender: TObject);
 var myfile : textfile;
 irow, icol, inum: integer;
 sline : string;
 begin
   assignfile(myfile, 'stemme.txt');
    reset(myfile);
    icol := 0;
    while not eof(myfile) do
      begin
        readln(myfile,sline);
        inc(icol);
        irow := 1;
        ar2Stemme[irow,icol] := strtoint(sline);
        readln(myfile,sline);
        irow := 2;
        ar2Stemme[irow, icol] := strtoint(sline);
      end;
end;

Kopiereg voorbehou                                                      Blaai om asseblief

### Page 16

Downloaded from hlayiso.com
16                                 INLIGTINGSTEGNOLOGIE V1               (EC/SEPTEMBER 2022)

procedure TForm1.btnQ4_2Click(Sender: TObject);
var
irow, icol, inum1, inum2, k, ia, ib : integer;
begin
    icol := 0;
    ia := 0;
    ib := 0;
  while icol < 10 do
    begin
      irow := 1 ;
      inc(icol);
      inum1 := ar2Stemme[irow,icol] ;
      irow := 2;
      inum2 := ar2Stemme[irow,icol];
      if inum1 > inum2 then
         begin
         redq4.Lines.Add('Distrik '+ inttostr(icol) + ' wenner is A');
         inc(ia);
         end
         else
         begin
         redq4.Lines.Add('Distrik '+ inttostr(icol) + ' wenner is B');
         inc(ib);
         end;
     end;
    redq4.Lines.Add('');
   if ia > ib then
      redq4.Lines.Add('Die algehele wenner is A')
     else
      redq4.Lines.Add('Die algehele wenner is B')
end;

end.

Kopiereg voorbehou                                                       Blaai om asseblief

## Related documents

- [IT P1 GR12 MEMO SEPT2018 Afrikaans](https://www.hlayiso.com/library/it-p1-gr12-memo-sept2018-afrikaans/55409ee4-7e45-46a3-88eb-9dbd26e43037) — Information Technology · Memo · 2018 · Afr
- [IT P2 GR12 QP SEPT2022 Afrikaans](https://www.hlayiso.com/library/it-p2-gr12-qp-sept2022-afrikaans/3392f845-8547-4e23-b73c-910c59ca4b2b) — Information Technology · QP · 2022 · Afr
- [INFORMATION TECHNOLOGY P1 GR 12 QP SEPT2020 Afrikaans](https://www.hlayiso.com/library/information-technology-p1-gr-12-qp-sept2020-afrikaans/42a51949-5c87-4fbf-8055-7cc9e3aaa612) — Information Technology · QP · 2020 · Afr
- [INFORMATION TECHNOLOGY P1 GR 12 QP SEPT2020 Afrikaans .docx](https://www.hlayiso.com/library/information-technology-p1-gr-12-qp-sept2020-afrikaans-docx/bcca23dc-b552-4601-9d0b-00117508a14e) — Information Technology · QP · 2020 · Afr
- [IT P1 GR12 QP SEPT2018 Afrikaans](https://www.hlayiso.com/library/it-p1-gr12-qp-sept2018-afrikaans/8a712e4b-3935-4095-aa63-c0cbea50a871) — Information Technology · QP · 2018 · Afr
- [INFO TECH P2 GR12 MEMO SEPT2017 Afrikaans](https://www.hlayiso.com/library/info-tech-p2-gr12-memo-sept2017-afrikaans/134bed6e-9b93-42cb-bc7b-bdb89503c63d) — Information Technology · Memo · 2017 · Afr

## More from Grade 12 Information Technology

- [IT-P2-GR12 QP-Afr-SEP-2025 watermark](https://www.hlayiso.com/library/it-p2-gr12-qp-afr-sep-2025-watermark/569cc299-ae7c-4635-9514-cf03f9242ebc) — QP · 2025 · Afr
- [IT P2 QP GR12 SEPT 2024 AFR](https://www.hlayiso.com/library/it-p2-qp-gr12-sept-2024-afr/9016098b-e233-49f4-b1dc-f0838363c6af) — QP · 2024 · Afr
- [Information Technology P1 Nov 2024 Afr](https://www.hlayiso.com/library/information-technology-p1-nov-2024-afr/f4b19c44-77ce-482a-9f85-438813c25f87) — QP · 2024 · Afr
- [Information Technology P2 Nov 2024 Eng](https://www.hlayiso.com/library/information-technology-p2-nov-2024-eng/3afa20d1-1c0f-4969-8a56-d690e9b24d70) — QP · 2024 · Eng
- [Information Technology P1 May-June 2023 Eng](https://www.hlayiso.com/library/information-technology-p1-may-june-2023-eng/896eee2c-884c-4527-97e2-ed0759edd97d) — QP · 2023 · Eng
- [Information Technology P1 Nov 2023 Eng](https://www.hlayiso.com/library/information-technology-p1-nov-2023-eng/8ae9d306-1975-4759-ad2b-96483154bd10) — QP · 2023 · Eng

## Collection

- [Grade 12 past papers](https://www.hlayiso.com/grade-12/past-papers)

---

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.
