diff --git a/G-Structs-Unions/pokemon-demo/pokemon.c b/G-Structs-Unions/pokemon-demo/pokemon.c new file mode 100644 index 0000000..101fdbb --- /dev/null +++ b/G-Structs-Unions/pokemon-demo/pokemon.c @@ -0,0 +1,49 @@ +#include "stdio.h" + +struct Pokemon +{ + void (*speak)(); + int level; +}; + +void pikaspeak() +{ + printf("PIKA PIKA"); +} + +void squirtlespeak() +{ + printf("SQUUIIIRTLE!"); +} + +void jaespeak() +{ + printf("jae jae!"); +} + +void yell(struct Pokemon p) +{ + for(int i = 0; i