You are on page 1of 5

Program Diploma in ICT Module Program Techniques -

Python
Student Registration
Name No
Marks

Instructions:

 Answer All Questions on this paper itself.


 Answers should submit in pdf format.
 Drawings (Flow Charts / Algorithms) can do in physical papers. They should scan and attached to
end of this paper.
 If not put all your work in one folder and submit the zipped folder.

1) Give one benefit of writing code in a low-level language.


………………………………………………………………………………………………………………………………………………………….
………………………………………………………………………………………………………………………………………………………….
………………………………………………………………………………………………………………………………………………………….
………………………………………………………………………………………………………………………………………………………….
2)
a. A program written in a high-level language is translated into machine code. This is so that it
can be processed by a computer.
Name one type of translator that can be used.
………………………………………………………………………………………………………………………………………………
b. Describe how your answer to part (a) translate this program.
………………………………………………………………………………………………………………………………………………
………….
………………………………………………………………………………………………………………………………………………
………….
………………………………………………………………………………………………………………………………………………
………….………………………………………………………………………………………………………………
3) Which of the following is not an OOPS concept?
a. Encapsulation
b. Polymorphism
c. Exception
d. Abstraction

4) Write down the attributes and objects for the object ‘book’
a. Attributes
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………

b. Methods
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………

5) Name 03 sub classes for ‘Hospital’ class

………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………

6) Explain the concept of inheritance with a real-life example.


………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………

7) Write down an algorithm for “Wash your hands”


………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………
………………………………………………………………………………………………………………………………………………

8) The flow chart on the right is meant to show the steps for stopping working on a computer and
shutting it down.
- Place the instructions below in the flow chart.
- Some of the instructions are not required - you should only include those which are relevant to
the task.
Start
Quit the Check your
Program email

Switch off the Turn on the


machine computer

Finish working Select ‘shut


on your down’
document

Start a new Save your work


document on a disk

End
9) Draw a flow chart to show the steps for safely crossing the road.
10) Draw a flowchart to log in to Facebook account. Algorithm in given for your reference.

1 Enter www.facebook.com in your browser.  (I/O)


2 facebook Home page loads   (PROCESS)

3 Enter your Email ID and Password    (I/O)

4 Is Email ID and Password Valid (DECISION)


if NO then
Log in error  (PROCESS)
go to step 3
else
Display facebook Account (I/O)
Stop

You might also like