TF = isprime(X)
| Parameter | Description |
|---|---|
| X | a scalar, vector, or matrix of nonnegative integers. |
| Parameter | Description |
|---|---|
| TF | logical array, true where the corresponding element of X is a prime number. |
isprime returns a logical array the same size as X, containing true where the elements of X are prime numbers and false where they are not.
isprime([2 3 4 5 6 7 8 9 10 11])
| Version | Description |
|---|---|
| 2.0.0 | initial version |