Which of the following can be used to import only a specific function or class from a module?

  • from module import function
  • import function from module
  • import module
  • import module.function
You can use 'from module import function' to import only a specific function or class from a module in Python.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *