Quick Answer
Function-based views (FBV): simple Python functions receiving request, returning response. Easy to understand, explicit flow. Class-based views (CBV): inherit from generic views (ListView, DetailView, CreateView), less code for standard CRUD operations, mixins for reusability. FBV: better for custom or complex logic. CBV: better for standard CRUD where Django generic views save significant boilerplate.
Answer
Function-based views: simple and direct. Class-based views: reusable patterns, mixins, and structured handling of HTTP methods.
S
SugharaIQ Editorial Team
Verified Answer
This answer has been peer-reviewed by industry experts holding senior engineering roles to ensure technical accuracy and relevance for modern interview standards.