fork download
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5. int a = 100;
  6. double b = (float)a; // c-cast a->float
  7. unsigned char const * c = (unsigned char const *)(a); // c-cast 100->pointer
  8. unsigned char * d = (unsigned char *)c; // c-cast const -> non-const
  9. printf("%d, %f, %x, %x", a, b, c, d);
  10. return 0;
  11. }
Success #stdin #stdout 0.02s 1676KB
stdin
Standard input is empty
stdout
100, 100.000000, 64, 64