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

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

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

select music_name from ( select distinct music_id, music_name

from ( select f1.user_id,f1.follower_id,ml.music_id,mc.music_name from follow as f1 join music_likes as ml

on f1.follower_id = ml.user_id join music as mc on ml.music_id = mc.id

where ml.music_id not in ( select ml.music_id from follow as f1 join music_likes as ml

on f1.user_id = ml.user_id where f1.user_id = 1 ) ) cc1 where cc1.user_id = 1) cc2 order by music_id

全部评论

相关推荐

评论
1
收藏
分享

创作者周榜

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