Bmit 226: Business Programming Question Paper

Bmit 226: Business Programming 

Course:Bachelor Of Business Management And Information Technology

Institution: Kabarak University question papers

Exam Year:2009



UNIVERSITY EXAMINATIONS
2009/2010 ACADEMIC YEAR
FOR THE DEGREE OF BACHELOR OF BUSINESS MANAGEMENT
& INFORMATION TECHNOLOGY & BACHELOR OF
ENVIRONMENTAL SCIENCE
COURSE CODE: BMIT 226

COURSE TITLE: BUSINESS PROGAMMING

STREAM: Y2S2, Y3S1, Y3S2, Y4S1 & Y4S2

DAY: THURSDAY

TIME: 9.00 – 12.00 P.M.

DATE: 10/12/2009

INSTRUCTIONS:
 Answer question ONE (COMPULSORY) and answer ANY TWO questions.

QUESTION ONE (40 marks)

a. Explain steps used to execute a C program [4 marks]

b. Write the syntax of do while statement and explain it [4 marks]

c. Explain any four derived data types used in C language [4 marks]

d. An electric power distribution company charges its domestic consumers as follows:

Consumption units Rate of charge (Ksh)
0-200 0.50 per unit
201 -400 100 plus 0.65 per unit
401 – 600 230 plus 0.80 per unit
Excess of 400
601 and above 390 plus 1.00 per unit
Excess of 600
Write a program that reads customer number and power consumed and prints amount to
be paid by the customer. [8 marks]


e. (i) What is a keyword? [2 marks]
(ii) State four examples ( ½ mark each) [2 marks]

f. Describe the following functions . [6 marks]
(i) Call by value
(ii) Call by reference
(iii) Inline function
g. Write a c++ program to find the largest value of any three numbers entered by the user
through the keyboard. [6 marks]

h. Write notes on Data abstraction and encapsulation [4 marks]


SECTION B ANSWER ANY TWO QUESTIONS

QUESTION TWO (20 Marks)

a) (i) What is an array? [2 marks]
(ii) State rules used when declaring an array? (4*1/2) [2 marks]

b).(i) What is a Pointer [ 2 marks]
(ii) Describe the advantages of using pointers [4 marks]

c) Write a c++ program to find factorial of given number [6 marks]

d) Write C LANGUAGE program to convert days into months and days [4 marks]


QUESTION THREE (20 Marks)

a) . Using switch statement write a c++ program to display the day depending ion the
choice entered by the user from the key board using else if statement [6 marks]

b) Discuss six principles of object oriented programming [6 marks]

c) What is a class? Describe its structure [4 marks]

d) “A program is a set of instructions” Discuss this statement in reference to
programming [4 marks]


QUESTION FOUR (20 Marks)

a) Using a suitable example describe a constant? [4 marks]

b) Explain the following terms
(i) Compiler
(ii)Translator [4 marks]

c) Discuss any three advantages for using functions in a program [3 marks]

d) Discuss any four types of operators in C language [4 marks]

e) Write a C language program to check whether the character entered is a vowel or not
[5 marks]


SECTION C ANSWER ANY TWO QUESTIONS

QUESTION FIVE (15 Marks)

a) (i) What is inheritance? [2 marks]
(ii) Discuss any four types of inheritance available in c++. [4 marks]

b) Write a C++ program to find the sum of first 100 natural Numbers using for loop
Statement [5marks]
c. (i) What is a constructor? [2 mark]
(ii) State three rules to be observed when declaring a constructor. [3 marks]

QUESTION SIX (15 Marks)
a. (i) What is Identifiers? [1 marks]
(ii) What are rules used naming a identifiers [2 marks]

b. Describe enumerated data type as used in C++ [4 marks]

c. Write a c++ program to find factorial of given number [6 marks]

d. What is a string [2 mark]

QUESTION SEVEN (15 Marks)

a. Write the syntax of switch case statement and explain it [5 marks]

b. Write a program to calculate the area of triangle [4 marks]

c. Discuss elements of user defined functions [2 marks]

d. (i) Describe predefined functions [2 marks]
(ii) When are they used in a program [2 marks]






More Question Papers


Popular Exams


Mid Term Exams

End Term 1 Exams

End Term 3 Exams

Opener Exams

Full Set Exams



Return to Question Papers