⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 algorith.html

📁 ST20 Embedded Toolset R2.0.5用于开发基于ST20芯片机顶盒软件的开发平台,2.0.5版本,国内找不到的.在国外论坛上花了N天才找到!
💻 HTML
📖 第 1 页 / 共 5 页
字号:
    void <B><A HREF="#inplace_merge">inplace_merge</A></B>(BidIt first, BidIt mid,        BidIt last, Pr pred);template&lt;class InIt1, class InIt2&gt;    bool <B><A HREF="#includes">includes</A></B>(InIt1 first1, InIt1 last1,        InIt2 first2, InIt2 last2);template&lt;class InIt1, class InIt2, class Pr&gt;    bool <B><A HREF="#includes">includes</A></B>(InIt1 first1, InIt1 last1,        InIt2 first2, InIt2 last2, Pr pred);template&lt;class InIt1, class InIt2, class OutIt&gt;    OutIt <B><A HREF="#set_union">set_union</A></B>(InIt1 first1, InIt1 last1,        InIt2 first2, InIt2 last2, OutIt dest);template&lt;class InIt1, class InIt2, class OutIt,    class Pr&gt;    OutIt <B><A HREF="#set_union">set_union</A></B>(InIt1 first1, InIt1 last1,        InIt2 first2, InIt2 last2, OutIt dest, Pr pred);template&lt;class InIt1, class InIt2, class OutIt&gt;    OutIt <B><A HREF="#set_intersection">set_intersection</A></B>(InIt1 first1, InIt1 last1,        InIt2 first2, InIt2 last2, OutIt dest);template&lt;class InIt1, class InIt2, class OutIt,    class Pr&gt;    OutIt <B><A HREF="#set_intersection">set_intersection</A></B>(InIt1 first1, InIt1 last1,        InIt2 first2, InIt2 last2, OutIt dest, Pr pred);template&lt;class InIt1, class InIt2, class OutIt&gt;    OutIt <B><A HREF="#set_difference">set_difference</A></B>(InIt1 first1, InIt1 last1,        InIt2 first2, InIt2 last2, OutIt dest);template&lt;class InIt1, class InIt2, class OutIt,    class Pr&gt;    OutIt <B><A HREF="#set_difference">set_difference</A></B>(InIt1 first1, InIt1 last1,        InIt2 first2, InIt2 last2, OutIt dest, Pr pred);template&lt;class InIt1, class InIt2, class OutIt&gt;    OutIt <B><A HREF="#set_symmetric_difference">set_symmetric_difference</A></B>(InIt1 first1,        InIt1 last1, InIt2 first2, InIt2 last2, OutIt dest);template&lt;class InIt1, class InIt2, class OutIt,    class Pr&gt;    OutIt <B><A HREF="#set_symmetric_difference">set_symmetric_difference</A></B>(InIt1 first1,        InIt1 last1, InIt2 first2, InIt2 last2, OutIt dest,            Pr pred);template&lt;class RanIt&gt;    void <B><A HREF="#push_heap">push_heap</A></B>(RanIt first, RanIt last);template&lt;class RanIt, class Pr&gt;    void <B><A HREF="#push_heap">push_heap</A></B>(RanIt first, RanIt last, Pr pred);template&lt;class RanIt&gt;    void <B><A HREF="#pop_heap">pop_heap</A></B>(RanIt first, RanIt last);template&lt;class RanIt, class Pr&gt;    void <B><A HREF="#pop_heap">pop_heap</A></B>(RanIt first, RanIt last, Pr pred);template&lt;class RanIt&gt;    void <B><A HREF="#make_heap">make_heap</A></B>(RanIt first, RanIt last);template&lt;class RanIt, class Pr&gt;    void <B><A HREF="#make_heap">make_heap</A></B>(RanIt first, RanIt last, Pr pred);template&lt;class RanIt&gt;    void <B><A HREF="#sort_heap">sort_heap</A></B>(RanIt first, RanIt last);template&lt;class RanIt, class Pr&gt;    void <B><A HREF="#sort_heap">sort_heap</A></B>(RanIt first, RanIt last, Pr pred);template&lt;class Ty&gt;    const Ty&amp; <B><A HREF="#max">max</A></B>(const Ty&amp; left, const Ty&amp; right);template&lt;class Ty, class Pr&gt;    const Ty&amp; <B><A HREF="#max">max</A></B>(const Ty&amp; left, const Ty&amp; right, Pr pred);template&lt;class Ty&gt;    const Ty&amp; <B><A HREF="#min">min</A></B>(const Ty&amp; left, const Ty&amp; right);template&lt;class Ty, class Pr&gt;    const Ty&amp; <B><A HREF="#min">min</A></B>(const Ty&amp; left, const Ty&amp; right, Pr pred);template&lt;class FwdIt&gt;    FwdIt <B><A HREF="#max_element">max_element</A></B>(FwdIt first, FwdIt last);template&lt;class FwdIt, class Pr&gt;    FwdIt <B><A HREF="#max_element">max_element</A></B>(FwdIt first, FwdIt last, Pr pred);template&lt;class FwdIt&gt;    FwdIt <B><A HREF="#min_element">min_element</A></B>(FwdIt first, FwdIt last);template&lt;class FwdIt, class Pr&gt;    FwdIt <B><A HREF="#min_element">min_element</A></B>(FwdIt first, FwdIt last, Pr pred);template&lt;class InIt1, class InIt2&gt;    bool <B><A HREF="#lexicographical_compare">lexicographical_compare</A></B>(InIt1 first1,        InIt1 last1, InIt2 first2, InIt2 last2);template&lt;class InIt1, class InIt2, class Pr&gt;    bool <B><A HREF="#lexicographical_compare">lexicographical_compare</A></B>(InIt1 first1,        InIt1 last1, InIt2 first2, InIt2 last2, Pr pred);template&lt;class BidIt&gt;    bool <B><A HREF="#next_permutation">next_permutation</A></B>(BidIt first, BidIt last);template&lt;class BidIt, class Pr&gt;    bool <B><A HREF="#next_permutation">next_permutation</A></B>(BidIt first, BidIt last,        Pr pred);template&lt;class BidIt&gt;    bool <B><A HREF="#prev_permutation">prev_permutation</A></B>(BidIt first, BidIt last);template&lt;class BidIt, class Pr&gt;    bool <B><A HREF="#prev_permutation">prev_permutation</A></B>(BidIt first, BidIt last,        Pr pred);    };</PRE><H2><A NAME="adjacent_find"><CODE>adjacent_find</CODE></A></H2><PRE>template&lt;class FwdIt&gt;    FwdIt <B>adjacent_find</B>(FwdIt first, FwdIt last);template&lt;class FwdIt, class Pr&gt;    FwdIt <B>adjacent_find</B>(FwdIt first, FwdIt last, Pr pred);</PRE><P>The first template function determines the lowest <CODE>N</CODE>in the range <CODE>[0, last - first)</CODE> for which<CODE>N + 1 &lt; last - first</CODE> and the predicate<CODE>*(first + N) == *(first + N + 1)</CODE> is true.Here, <CODE>operator==</CODE> must perform a<A HREF="lib_stl.html#pairwise comparison">pairwise comparison</A>between its operands.It then returns <CODE>first + N</CODE>.If no such value exists, the function returns <CODE>last</CODE>.If the sequence contains fewer than two elements, the functionnever evaluates the predicate. Otherwise, if it returns<CODE>last</CODE>, it evaluates the predicate exactly<CODE>last - first - 1</CODE> times. Otherwise,it evaluates the predicate exactly <CODE>N + 1</CODE> times.</P><P>The second template function behaves the same, except thatthe predicate is <CODE>pred(*(first + N), *(first + N + 1))</CODE>.</P><H2><A NAME="binary_search"><CODE>binary_search</CODE></A></H2><PRE>template&lt;class FwdIt, class Ty&gt;    bool <B>binary_search</B>(FwdIt first, FwdIt last,        const Ty&amp; val);template&lt;class FwdIt, class Ty, class Pr&gt;    bool <B>binary_search</B>(FwdIt first, FwdIt last,        const Ty&amp; val, Pr pred);</PRE><P>The first template function determines whethera value of <CODE>N</CODE> existsin the range <CODE>[0, last - first)</CODE> for which<CODE>*(first + N)</CODE> has<A HREF="lib_stl.html#equivalent ordering">equivalent ordering</A>to <CODE>val</CODE>, where the elements designated by iteratorsin the range <CODE>[first, last)</CODE> form a sequence<A HREF="lib_stl.html#sequence ordering">ordered by</A> <CODE>operator&lt;</CODE>.If so, the function returns true.If no such value exists, it returns false.</P><P>Yhe function evaluates the ordering predicate <CODE>X &lt; Y</CODE> at most<CODE>ceil(log(last - first)) + 2</CODE> times.</P><P>The second template function behaves the same, except thatit replaces <CODE>operator&lt;(X, Y)</CODE> with<CODE>pred(X, Y)</CODE>.</P><H2><A NAME="copy"><CODE>copy</CODE></A></H2><PRE>template&lt;class InIt, class OutIt&gt;    OutIt <B>copy</B>(InIt first, InIt last, OutIt dest);</PRE><P>The template function evaluates <CODE>*(dest + N) = *(first + N))</CODE>once for each <CODE>N</CODE> in the range <CODE>[0, last - first)</CODE>,for strictly increasing values of <CODE>N</CODE> beginning withthe lowest value. It then returns <CODE>dest + N</CODE>.If <CODE>dest</CODE> and <CODE>first</CODE> designate regions of storage,<CODE>dest</CODE> must not be in the range <CODE>[first, last)</CODE>.</P><H2><A NAME="copy_backward"><CODE>copy_backward</CODE></A></H2><PRE>template&lt;class BidIt1, class BidIt2&gt;    BidIt2 <B>copy_backward</B>(BidIt1 first, BidIt1 last,        BidIt2 dest);</PRE><P>The template function evaluates<CODE>*(dest - N - 1) = *(last - N - 1))</CODE> once foreach <CODE>N</CODE> in the range <CODE>[0, last - first)</CODE>,for strictly oncreasing values of <CODE>N</CODE> beginning withthe lowest value. It then returns <CODE>dest - (last - first)</CODE>.If <CODE>dest</CODE> and <CODE>first</CODE> designate regions of storage,<CODE>dest</CODE> must not be in the range <CODE>[first, last)</CODE>.</P><H2><A NAME="count"><CODE>count</CODE></A></H2><PRE>template&lt;class InIt, class Ty&gt;    typename iterator_traits&lt;InIt&gt;::difference_type        <B>count</B>(InIt first, InIt last, const Ty&amp; val);</PRE><P>The template function sets a count <CODE>count</CODE> to zero. It thenexecutes <CODE>++count</CODE> foreach <CODE>N</CODE> in the range <CODE>[0, last - first)</CODE>for which the predicate <CODE>*(first + N) == val</CODE> is true.Here, <CODE>operator==</CODE> must perform a<A HREF="lib_stl.html#pairwise comparison">pairwise comparison</A>between its operands.The function returns <CODE>count</CODE>.It evaluates the predicate exactly <CODE>last - first</CODE> times.</P><H2><A NAME="count_if"><CODE>count_if</CODE></A></H2><PRE>template&lt;class InIt, class Pr, class Dist&gt;    typename iterator_traits&lt;InIt&gt;::difference_type        <B>count_if</B>(InIt first, InIt last,            Pr pred);</PRE><P>The template function sets a count <CODE>count</CODE> to zero. It thenexecutes <CODE>++count</CODE> foreach <CODE>N</CODE> in the range <CODE>[0, last - first)</CODE>for which the predicate <CODE>pred(*(first + N))</CODE> is true.The function returns <CODE>count</CODE>.It evaluates the predicate exactly <CODE>last - first</CODE> times.</P><H2><A NAME="equal"><CODE>equal</CODE></A></H2><PRE>template&lt;class InIt1, class InIt2&gt;    bool <B>equal</B>(InIt1 first1, InIt1 last1, InIt2 first2);template&lt;class InIt1, class InIt2, class Pr&gt;    bool <B>equal</B>(InIt1 first1, InIt1 last1, InIt2 first2, Pr pred);</PRE><P>The first template function returns true only if, foreach <CODE>N</CODE> in the range <CODE>[0, last1 - first1)</CODE>,the predicate <CODE>*(first1 + N) == *(first2 + N)</CODE> is true.Here, <CODE>operator==</CODE> must perform a<A HREF="lib_stl.html#pairwise comparison">pairwise comparison</A>between its operands.The function evaluates the predicate at most oncefor each <CODE>N</CODE>.</P><P>The second template function behaves the same, except thatthe predicate is <CODE>pred(*(first1 + N), *(first2 + N))</CODE>.</P><H2><A NAME="equal_range"><CODE>equal_range</CODE></A></H2><PRE>template&lt;class FwdIt, class Ty&gt;    pair&lt;FwdIt, FwdIt&gt; <B>equal_range</B>(FwdIt first,        FwdIt last, const Ty&amp; val);template&lt;class FwdIt, class Ty, class Pr&gt;    pair&lt;FwdIt, FwdIt&gt; <B>equal_range</B>(FwdIt first,        FwdIt last, const Ty&amp; val, Pr pred);</PRE><P>The first template function effectively returns<CODE><A HREF="utility.html#pair">pair</A>(<A HREF="#lower_bound">lower_bound</A>(first, last, val),<A HREF="#upper_bound">upper_bound</A>(first, last, val))</CODE>,where the elements designated by iteratorsin the range <CODE>[first, last)</CODE> form a sequence<A HREF="lib_stl.html#sequence ordering">ordered by</A> <CODE>operator&lt;</CODE>.Thus, the function determines the largest range of positionsover which <CODE>val</CODE> can be inserted in the sequenceand still preserve its ordering.</P><P>The function evaluates the ordering predicate <CODE>X &lt; Y</CODE> at most<CODE>ceil(2 * log(last - first)) + 1</CODE>.</P><P>The second template function behaves the same, except thatit replaces <CODE>operator&lt;(X, Y)</CODE> with<CODE>pred(X, Y)</CODE>.</P><H2><A NAME="fill"><CODE>fill</CODE></A></H2><PRE>template&lt;class FwdIt, class Ty&gt;    void <B>fill</B>(FwdIt first, FwdIt last, const Ty&amp; val);</PRE><P>The template function evaluates <CODE>*(first + N) = val</CODE> once foreach <CODE>N</CODE> in the range <CODE>[0, last - first)</CODE>.</P><H2><A NAME="fill_n"><CODE>fill_n</CODE></A></H2><PRE>template&lt;class OutIt, class Diff, class Ty&gt;    void <B>fill_n</B>(OutIt first, Diff count, const Ty&amp; val);</PRE><P>The template function evaluates <CODE>*(first + N) = val</CODE> once foreach <CODE>N</CODE> in the range <CODE>[0, count)</CODE>.</P><H2><A NAME="find"><CODE>find</CODE></A></H2><PRE>template&lt;class InIt, class Ty&gt;    InIt <B>find</B>(InIt first, InIt last, const Ty&amp; val);</PRE><P>The template function determines the lowest value of <CODE>N</CODE>in the range <CODE>[0, last - first)</CODE> for which the predicate<CODE>*(first + N) == val</CODE> is true.Here, <CODE>operator==</CODE> must perform a<A HREF="lib_stl.html#pairwise comparison">pairwise comparison</A>between its operands.It then returns <CODE>first + N</CODE>.If no such value exists, the function returns <CODE>last</CODE>.It evaluates the predicate at most oncefor each <CODE>N</CODE>.</P><H2><A NAME="find_end"><CODE>find_end</CODE></A></H2><PRE>template&lt;class FwdIt1, class FwdIt2&gt;    FwdIt1 <B>find_end</B>(FwdIt1 first1, FwdIt1 last1,        FwdIt2 first2, FwdIt2 last2);template&lt;class FwdIt1, class FwdIt2, class Pr&gt;    FwdIt1 <B>find_end</B>(FwdIt1 first1, FwdIt1 last1,        FwdIt2 first2, FwdIt2 last2, Pr pred);</PRE><P>The first template function determines the highest value of<CODE>N</CODE> in the range <CODE>[0,last1 - first1 - (last2 - first2))</CODE>such that for each <CODE>M</CODE> in the range<CODE>[0, last2 - first2)</CODE>,the predicate <CODE>*(first1 + N + M) == *(first2 + N + M)</CODE> is true.Here, <CODE>operator==</CODE> must perform a<A HREF="lib_stl.html#pairwise comparison">pairwise comparison</A>between its operands.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -