Our History

THE HISTORICAL BACKGROUND OF THE SCHOOL

Gahogo Adventist Academy started in 2010 with 19 classrooms, that include 3 classes that were used as; a computer lab, a science lab(for Physics, Chemistry, Biology) and a library. The school has a staffroom and adminstrative offices

In the beginning the school had around 102 students: 42 students in Ordinary Level, and 60 students in Advanced Level (Math-Compuer-Physics and Math-Physics-Geography).

Staff: It had 11 teachers, The Headmaster, The Deputy headmaster in charge of Discpline,  The Deputy headmaster in charge of Studies, Accountant, The Cashier and The Matron. Click the link below to get more about the school.

Umwihariko wa Gahogo Adventist Academy/ Fees Payment Modes/ Amatangazo/Announcements

Up to now the school has the following options/combinations:

 Ordinary Level

           S1,S2,S3

 Advanced Level

*Mathematics-Physics-Computer (MPC)

*Mathematics-Physics-Geography (MPG)

*Mathematics-Computer-Economics(MCE)

*Mathematics-Economics-Geography (MEG)

*History-Economics-Geography (HEG)

*Literature-Economics- Geography (LEG)

*Mathematics-Chemistry-Biology (MCB)

 

Umwihariko wa Gahogo Adventist Academy/ Fees Payment Modes/ Amatangazo/Announcements

Minutes

GAHOGO ADVENTIST ACADEMY

________________________

IMYANZURO 10 Y'INAMA RUSANGE Y'ABABYEYI

YO

KUWA 28 KANAMA 2016

 Inama yatangiye saa 10h20 iyobowe n’Umuyobozi uhagarariye uburezi mu Itorero ry'abadiventisiti mu Rwanda witwa Pr Jacques Nkinzingabo mu gihe byari bigaragaye nta mubyeyi uri muri Komite wabashije kuboneka.Uyu muyobozi ni nawe watugejejeho Ijambo ry'Imana.

 

1. Kwemeza imyanzuro y’ inama rusange y’ ababyeyi yo ku wa 20/09/2015, kuyikorera ubugororangingo no gusuzuma ko imyanzuro yose yashyizwe mu bikorwa. Inama yasanze hejuru ya 90% y’imyanzuro yarashyizwe mu bikorwa.

2. Hasesesenguwe ikibazo cyibitabo bya program nshya bigomba kugurwa mu buryo bwihuse ( Competent Based curriculum) kugira ngo byorohere abanyeshuri kwiga neza nkuko biteganywa na gahunda nshya. Uruhare rw ikigo ndetse n ababyeyi rukaba rukenewe kugira ngo heswe uyu muhigo mu mwaka wa 2017.

3. Urugendo shuri ruzakorwa n abana mu karere ka Rubavu kureba amashyuza, ikiyaga cya Kivu, n’ibindi byiza nyaburanga biherereye muri ako karere. Buri mwana uzajyayo akazatanga amafaranga ibihumbi umunani (8,000 Rwf).

4. Kongera ingufu ku mpande zombi ( ababyeyi n’ishuri ) mu gukundisha abana umurimo wo kwiga kuko abana bamwe nta gaciro ndetse n’umwanya babiha, ibyo bikaba impamvu nyamukuru ituma abana badatsinda neza mu ishuri. Ibi bizagerwaho mu gihe ababyeyi babaye hafi y’ishuri, naryo rigatanga amakuru hakiri kare.

5. Hakozwe Amatora y ubuyobozi buhagarariye ababyeyi: Inama yatoye abayobozi bakurikira:

  • President: NDAHAYO Samuel
  • Vice President: MUSABYIMANA Angèle
  • Secretary: HATEGEKIMANA Assiel, Director
  • Uhagarariye Nyirikigo: KARANGWA Appolinnaire, Gitarama District Pastor
  • Umubitsi: HAKIZIMANA Philippe
  • Abajyanama 2:
  1. MUGENI Dianne
  2. NYIRACITOYENNE Alphonsine.

 

6. Hashingiwe ku izamuka rikataje ry’ibiciro by’ibiribwa ku masoko ndetse hanagendewe ku ivugururwa rigomba gukorwa mu myigishirize cyane cyane ku bijyanye n’ibikoresho abana bagomba gukenera kugira ngo bige neza, Inama yemeje ko amafaranga y ishuri (Minerval) mu mwaka wa 2017 azishurwa ku buryo bukurikira: ibihumbi ijana na makumyabiri (120,000 Rwf) ku gihembwe ku bana biga baba mu kigo, n ibihumbi mirongo itandatu (60,000 Rwf) ku bana biga bataha. Abiga barya mu kigo saa sita bazishura 80,000frw.

7. Bitewe nuko abayobozi b’ishuri muri rusange bigorana kwitaba telephone mu gihe ababyeyi babahamagara, Hifujwe ko ibi byakosorwa kugira ngo itumanaho rigende neza hagati y ababyeyi ndetse n abayobozi b’ishuri.

8. Hemejwe ko Discipline iba umuyoboro mwiza ukoreshwa kugira ngo ireme ry uburezi rigerweho, bityo discipline ikaba igomba gusigasirwa mu buryo bwose bushoboka. Abana bagaragaje imyitwarire itari myiza ndetse ishobora kurogoya gahunda z ishuri bakagirwa inama, byananirana bagasezererwa kugira ngo abasigaye bitabweho mu buryo bukwiye.

9. Hongeye gushimangirwa ko igihe bibaye ngombwa ko umwana yoherezwa mu rugo, ubuyobozi bw’ ikigo bumenyesha umubyeyi cyangwa urera umwana mbere yo kumwohereza kugira ngo bibaye ngombwa urera umwana amenye uko amakuru aba yagiye atangwa.

10. Bitewe nuko hari abana bagera ku ishuri ugasanga batabasha kubika ibikoresho byabo neza kubera uburangare ndetse bamwe ugasanga bangije imyambaro y’ishuri bahawe, hemejwe ko uwangije umwambaro agomba kudodesha undi uhwanye n’amabwiriza y’ishuri kandi hakabaho uburyo bwo kubungabunga umutekano w’ibikoresho by’abana mu buryo bwose bushoboka. Abana baba biba bagenzi babo bagahabwa ibihano biteganwa n’amategeko agenga ishuri

Bikorewe i Gahogo ku wa 28/08/2016

HATEGEKIMANA Assiel

Umwanditsi w’Inama rusange y’ababyeyi

 

 

 

-------------------------------------------------------------------------------------------------------------------------------

 

GAHOGO ADVENTIST ACADEMY

________________________

 

 

 

IMYANZURO 16 Y'INAMA Y'ABABYEYI YO

KUWA 20 NZERI 2015

 

 

