Files
Paradise/datum/sort_instance.html

13 lines
2.4 KiB
HTML

<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><base href="../"><link rel="stylesheet" href="dmdoc.css"><title>/datum/sort_instance - Space Station 13</title></head><body><header><a href="index.html">Space Station 13</a> - <a href="index.html#modules">Modules</a> - <a href="index.html#types">Types</a><a href="datum/sort_instance.html#proc">Proc Details</a></header><main><h1>sort_instance <aside>/<a href="datum.html">datum</a>/<a href="datum/sort_instance.html">sort_instance</a></aside> <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/__HELPERS/sorts/__main.dm#L13"><img src="git.png" width="16" height="16" title="code/__HELPERS/sorts/__main.dm 13"></a></h1><table class="summary" cellspacing="0"><tr><td colspan="2"><h2>Procs</h2></td></tr><tr><th><a href="datum/sort_instance.html#proc/gallopRight">gallopRight</a></th><td>Like gallopLeft, except that if the range contains an element equal to
key, gallopRight returns the index after the rightmost equal element.</td></tr></table><h2 id="proc">Proc Details</h2><h3 id="proc/gallopRight"><aside class="declaration">proc </aside>gallopRight<aside>(key, base, len, hint) <a href="https://github.com/ParadiseSS13/Paradise/blob/8a8a00a2a9bec485351e5f219982b7315d3504fa/code/__HELPERS/sorts/__main.dm#L319"><img src="git.png" width="16" height="16" title="code/__HELPERS/sorts/__main.dm 319"></a></aside></h3><p>Like gallopLeft, except that if the range contains an element equal to
key, gallopRight returns the index after the rightmost equal element.</p>
<p>Returns the int <code>k</code>, <code>0 &lt;= k &lt;= n</code> such that <code>a[b + k - 1] &lt;= key &lt; a[b + k]</code>.</p>
<p>Arguments:</p>
<ul>
<li>key: the key whose insertion point to search for</li>
<li>a: the array in which to search</li>
<li>base: the index of the first element in the range</li>
<li>len: the length of the range; must be &gt; 0</li>
<li>hint: the index at which to begin the search, <code>0 &lt;= hint &lt; n</code>. The closer hint is to the result, the faster this method will run.</li>
<li>c: the comparator used to order the range, and to search</li>
</ul></main><footer>paradise.dme <a href="https://github.com/ParadiseSS13/Paradise/tree/8a8a00a2a9bec485351e5f219982b7315d3504fa">8a8a00a</a> (master) — <a href="https://github.com/SpaceManiac/SpacemanDMM/blob/master/crates/dmdoc/README.md">dmdoc 1.11.0</a></footer></body></html>