Returns `true` if matrix has no rows and no columns, i.e. the matrix does not contain an element. # Example ``` use rustml::Matrix; let m = Matrix::fill(1, 2, 2); assert!(!m.empty()); let n = Matrix:: ::new(); assert!(n.empty()); ```
(&self)
| 326 | /// assert!(n.empty()); |
| 327 | /// ``` |
| 328 | pub fn empty(&self) -> bool { |
| 329 | self.rows() == 0 && self.cols() == 0 |
| 330 | } |
| 331 | |
| 332 | /// Creates a matrix with random values. |
| 333 | /// |
no test coverage detected