40

I want to create a structure in C with initial values like:

typedef struct {
    int id = 0;
    char *name = "none";
} employee;

I know the above is not possible, is there any other way to do this?

chqrlie
  • 131,814
  • 10
  • 121
  • 189
Layla
  • 5,234
  • 15
  • 51
  • 66

0 Answers0