structure-packing

    35El calor

    4Respuesta

    Duplicar posibles: Why isn’t sizeof for a struct equal to the sum of sizeof of each member? Consideremos el siguiente código C: #include <stdio.h> struct employee { int id; char name[30]

    18El calor

    9Respuesta

    Cuando corro sólo el fragmento de código int *t; std::cout << sizeof(char) << std::endl; std::cout << sizeof(double) << std::endl; std::cout << sizeof(int) << std::endl; std::cout << sizeof(t) <<