Skip to content
Sharp

Classes and Objects · interview question

A teammate submits shaky factories code. Which review comment is the strongest?

Multiple choiceHardchapter-7-curatedpremiumclasses-and-objectsfactories
Choose one answer
Answer and explanation

Correct answer

A. Make the rule clearer and easier to explain. Use class methods when a named construction path explains the domain better than one raw initializer signature.

Why

The best review comment anchors the change to readability, correctness, and future maintenance. Forcing all construction through one overloaded initializer can make object creation harder to read.

Test yourself on Classes and Objects

A free test with instant, explained results. No account needed.

Start free test
All Classes and Objects questions →