mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-01-25 17:50:26 +08:00
63 lines
6.1 KiB
JSON
63 lines
6.1 KiB
JSON
{
|
|
"data": {
|
|
"question": {
|
|
"questionId": "3302",
|
|
"questionFrontendId": "2995",
|
|
"categoryTitle": "Database",
|
|
"boundTopicId": 2591529,
|
|
"title": "Viewers Turned Streamers",
|
|
"titleSlug": "viewers-turned-streamers",
|
|
"content": null,
|
|
"translatedTitle": "观众变主播",
|
|
"translatedContent": null,
|
|
"isPaidOnly": true,
|
|
"difficulty": "Hard",
|
|
"likes": 0,
|
|
"dislikes": 0,
|
|
"isLiked": null,
|
|
"similarQuestions": "[]",
|
|
"contributors": [],
|
|
"langToValidPlayground": null,
|
|
"topicTags": [
|
|
{
|
|
"name": "Database",
|
|
"slug": "database",
|
|
"translatedName": "数据库",
|
|
"__typename": "TopicTagNode"
|
|
}
|
|
],
|
|
"companyTagStats": null,
|
|
"codeSnippets": null,
|
|
"stats": "{\"totalAccepted\": \"24\", \"totalSubmission\": \"45\", \"totalAcceptedRaw\": 24, \"totalSubmissionRaw\": 45, \"acRate\": \"53.3%\"}",
|
|
"hints": [],
|
|
"solution": null,
|
|
"status": null,
|
|
"sampleTestCase": "{\"headers\":{\"Sessions\":[\"user_id\",\"session_start\",\"session_end\",\"session_id\",\"session_type\"]},\"rows\":{\"Sessions\":[[101,\"2023-11-06 13:53:42\",\"2023-11-06 14:05:42\",375,\"Viewer\"],[101,\"2023-11-22 16:45:21\",\"2023-11-22 20:39:21\",594,\"Streamer\"],[102,\"2023-11-16 13:23:09\",\"2023-11-16 16:10:09\",777,\"Streamer\"],[102,\"2023-11-17 13:23:09\",\"2023-11-17 16:10:09\",778,\"Streamer\"],[101,\"2023-11-20 07:16:06\",\"2023-11-20 08:33:06\",315,\"Streamer\"],[104,\"2023-11-27 03:10:49\",\"2023-11-27 03:30:49\",797,\"Viewer\"],[103,\"2023-11-27 03:10:49\",\"2023-11-27 03:30:49\",798,\"Streamer\"]]}}",
|
|
"metaData": "{\"mysql\":[\"Create table If Not Exists Sessions (user_id int, session_start datetime, session_end datetime, session_id int, session_type ENUM('Viewer','Streamer'))\"],\"mssql\":[\"Create table Sessions (user_id int, session_start datetime, session_end datetime, session_id int, session_type varchar(20) NOT NULL CHECK (session_type in ('Viewer', 'Streamer' )))\"],\"oraclesql\":[\"Create table Sessions (user_id int, session_start date, session_end date, session_id int, session_type varchar(20) NOT NULL CHECK (session_type in ('Viewer', 'Streamer' )))\",\"ALTER SESSION SET nls_date_format='YYYY-MM-DD HH24:MI:SS'\"],\"database\":true,\"name\":\"count_turned_streamers\",\"pythondata\":[\"Sessions = pd.DataFrame([], columns=['user_id', 'session_start', 'session_end', 'session_id', 'session_type']).astype({'user_id':'Int64', 'session_start':'datetime64[ns]', 'session_end':'datetime64[ns]', 'session_id':'Int64', 'session_type':'object'})\\n\"],\"postgresql\":[\"Create table If Not Exists Sessions (user_id int, session_start timestamp, session_end timestamp, session_id int, session_type VARCHAR(50) CHECK (session_type IN ('Viewer','Streamer')))\\n\"],\"database_schema\":{\"Sessions\":{\"user_id\":\"INT\",\"session_start\":\"DATETIME\",\"session_end\":\"DATETIME\",\"session_id\":\"INT\",\"session_type\":\"ENUM('Viewer', 'Streamer')\"}}}",
|
|
"judgerAvailable": true,
|
|
"judgeType": "large",
|
|
"mysqlSchemas": [
|
|
"Create table If Not Exists Sessions (user_id int, session_start datetime, session_end datetime, session_id int, session_type ENUM('Viewer','Streamer'))",
|
|
"Truncate table Sessions",
|
|
"insert into Sessions (user_id, session_start, session_end, session_id, session_type) values ('101', '2023-11-06 13:53:42', '2023-11-06 14:05:42', '375', 'Viewer')",
|
|
"insert into Sessions (user_id, session_start, session_end, session_id, session_type) values ('101', '2023-11-22 16:45:21', '2023-11-22 20:39:21', '594', 'Streamer')",
|
|
"insert into Sessions (user_id, session_start, session_end, session_id, session_type) values ('102', '2023-11-16 13:23:09', '2023-11-16 16:10:09', '777', 'Streamer')",
|
|
"insert into Sessions (user_id, session_start, session_end, session_id, session_type) values ('102', '2023-11-17 13:23:09', '2023-11-17 16:10:09', '778', 'Streamer')",
|
|
"insert into Sessions (user_id, session_start, session_end, session_id, session_type) values ('101', '2023-11-20 07:16:06', '2023-11-20 08:33:06', '315', 'Streamer')",
|
|
"insert into Sessions (user_id, session_start, session_end, session_id, session_type) values ('104', '2023-11-27 03:10:49', '2023-11-27 03:30:49', '797', 'Viewer')",
|
|
"insert into Sessions (user_id, session_start, session_end, session_id, session_type) values ('103', '2023-11-27 03:10:49', '2023-11-27 03:30:49', '798', 'Streamer')"
|
|
],
|
|
"enableRunCode": true,
|
|
"envInfo": "{\"mysql\":[\"MySQL\",\"<p>\\u7248\\u672c\\uff1a<code>MySQL 8.0<\\/code><\\/p>\"],\"mssql\":[\"MS SQL Server\",\"<p>mssql server 2019.<\\/p>\"],\"oraclesql\":[\"Oracle\",\"<p>Oracle Sql 11.2.<\\/p>\"],\"pythondata\":[\"Pandas\",\"<p>Python 3.10 with Pandas 2.0.2 and NumPy 1.25.0<\\/p>\"],\"postgresql\":[\"PostgreSQL\",\"<p>PostgreSQL 16<\\/p>\"]}",
|
|
"book": null,
|
|
"isSubscribed": false,
|
|
"isDailyQuestion": false,
|
|
"dailyRecordStatus": null,
|
|
"editorType": "CKEDITOR",
|
|
"ugcQuestionId": null,
|
|
"style": "LEETCODE",
|
|
"exampleTestcases": "{\"headers\":{\"Sessions\":[\"user_id\",\"session_start\",\"session_end\",\"session_id\",\"session_type\"]},\"rows\":{\"Sessions\":[[101,\"2023-11-06 13:53:42\",\"2023-11-06 14:05:42\",375,\"Viewer\"],[101,\"2023-11-22 16:45:21\",\"2023-11-22 20:39:21\",594,\"Streamer\"],[102,\"2023-11-16 13:23:09\",\"2023-11-16 16:10:09\",777,\"Streamer\"],[102,\"2023-11-17 13:23:09\",\"2023-11-17 16:10:09\",778,\"Streamer\"],[101,\"2023-11-20 07:16:06\",\"2023-11-20 08:33:06\",315,\"Streamer\"],[104,\"2023-11-27 03:10:49\",\"2023-11-27 03:30:49\",797,\"Viewer\"],[103,\"2023-11-27 03:10:49\",\"2023-11-27 03:30:49\",798,\"Streamer\"]]}}",
|
|
"__typename": "QuestionNode"
|
|
}
|
|
}
|
|
} |