ee.Array.sort
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
यह फ़ंक्शन, ऐरे के एलिमेंट को एक ऐक्सिस के हिसाब से क्रम में लगाता है.
इस्तेमाल | रिटर्न |
---|
Array.sort(keys) | Array |
आर्ग्यूमेंट | टाइप | विवरण |
---|
यह: array | Array | सॉर्ट करने के लिए इमेज का ऐरे. |
keys | ऐरे, डिफ़ॉल्ट: null | क्रम से लगाने के लिए वैकल्पिक कुंजियां. अगर यह विकल्प नहीं दिया गया है, तो वैल्यू को कुंजियों के तौर पर इस्तेमाल किया जाता है. कुंजियों में सिर्फ़ एक ऐक्सिस के साथ कई एलिमेंट हो सकते हैं. इससे यह तय होता है कि किस दिशा में क्रम से लगाना है. |
जब तक कुछ अलग से न बताया जाए, तब तक इस पेज की सामग्री को Creative Commons Attribution 4.0 License के तहत और कोड के नमूनों को Apache 2.0 License के तहत लाइसेंस मिला है. ज़्यादा जानकारी के लिए, Google Developers साइट नीतियां देखें. Oracle और/या इससे जुड़ी हुई कंपनियों का, Java एक रजिस्टर किया हुआ ट्रेडमार्क है.
आखिरी बार 2025-07-26 (UTC) को अपडेट किया गया.
[null,null,["आखिरी बार 2025-07-26 (UTC) को अपडेट किया गया."],[[["\u003cp\u003eThe \u003ccode\u003esort\u003c/code\u003e method arranges elements within an array along a single axis.\u003c/p\u003e\n"],["\u003cp\u003eBy default, \u003ccode\u003esort\u003c/code\u003e uses the array values for sorting; however, optional \u003ccode\u003ekeys\u003c/code\u003e can be specified for customized sorting based on another array with matching dimensions.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003ekeys\u003c/code\u003e array must have multiple elements along only one axis to determine the sort direction.\u003c/p\u003e\n"],["\u003cp\u003eThe modified array, with elements sorted according to the specified logic, is returned by the \u003ccode\u003esort\u003c/code\u003e method.\u003c/p\u003e\n"]]],[],null,["# ee.Array.sort\n\nSorts elements of the array along one axis.\n\n\u003cbr /\u003e\n\n| Usage | Returns |\n|------------------------|---------|\n| Array.sort`(`*keys*`)` | Array |\n\n| Argument | Type | Details |\n|---------------|----------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| this: `array` | Array | Array image to sort. |\n| `keys` | Array, default: null | Optional keys to sort by. If not provided, the values are used as the keys. The keys can only have multiple elements along one axis, which determines the direction to sort in. |"]]