Quiz: Concepts and Constraints
Assess your knowledge gained in this section by attempting the quiz below.
What is the difference between a requires clause and a requires expression?
A requires clause specifies template parameters requires (parameter-list)
, and a requires expression defines the body of a function { requirement-seq }
.
A requires clause defines the body of a constraint { requirement-seq }
, and requires expression specifies requirement parameters requires (parameter-list)
.
A requires clause defines the constraints on the template parameters.
requires requirement
A requires expression can contain a sequence of requirements and uses curly branches, {}
.
requires { requirement-seq }
A requires clause can contain a sequence of requirements and uses curly branches, {}
.
requires { requirement-seq }
A requires expression defines the constraints on the template parameters.
requires requirement
Get hands-on with 1200+ tech skills courses.