operator==,!=,<,<=,>,>=(std::list)
来自cppreference.com
该页由英文版wiki使用Google Translate机器翻译而来。
该翻译可能存在错误或用词不当。鼠标停留在文本上可以看到原版本。你可以帮助我们修正错误或改进翻译。参见说明请点击这里. |
检查到模板循环:Template:include page
template< > bool operator==( list<>& lhs, |
(1) | |
template< > bool operator!=( list<>& lhs, |
(2) | |
template< > bool operator<( list<>& lhs, |
(3) | |
template< > bool operator<=( list<>& lhs, |
(4) | |
template< > bool operator>( list<>& lhs, |
(5) | |
template< > bool operator>=( list<>& lhs, |
(6) | |
比较两个容器的内容.....
原文:
Compares the contents of two containers.
1-2) Checks if the contents of
lhs
and rhs
are equal, that is, whether lhs.size() == rhs.size() and each element in lhs
has equivalent element in rhs
at the same position.3-6)
比较的内容
lhs
rhs
字典。在执行比较的功能相当于std::lexicographical_compare.原文:
Compares the contents of
lhs
and rhs
lexicographically. The comparison is performed by a function equivalent to std::lexicographical_compare.[编辑] 参数
lhs, rhs | - | 容器中的内容进行比较
原文: containers whose contents to compare |
[编辑] 返回值
1)true的容器中的内容是否是等效,false否则
2) 原文:
true if the contents of the containers are equivalent, false otherwise
true如果容器的内容是不等价的,false否则
3) 原文:
true if the contents of the containers are not equivalent, false otherwise
true如果内容的
4) lhs
字典“小于”比内容rhs
,false否则原文:
true if the contents of the
lhs
are lexicographically less than the contents of rhs
, false otherwisetrue如果内容的
5) lhs
字典“小于”或“等于”的内容rhs
,false否则原文:
true if the contents of the
lhs
are lexicographically less than or equal the contents of rhs
, false otherwisetrue如果内容的
6) lhs
字典“更大”比内容rhs
,false否则原文:
true if the contents of the
lhs
are lexicographically greater than the contents of rhs
, false otherwisetrue如果内容的
lhs
字典“更大”大于或“等于”的内容rhs
,false否则原文:
true if the contents of the
lhs
are lexicographically greater than or equal the contents of rhs
, false otherwise[编辑] 复杂性
线性大小的容器