我有結構和功能,我要指派一個陣列poiner在我的結構的指針:分配二維數組ç
struct
{
int array[3][2]
}some_struct;
void example(some_struct* st, int array[3][2])
{
//st->array=array
//st->array[0]=array[0],st->array[1]=array[1],st->array[2]=array[2]
// how to do that ??
}
你想讓'st-> array'指向''array'還是你想將'array'的值複製到'st-> array'? –