题解 | 网易云音乐推荐(网易校招笔试真题)

网易云音乐推荐(网易校招笔试真题)

https://www.nowcoder.com/practice/048ed413ac0e4cf4a774b906fc87e0e7

with a as (select distinct 
id
,music_name 
from follow t
join music_likes t1 on t.follower_id=t1.user_id
join music t2 on t1.music_id=t2.id
where t.user_id=1 
and music_name not in (select music_name
from music_likes t
join music t1 on t.music_id=t1.id
where t.user_id=1 )
order by id)
select music_name from a 





全部评论

相关推荐

评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务