Report Bug

QusWhich of the following function of dictionary gets all the keys from the dictionary? Qusनिम्नलिखित में से डिक्शनरी का कौन सा फंक्शन सभी कीज को डिक्शनरी से प्राप्त करता है?


A. getkeys ()
B. key()
C. keys()
D. None


Solution
C. keys()



Explanation

In Python, the keys() function is a built-in method for dictionaries. It returns a view object that displays a list of all the keys in the dictionary. The order of the keys in the view is not guaranteed to be the same as the order in which they were inserted into the dictionary.

CCC Online Test 2021 CCC Practice Test Hindi Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Best Java Training Institute in Prayagraj (Allahabad) Best Python Training Institute in Prayagraj (Allahabad) O Level Online Test in Hindi Bank SSC Railway TET UPTET Question Bank career counselling in allahabad Sarkari Naukari Notification Best Website and Software Company in Allahabad Sarkari Exam Quiz