Răspuns :
Răspuns:
#include <iostream>
using namespace std;
int main(){
int N, i;
cin >> N;
for(i = 2; i <= N; i++)
if(i % 2 == 0)
cout << i << " ";
return 0;
}
#include <iostream>
using namespace std;
int main()
{
int n,i;
cin>>n;
for(i=0;i<=n;i=i+2)
cout<<i<<" ";
return 0;
}