fork download
  1. // Online C compiler to run C program online
  2. #include <stdio.h>
  3. typedef unsigned int uint32;
  4. typedef unsigned char uint8;
  5.  
  6. #define Marker_Value 0x1234567890a0b0c0d
  7.  
  8. uint32 array[2];
  9. int main() {
  10. // Write C code here
  11. uint8 idx;
  12. array[0]=0x12345678;
  13. array[1]=0x0a0b0c0d;
  14.  
  15. uint8* pt8 =(uint8*)array;
  16.  
  17. for (idx=0;idx<8;idx++)
  18. {
  19. printf("\n The %d byte of Marker %x",idx,pt8[idx]);
  20. }
  21. printf("\nTry programiz.pro");
  22.  
  23. return 0;
  24. }
Success #stdin #stdout 0.01s 5292KB
stdin
123
stdout
 The 0 byte of Marker 78
 The 1 byte of Marker 56
 The 2 byte of Marker 34
 The 3 byte of Marker 12
 The 4 byte of Marker d
 The 5 byte of Marker c
 The 6 byte of Marker b
 The 7 byte of Marker a
Try programiz.pro