What's the difference between {} and [] in MATLAB?

前端 未结 5 456
清酒与你
清酒与你 2021-01-03 03:57
>> A={1 2;2 3}

A = 

    [1]    [2]
    [2]    [3]
>> A=[1 2;2 3]

A =

     1     2
     2     3

It seems to me they are essentially

5条回答
  •  南方客
    南方客 (楼主)
    2021-01-03 04:00

    If you relate it to object oriented programming, cells {} are like objects and [] is for arrays

提交回复
热议问题