COPA programming in python Page-3 Question Bank

11.  What happens while trying to retrieve a value using the expression d[“susan”] in the following code?
d = {“ajay”:40, “vijay”:45}
निम्नलिखित कोड में अभिव्यक्ति d[“susan”] का उपयोग करके मान प्राप्त करने का प्रयास करते समय क्या होता है?
d = {“ajay”:40, “vijay”:45}  [NCVT Exam 24]

(A) Python raises a null exception
 पायथन एक शून्य अपवाद उठाता है
(B) It is executed fine and no exception is raised,
 इसे ठीक से क्रियान्वित किया गया है और कोई अपवाद नहीं उठाया गया है,
(C) Python raises a syntax error
 Python एक सिंटैक्स त्रुटि उत्पन्न करता है
(D) Python raises a KeyError exception
 Python एक KeyError अपवाद उठाता है

12.  What is Debugging?
डिबगिंग क्या है?  [NCVT Exam 25]

(A) Creating Program Code
 क्रिएटिंग प्रोग्राम कोड
(B) Identifying The Task To Be Computerized
 कंप्यूटराइज्ड होने के लिए टास्क की पहचान करना
(C) Finding and Correcting Errors In The Program Code
 प्रोग्राम कोड में एरर को खोजना और सुधारना
(D) Creating The Algorithm
 एल्गोरिथम क्रिएट करना

13.  Which character gives single-line comments in Python?
पायथन में कौन सा कैरेक्टर सिंगल-लाइन कमेंट देता है?  [NCVT Exam 25]

(A) /*
(B) !
(C) //
(D) #

14.  Which of the following is true for variable names in Python?
पायथन में वेरिएबल नामों के लिए निम्न में से कौन सा सही है?  [NCVT Exam 25]

(A) ( - ) and ( & ) are the only two special characters allowed
 ( - ) और ( & ) केवल दो विशेष करैक्टर की अनुमति है
(B) Start variable name by space
 वैरिएबल नाम को स्पेस से प्रारंभ करना
(C) Case-insensitive
 केस-इंसेन्सिटिव
(D) Unlimited Length
 असीमित लंबाई