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.

Latest Current Affairs 2025 Online Exam Quiz for One day Exam Online Typing Test CCC Online Test Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Online MBA 2 years Online MCA Online BCA Best Website and Software Company in Allahabad