- Find the option(s) which will give error:
- raise="NO"
- assert=50
- my#Marks=50
- 9_90=5
- Is Python case sensitive when dealing with identifiers?
- yes
- no
- machine-dependent
- none of the mentioned
- What will be the output of the following python command:
>>> "*".join("Hello") i) "Hello*" ii) "*Hello" iii) Error iv) None of these
-
What is the output of :
S = “COMPUTER SCIENCE”
Print(S[-10:5:-2])
- 'E'
- '' (Empty String)
- 'CS RE'
- 'C E'
- What is the output of :
S = "INFORMATICS PRACTICES" print(S[-9:5:-2]) i) 'PSIA' ii) '' (Empty String) iii) 'MTC' iv) ' CTM'
- What will be the output of the following python command:
>>> bool(5*5/5-5) or bool('5-5')
i) True
ii) False
iii) Error
iv) None of These - Find the output of the following :
word="green vegetables" print(word.find('g',2)) i) 0 ii) 8 iii) -1 iv) Error
- Write the valid identifier in the following:
i) My.File
ii) My-File
iii) 2um
iv) pie - Write the type of tokens from the following:
i) 12.6
ii) False - What type of objects can be used as keys in dictionaries?
- What are two ways to remove something from a list? Write syntax only for both.
- Convert the following for loop into a while loop :
1 2
for k in range (10,20,5) : print(k)
how to get the pdf of these
ReplyDelete