Inama yatangiye saa 10h15 iyobowe n’Umubyeyi waruhagarariye abandi witwa Nzayisenga Emmanuel. Ikaba yaratangijwe n’Indirimbo zatoranijwe z’amakorari yo muri Gahogo Adventist Academy harimo Korari yitwa Last events laymen na Revival Choir. Ijambo ry’Imana ryatanzwe na Ruti Mfizi Christophe, Umuyobozi ushinzwe iby’umwuka mu kigo.

 

  1. Inama rusange yashimye Raporo zitandukanye zatanzwe n’Umuyobozi w’ishuri, Umuyobozi wungirije ushinzwe amasomo, Umuyobozi wungirije ushinzwe discipline.
  2. Inama yemeje ko mu mwaka w’amashuri utaha minerivali izaba ari 105,000frw, uniforme  izagurwa amafaranga 25000frw irimo ishati 2, ipantalo2, umupira w’imbeho1, karavate 1 n’agapira ka sport 1. Ibindi bisanzwe byishyurwa bizamenyeshwa ababyeyi binyuze ku ibauwa izandikirwa ababyeyi.
  3. Inama yemeje ko buri gihembwe hazajya hatangwa amafaranga 500 ajyanye n”itumanaho nkuko company ibikora aricyo giciro isaba kandi bikaba bigaragara ko ubu buryo bwo gutumanaho buri kudufasha cyane mu mikorere y’ishuri nderse n’ababyeyi.
  4. Amafaranga yo gusuzumira abana ku ishuri azatangwa ni 2500frw ku gihembwe. Aya mafaranga akazafasha no kubona imiti yoroheje yunganira mu gihe umurwayi aje kwisuzumisha ariko mu gihe hakenewe imiti ihenze umwana azajya ayiyishyurira.
  5. Inama yemeje ko amafaranga atandukanye yahabwaga abanyeshuri mu ntoki, hashakwa konti yajya ashyirwaho kuko usanga abanyeshuri bayahabwa ntibayatange ku buyobozi bw’ishuri bigateza imikoranire hagati y’ishuri n’ababyeyi.
  6. Inama yemeje ko buri mwana wiga yagombye kuba afite ibikoresho bihagije byo kwigiramo ndetse akagira umuhati wo kubicunga neza, cyane cyane amakaye yigiramo kandi akayakoresha nkuko bikwiye. Amakaye agafatirwamo notes kandi uwo bigaragaye ko atabikora akabihanirwa nkuko amategeko y’ishuri abiteganya.
  7. Inama yemeje ko mu gihe umwana aciyemo umwambaro w’ishuri, umubyeyi we azajya asabwa kumudodeshereza undi ujyanye n’amabwiriza y’ishuri.
  8. Hafashwe umwanzuro ko ababyeyi bafite abana biga bataha bagomba kujya bafasha ubuyobozi bw’ikigo mu gihe abo bana batabashije kugera ku ishuri kuko mu gihe bazajya basiba ntibimenyekane bishobora kuviramo abana gusezererwa burundu mu kigo
  9. Inama yashimye ko ubuyobozi bw’ishuri bwakuye abana mu bwigunge buteganya ko buri mwana agira sim card ye ashobora gukoresha avugana n’iwabo bitagize icyo byangije. Bityo telephones ngendanwa ntabwo zemewe mu kigo, uzayifatanwa azahanwa nkuko amategeko y’ishuri abiteganya.
  10. Inama yemeje ko mu gihe umubyeyi atumweho n’ubuyobozi bw’ishuri kubera ikibazo cy’imyitwarire y’umwana ntaboneke, uwo mwana azajya yoherezwa mu rugo. Kandi mu gihe imyitwarire y’umwana idahindutse azajya yoherezwa burundu iwabo mu rwego rwo kurushaho gufasha no kurengera abandi bana bakeneye kwiga. Mu gihe umwana agaragaweho ikosa nibyiza ko umubyeyi yihutira gufatanya n’ubuyobozi bw’ishuri mu maguru mashya kugira ngo umwana afashwe hakiri kare bitaragera kure.
  11. Inama yemeje ko byaba byiza ko abana batahatirwa kutabatizwa mu gihe babyifuje kuko aba ari uburenganzira bwabo bwo guhitamo nkuko itegeko nshinga ry’u Rwanda ribisobanura
  12. Inama yemeje ko abayobozi ndetse n’abarezi bajya bashyira imbaraga mu kuvuga indimi z’amahanga mu rwego rwo gufasha n’abana kwiyumva muri izo ndimi dore ko ari nazo bakoresha biga
  13. Inama yemeje ko mu gihe umubyeyi abonye ubutumwa bumugezeho yajya agira umuhati wo kugaragaza ko bwamugezeho.
  14. Inama yemeje ko ingingo yarebanaga n’amatora ya Komite nyobozi y’inama rusange y’ababyeyi yakorwa mu mwaka utaha mu gihembwe cya mbere, dore ko iyi nama ibaye ari iya nyuma muri uyu mwaka w’amashuri hakaba hari abana benshi barangije ntibazagaruke umwaka utaha bikaba byahita bidusaba nanone kuvugurura. Amatora azategurwa kandi akorwe mu gihembwe cya mbere cya 2016.
  15. Inama yemeje ko mu gihe umunyeshuri akomeje kurangwa n’akajagari ku ishuri, ntiyige, ntabe mu murongo umwe n’amategeko ngengamikorere y’ikigo agiye kujya yoherezwa mu rugo burundu. By’umwihariko abiga mu wa gatatu S3 no mu wa gatandatu S6 bazajya basabirwa gukurwa ku rutonde rw’abazakora ikizamini cya Leta.
  16. Inama yemeje ko amategeko ngengamikorere y’ishuri agiye gusohoka bityo ababyeyi bakarushaho gusobanukirwa na za kirazira mu gihe umwana ari ku ishuri mu rwego rwo kugaragaza by’umwihariko bimwe mu bihano biba biteganijwe.

HATEGEKIMANA Assiel

Umwanditsi w’Inama rusange y’Ababyeyi

Gahogo Adventist Academy

 --------------------------------------------------------------------------------------------------------

Umwihariko wa Gahogo Adventist Academy/Fees Payment ModesAmatangazo/Announcements

______________________________________________________________________

 

 

 

 

 

 

GAHOGO ADVENTIST ACADEMY

___________________________

IMYANZURO 12 Y'INAMA Y'ABABYEYI YO

KUWA 17 GICURASI 2015.

