#include <iostream>
#include "stdio.h"
using namespace std;
void fun1(){
cout<<"1"<<endl;
}
void fun2(){
cout<<"2"<<endl;
}
void fun3(){
cout<<"3"<<endl;
}
void fun4(){
cout<<"4"<<endl;
}
int main(){
void (*f1[4])();
f1[0] = &fun1;
f1[1] = &fun2;
f1[2] = &fun3;
f1[3] = &fun4;
(*(f1 + sizeof(f1)/sizeof(f1[0]) - 1))();
}