Hi guys.
I am trying to access the element asd7 inside the innermost structure, here is my code:
#include <stdio.h>
int main()
{
struct asd
{
int asd;
struct asd1
{
int asd1;
struct asd6
{
int asd7;
}asd6;
}asd1;
}asd;
int asd10;
int asd11;
struct asd *ptr1;
struct asd1 *ptr2;
struct asd6 *ptr3;
asd.asd1.asd6.asd7=10;
printf("%d\n",asd.asd1.asd6.asd7);
}
The code is compiling but I am unable to run it - I am getting a segmentation fault. Any help would be great.
Thanks
The output is:
10
Exited: ExitFailure 3