Inama y'ababyeyi yatangiye saa 9h45 iyoborwa n'umubyeyi witwa NZAYISENGA   Emmanuel ikaba yarafashe imyanzuro ikurikira:

  1. Inama yashimye ubuyobozi bw'Ishuri kuri gahunda nziza bufite cyane cyane uburyo bwashyizweho bwo kugezaho ababyeyi amakuru yubuzima bwo ku ishuri, ababyeyi basaba ko bukomeza kurushaho.

  2.  Mu rwego rwo gufasha abana mu gihe cy’uburwayi hafashwe umwanzuro wo gushyiraho  ivuriro mu kigo(Sick bay/infirmerie) numuganga wo kubavura mu gihe ari indwara zoroheje  bityo bikagabanya ingendo abana bakoraga bajya kwa muganga. Ubuyobozi bwishuri bwasabwe kurangiza uyu mushinga ugatangarizwa ababyeyi icyo usaba.

  3. Mu rwego rwo kurushaho kwita ku myitwarire nimicungire yabana ku ishuri hafashwe umwanzuro ko mu gihe umubyeyi ahamagawe ku ishuri kubera imyitwarire mibi yumwana we ntaboneke, azajya yoherezwa mu rugo. Ababyeyi basabwa kuba hafi y'ubuyobozi bwikigo kubijyanye nimyitwarire yabana babo.

  4. Hafashwe umwanzuro ko mu gihe igitambaro cy'ishati cyakoreshwaga  kitabonetse hakoreshwa paupeline qualite  ya mbere kugira ngo abana batabashije kubona uniforme babashe kuzibona mu gihe kihuse.

  5. Nyuma yo kungurana ibitekerezo kuri uniforme n'uburyo yagiye igorana hafashwe ko ubuyobozi bw;ishuri bwajya bukora commande y'imyenda mbere yuko umwaka wamashuri utangira, abana bakaza kwiga bahita babona uniforms.

  6.  Mu rwego rwo guca kuryama muri dortoir kwabana bamwe na bamwe 'itewe nubunebwe bafite cyangwa kwirwaza hafashwe umwanzuro ko hagiye gushyira mu bikorwa icyo amategeko ateganya. Igihano cyo koherezwa mu rugo mu gihe cy'icyumweru ku munyeshuri ufatiwe muri dortoir bitazwi.

  7. Ababyeyi bafite abana biga bataha basabwe kujya bamenyesha mbere ubuyobozi bw'ishuri miba habonetse impamvu ituma umwana asiba ishuri. Mu gihe bitakozwe umwana azajya abihanirwa nkuko amategeko y'ishuri abiteganya.

  8. Mu rwego rwo kurushaho kuzamura amajyambere y'ikigo hemejwe ko mu nama itaha hazatangwa ubusobanuro ku mishinga y'ishuri ifasha abana kurushaho kwiga neza ariyo computer Lab, Ibibuga bitandukanye nindi yose ifasha ishuri kurushaho kuzuza inshingano yaryo.

  9. Hemejwe ko ababyeyi bajya barushaho kunganira ishuri mu gutanga ibitekerezo ndetse ninama cyane cyane ku burere bwifuzwa ku bana barererwa muri Gahogo Adventist Academy.

  10. Hemejwe ko Ubuyobozi bw'ishuri bwakwiga umushinga wo gushyiraho groupe ya Watsap ihuriweho n’ababyeyi barerera mu kigo kugira ngo hajye habaho uburyo bwo guhana amakuru yuko abana baba babayeho ku ishuri.

  11. Hemejwe ko ubuyobozi bw'ishuri bwashyiraho uburyo bwo kureba ibikoresho abana bakenera baje cyangwa bari ku ishuri kugira ngo hirindwe gusohoka ikigo kubwimpamvu zo gushaka ibyo bikoresho hanze.

  12. Hafashwe umwanzuro ko abanyeshuri bagaragaza imyitwarire itandukanye nuko amategeko yishuri abiteganya  cyane cyane ku bijyanye na Copinage(ubucuti hagati yabanyeshuri ahanini usanga bubarangaza), maquillage(kwihindura: kogosha ingohe, gusiga iminwa, Gusiga inzara), Gucamo cyangwa kugabanya  imyambaro y'ishuri bahawe; ko hagiyeho gahunda yo kubigisha uko bagomba kwitwara, uwo bigaragaye ko atabashije kwikosora agahanwa.

HATEGEKIMANA Assiel

Umwanditsi w Inama rusange y’ababyeyi

 0788659851/0722659851

 

Umwihariko wa Gahogo Adventist Academy/Fees Payment ModesAmatangazo/Announcements


Ibitabo byavuzweko bishobora kwitabwaho mugihe umubyeyi ashatse

kugurira umwana ibitabo

  • FOR ADVANCED LEVEL

  • ORDINARY LEVEL

 

Umwihariko wa Gahogo Adventist Academy/Fees Payment ModesAmatangazo/Announcements

Home

 

MOTTO OF THE SCHOOL

Strengthened for Shining

Kugabanyirizwa amafaranga y’ishuri ku bana b’Indashyikirwa (SCHOOL FEES DISCOUNT)

Umwihariko wa Gahogo Adventist Academy/

Uburyo bwo kwishyura/Fees Payment Modes/

Ibikoresho by'ibanze bisabwa umunyeshuri mbere yo kwinjira mu kigo

MISSION OF THE SCHOOL

To provide quality education based on developing Spiritual, Intellectual, and Physical aspect.

To prepare the student to be an efficient person in this world and the new world to come. To prepare a student who can serve God as well as people.

Umwihariko wa Gahogo Adventist Academy/ Fees Payment Modes/Uburyo bwo kwishyura amafaranga y'ishuri/Amatangazo/Annoncements

School Materials/Ibikoresho by'ibanze bisabwa umunyeshuri mbere yo kwinjira mu kigo

Kugabanyirizwa amafaranga y’ishuri ku bana b’Indashyikirwa (SCHOOL FEES DISCOUNT)

 

          VISION OF THE SCHOOL

GAHOGO ADVENTIST ACADEMY aims at becoming a regional role model Adventist secondary school.                                                                

It also aims at offering quality education according to the policy of the seventh Day Adventist Church and the Rwanda Ministry of Education.

Mainly it aims at training good citizens for this world and the world to come (New Earth); People who love and obey God and people.

To train skilled people competent at the labor market in the region with advanced level of technology.

To be a school where the students speak more than two Languages and have a spirit of job creation,  and customer care spirit.
 
 
 

Teachers' Publications

MARKING SCHEME  S6MCE&MPC COMPUTER SCIENCE EXAMINATION  3rd term 2016

REPUBLIC OF RWANDA

MINISTRY OF EDUCATION

MUHANGA DISTRIC

ACADEMIC YEAR 2016

 

MARKING SCHEME OF COMPUTER SCIENCE /100 marks

Section A: Answer all questions /55pts

  1. Which two controls in VB display graphic images? /1Mark

Image control and Picture box

  1. List the steps required to connect a computer using a UPS /3Marks

ü  Connecting the battery wires

ü  Plugging the UPS directly into a properly wired and grounded power outlet

ü  Deciding which critically important devices(computer) to plug into the "battery" outlets.

 

Or

  • First you need to connect the UPS overnight to charge the battery.
  • Normally the UPS comes with instructions of how to connect the battery because the manufactures ship the UPS with the battery inside disconnected.
  • After that connect the CPU and the Monitor to the back of the UPS there is a plug behind the UPS that says SURGE those doesn't provide electricity after a power outages those are only to protect devices normally used for speakers.
  1. How to move (delete) a program from your computer? /3Marks

Click on the Windows 7 Start Menu button ( ) and then click on the Control Panel. Please double-click the Uninstall a program icon: A list of programs installed will be populated this may take a bit of time. In this list please find the program that you would like to remove and select it by left-clicking once on it.

 

  1. What is a computer virus? In which ways can a virus be transmitted into your PC? /4Marks

A computer virus is a type of malicious software program ("malware") that, when executed, replicates by reproducing itself (copying its own source code) or infecting other computer programs by modifying them.

