MAKEARRAY

MAKEARRAY(rows, cols, lambda(row, col))

Returns the array calculated by applying a LAMBDA function.

rowsThe number of rows in the array.
colsThe number of columns in the array.
lambdaA nested LAMBDA function that takes two parameters.
rowThe row index of the array.
colThe column index of the array.

REMARKS
* This function was added in Microsoft 365.
* This function can create a Dynamic Array Formula.
* This function uses the LAMBDA function.
* This LAMBDA function must take two parameters.
* The parameter names must not contain any numbers.
* If "row" < 1, then #VALUE! is returned.
* If "col" < 1, then #VALUE! is returned.
* This function was released in July 2021.
* For the Microsoft documentation refer to support.microsoft.com
* For the Google documentation refer to support.google.com

 A
1=MAKEARRAY(1, 1, LAMBDA(p_one, p_two, p_one)) = 1
2=MAKEARRAY(1, 1, LAMBDA(p_one, p_two, p_two)) = 1
3=MAKEARRAY(1, 1, LAMBDA(p_one, p_two, p_one+p_two)) = 2
4=MAKEARRAY(2, 2, LAMBDA(p_one, p_two, p_one*p_two)) = { 1, 2 ; 2, 4 }

1 - Create a 1x1 array using a formula that returns the row number.
2 - Create a 1x1 array using a formula that returns the column number.
3 - Create a 1x1 array using a formula that adds the row number and the column number together.
4 - Create a 2x2 array using a formula that multipies the row number and the column number together. The array that is returned is calculated from (1*1, 1*2 ; 2*1, 2*2).

© 2024 Better Solutions Limited. All Rights Reserved. © 2024 Better Solutions Limited Top