1
0
mirror of https://gitee.com/coder-xiaomo/leetcode-problemset synced 2025-01-11 02:58:13 +08:00
Code Issues Projects Releases Wiki Activity GitHub Gitee
leetcode-problemset/leetcode/originData/[no content]array-upper-bound.json

54 lines
4.1 KiB
JSON
Raw Normal View History

2023-07-16 12:28:13 +08:00
{
"data": {
"question": {
"questionId": "2768",
"questionFrontendId": "2774",
"boundTopicId": null,
"title": "Array Upper Bound",
"titleSlug": "array-upper-bound",
"content": null,
"translatedTitle": null,
"translatedContent": null,
"isPaidOnly": true,
"difficulty": "Easy",
2023-12-09 18:42:21 +08:00
"likes": 15,
2023-07-16 12:28:13 +08:00
"dislikes": 1,
"isLiked": null,
"similarQuestions": "[{\"title\": \"Array Prototype Last\", \"titleSlug\": \"array-prototype-last\", \"difficulty\": \"Easy\", \"translatedTitle\": null}, {\"title\": \"Group By\", \"titleSlug\": \"group-by\", \"difficulty\": \"Medium\", \"translatedTitle\": null}, {\"title\": \"Snail Traversal\", \"titleSlug\": \"snail-traversal\", \"difficulty\": \"Medium\", \"translatedTitle\": null}]",
"exampleTestcases": "[3,4,5]\n5\n[1,4,5]\n2\n[3,4,6,6,6,6,7]\n6",
"categoryTitle": "JavaScript",
"contributors": [],
"topicTags": [],
"companyTagStats": null,
"codeSnippets": null,
2023-12-09 18:42:21 +08:00
"stats": "{\"totalAccepted\": \"751\", \"totalSubmission\": \"916\", \"totalAcceptedRaw\": 751, \"totalSubmissionRaw\": 916, \"acRate\": \"82.0%\"}",
2023-07-16 12:28:13 +08:00
"hints": [
"Inside the Array.prototype.upperBound function you have access to the \"this\" keyword. You can access array elements, values, and methods. For example \"this[0]\", \"this[1]\", \"this.length\", \"this.map()\", etc.",
"The most efficient way to solve this problem is with binary search.",
"Choose the middle element and check if it's less than or equal to the goal value. If so, you can rule out the left side of the array."
],
2023-12-09 18:42:21 +08:00
"solution": {
"id": "2115",
"canSeeDetail": true,
"paidOnly": false,
"hasVideoSolution": false,
"paidOnlyVideo": true,
"__typename": "ArticleNode"
},
2023-07-16 12:28:13 +08:00
"status": null,
"sampleTestCase": "[3,4,5]\n5",
"metaData": "{\n \"name\": \"upperBound\",\n \"params\": [\n {\n \"name\": \"nums\",\n \"type\": \"integer[]\"\n },\n {\n \"type\": \"integer\",\n \"name\": \"target\"\n }\n ],\n \"return\": {\n \"type\": \"integer\"\n },\n \"languages\": [\n \"javascript\",\n \"typescript\"\n ],\n \"manual\": true\n}",
"judgerAvailable": true,
"judgeType": "large",
"mysqlSchemas": [],
"enableRunCode": true,
"enableTestMode": false,
"enableDebugger": false,
"envInfo": "{\"javascript\": [\"JavaScript\", \"<p><code>Node.js 16.13.2</code>.</p>\\r\\n\\r\\n<p>Your code is run with <code>--harmony</code> flag, enabling <a href=\\\"http://node.green/\\\" target=\\\"_blank\\\">new ES6 features</a>.</p>\\r\\n\\r\\n<p><a href=\\\"https://lodash.com\\\" target=\\\"_blank\\\">lodash.js</a> library is included by default.</p>\\r\\n\\r\\n<p>For Priority Queue / Queue data structures, you may use 5.3.0 version of <a href=\\\"https://github.com/datastructures-js/priority-queue/tree/fb4fdb984834421279aeb081df7af624d17c2a03\\\" target=\\\"_blank\\\">datastructures-js/priority-queue</a> and 4.2.1 version of <a href=\\\"https://github.com/datastructures-js/queue/tree/e63563025a5a805aa16928cb53bcd517bfea9230\\\" target=\\\"_blank\\\">datastructures-js/queue</a>.</p>\"], \"typescript\": [\"Typescript\", \"<p><code>TypeScript 5.1.6, Node.js 16.13.2</code>.</p>\\r\\n\\r\\n<p>Your code is run with <code>--harmony</code> flag, enabling <a href=\\\"http://node.green/\\\" target=\\\"_blank\\\">new ES2022 features</a>.</p>\\r\\n\\r\\n<p><a href=\\\"https://lodash.com\\\" target=\\\"_blank\\\">lodash.js</a> library is included by default.</p>\"]}",
"libraryUrl": null,
"adminUrl": null,
"challengeQuestion": null,
"__typename": "QuestionNode"
}
}
}