ColumnAt function
Fully qualified name: Std.Arrays.ColumnAt
Q#
function ColumnAt<'T>(column : Int, matrix : 'T[][]) : 'T[]
Extracts a column from a matrix.
This function extracts a column in a matrix in row-wise order. Extracting a row corresponds to element access of the first index and therefore requires no further treatment.
The type of each element of matrix
.
Column of the matrix
2-dimensional matrix in row-wise order
Q#
let matrix = [[1, 2, 3], [4, 5, 6], [7, 8, 9]];
let column = ColumnAt(0, matrix);
// same as: column = [1, 4, 7]