1 #include <stdio.h>
 2 #include <stdlib.h>
 3 struct MyStruct
 4 {
 5     int a;
 6     char b;
 7 
 8 };
 9 struct MyStruct hello[]=
10 {1,'a',2,'b'
11 
12 };
13 
14 
15 int main( ){
16     printf("%c",hello[0].b);
17     return(0);
18 
19 }

有没有怪怪的感觉 :

C结构体数组赋值

相关文章:

  • 2021-08-25
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-11-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案