// The correct answer is that this is an opportunity to learn typedef. :)
#include <stdio.h>
void apple() { printf("apple\n"); }
typedef void op();
// And that a function expression evaluates to a pointer to that function.
op *iapple() { return apple; }
typedef op *iop();
// So we don't need those &s.
iop *ops[] = { iapple };
// Hurrah.
int main() {
ops[0]()();
}
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Discussion on: Types in C: The void (*(*[])())()
For further actions, you may consider blocking this person and/or reporting abuse