#include <stdio.h>
#include <stddef.h>
struct Elenco {
char uno;
short due;
int tre;
};
int main (int argc, char *argv[])
{
size_t offset
= offsetof (struct Elenco
, due
); printf ("Il membro \"due\" si trova %i byte dopo " "l'inizio della struttura.\n", offset);
return 0;
}
I2luY2x1ZGUgPHN0ZGlvLmg+CiNpbmNsdWRlIDxzdGRkZWYuaD4KCnN0cnVjdCBFbGVuY28gewogICAgY2hhciAgdW5vOwogICAgc2hvcnQgZHVlOwogICAgaW50ICAgdHJlOwp9OwoKaW50IG1haW4gKGludCBhcmdjLCBjaGFyICphcmd2W10pCnsKICAgIHNpemVfdCBvZmZzZXQgPSBvZmZzZXRvZiAoc3RydWN0IEVsZW5jbywgZHVlKTsKICAgIHByaW50ZiAoIklsIG1lbWJybyBcImR1ZVwiIHNpIHRyb3ZhICVpIGJ5dGUgZG9wbyAiCiAgICAgICAgICAgICJsJ2luaXppbyBkZWxsYSBzdHJ1dHR1cmEuXG4iLCBvZmZzZXQpOwogICAgcmV0dXJuIDA7Cn0K