All challenges
Code AnalysisIntermediate 60s

LSP: widening (not narrowing) can also break

class Logger { log(msg: string, level='INFO') {} } class SilentLogger extends Logger { log(msg: string, level='ERROR', alsoToDisk=true) {} // changed default & added param } // Client calls log('x') -> now behaves as ERROR + disk. What contract issue arises?

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.

Play this in a 3-minute battle