Ways Computer Viruses Are Spread:

         Email attachments.

         Networks

         Infected Boot disks

         Infected Software

         Hackers

         Fake Anti Virus Software

         From Mobile/Removable Devices

 

  1. Give the four impacts of computer on society /4Marks

Everyone knows that this is the age of computer and vast majority of people are using computer. Development of science and technology has direct effect on our daily life as well as in our social life. Computer technology has made communication possible from one part of the world to the other in seconds. They can see the transactions in one part of the world while staying in the other part. Computer development is one of the greatest scientific achievements of the 20 th century. Computers are used in various fields as well as in teaching and learning. Some of the major computer application fields are listed below.

  1. An aid to management: The computer can also be used as a management tool to assist in solving business problems.
  2. Banking: Branches are equipped with terminals giving them an online accounting facility and enabling them to information as such things as current balances, deposits, overdrafts and interest charges.
  3. Industrial Application: In industry, production may be planned, coordinated and controlled with the aid of a computer.
  4. Engineering Design: Computer help in calculating that all the parts of a proposed design are satisfactory and also assist in the designing.
  5. Meteorology: Data is recorded at different levels of atmosphere at different places, using remote sensors carried on a satellite.
  6. Air Travel: Small computers are installed as a part of the plane's equipment.
  7. Road Traffic Control: Computers assist with the control of traffic lights.
  8. Telephones: Computerized telephone exchanges handle an ever increasing volume of calls very efficiently.
  9. Medicine: Computers are widely used in hospitals for such task as maintaining drugs, surgical equipments and linen, for payroll and also for checkup and treatment of diseases.

  1. List and explain the types of SQL commands. /5Marks

Types of SQL Commands

The following sections discuss the basic categories of commands used in SQL to perform various functions. These functions include building database objects, manipulating objects, populating database tables with data, updating existing data in tables, deleting data, performing database queries, controlling database access, and overall database administration.

The main categories are

  • DDL (Data Definition Language)
  • DML (Data Manipulation Language)
  • DQL (Data Query Language)
  • DCL (Data Control Language)
  • Data administration commands
  • Transactional control commands

Defining Database Structures

Data Definition Language, DDL, is the part of SQL that allows a database user to create and restructure database objects, such as the creation or the deletion of a table.

Manipulating Data

Data Manipulation Language, DML, is the part of SQL used to manipulate data within objects of a relational database.

There are three basic DML commands:

INSERT

UPDATE

DELETE

Selecting Data

Though comprised of only one command, Data Query Language (DQL) is the most concentrated focus of SQL for modern relational database users. The base command is as follows:

SELECT

This command, accompanied by many options and clauses, is used to compose queries against a relational database. Queries, from simple to complex, from vague to specific, can be easily created.

A query is an inquiry to the database for information. A query is usually issued to the database through an application interface or via a command line prompt.

Data Control Language

Data control commands in SQL allow you to control access to data within the database. These DCL commands are normally used to create objects related to user access and also control the distribution of privileges among users. Some data control commands are as follows:

ALTER PASSWORD

GRANT

REVOKE

CREATE SYNONYM

You will find that these commands are often grouped with other commands and may appear in a number of different lessons throughout this book.

Data Administration Commands

Data administration commands allow the user to perform audits and perform analyses on operations within the database. They can also be used to help analyze system performance. Two general data administration commands are as follows:

START AUDIT

STOP AUDIT

Do not get data administration confused with database administration. Database administration is the overall administration of a database, which envelops the use of all levels of commands. Database administration is much more specific to each SQL implementation than are those core commands of the SQL language.

Transactional Control Commands

In addition to the previously introduced categories of commands, there are commands that allow the user to manage database transactions.

  • COMMIT Saves database transactions
  • ROLLBACK Undoes database transactions
  • SAVEPOINT Creates points within groups of transactions in which to ROLLBACK
  • SET TRANSACTION Places a name on a transaction

 

  1. What is a data type? What is the difference between a String and a Boolean data type? What are two controls that behave as if they conform to the Boolean data type? /4Marks

ü  A data type or simply type is a classification identifying one of various types of data, such as real, integer or Boolean, that determines the possible values for that type, the operations that can be done on values of that type, the meaning of the data, and the way values of that type can be stored.

 

ü  The Boolean type has only two values. The constants for these values are true and false and are only used for truth values. Unlike some languages, false isn't exactly the same as 0 (zero), but it will convert to 0 when used where a number is expected, so it's much the same thing.

The String type is for textual characters. There is no type for representing just one character. A String is a row of zero or more characters as a unit, not an array of single characters. Of course, a String of exactly one character is as good as a single character, so that is the way a single character is represented.

 

ü  Checkbox and option button are Boolean controls

  1. What is usually the last step a VB programmer takes before distributing an application to users? /1Mark

Implementation

  1. What do the following acronyms stand for? /4Marks
    1. ATX: Advanced Technology extended
    2. BTX: Balanced Technology Extended
    3. RAM: Random Access Memory
    4. IRQ: Interrupt Request
    5. DMA: Direct Memory Access
    6. DIMM: Dual Inline Memory Module
    7. SCSI: Small Computer System Interconnect
    8. NIC: Network  Interface Card


 


  1. A hard disk has the following parameters: number of cylinders C=16383, Number of heads=16, Sectors per Track SPT=63, Bytes Per Sector BPS=512B.
    1. Calculate disk capacity in bytes. /2Marks
    2. Calculate disk capacity in GB. /1Mark

Capacity = Number of cylinders × number of heads × sectors/track × 512 = hard disk size (bytes)
For my specific hard disk my calculations are:16,383 * 16 * 63 * 512 = 8455200768 bytes

Drive H=16, C=16383, S=63, B=512, Size=8.4GB

 

  1. State any three differences between SATA and IDE computer technologies. /3Marks

         SATA data transfer at the rate of up to 6 GB/s that is far more than IDE data transfers rate which works at the rate of up to 133MB/s

         SATA interface supports hot plugging IDE interface does not support hot plugging.

         SATA narrow can be up to a tempo (roughly 3ft) long. Power and data split into two connections, IDE ribbon-like, wide, can be up to 18 inches long.

 

  1. Give the output from the following codes fragments: /4Marks
  2. #include <stdio.h>


#include <stdlib.h>

int main(int argc, char *argv[])

{          int a,b,sum1,sum2;

            a=b=2;

            sum1=a+(++b);

            sum2=a+(b++);

            printf("%d %d %d %d", a, b, sum1, sum2);

return 0;            }

           

  1. #include

<stdio.h>

int main()

     {

       int x=5, y=10, z=10;

         x=y==z;

        printf(“%d”, x);

      }


  1.  Use function to write a program to find the factorial of an integer. /3Marks

#include<stdio.h>

int main(){

  int i,f=1,num;

  printf("Enter a number: ");

  scanf("%d",&num);

  for(i=1;i<=num;i++)

      f=f*i;

  printf("Factorial of %d is: %d",num,f);

  return 0;

}

Or

#include<stdio.h>

void findFactorial(int,int *);

int main(){

  int i,factorial,num;

  printf("Enter a number: ");

  scanf("%d",&num);

  findFactorial(num,&factorial);

  printf("Factorial of %d is: %d",num,*factorial);

  return 0;

}

