Python Programming - Standard Libraries
Exercise : Standard Libraries - General Questions
- Standard Libraries - General Questions
56.
Which module in Python provides functions for working with the file system, such as copying, moving, and deleting files?
Answer: Option
Explanation:
The
shutil
module in Python provides functions for working with the file system, such as copying, moving, and deleting files.
57.
What is the purpose of the
collections.ChainMap
class?
Answer: Option
Explanation:
The
collections.ChainMap
class in Python is used to chain multiple dictionaries into a single view, allowing you to access them as a single dictionary.
58.
Which method is used to join elements of a list into a single string?
Answer: Option
Explanation:
The
join()
method is used to join elements of a list into a single string in Python.
59.
What is the purpose of the
contextlib
module?
Answer: Option
Explanation:
The
contextlib
module in Python provides utilities for working with context managers, including the contextlib.contextmanager
decorator.
60.
Which module in Python provides support for interacting with the operating system, including functions for file and directory manipulation?
Answer: Option
Explanation:
The
os
module in Python provides support for interacting with the operating system, including functions for file and directory manipulation.
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers