Professional Documents
Culture Documents
How To Make Sequential Value: 10,20,30,40,50
How To Make Sequential Value: 10,20,30,40,50
int main ()
{
num (10,50);
}
////OR////
#include <iostream>
using namespace std;
int main()
{
cout << "10,20,30,40,50,60,70";
return 0;
}
2. HOW TO FIND THE MINIMUM AND MAXIMUM VALUE IN THE MATRIX USING C++
#include<iostream>
int m,n,a[10][10],i,j,high,low;
cout<<"\nEnter how many Rows and coloumns Sequentially (Hit the enter for the
next step):";
cin>>m>>n;
cout<<"\nEnter matrix:\n";
for(i=0;i<m;++i)
for(j=0;j<n;++j)
cin>>a[i][j];
high=a[0][0];
low=a[0][0];
for(i=0;i<m;++i)
{
for(j=0;j<n;++j)
if(a[i][j]>high)
high=a[i][j];
else
if(a[i][j]<low)
low=a[i][j];
return 0;
int main()
{
int n, i;
float num[1000], sum=0.0, average;
average = sum / n;
cout << "Average = " << average;
return 0;
}