Multiple ChoiceBeginner 45s
Aggregate vs constructor initialization
As of C++20, an aggregate is a class that:
Options
- 1has virtual functions, which is allowed as long as every data member remains public
- 2has private non-static data members, provided no base class and no functions are declared
- 3has no user-declared or inherited constructors (plus other conditions), allowing brace init
- 4cannot be initialized with braces, since aggregate init needs no user constructor
Think you can answer under pressure?
Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.