Introduction to Python Class 11 Introduction to Python Class 11 Hello friends in this section we are sharing some important question related to introduction to python from basic which will helps you in understanding related to python basics. If you want to good score in Informatics practice you should read this question and practice this simple and basic python question, which will helps you in getting good marks in this subject.
Q1. Which of the following is not in Python Character Set.
a. Letters : A-Z or a – z b. Digits : 0 – 9
c. Whitespaces : blank space, tab etc d. Images : Vector
Q2. Which of the following is not the mode of interacting with python?
a. Interactive Mode b. Script Mode
c. Hybrid Mode d. None of the above Show Answer
Q3. Python supports dynamic typing.
a. True b. False
Q4. What will be the data type of the following variable?
A = ‘101’
a. Integer b. String
c. Float d. None of the above Show Answer
Q5. Write the output of the following: print(range(0,8,2))
a. 0,2,4,6 b. range(0, 8, 2)
c. Error d. None of the above
Q6. Which of the following is not correct about python?
a. Python is an open source language. b. Python is based on ABC language. c. Python is developed by Guido Van Rossum d. None of the above
Q7. Smallest element of of python coding is called __________
a. Identifiers b. Token
c. Keywords d. Delimiters
Q8. Which of the following is not a token?
a. // b. “X”
c. ## d. 23
Q9. Write the output of the following code: x=2 x=5 x=x+x print(x)
a. 7 b. 4
c. 10 d. Error
Q10. Write the output of the following code :
x=2
y=3
x+y+5
print(x+y)
a. 10 b. 5
c. Error d. None of the above
Q11. Which of the following symbol is used to write comment?
a. ? b. //
c. # d. ** Show Answer
Q12. Writing comments is mandatory in python programs(T/F)
a. True b. False
Q13. Each statement in python is terminated by ___________
a. Semicolon(;) b. Colon(:)
c. Comma(,) d. None of the above
Q14. Write the output of the following: print(‘Hello, world!’);print(“H”)
a. Hello world H b. Hello worldH
c. Hello world
H d. Error
Q15. _______ spaces should be left for indentation.
a. 3 b. 4 c. 5 d. 0
Q16. What type of error is returned by the following statement?
def abc(a):
print(a)
a. ErrorIndentation b. IndentationError
c. SpaceError d. No error in the given statement
Q17. return statement is mandatory in function definition.(T/F)
a. True b. False
Q18. Which keyword is used to define a function in python?
a. def b. define
c. new d. None of the above Show Answer
Q19. Write the output of the following:
a=8
def abc(a):
print(a)
abc(7)
a. 8 b. Error
c. No Output d. 7
Q20. Statement below “function definition” begin with spaces called _________________ a. Indentation b. Condition
c. Definition d. None of the above Show Answer
0 Comments