0% found this document useful (0 votes)
55 views

Bit4205 Network Programming Extra 5

This document contains instructions and questions for a University examination on network programming and operating systems. Students must answer one question from Question One, and then any two other questions. The questions cover a range of topics including: the differences between procedure-oriented and object-oriented programming; exception handling mechanisms; networking protocols like UDP; UNIX/Linux commands and file systems; threads and mutexes; and Unix system calls. Students are asked to provide diagrams, code samples, and explanations to fully answer the questions.

Uploaded by

ashleykiki.ke
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
55 views

Bit4205 Network Programming Extra 5

This document contains instructions and questions for a University examination on network programming and operating systems. Students must answer one question from Question One, and then any two other questions. The questions cover a range of topics including: the differences between procedure-oriented and object-oriented programming; exception handling mechanisms; networking protocols like UDP; UNIX/Linux commands and file systems; threads and mutexes; and Unix system calls. Students are asked to provide diagrams, code samples, and explanations to fully answer the questions.

Uploaded by

ashleykiki.ke
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

UNIVERSITY EXAMINATION 2017/2018

SCHOOL OF COMPUTING AND INFORMATICS


DEPARTMENT OF INFORMATION TECHNOLOGY

BIT/ BBIT

UNIT CODE: BIT4205 UNIT TITLE: NETWORK PROGRAMMING

DATE: APRIL 2018 5 TIME: 2 HOURS

INSTRUCTIONS: ANSWER QUESTION ONE AND ANY OTHER TWO QUESTIONS

QUESTION ONE

a) Distinguish between procedure-oriented programming language and objected


i) Oriented.
ii) Language. (7 Marks)

b) With the help of a c++ language program derive a class-template program.


(7 Marks)
OR
a) What are the principals of Exception Handling Show Exception handling
mechanism? (10 Marks)

b) Define the following terms;


i. Encapsulation.
ii. Polymorphism.
iii. Inheritance. (6 Marks)

Library copy Page 1


QUESTION TWO

a) With the help of a diagram discuss UDP (user datagram protocol). (10 Marks)

b) Define the following terms;


i) Circuits
ii) Packets
iii) TCP
iv) IP (10 Marks)

OR

c) With the help of a diagram discuss and compare the OSI and TCP/IP reference
models. (20 Marks)

QUESTION THREE

a) Discuss any seven Unix/Linux directory and file handling commands.(10 Marks)

b) What are the components of Linux operating system? Also derive Linux file
systems. (10 Marks)

OR

a) Define the following terms;


i. Thread
ii. Pthread (5 Marks)

b) Explain the concept of pipelining in relation to socket development. (5 Marks)

c) With the help of program show pthread creation and termination. (10 Marks)

QUESTION FOUR

a) What are Mutex variables. (5 Marks)

b) With the help of sythax/routine show how to lock and unlock mutexes
(5 Marks)

Library copy Page 2


c) Discuss the following types of thread models
i. Delegation
ii. Peer-to-peer
iii. Pipeline
iv. Producer consumer
(10 Marks)

QUESTION FIVE

a) Discuss the system call functions in Unix. 20 Marks)

OR

b) Write a program of a simple stream client in Unix/Linux. (20 Marks)

Library copy Page 3

You might also like