#include <vector>
#include <utility>
#include <iostream>
#include <algorithm>
using namespace std;
int main()
{
vector<pair<int, int> > result;
for(int k = 0; k < 2; k++)
for(int i = -1; i < 2; i += 2)
for(int j = -1; j < 2; j+= 2)
result.push_back(make_pair(i * (k+1), j * (((k + 1) % 2) + 1)));
for(vector<pair<int, int> >::iterator it = result.begin(); it != result.end(); it++)
cout << "(" << it->first << ", " << it->second << ")" << endl;
return 0;
}
I2luY2x1ZGUgPHZlY3Rvcj4KI2luY2x1ZGUgPHV0aWxpdHk+CiNpbmNsdWRlIDxpb3N0cmVhbT4KI2luY2x1ZGUgPGFsZ29yaXRobT4KCnVzaW5nIG5hbWVzcGFjZSBzdGQ7CgppbnQgbWFpbigpCnsKICAgIHZlY3RvcjxwYWlyPGludCwgaW50PiA+IHJlc3VsdDsKICAgIGZvcihpbnQgayA9IDA7IGsgPCAyOyBrKyspCiAgICAgICAgZm9yKGludCBpID0gLTE7IGkgPCAyOyBpICs9IDIpCiAgICAgICAgICAgIGZvcihpbnQgaiA9IC0xOyBqIDwgMjsgais9IDIpCiAgICAgICAgICAgICAgICByZXN1bHQucHVzaF9iYWNrKG1ha2VfcGFpcihpICogKGsrMSksIGogKiAoKChrICsgMSkgJSAyKSArIDEpKSk7CiAgICAgICAgICAgICAgICAKICAgIGZvcih2ZWN0b3I8cGFpcjxpbnQsIGludD4gPjo6aXRlcmF0b3IgaXQgPSByZXN1bHQuYmVnaW4oKTsgaXQgIT0gcmVzdWx0LmVuZCgpOyBpdCsrKQogICAgICAgIGNvdXQgPDwgIigiIDw8IGl0LT5maXJzdCA8PCAiLCAiIDw8IGl0LT5zZWNvbmQgPDwgIikiIDw8IGVuZGw7CiAgICAgICAgCiAgICByZXR1cm4gMDsKfQo=