fork(1) download
  1. #include<stdio.h>
  2. #include<stdlib.h>
  3.  
  4. int main() {
  5. struct calendario {
  6. int dia;
  7. int mes;
  8. int ano;
  9. };
  10. struct calendario *ptr = malloc(sizeof(struct calendario));
  11. ptr->dia = 5;
  12. ptr->mes = 10;
  13. ptr->ano = 1990;
  14. printf("%i/%i/%i", ptr->dia, ptr->mes, ptr->ano);
  15. return 0;
  16. }
Success #stdin #stdout 0s 2244KB
stdin
Standard input is empty
stdout
5/10/1990