#include<iostream>
using namespace std;
void function_addition();
void function_subtraction();
void function_multiplication();
void function_division();
int main()
{
	void (*point_function[4])();
	point_function[0]=function_addition;
	point_function[1]=function_subtraction;
	point_function[2]=function_multiplication;
	point_function[3]=function_division;
	int i;
	while(1)
	{
	    cout<<"put the i"<<endl;
	    cout<<"0--addition#1--subtraction#2--multiplication#3--division#10--end"<<endl;
	    cin>>i;
	    if(i==10)
	    {
	        return 0;
	    }
	    point_function[i]();
	}
	return 0;
}
void function_addition()
{
	cout<<"this is addition:"<<endl<<"put two num"<<endl;
	double a,b;
	cin>>a>>b;
	cout<<a+b<<endl<<endl;
}
void function_subtraction()
{
	cout<<"this is subtraction:"<<endl<<"put two num"<<endl;
	double a,b;
	cin>>a>>b;
	cout<<a-b<<endl<<endl;
}
void function_multiplication()
{
	cout<<"this is multiplication:"<<endl<<"put two num"<<endl;
	double a,b;
	cin>>a>>b;
	cout<<a*b<<endl<<endl;
}
void function_division()
{
	cout<<"this is division:"<<endl<<"put two num"<<endl;
	double a,b;
	cin>>a>>b;
	cout<<a/b<<endl<<endl;
}

	
