Page 421 - Ai_417_V3.0_C9_Flipbook
P. 421
4. Name the steps involved in computer problem-solving.
Ans. Computer problem-solving involves several steps, which are as follows:
• Understanding the problem
• Analysing the problem
• Developing the solution
• Coding and implementation
5. How did Python get its name?
Ans. Guido van Rossum designed Python and released in 1991. He wanted to give a unique name to it. So, he named it after
the famous BBC comedy TV show "Monty Python's Flying Circus".
6. Why is Python considered as a high-level language?
Ans. Python is a high-level and general-purpose programming language which simplifies the process of developing a
program. The code written in Python is more close to human language and away from machine language.
7. Name different modes of working in Python.
Ans. The two different modes of working in Python are:
• Interactive Mode
• Script Mode
8. What are tokens in Python? Name a few of them.
Ans. Tokens are the smallest meaningful unit of a program. Tokens supported by Python are Keywords, Identifiers, Literals,
Operators and Punctuators.
9. What is the use of 'if' statement in Python?
Ans. In 'if' statement, a statement or block of statement will be executed only when the condition is True. If the condition is
False then nothing happens.
10. How is a block of statements identified in Selection or Iteration?
Ans. A block is identified by using an indentation (minimum 1 space). Ensure that all statements in one block are indented
at the same level.
11. What is iteration?
Ans. Iteration refers to the process of repeating a set of instructions based on a condition.
12 What is the use of the + operator with lists?
Ans. The + operator is used to concatenate a list with another list.
13. What do you mean by traversing a list?
Ans. Traversing a list means to visit each element and process it as required by a program.
14. What is the use of the pop( ) function?
Ans. The pop( ) function removes an element from the list based on the index number specified in the function and returns
the deleted value.
B. Long answer type questions:
1. What is sequential flow? Explain with an example.
Introduction to Python 419

