A

Admin • 828.03K Points
Coach

Q. What will `get_or_create()` return in Django?

  • (A) Only the object
  • (B) Only boolean
  • (C) Tuple (object, created)
  • (D) List of objects
  • Correct Answer - Option(C)
  • Views: 13
  • Filed under category Django
  • Hashtags:

Explanation by: Admin
`get_or_create()` returns a tuple containing the object and a boolean indicating if it was created.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.