This project is closed and read-only.
Bug #1515 ยป matrix-square.patch
| lib/matrix.rb (working copy) | ||
|---|---|---|
|
end
|
||
|
#
|
||
|
# Returns +true+ is this is a square matrix. See note in column_size about this
|
||
|
# being unreliable, though.
|
||
|
# Returns +true+ is this is a square matrix.
|
||
|
#
|
||
|
def square?
|
||
|
column_size == row_size
|
||
|
@rows.all?{|row| row.size == @rows.size}
|
||
|
end
|
||
|
#--
|
||