
Patrick B. answered 09/30/20
Math and computer tutor/teacher
using namespace std;
#include <iostream>
int main()
{
int N=-1;
while (N<3)
{
cout << " Input positive integer N :>";
cin >> N;
}
int x=2;
long sum=0;
while (x<N)
{
sum += x;
x+=2;
}
cout << sum << endl;
}