Răspunsuri

2014-05-07T22:28:08+03:00
#include<iostream>
using namespace std;
int main(){ int v[100],i,x,n,S;
cout<<"n=";cin>>n;
for(i=1;i<=n;i++){

cout<<"v["<<i<<"]=";
 
 cin>>v[i];

}
for(i=1;i<=n;i++){
S=0;
x=v[i];
while(x!=0){
S=S+x%10;
x=x/10;

}

if(S%2==0){
cout<<v[i]<<" ";
break;
}
}
return 0;
}