Fetch the repository succeeded.
{
"data": {
"question": {
"questionId": "619",
"questionFrontendId": "619",
"boundTopicId": null,
"title": "Biggest Single Number",
"titleSlug": "biggest-single-number",
"content": "<p>Table: <code>MyNumbers</code></p>\n\n<pre>\n+-------------+------+\n| Column Name | Type |\n+-------------+------+\n| num | int |\n+-------------+------+\nThis table may contain duplicates (In other words, there is no primary key for this table in SQL).\nEach row of this table contains an integer.\n</pre>\n\n<p> </p>\n\n<p>A <strong>single number</strong> is a number that appeared only once in the <code>MyNumbers</code> table.</p>\n\n<p>Find the largest <strong>single number</strong>. If there is no <strong>single number</strong>, report <code>null</code>.</p>\n\n<p>The result format is in the following example.</p>\n<ptable> </ptable>\n<p> </p>\n<p><strong class=\"example\">Example 1:</strong></p>\n\n<pre>\n<strong>Input:</strong> \nMyNumbers table:\n+-----+\n| num |\n+-----+\n| 8 |\n| 8 |\n| 3 |\n| 3 |\n| 1 |\n| 4 |\n| 5 |\n| 6 |\n+-----+\n<strong>Output:</strong> \n+-----+\n| num |\n+-----+\n| 6 |\n+-----+\n<strong>Explanation:</strong> The single numbers are 1, 4, 5, and 6.\nSince 6 is the largest single number, we return it.\n</pre>\n\n<p><strong class=\"example\">Example 2:</strong></p>\n\n<pre>\n<strong>Input:</strong> \nMyNumbers table:\n+-----+\n| num |\n+-----+\n| 8 |\n| 8 |\n| 7 |\n| 7 |\n| 3 |\n| 3 |\n| 3 |\n+-----+\n<strong>Output:</strong> \n+------+\n| num |\n+------+\n| null |\n+------+\n<strong>Explanation:</strong> There are no single numbers in the input table so we return null.\n</pre>\n",
"translatedTitle": null,
"translatedContent": null,
"isPaidOnly": false,
"difficulty": "Easy",
"likes": 497,
"dislikes": 170,
"isLiked": null,
"similarQuestions": "[]",
"exampleTestcases": "{\"headers\": {\"MyNumbers\": [\"num\"]}, \"rows\": {\"MyNumbers\": [[8],[8],[3],[3],[1],[4],[5],[6]]}}\n{\"headers\": {\"MyNumbers\": [\"num\"]}, \"rows\": {\"MyNumbers\": [[8],[8],[7],[7],[3],[3],[3]]}}",
"categoryTitle": "Database",
"contributors": [],
"topicTags": [
{
"name": "Database",
"slug": "database",
"translatedName": null,
"__typename": "TopicTagNode"
}
],
"companyTagStats": null,
"codeSnippets": [
{
"lang": "MySQL",
"langSlug": "mysql",
"code": "# Write your MySQL query statement below\n",
"__typename": "CodeSnippetNode"
},
{
"lang": "MS SQL Server",
"langSlug": "mssql",
"code": "/* Write your T-SQL query statement below */\n",
"__typename": "CodeSnippetNode"
},
{
"lang": "Oracle",
"langSlug": "oraclesql",
"code": "/* Write your PL/SQL query statement below */\n",
"__typename": "CodeSnippetNode"
},
{
"lang": "Pandas",
"langSlug": "pythondata",
"code": "import pandas as pd\n\ndef biggest_single_number(my_numbers: pd.DataFrame) -> pd.DataFrame:\n ",
"__typename": "CodeSnippetNode"
},
{
"lang": "PostgreSQL",
"langSlug": "postgresql",
"code": "-- Write your PostgreSQL query statement below\n",
"__typename": "CodeSnippetNode"
}
],
"stats": "{\"totalAccepted\": \"129.6K\", \"totalSubmission\": \"223.6K\", \"totalAcceptedRaw\": 129566, \"totalSubmissionRaw\": 223574, \"acRate\": \"58.0%\"}",
"hints": [],
"solution": {
"id": "188",
"canSeeDetail": false,
"paidOnly": true,
"hasVideoSolution": false,
"paidOnlyVideo": true,
"__typename": "ArticleNode"
},
"status": null,
"sampleTestCase": "{\"headers\": {\"MyNumbers\": [\"num\"]}, \"rows\": {\"MyNumbers\": [[8],[8],[3],[3],[1],[4],[5],[6]]}}",
"metaData": "{\"mysql\": [\"Create table If Not Exists MyNumbers (num int)\"], \"mssql\": [\"Create table MyNumbers (num int)\"], \"oraclesql\": [\"Create table MyNumbers (num int)\"], \"database\": true, \"name\": \"biggest_single_number\", \"pythondata\": [\"MyNumbers = pd.DataFrame([], columns=['num']).astype({'num':'Int64'})\"], \"postgresql\": [\"Create table If Not Exists MyNumbers (num int)\"], \"database_schema\": {\"MyNumbers\": {\"num\": \"INT\"}}}",
"judgerAvailable": true,
"judgeType": "large",
"mysqlSchemas": [
"Create table If Not Exists MyNumbers (num int)",
"Truncate table MyNumbers",
"insert into MyNumbers (num) values ('8')",
"insert into MyNumbers (num) values ('8')",
"insert into MyNumbers (num) values ('3')",
"insert into MyNumbers (num) values ('3')",
"insert into MyNumbers (num) values ('1')",
"insert into MyNumbers (num) values ('4')",
"insert into MyNumbers (num) values ('5')",
"insert into MyNumbers (num) values ('6')"
],
"enableRunCode": true,
"enableTestMode": false,
"enableDebugger": false,
"envInfo": "{\"mysql\": [\"MySQL\", \"<p><code>MySQL 8.0</code>.</p>\"], \"mssql\": [\"MS SQL Server\", \"<p><code>mssql server 2019</code>.</p>\"], \"oraclesql\": [\"Oracle\", \"<p><code>Oracle Sql 11.2</code>.</p>\"], \"pythondata\": [\"Pandas\", \"<p>Python 3.10 with Pandas 2.0.2 and NumPy 1.25.0</p>\"], \"postgresql\": [\"PostgreSQL\", \"<p>PostgreSQL 16</p>\"]}",
"libraryUrl": null,
"adminUrl": null,
"challengeQuestion": null,
"__typename": "QuestionNode"
}
}
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。