C array declaration and assignment?

前端 未结 7 1542
囚心锁ツ
囚心锁ツ 2020-11-29 07:59

I\'ve asked a similar question on structs here but I\'m trying to figure out how C handles things like assigning variables and why it isn\'t allowed to assign them to eachot

7条回答
  •  被撕碎了的回忆
    2020-11-29 08:20

    In order to assign arrays you will have to assign the values inside the array.

    ie. x=y is equivalent to

    for(int i = 0; i < 10 < ++i)
    {
    x[i] = y[i];
    }
    

提交回复
热议问题