void findFactorial(int num,int *factorial){

    int i;

    *factorial =1;

    for(i=1;i<=num;i++)

      *factorial=*factorial*i;

}

Or

TO FIND FACTORIAL USING ALL THREE LOOP

Private Sub cmdFactorial_Click()
n = Val(InputBox(“Enter Number To Find Factorial ?”))

‘USING FOR…… NEXT LOOP
fact = 1
For i = n To 1 Step -1
    fact = fact * i
Next

Print “Answer Using For Loop”
Print “=====================”
Print “Factorial of ” & n & ” is” & fact
Print “”

  1. Write a program in VB to solve quadratic equation. /5Marks

 

Private Sub Cmd1_ click ( )

Dim a , b , c , X1 , X2 as variant

a= Val (Txt1.text)       

b= Val (Txt2.text)

c= Val (Txt3.text)

X1=Cdbl (- b + Sqr (b ^ 2 – 4 * a * c) ) / (2 * a)      

X2= Cdbl (- b – Sqr (b ^ 2 – 4 * a * c) ) / ( 2 * a)

End Sub

Or

The Code

Private Sub Form_Load()
Dim a, b, c, det As Integer
Dim root1, root2 As Single
Dim numroot As Integer
End Sub

Private Sub new_Click()
' To set all values to zero
Coeff_a.Text = ""
Coeff_b.Text = ""
Coeff_c.Text = ""
Answers.Caption = ""
txt_root1.Visible = False
txt_root2.Visible = False
txt_root1.Text = ""
txt_root2.Text = ""
Lbl_and.Visible = False
Lbl_numroot.Caption = ""
End Sub

Private Sub Solve_Click()
a = Val(Coeff_a.Text)
b = Val(Coeff_b.Text)
c = Val(Coeff_c.Text)

'To compute the value of the determinant

det = (b ^ 2) - (4 * a * c)
If det > 0 Then
Lbl_numroot.Caption = 2
root1 = (-b + Sqr(det)) / (2 * a)
root2 = (-b - Sqr(det)) / (2 * a)
Answers.Caption = "The roots are "
Lbl_and.Visible = True
txt_root1.Visible = True
txt_root2.Visible = True
txt_root1.Text = Round(root1, 4)
txt_root2.Text = Round(root2, 4)

ElseIf det = 0 Then
root1 = (-b) / 2 * a
Lbl_numroot.Caption = 1
Answers.Caption = "The root is "
txt_root1.Visible = True
txt_root1.Text = root1
Else
Lbl_numroot.Caption = 0
Answers.Caption = "There is no root "
End If
End Sub

  1. To design a simply calculator, design a form with three text boxes and four command buttons. The integer value of the first and second number is entered into separate (labeled) text boxes. Write codes to perform add, subtract, multiply, and divide where pressing on buttons. Display the result operation in separate Textbox by using the following formula.  8+7=15  /4Marks
  1.  Produce the Intersection and the Union of the  tables below:                        /4Marks

FOOTBALL_PLAYER Table                                                  CRICKET_PLAYER Table

Id Name
1101/01 Sam
3303/03 Tom
7707/07 Jack
9909/09 Kalim
Id Name
7707/07 Jack
8808/08 Jackob
9909/09 Kalim
1111/11 Abu
2222/22 Kaliba

 

SECTION B: Answer any three questions of the followings /30 marks

  1. Design a form with one command and two text boxes. Enter the value of integer number (N) in separate text box. Write a code program to check if the number (N) is a prime Number or not. Display the “It is not a prime number” or “It is a prime number” in separate text box.

Private Sub Command1_Click()

Dim N, D As Single

Dim tag As String

N = Val(Text1.Text)

Select Case N

Case Is < 2

Case 2

Case Is > 2 

D = 2

Do

If N / D = Int(N / D) Then

tag = "Not Prime"

Exit Do

End If

D = D + 1

Loop While D <= N - 1

If tag <> "Not Prime" Then

End If

End Select

End Sub

 

  1. Consider the relation below:    

The EMPLOYEE relation

EmpNo EmpName Designation Salary DeptNo
1001 Sam Teacher 5,000 1
 002 Peter Secretary 5,500 1
1003 Jane Accountant 6,000 2
1004 Jack Manager 11,000 2
  1. Give all information for employees.

ü  Write SQL query.

ü  Give the relation resulting from the query.

  1. List all employees with a salary greater than 1,000.

ü  Write SQL query

ü  Give the relation resulting from the query

  1. Produce a list of salaries for all employees of DeptNo2 showing only EmpNo, EmpName, Salary, DeptNo.

ü  Write SQL query

ü  Give the relation resulting from the query

  1. Define a class to represent a bank account. Include:


Data members:

  • Name of the depositor
  • Account number
  • Type of account
  • Balance amount in the account

Member functions:

  • To assign initial values
  • To deposit an amount
  • To withdraw an amount after checking the balance
  • To display name and balance


Write a main function to test the program

Program to represent a bank account (implemented as a Class)

# include<iostream.h>

# include<conio.h>

# include<iomanip.h>

class bank

            {

            char name[20];

            int acno;

            char actype[4];

            float balance;

            public:

            void init();

            void deposit();

            void withdraw();

            void disp_det();

            };

//member functions of bank class

void bank :: init()

