int computemax(double t[10], double i);//function prototype
int computemin(double t[10], double i);
int computesum(double t[10], double i);
void odd_even(double t[10], double i);
int main()
{
//Declare variables
ofstream fout("output.txt");
int t[10];//the array
int i;//the loop
srand((unsigned)time(0));
//Assign value to array t
for(i=0; i<10; ++i)
{
//int random_integer = rand();//produce random number
t[i] = rand();//random_integer;
fout << t[i] << endl;
}
fout.close();
return 0;
}
int computemax(double t[10], double i)//Function header
{
int max=0;
for(i=0; i<10; ++i)
{
if(max>t[i])
max=t[i];
}
return max;
}//end function
int computemin(double t[10], double i)//function header
{
int min=0;
for(int i=0; i<10; ++i)
{
if(min<t[i])
min=t[i];
}
return min;
}//end function
int computesum(double t[10], double i)
{
int sum=0;
for(i=0; i<10; ++i)
{
sum=sum + t[i];
}
return sum;
}//end of function