14.9.7 String equality operators
来源:互联网 发布:互联网商业模式知乎 编辑:程序博客网 时间:2024/06/03 23:01
The predefined string equality operators are:
bool operator ==(string x, string y);
bool operator !=(string x, string y);
Two string values are considered equal when one of the following is true:
?Both values are null.
?Both values are non-null references to string instances that have
identical lengths and identical
characters in each character position.
The string equality operators compare string values rather than string
references. When two separate string
instances contain the exact same sequence of characters, the values of the
strings are equal, but the
references are different. [Note: As described in ?4.9.6, the reference
type equality operators can be used to
compare string references instead of string values. end note]
bool operator ==(string x, string y);
bool operator !=(string x, string y);
Two string values are considered equal when one of the following is true:
?Both values are null.
?Both values are non-null references to string instances that have
identical lengths and identical
characters in each character position.
The string equality operators compare string values rather than string
references. When two separate string
instances contain the exact same sequence of characters, the values of the
strings are equal, but the
references are different. [Note: As described in ?4.9.6, the reference
type equality operators can be used to
compare string references instead of string values. end note]
- 14.9.7 String equality operators
- 14.9.4 Boolean equality operators
- 14.9.8 Delegate equality operators
- 14.9.6 Reference type equality operators
- Python中的 equality operators
- Equality
- String comparision Operators
- Variable Mangling in Bash with String Operators
- String Operators 字符串 oracle/mssql 对比
- Operators
- Operators
- Operators
- Operators
- Java String compare to determine Equality(Java String类型比较的三种方法)
- 14.9 Relational & type-testing operators
- 14.9.1 Integer comparison operators
- 14.9.3 Decimal comparison operators
- 14.9.5 Enumeration comparison operators
- 14.9.2 Floating-point comparison operators
- 14.9.3 Decimal comparison operators
- 14.9.4 Boolean equality operators
- 14.9.5 Enumeration comparison operators
- 14.9.6 Reference type equality operators
- 14.9.7 String equality operators
- 14.9.8 Delegate equality operators
- 14.9.9 The is operator
- 14.9.10 The as operator
- 14.10 Logical operators
- 14.11 Conditional logical operators
- 当Spring遇到Ruby
- ASP源码现阶段最好的保护方案软件特点:无需改动原网站代码,无需写成DLL。加解快速方便。加密后的密文能法解密。
- 图片等比例截取