{

cout<<"

                        New Account

";

cout<<"

Enter the Name of the depositor : ";

cin.get(name,19,'

');

cout<<"

Enter the Account Number : ";

cin>>acno;

cout<<"

Enter the Account Type : (CURR/SAVG/FD/RD/DMAT) ";

cin>>actype;

cout<<"

Enter the Amount to Deposit : ";

cin >>balance;

}

void bank :: deposit()

{

float more;

cout <<"

                        Depositing

";

cout<<"

Enter the amount to deposit : ";

cin>>more;

balance+=more;

}

void bank :: withdraw()

{

float amt;

cout<<"

                        Withdrwal

";

cout<<"

Enter the amount to withdraw : ";

cin>>amt;

balance-=amt;

}

void bank :: disp_det()

{

cout<<"

                        Account Details

";

cout<<"Name of the depositor : "<<name<<endl;

cout<<"Account Number        : "<<acno<<endl;

cout<<"Account Type          : "<<actype<<endl;

cout<<"Balance               : $"<<balance<<endl;

}

// main function , exectution starts here

void main(void)

{

clrscr();

bank obj;

int choice  =1;

while (choice != 0 )

{

cout<<"

Enter 0 to exit

            1. Initialize a new acc.

            2. Deposit

            3.Withdraw

            4.See A/c Status";

cin>>choice;

switch(choice)

{

            case 0 :obj.disp_det();

                        cout<<"

                        EXITING PROGRAM.";

                        break;

            case 1 : obj.init();

                        break;

            case 2: obj.deposit();

                        break;

            case 3 : obj.withdraw();

                        break;

            case 4: obj.disp_det();

                        break;

            default: cout<<"

Illegal Option"<<endl;

}

}

getch();

}

Or

#include<iostream.h>

#include<iomanip.h>

class bank

{

    char name[40];

    int ac_no;

    char ac_type[20];

    double balance;

public:

    int assign(void);

    void deposite(float b);

    void withdraw(float c);

    void display(void);

};

int bank::assign(void)

{

    float initial;

    cout<<" You have to pay   500 TK to open your account \n"

    <<" You have to store at least 500 TK to keep your account active\n"

    <<"Would you want to open a account????\n"

    <<" If Yes press 1 \n"

    <<" If No press 0 : ";

    int test;

    cin>>test;

    if(test==1)

    {

        initial=500;

        balance=initial;

      cout<<" Enter name ,account number & account type to creat account : \n";

         cin>>name>>ac_no>>ac_type;

    }

    else

    ;// do nothing

    return  test;

}

void bank::deposite(float b)

{

    balance+=b;

}

void bank::withdraw(float c)

{

    balance-=c;

    if(balance<500)

    {

        cout<<" Sorry your balance is not sufficient to withdraw "<<c<<"TK\n"

             <<" You have to store at least 500 TK to keep your account active\n";

                balance+=c;

    }

}

void bank::display(void)

{

    cout<<setw(12)<<"Name"<<setw(20)<<"Account type"<<setw(12)<<"Balance"<<endl;

    cout<<setw(12)<<name<<setw(17)<<ac_type<<setw(14)<<balance<<endl;

}

int main()

{

    bank account;

    int  t;

    t=account.assign();

    if(t==1)

    {

        cout<<" Would you want to deposite: ?"<<endl

        <<"If NO press 0(zero)"<<endl

        <<"If YES enter deposite ammount :"<<endl;

        float dp;

        cin>>dp;

        account.deposite(dp);

        cout<<" Would you want to withdraw : ?"<<endl

        <<"If NO press 0(zero)"<<endl

        <<"If YES enter withdrawal ammount :"<<endl;

        float wd;

        cin>>wd;

        account.withdraw(wd);

        cout<<" see details :"<<endl<<endl;

        account.display();

    }

            else if(t==0)

    cout<<" Thank you ,see again\n";

    return 0;

}

  1. Write a program to enter an angle value (Degree, Minutes, and Seconds) into separate text boxes. Calculate the value of angle (in degree only). Display angle in separate text box. When the user click the option button, calculate the value of the function (Sin, Cos or Tan) and display in separate text box. If the value of Minutes or seconds exceeded 60, write a message box (The value of minutes or seconds exceeds 60) to stop the program.

Private Sub Command1_Click() 

Dim deg As Double, minut As Double, second As Double

Dim total As Double, p As Double

deg = Val(Text1.Text)

minut = Val(Text2.Text)

second = Val(Text3.Text)

If minut > 60 Or second > 60 Then

res = MsgBox("The value of minutes or seconds exceeds 60", 0)

If res = 1 Then Text1.Text = "": Text2.Text = "": Text3.Text = "": Exit Sub

End If

total = deg + (minut / 60) + (second / 3600)

Text4.Text = Str(total)

p = 3.141596 / 180

If Option1.Value = True Then

Text5.Text = Str(Sin(p * total))

End If

If Option2.Value = True Then

Text5.Text = Str(Cos(p * total))

End If

If Option3.Value = True Then

If Cos(p * total) <= Abs(0.00001) Then Text5.Text = "division by zero": Exit Sub

Text5.Text = Str(Tan(p * total))

End If 

End Sub

 

 

 

 

SECTION C: Answer any one question of your choice /15 marks

  1. Consider the following table which provides practice in converting a number from binary notation to decimal format of an IP Address.
  1. Complete the table above
  1. Based on the rules of categorizing IP addresses summarized in the table below:
CLASS LEFT MOST BITS
A 0XXX
B 10XX
C 110X
D 111X
  1. Express 145.32.59.24 IP Address in binary format and identify the address class of it.
  2. Determine the class of the Address 200.42.129.16
  1. Considering the following tables:

CLIENT

ClientID SurName FirstName Telephone
001 Uwera Diane 08754172
002 Kayiranga Alain 08965216
003 Kayitesi Aimée 08952141

CAR

CarID Manufacturer Meter ClientID
4698 SJ 45 Renault 123450 003
4568 HD 16 Toyota 56000 002
6576 VE 38 Benz 12000 001
7845 ZS 83 Fiat 75600 003
7647 ABY 82 Renault 189500 002
8562 EV 23 Benz   002
8941 UD 61 Fiat   001
7846 AZS 75 Peugeot 21350 003

Give the output of the following SQL queries:

  1. SELECT SurName, FirstName, CarID, Manufacturer FROM CLIENTS, CAR

WHERE CLIENTS.ClientID= CAR.ClientID

AND Manufacturer= "Benz";

  1. SELECT * FROM CAR
  2. UPDATE CLIENTS
WHERE Meter< (SELECT AVG (Meter) FROM CAR);

SET Telephone= "075082141"

WHERE ClientID="003";

  1. ALTER TABLE CLIENT

ADD COLUMN Mail varchar (10);

  1. SELECT Manufacturer, SUM (Meter) As Total

FROM CAR

WHERE Manufacturer IN (“Renault”,” Fiat”)

GROUP BY Manufacturer;


 

 

REPUBLIC OF RWANDA

MINISTRY OF EDUCATION

MUHANGA DISTRICT

JULY 2016              

CLASS: SENIOR SIX

SUBJECT: COMPUTER SCIENCE

COMBUNATION: MATHEMATICS-COMPUTER SCIENCE-ECONOMICS (MCE) &

                                   MATHEMATICS-PHYSICS -COMPUTER SCIENCE (MPC)

 

MARKING SCHEME

SECTION A: Answer All questions /55 marks

  1. Multiple choice/5marks

 b. A serial data port on your PC would have how many pins out?

A. 9,   B. 5, C. 7

         b) How many wires does the standard IDE drive cable have?

   A. 40

   B. 55

   C. 50

 c) What type of port communicates information to a peripheral device one bit at a time?  

A. Parallel port

   B. Serial port

   C. Optical port

 d) What component of the computer processes data?

  A. The RAM

   B. The Storage devices

   C. The Processor.

   D. The Monitor

e) Which computer below uses the screen touch technology?

A. The palmtop

   B. The laptop

   C. The minicomputer

   D. The desktop computer

f) Which computer device below is an example of output hardware?

   A. The keyboard

   B. The printer

C. The scanner

   D. The microphone

g) Which storage device of the computer stores or keeps the operating system and application programs?

A. The flash disk.

B. The diskette

C. The CD ROM

D. The hard disk

h) Which operating system below does not require the use of the mouse?

A. Windows Vista

B. Windows Linux

C. Windows ME

D. MS DOS

i) Which software below is an application program?

   A. Windows Explorer

   B. Microsoft DOS

   C. Microsoft OS

   D. Microsoft Access

j) Which computer peripheral produces the soft copy of a hard copy?

A. The scanner

B. The printer

C. The CD ROM

D. The Tape drive

2. Give three examples of audio ports that connect audio devices to the computer. /1.5marks

Line in, line out, microphone connectors

