Skip to main content
Journey Uncommon Logo
JourneyUncommon
hardJavaScriptToPrimitive coercion algorithmSingle-choice MCQ

What does the ToPrimitive abstract operation use as the default hint when an object is the operand of `+` with a string, and which method is tried first under that hint?

const o = { valueOf() { return 'V'; }, toString() { return 'T'; } }; const r = o + ''; // r === ?