#include <iostream>
#include <vector>
using namespace std;
int main ()
{
vector<int>t;
int val,i,n;
cout<<"Array Elements: ";
cin>>n;
for(i=0;i<n;i++)
{
cin>>val;
t.push_back(val);
}
for(i=0;i<10;i++)
cout<<t[i]<<endl;
return 0;
}
#include <vector>
using namespace std;
int main ()
{
vector<int>t;
int val,i,n;
cout<<"Array Elements: ";
cin>>n;
for(i=0;i<n;i++)
{
cin>>val;
t.push_back(val);
}
for(i=0;i<10;i++)
cout<<t[i]<<endl;
return 0;
}
No comments:
Post a Comment