3. List the three motherboard form factors. /1.5marks

AT, ATX, BTX

4. Describe the three components of a UPS. /1.5marks

Rectifier: converts Ac power to DC power so that the battery can store it.

Battery: stores the power for use in case of surge

Inverter: converts the battery DC power into AC power for the equipment and provides continues power to the computer for as the battery provides uninterrupted power to the inverter.

Identify from the following which are hardware or software. /3marks

    1. Capacitors
    2. Internet Explorer
    3. Hard Disk
  • Unix
  • Scanner
  • RAID


 


Hardware Software

¾     Hard Disk

¾     Scanner

¾     RAID

 

¾     Internet explorer

¾     Unix

 RAID

  1. What is a browser? List any four types of web browsers. /3marks

A browser

A web browser (commonly referred to as a browser) is a software application for retrieving, presenting, and traversing information resources on the World Wide Web.

Mozilla Firefox, internet explorer, opera mini , Google chrome, safaris

  1. A “1.44 MB” floppy disk has 80 cylinders (numbered 0 to 79), 2 heads (numbered 0 to 1) and 18 sectors (numbered 1 to 18). Calculate its capacity in sectors. /4.5marks

Total storage capacity of a floppy/hard disk=total number of sectors*512 bytes per sector 

 Total number of sectors =sectors per side*number of heads

 Sectors per side=Tracks per side*sectors per track

 Total number of sectors=(80*18)*2=2880  

 Total storage capacity=2880*512 bytes /sector=1474560 bytes (1.44MB)  

  1. Distinguish the different families of computers./2marks

Microcomputer, minicomputer, mainframe computers, supercomputer

 

  1. State five differences between DOS and Linux./2.5marks

DOS does not provide any graphical user interface, whereas Linux does.

DOS does not support the concept of multi-users; whereas Linux does.

DOS also does not have any in built security features, whereas Linux does

Basically DOS has had very different goals from that of Linux.

MS-DOS is a 16-bit operating system whereas Linux use 32-bits and 64-bit

MS-DOS is a closed source, Linux is a open source

Files and directories

The files in Linux can be very long, up-to 255 characters, and they do not always have extensions.

The path names are separated by forward slashes (/) in Linux whereas DOS and Windows uses back slashes (\).   

  1. Why is a hard disk technically 80 GB but the operating system treats it as 72GB only?/5marks

With 80GB but the computer it calculates 72.72GBs by referencing that 1KB equals to 1024 bytes multiplicate by 1024 bytes which is equals 1,048,576KB.

1,048,576 KB or 1MB and then a Gigabyte in turn equals 1,048,576 KB multiplicate by 1,048KB which in turn equals 1,099.8 MB. or 1100MB.

If we were to calculate that out according to the computers determination of 80GB, we would divide the 80.000MB that are on the hard drive by 1100MB.that the computer seems to be 1B and we get 72.72GBs.

 

  1. What are the data types? Write down all the data types that are predefined in C++. /5marks

In computer programming, information is stored in a computer memory with different data types. We must know what is to be stored in a computer memory,whether it is a simple number, a letter or a very large number. As we also know, computer memory is organized in bytes, and for these variables with varying information a data type is associated. The minimum amount of memory in computer memory is a byte, that can store a small amount of data and managed easily. Every variable is declared with two entities, its type and its name. There are several data types available in C++. The basic built in data types are charint, float, double and bool. There is another data type void, which we will discuss some other time. C++ also allows user defined data types

  1. What are the output for the following fragments of codes:/3marks

a) int n, k=5;

   n=(100%k==0?k+1:k-1);

   cout<<“n=”<<n<<“k=”<<k<<endl;

   return 0;

output

n=6k=5

b) int n;

     float x=3.8;

     n=int(x);

     cout<<“n=”<<n<<endl;

     return 0;

output

n=3

c) int i=5, j=6, k=7, n=3;

     cout<<i+j*k-k%n<<endl;

     cout<<i/n<<endl;

     return 0;

output

46

1

  1. Describe two types of class members used in OOP and explain how they can be accessed in three different ways. /5marks

Data members and member functions

Private, public, protected

  1. Enumerate the procedures followed to create a new project in Visual Basics. /2marks

To create a project for your program

  • From the Windows Start menu, click Visual Basic 6.0
  • Click New Project.
  • On the File menu, The New Project dialog box opens.
  • Choose Standard.EXE project
  • Click open
  • Double click the form object
  • Type the program
  • Press F5 to run the program.
  1. Explain the following terms: /2marks
  2. is a group of statements designed to perform a specific task.
  3. Assign the prefixes for controls and data types as used in VB: /2marks

cbo, pic, tmr, int

  1. Draw a flowchart for an algorithm for calculating the Greatest Common Divisor (GCD) of two numbers. The algorithm proceeds by successive subtractions in two loops: If the test A<=B yields “Yes” (or True), Then the algorithm specifies B<--B-A (meaning the number B-A replaces the old B). Similarly If A>B Then A<--A-B. The process terminates when the content of B is 0, yielding the GCD in A. /5marks

 

 

 

 

  1. What are the function of the following commands:/3marks


a) ls: display the list of files

b) cd: change directory

c) cp: copy a file or directory

d) cat: displays content of a file

e) ipconfig: used to display the IP Address

f) ping: Ping is a basic Internet program that allows a user to verify that a particular IP address exists and can accept requests .

Ping is a computer network administration software utility used to test the reachability of a host on an Internet Protocol (IP) network.



 

 

 

 

SECTION B: Answer any three questions for your choice /30 marks

  1. Knowing that the formula to compute the volume of a cylinder is v=pi*(r^2)*h. Where v=volume, pi=22/7, r=radius and h=height. Write a required code to make a Visual Basic program that calculates the volume of a cylinder. Starting by designing the interface for the user with three label boxes, three text boxes and one command Button(OK). When you run the program, you should be able to interact within the interface, So that if you enter a value each in the radius box and the height box, then click command button; the value of the volume will be displayed in the volume box.

NB: Using the function Str$. The declaration step is not required. /10marks

Private Sub OK_Click( )

r = Val(radius.Text)

h = Val(hght.Text)

pi = 22 / 7

v = pi * (r ^ 2) * h
volume.Text= Str$(v)

End Sub

  1. Write a program for an Automated Teller Machine while currencies are 5000, 2000 and 1000. /10marks

#include<stdio.h> /0.5marks

 int totalFiveThousand=100;

int totalTwoThousand=100;

int totalOneThousand=100;  /0.5marks

 int main()

