fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4.  
  5. int i=1;
  6. char c = 'c';
  7. float f = 1.0;
  8.  
  9. void* p = &i;
  10. printf("%d\n",*(int*)p);
  11. p = &c;
  12. printf("%c\n",*(char*)p);
  13. p = &f;
  14. printf("%f\n",*(float*)p);
  15. return 0;
  16. }
Success #stdin #stdout 0s 3412KB
stdin
Standard input is empty
stdout
1
c
1.000000