1)#include<iostream>
using namespace std;
int main()
{
cin n, suma=0;;
cin>>n;
while(n!=0)
{
if(n%2==0)
{
suma=suma+n;
}
cin>>n;
}
cout<<suma;
return 0;
}
2)#include <iostream>
using namespace std;
int main()
{
int n, v[255], mare=0, p=0;
cin>>n;
while(n!=0)
{
p=p+1
v[p]=n;
cin>>n;
}
for( int i=1; i<=p; i++)
{
if ( v[i] > mare )
{
mare=v[i];
}
}
cout<<mare;
return 0;
}
3)#include<iostream>
using namespace std;
int main()
{
int n, v[255], suma=0;
cin >>n ;
for(int i=1; i<=n; i++)
{
cin >> v[i];
if(v[i]%3==0)
{
suma=suma+v[i];
}
}
cout<<suma;
return 0;
}