what if there is a member in the item structure someItem and how to assign a value to it if it is type 1 of the list structure? I have 2 structures

struct list { DWORD Count; char treeItem[9]; }; struct item { list someItem[9]; int num; }; item itemOne; itemOne.num= 1; // Как присвоить simeItem тип list??? itemOne.someItem=; ////////////////////////////////////////// // Работает, все отлично list Neewlist; Neewlist.Count = 5; strcpy(Neewlist.treeItem ,"12345678"); 
  • No, you also wrote in the previous question that arrays in C ++ can not be assigned. Use ::std::array or a function of type ::std::memcpy . Or initialize immediately upon creation. - VTT
  • one
    Nothing is clear. Bother to express yourself more clearly. What and where are you going to assign? You have an array there. What are you going to fill the array? - AnT
  • It is impossible to assign something to the whole array at once, but it is possible for a separate element. So something like this: itemOne.someItem[i] = {...}; . - HolyBlackCat

0