{

     unsigned long withdrawAmount;

    unsigned long totalMoney;

     int fivethousand=0,twothousand=0,onethousand=0; /0.5marks

     printf("Enter the amount in multiple of 1000: ");/0.5marks

    scanf("%lu", &withdrawAmount); /0.5marks

     if(withdrawAmount%1000 !=0) /0.5marks

      {

         printf("Invalid amount;"); /0.5marks

         return 0;

       }

     totalMoney=totalFiveThousand*5000 + totalTwoThousand*2000+totalOneThousand*1000; /1mark

     if(withdrawAmount> totalMoney) /0.5marks

{

         printf("Sorry,Insufficient money"); /0.5marks

         return 0;

    }

     fivethousand = withdrawAmount / 5000; /0.5marks

    if(fivethousand > totalFiveThousand) /0.5marks

         fivethousand = totalFiveThousand;

    withdrawAmount = withdrawAmount - fivethousand *5000; /0.5marks

     if (withdrawAmount> 0)

     {

         twothousand = withdrawAmount / 2000; /0.5marks

         if(twothousand> totalTwoThousand) /0.5marks

             twothousand = totalTwoThousand;

         withdrawAmount = withdrawAmount - twothousand * 2000; /0.5marks

    }

     if (withdrawAmount> 0)

         onethousand= withdrawAmount /1000;  /0.5marks

     printf("Total 5000 notes: %d\n", fivethousand);

    printf("Total  2000 notes: %d\n", twothousand);

    printf("Total  1000 notes: %d\n", onethousand); /1mark

     return 0;

}

  1. Based on the employees table below
employee_number first_name last_name Age salary dept_id
1001 John Smith 32 62000 500
1002 Jane Anderson 35 57500 500
1003 Brad Everest 45 71000 501
1004 Jack Horvath 47 42000 501

Write SQL statements to:

  1. Create the above table

CREATE TABLE employees

(employee_number VARCHAR(64),

first_name     CHAR(10),
last_name     CHAR(64),
Age   INTEGER,
salary INTEGER,
dept_id  CHAR(64),
PRIMARY KEY (employee_number) )

  1. Display first name and age for everyone whose name is in the table.

SELECT * FROM employees;

  1. select all fields from the employees table whose salary is less than or equal to 52,500 .

SELECT * FROM employees WHERE salary<=52,500;

  1. d)insert into employees the following values 1001, Smith, John, 62000, 500.

INSERT INTO employees VALUES (1001, ‘Smith’, ‘John’, 62000, 500);

  1. Select first , last names and salary for everyone whose last name ends with th.

SELECT first_name, last_name, salary FROM employees WHERE last_name LIKE’%th’;

  1. Select all columns for everyone over 35 years old

SELECT * FROM employees WHERE Age>35 ;

  1. Select first name for everyone whose first name equals Jane.

SELECT first_name FROM employees WHERE first_name= ‘Jane’;

  1. Select all columns for everyone whose last name contains est.

SELECT * FROM employees WHERE last_name’% est%’;

  1. Remove all employees who are earning over 70,000.00.

DELETE FROM employees WHERE salary>70,000.00;

  1. j)Delete an entire table

DROP TABLE employees;

  1. Based on the relation A, B and C, answer the following questions. /10marks

A

A1 A2 A3
1 12 100
2 16 102
3 16 103
4 19 104

B

B1 B2
22 214
24 216
27 284
29 216

C

C1 C2 C3
31 401 1006
32 401 1025
33 405 1065
  1. You have relations A,B and C .show the resulting relation if you apply the following SQL statements. Select B1 from B where B2=216.
  2. You have relations A,B and C .show the resulting relation if you apply the following SQL statements. Select A3 from A .
  3. You have relations A,B and C .show the resulting relation if you apply the following SQL statements. Update C set C1=37 where C1=31.
  4. You have relations A,B and C .show the resulting relation if you apply the following SQL statements. Select * from A union select *from B.
  5. You have relations A,B and C .show the resulting relation if you apply the following SQL statements. INSERT INTO C (C1, C2,C3) VALUES (‘35’, ‘407’, ‘1050’).

 

RESULTS

B1
24
A3
100
102
103
104
C1 C2 C3
37 401 1006
32 401 1025
33 405 1065
A1 A2 A3 B1 B2

1

12 100 22 214
2 16 102 24 216
3 16 103 27 284
4 19 104 29 216
C1 C2 C3
31 401 1006
32 401 1025
33 405 1065
35 407 1050

 

SECTION C: Answer any One Question/15 marks

  1. Write a C++ program to implement a circle class. Each object of this class will represent a circle, storing its radius and the x and y coordinate of its center as floats. Include two access functions for:

i. Calculating area of circle.

ii. Calculating the circumference of circle.

#include <iostream>
#include <iostream>
#include <cmath>
#define PI 3.142
usingnamespace std;
class Circle
{
        private:
        int r; //Data Members, declare r as an integer
        float area, cir, x, y; //declare area, cir, x and y as floats
           public:
               Circle(); // Constructor
               Circle(float, float, int);
               float getCirc();
               float getArea();
};
// Function Definitions
Circle :: Circle() // Constructor function
{
        r = 0;
        area = 0.0;
        cir = 0.0;
        x = 0.0;
        y = 0.0;
}
Circle::Circle(float x_, float y_, int r_) {
        x=x_;
        y=y_;
        r=r_;
}
float Circle::getArea() {
        return (float)M_PI*r*r;
}
float Circle::getCirc() {
        return (float)(2*M_PI*r);
}
int main()
{
        Circle c(1, 2, 3); // c is an object of class Circle
        cout << "The area is " << c.getArea() << endl;
        cout << "The circumference is " << c.getCirc() << endl;
        return 0;
}
24.

 

.........................................................................................................................................


  Umwihariko wa Gahogo Adventist Academy/ Fees Payment Modes/Amatangazo/Announcements


Academic Calendar

IMBONERAHAMWE IGARAGAZA  UKO UMWAKA W'AMASHURI 2015 UGABANIJE /A CHART SHOWING DIVISIONS FOR THE  2016 SHOOL YEAR/ TABLEAU INDIQUANT LE CALENDRIER DE L'ANNEE SCOLAIRE 2016

IMBONERAHAMWE IGARAGAZA  UKO UMWAKA W'AMASHURI 2015 UGABANIJE /A CHART SHOWING DIVISIONS FOR THE  2015 SHOOL YEAR/ TABLEAU INDIQUANT LE CALENDRIER DE L'ANNEE SCOLAIRE 2015

IGIHEMBWE CY'UMWAKA AMATARIKI UKO KINGANA
Igice cya mbere cy'igihembwe cya mbere   26/01/2015-03/04/2015  Ibyumweru 10
Ikiruhuko cya mbere   04/04/2015-19/04/2015  Ibyumweru 2
 Igihembwe cya 2  20/04/2015-31/07/2015  Ibyumweru 14
 Ikiruhuko cya kabiri  01/08/2015-16/11/2015  Ibyumweru 2
 Igihembwe cya gatatu   17/08/2015-06/11/2015  Ibyumweru 12
 Ibizamini bya Leta ku barangiza amashuri abanza  03/11/2015-05/11/2015  Iminsi 3
 Ibizamini bya Leta ku barangiza icyiciro rusange n'abarangiza A2  11/11/2015-20/11/2015  Ibyumweru 2

 NB: Umwaka w'amashuri ugizwe n'ibyumweru 36 (10 by'igihembwe cya mbere, 14 by'igihembwe cya kabiri na 12 by'igihembwe cya 3)

 


Umwihariko wa Gahogo Adventist Academy/ Fees Payment Modes/ Amatangazo/Announcements

 

Contacts

Head Teacher

+250 788 659 851