函数 equalText #
检查两个字符串的相等性。比较区分大小写。
对于矩阵,该函数逐元素求值。
Syntax #
math.equalText(x, y)
Parameters #
| Parameter | Type | Description |
|---|---|---|
x |
string | Array | DenseMatrix | 要比较的第一个字符串 |
y |
string | Array | DenseMatrix | 要比较的第二个字符串 |
Returns #
| Type | Description |
|---|---|
| number | Array | DenseMatrix | 如果值相等,则返回 true;否则返回 false。 |
Throws #
Type | Description —- | ———–
Examples #
math.equalText('Hello', 'Hello') // returns true
math.equalText('a', 'A') // returns false
math.equal('2e3', '2000') // returns true
math.equalText('2e3', '2000') // returns false
math.equalText('B', ['A', 'B', 'C']) // returns [false, true, false]