Symptom
Courses with level 1 (e.g., "Intro to Git & GitHub") always get a recommendation score of 0 using PopularityStrategy. Level 2 gets 10.
Expected: Level 1 should produce a base score of 10 (level * 10).
Context
The scoring system uses a Template Method pattern. The base class Strategy orchestrates the pipeline:
baseScore()-- subclass computes initial scoreapplyLevelWeight()-- multiplies by clamped level weightapplyDeadlinePenalty()-- urgency boostapplyInstructorAdjustment()-- self-paced bonusfinalAdjustments()-- subclass hook
PopularityStrategy only overrides baseScore(). Focus there.
Hints
TypeScript
TypeScript ready
Test Output
▶
Click "Run Tests" to execute your code