{ "data": { "question": { "questionId": "602", "questionFrontendId": "602", "boundTopicId": null, "title": "Friend Requests II: Who Has the Most Friends", "titleSlug": "friend-requests-ii-who-has-the-most-friends", "content": null, "translatedTitle": null, "translatedContent": null, "isPaidOnly": true, "difficulty": "Medium", "likes": 249, "dislikes": 73, "isLiked": null, "similarQuestions": "[]", "exampleTestcases": "{\"headers\":{\"RequestAccepted\":[\"requester_id\",\"accepter_id\",\"accept_date\"]},\"rows\":{\"RequestAccepted\":[[1,2,\"2016/06/03\"],[1,3,\"2016/06/08\"],[2,3,\"2016/06/08\"],[3,4,\"2016/06/09\"]]}}", "categoryTitle": "Database", "contributors": [], "topicTags": [ { "name": "Database", "slug": "database", "translatedName": null, "__typename": "TopicTagNode" } ], "companyTagStats": null, "codeSnippets": null, "stats": "{\"totalAccepted\": \"48.8K\", \"totalSubmission\": \"80.4K\", \"totalAcceptedRaw\": 48834, \"totalSubmissionRaw\": 80375, \"acRate\": \"60.8%\"}", "hints": [ "Being friends is bidirectional. If you accept someone's adding friend request, both you and the other person will have one more friend." ], "solution": null, "status": null, "sampleTestCase": "{\"headers\":{\"RequestAccepted\":[\"requester_id\",\"accepter_id\",\"accept_date\"]},\"rows\":{\"RequestAccepted\":[[1,2,\"2016/06/03\"],[1,3,\"2016/06/08\"],[2,3,\"2016/06/08\"],[3,4,\"2016/06/09\"]]}}", "metaData": "{\n \"mysql\": [\n \"Create table If Not Exists RequestAccepted (requester_id int not null, accepter_id int null, accept_date date null)\"\n ],\n \"mssql\": [\n \"Create table RequestAccepted (requester_id int not null, accepter_id int null, accept_date date null)\"\n ],\n \"oraclesql\": [\n \"Create table RequestAccepted (requester_id int not null, accepter_id int null, accept_date date null)\",\n \"Alter SESSION set NLS_DATE_FORMAT = 'YYYY/MM/DD'\"\n ],\n \"database\": true\n}", "judgerAvailable": true, "judgeType": "large", "mysqlSchemas": [ "Create table If Not Exists RequestAccepted (requester_id int not null, accepter_id int null, accept_date date null)", "Truncate table RequestAccepted", "insert into RequestAccepted (requester_id, accepter_id, accept_date) values ('1', '2', '2016/06/03')", "insert into RequestAccepted (requester_id, accepter_id, accept_date) values ('1', '3', '2016/06/08')", "insert into RequestAccepted (requester_id, accepter_id, accept_date) values ('2', '3', '2016/06/08')", "insert into RequestAccepted (requester_id, accepter_id, accept_date) values ('3', '4', '2016/06/09')" ], "enableRunCode": true, "enableTestMode": false, "enableDebugger": false, "envInfo": "{\"mysql\": [\"MySQL\", \"

MySQL 8.0.

\"], \"mssql\": [\"MS SQL Server\", \"

mssql server 2019.

\"], \"oraclesql\": [\"Oracle\", \"

Oracle Sql 11.2.

\"]}", "libraryUrl": null, "adminUrl": null, "challengeQuestion": null, "__typename": "QuestionNode" } } }