fork(3) download
#include <iostream>

using namespace std;
int d;
long int a,b;
int main()
{
    cin >> d;
    for (int i=1;i<=d;i++)
    {
        cin >> a >> b;
        for (int j=a+1;j<b;j++)
        {
            if (j%2==0) {cout<<j<<' ';}
        }
        cout << endl;
    }
    return 0;
}
Success #stdin #stdout 0s 15232KB
stdin
2
3 9
4 9
stdout
4 6 8 
6 8