Leetcode 597. 好友申请 I:总体通过率(round,计数)

2021-04-20 10:59:42 浏览数 (1)

代码语言:javascript复制
select 
    round(
        ifnull(
            1/(count(
                distinct f1.sender_id,f1.send_to_id)
                /count(distinct r1.requester_id,r1.accepter_id)),0),2)                    
     accept_rate

    from friendrequest f1 , requestaccepted r1

0 人点赞