1 solutions

  • 0
    @ 2024-12-11 16:23:42
    #include <bits/stdc++.h>
    using namespace std;
    int n, x, ans=0;
    int main()
    {
    	cin >> n;
    	for(int i = 1; i <= n; i++)
    	{
    		cin >> x;
    		if(x%2==0)
    		{
    			ans+=x;
    		}
    	}
    	cout << ans;
    	
    	
    	return 0;
    }
    
    • 1

    Information

    ID
    62
    Time
    1000ms
    Memory
    64MiB
    Difficulty
    10
    Tags
    # Submissions
    4
    Accepted
    1
    Uploaded By