mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-09-02 22:13:28 +08:00
update
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
"translatedContent": "<p>请你编写一个程序来计算两个日期之间隔了多少天。</p>\n\n<p>日期以字符串形式给出,格式为 <code>YYYY-MM-DD</code>,如示例所示。</p>\n\n<p> </p>\n\n<p><strong>示例 1:</strong></p>\n\n<pre><strong>输入:</strong>date1 = "2019-06-29", date2 = "2019-06-30"\n<strong>输出:</strong>1\n</pre>\n\n<p><strong>示例 2:</strong></p>\n\n<pre><strong>输入:</strong>date1 = "2020-01-15", date2 = "2019-12-31"\n<strong>输出:</strong>15\n</pre>\n\n<p> </p>\n\n<p><strong>提示:</strong></p>\n\n<ul>\n\t<li>给定的日期是 <code>1971</code> 年到 <code>2100</code> 年之间的有效日期。</li>\n</ul>\n",
|
||||
"isPaidOnly": false,
|
||||
"difficulty": "Easy",
|
||||
"likes": 46,
|
||||
"likes": 47,
|
||||
"dislikes": 0,
|
||||
"isLiked": null,
|
||||
"similarQuestions": "[]",
|
||||
@@ -143,7 +143,7 @@
|
||||
"__typename": "CodeSnippetNode"
|
||||
}
|
||||
],
|
||||
"stats": "{\"totalAccepted\": \"10.4K\", \"totalSubmission\": \"20.6K\", \"totalAcceptedRaw\": 10393, \"totalSubmissionRaw\": 20603, \"acRate\": \"50.4%\"}",
|
||||
"stats": "{\"totalAccepted\": \"10.7K\", \"totalSubmission\": \"21.3K\", \"totalAcceptedRaw\": 10731, \"totalSubmissionRaw\": 21334, \"acRate\": \"50.3%\"}",
|
||||
"hints": [
|
||||
"Create a function f(date) that counts the number of days from 1900-01-01 to date. How can we calculate the answer ?",
|
||||
"The answer is just |f(date1) - f(date2)|.",
|
||||
|
Reference in New Issue
Block a user