What are the distinct student ids for students who have gotten a "B" grade?
select distinct stuid from enrolled_in where grade = "B"
How many are there?
select count(distinct stuid) from enrolled_in where grade = "B"