Mathematica > Mathematics and Algorithms > Matrices and Linear Algebra > Constructing Matrices >

ConstantArray

Updated In 7 Graphic
ConstantArray[c, n]
generates a list of n copies of the element c.
ConstantArray[c, {n1, n2, ...}]
generates an n_1xn_2x... array of nested lists containing copies of the element c.
New in 6 | Last modified in 7
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team