#include <stdio.h>
#include <stdlib.h>
int main (void) {
typedef union _Conversor
{
unsigned int inicial; //Valor que vai armazenar
unsigned char leitor[4];//Para ler todos os bytes unsigned int tem 4 em windows e linux
}Conversor;
Conversor conv;
conv.inicial = 0xCE87;//Valor random
printf("%02X %02X %02X %02X\n", conv.
leitor[0], conv.
leitor[1], conv.
leitor[2], conv.
leitor[3]);
return 0;
}
I2luY2x1ZGUgPHN0ZGlvLmg+CiNpbmNsdWRlIDxzdGRsaWIuaD4KCmludCBtYWluICh2b2lkKSB7CgogICB0eXBlZGVmIHVuaW9uIF9Db252ZXJzb3IKICAgewoJICAgdW5zaWduZWQgaW50IGluaWNpYWw7IC8vVmFsb3IgcXVlIHZhaSBhcm1hemVuYXIKCSAgIHVuc2lnbmVkIGNoYXIgbGVpdG9yWzRdOy8vUGFyYSBsZXIgdG9kb3Mgb3MgYnl0ZXMgdW5zaWduZWQgaW50IHRlbSA0IGVtIHdpbmRvd3MgZSBsaW51eAoJfUNvbnZlcnNvcjsKCQoJQ29udmVyc29yIGNvbnY7Cgljb252LmluaWNpYWwgPSAweENFODc7Ly9WYWxvciByYW5kb20KCXByaW50ZigiJTAyWCAlMDJYICUwMlggJTAyWFxuIiwgY29udi5sZWl0b3JbMF0sIGNvbnYubGVpdG9yWzFdLCBjb252LmxlaXRvclsyXSwgY29udi5sZWl0b3JbM10pOwoJCgkKCXJldHVybiAwOwkKfQ==