Available question text
For each teacher, compute how many distinct subjects they teach across all departments — i.e., group by teacher_id and count the unique subject_id values. Return each teacher_id with its count.
Related questions
Continue with questions that share topics or the same question type.
- Count Number of Rectangles Containing Each Point
Coding
- First Unique Number
Coding · Array · Data Stream · Design
- Largest Unique Number
Coding
- Least Number of Unique Integers after K Removals
Coding
Sources · 1 reference
These records explain where the question appears. A company tag or candidate report does not guarantee a future interview question.
Hello Interview · 1 record
No company association
Leetcode 2356. Number of Unique Subjects Taught by Each Teacher
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source